Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 19, 2009, 5:31:02 PM (15 years ago)
Author:
rgrieder
Message:

Merged all remaining revisions from core4 back to the trunk.

Location:
code/trunk
Files:
1 edited
1 copied

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/core/input/JoyStickQuantityListener.h

    r3276 r3327  
    4040namespace orxonox
    4141{
     42    //! Derive from this class to get informed when joy sticks get added/removed
    4243    class _CoreExport JoyStickQuantityListener : virtual public OrxonoxClass
    4344    {
    44     public:
     45        friend class InputManager;
     46    protected:
    4547        JoyStickQuantityListener();
    4648        virtual ~JoyStickQuantityListener() { }
    4749
    48         virtual void JoyStickQuantityChanged(unsigned int value) = 0;
     50        //! Returns a list with all JoySticks currently loaded
     51        const std::vector<JoyStick*>& getJoyStickList() const { return joyStickList_s; }
     52
     53    private:
     54        //! Called whenever joy sticks get added/removed
     55        virtual void JoyStickQuantityChanged(const std::vector<JoyStick*>& joyStickList) = 0;
     56
     57        static void changeJoyStickQuantity(const std::vector<JoyStick*>& joyStickList);
     58
     59        //! Static variable that holds the latest distributed information
     60        static std::vector<JoyStick*> joyStickList_s;
    4961    };
    5062}
Note: See TracChangeset for help on using the changeset viewer.