Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 30, 2012, 11:08:17 PM (12 years ago)
Author:
landauf
Message:

merged branch presentation2012merge back to trunk

Location:
code/trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/libraries/core/Super.h

    r8866 r9348  
    280280        SUPER_NOARGS(classname, functionname)
    281281
    282     #define SUPER_clone(classname, functionname, ...) \
    283         SUPER_ARGS(classname, functionname, __VA_ARGS__)
    284 
    285282    #define SUPER_changedCarrier(classname, functionname, ...) \
    286283        SUPER_NOARGS(classname, functionname)
     
    398395                    inline void operator()( SUPER_CALL_ARGUMENTS##hasarguments(__VA_ARGS__) ) \
    399396                    { \
    400                         (dynamic_cast<T*>(object))->T:: functionname
     397                        (orxonox_cast<T*>(object))->T:: functionname
    401398
    402399        /*
     
    508505                inline void operator()( SUPER_CALL_ARGUMENTS##hasarguments(__VA_ARGS__) )
    509506                {
    510                     (dynamic_cast<T*>(object))->T:: functionname ( Call the function with it's arguments );
     507                    (orxonox_cast<T*>(object))->T:: functionname ( Call the function with it's arguments );
    511508                }
    512509
     
    566563        SUPER_FUNCTION_GLOBAL_DECLARATION_PART2;
    567564
    568         SUPER_FUNCTION_GLOBAL_DECLARATION_PART1(11, clone, true, OrxonoxClass*& item)
    569             (item)
    570         SUPER_FUNCTION_GLOBAL_DECLARATION_PART2;
    571 
    572         SUPER_FUNCTION_GLOBAL_DECLARATION_PART1(12, changedCarrier, false)
    573             ()
    574         SUPER_FUNCTION_GLOBAL_DECLARATION_PART2;
    575 
    576         SUPER_FUNCTION_GLOBAL_DECLARATION_PART1(13, changedPickedUp, false)
     565        SUPER_FUNCTION_GLOBAL_DECLARATION_PART1(11, changedCarrier, false)
     566            ()
     567        SUPER_FUNCTION_GLOBAL_DECLARATION_PART2;
     568
     569        SUPER_FUNCTION_GLOBAL_DECLARATION_PART1(12, changedPickedUp, false)
    577570            ()
    578571        SUPER_FUNCTION_GLOBAL_DECLARATION_PART2;
     
    632625    SUPER_INTRUSIVE_DECLARATION(changedGametype);
    633626    SUPER_INTRUSIVE_DECLARATION(changedUsed);
    634     SUPER_INTRUSIVE_DECLARATION(clone);
    635627    SUPER_INTRUSIVE_DECLARATION(changedCarrier);
    636628    SUPER_INTRUSIVE_DECLARATION(changedPickedUp);
  • code/trunk/src/libraries/core/Template.cc

    r8858 r9348  
    149149        orxout(verbose, context::templates) << object->getLoaderIndentation() << " aplying Template \"" << this->getName() << "\"..." << endl;
    150150
     151        // check if the template is applied on an object of the right type
     152        Identifier* identifier = Identifier::getIdentifierByString(this->getXMLElement().Value());
     153        if (!object->getIdentifier()->isA(identifier))
     154            orxout(internal_warning, context::templates) << "Template was defined for " << identifier->getName() << " but the object is of type " << object->getIdentifier()->getName() << endl;
     155
    151156        Element temp = &const_cast<TiXmlElement&>(this->getXMLElement());
    152157
  • code/trunk/src/libraries/core/XMLPort.h

    r8858 r9348  
    197197        ClassIdentifier<classname>::getIdentifier()->addXMLPortParamContainer(paramname, containername); \
    198198    } \
    199     containername->port(dynamic_cast<BaseObject*>(this), object, xmlelement, mode)
     199    containername->port(orxonox_cast<BaseObject*>(this), object, xmlelement, mode)
    200200
    201201// --------------------
  • code/trunk/src/libraries/core/command/ConsoleCommand.cc

    r8858 r9348  
    594594        @param bPrintError If true, an error is printed if the command doesn't exist
    595595    */
    596     /* static */ const ConsoleCommand* ConsoleCommand::getCommand(const std::string& group, const std::string& name, bool bPrintError)
     596    /* static */ ConsoleCommand* ConsoleCommand::getCommand(const std::string& group, const std::string& name, bool bPrintError)
    597597    {
    598598        // find the group
     
    624624        @param bPrintError If true, an error is printed if the command doesn't exist
    625625    */
    626     /* static */ const ConsoleCommand* ConsoleCommand::getCommandLC(const std::string& group, const std::string& name, bool bPrintError)
     626    /* static */ ConsoleCommand* ConsoleCommand::getCommandLC(const std::string& group, const std::string& name, bool bPrintError)
    627627    {
    628628        std::string groupLC = getLowercase(group);
  • code/trunk/src/libraries/core/command/ConsoleCommand.h

    r8858 r9348  
    382382                public:
    383383                    /// Constructor: Creates a manipulator for a given ConsoleCommand.
    384                     ConsoleCommandManipulator(const ConsoleCommand* command) : command_(const_cast<ConsoleCommand*>(command)) {}
     384                    ConsoleCommandManipulator(ConsoleCommand* command) : command_(command) {}
    385385
    386386                    /// Changes the current function of the command. @param function The new function-pointer @param bForce If true, the new function-pointer is always assigned, even if the headers don't match
     
    619619
    620620            /// Returns a manipulator for this command.
    621             inline ConsoleCommandManipulator getManipulator() const
     621            inline ConsoleCommandManipulator getManipulator()
    622622                { return this; }
    623623
     
    667667
    668668            /// Returns a command (shortcut) with given name. @param name The name of the command shortcut @param bPrintError If true, an error is printed if the command doesn't exist
    669             static inline const ConsoleCommand* getCommand(const std::string& name, bool bPrintError = false)
     669            static inline ConsoleCommand* getCommand(const std::string& name, bool bPrintError = false)
    670670                { return ConsoleCommand::getCommand("", name, bPrintError); }
    671671            /// Returns a command (shortcut) with given name in lowercase. @param name The lowercase name of the command shortcut @param bPrintError If true, an error is printed if the command doesn't exist
    672             static inline const ConsoleCommand* getCommandLC(const std::string& name, bool bPrintError = false)
     672            static inline ConsoleCommand* getCommandLC(const std::string& name, bool bPrintError = false)
    673673                { return ConsoleCommand::getCommandLC("", name, bPrintError); }
    674674
    675             static const ConsoleCommand* getCommand(const std::string& group, const std::string& name, bool bPrintError = false);
    676             static const ConsoleCommand* getCommandLC(const std::string& group, const std::string& name, bool bPrintError = false);
     675            static ConsoleCommand* getCommand(const std::string& group, const std::string& name, bool bPrintError = false);
     676            static ConsoleCommand* getCommandLC(const std::string& group, const std::string& name, bool bPrintError = false);
    677677
    678678            static void destroyAll();
  • code/trunk/src/libraries/util/output/ConsoleWriter.cc

    • Property svn:eol-style set to native
Note: See TracChangeset for help on using the changeset viewer.