Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Mar 16, 2010, 11:22:36 AM (15 years ago)
Author:
rgrieder
Message:

Merged revisions 6430-6440 from the gamestate branch to the trunk.
This adds keybindings merging functionality.

(from log of r6437)
When running development builds, the keybinder will merge the local file and the one from the data folder.
Catch: if you want to remove a binding, you'll have to write "NoBinding" (not case sensitive) to override the default command

The keybind command already does that for you though.

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

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

    r6417 r6536  
    5252#include <cassert>
    5353#include "util/Singleton.h"
    54 
    55 #define AddLanguageEntry(label, fallbackstring) \
    56     orxonox::Language::getInstance().addEntry(label, fallbackstring)
    57 
    58 #define GetLocalisation(label) \
    59     orxonox::Language::getInstance().getLocalisation(label)
    60 
    6154
    6255namespace orxonox
     
    140133            static Language* singletonPtr_s;
    141134    };
     135
     136    //! Shortcut function for Language::addEntry
     137    inline void AddLanguageEntry(const LanguageEntryLabel& label, const std::string& fallbackString)
     138    {
     139        Language::getInstance().addEntry(label, fallbackString);
     140    }
     141
     142    //! Shortcut function for Language::getLocalisation
     143    inline const std::string& GetLocalisation(const LanguageEntryLabel& label)
     144    {
     145        return Language::getInstance().getLocalisation(label);
     146    }
    142147}
    143148
Note: See TracChangeset for help on using the changeset viewer.