Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 30, 2010, 7:52:33 PM (14 years ago)
Author:
landauf
Message:

pushFunction() (which explicitly adds a new level to the console command stack) was not forwarded to ConsoleCommandManipulator

also fixed a bug which was caused by pushFunction() with a subsequent call to setFunction(…) because it may have unexpectedly changed the functor of the lower stack levels. now pushFunction() not only copyconstructs the executor, but also the Functor (with a clone() function)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/consolecommands3/src/libraries/core/command/Functor.h

    r7242 r7270  
    8585        public:
    8686            virtual MultiType operator()(const MultiType& param1 = MT_Type::Null, const MultiType& param2 = MT_Type::Null, const MultiType& param3 = MT_Type::Null, const MultiType& param4 = MT_Type::Null, const MultiType& param5 = MT_Type::Null) = 0;
     87
     88            virtual FunctorPtr clone() = 0;
    8789
    8890            virtual Type::Enum getType() const = 0;
     
    269271            }
    270272
     273            FunctorPtr clone()
     274            {
     275                return new FunctorTemplate(*this);
     276            }
     277
    271278            void evaluateParam(unsigned int index, MultiType& param) const
    272279            {
Note: See TracChangeset for help on using the changeset viewer.