]> git.tdb.fi Git - libs/gui.git/blobdiff - source/input/windows/gamecontroller_platform.h
Use default member initializers and defaulted default constructors
[libs/gui.git] / source / input / windows / gamecontroller_platform.h
index 928ad6770dd3b917f50d823dea17ac2862cbe275..d6ee6c27d4bc2f252acf3bc26d1fb4187f37d30b 100644 (file)
@@ -14,7 +14,7 @@ class GameControllerTimerThread: public Msp::Thread
 {
 private:
        Time::Timer timer;
-       unsigned n_users;
+       unsigned n_users = 0;
 
        static GameControllerTimerThread *thread;
 
@@ -31,15 +31,13 @@ private:
 
 struct GameController::Private
 {
-       unsigned index;
-       unsigned last_packet_number;
-       IO::Pipe *event_pipe;
-       Time::Timer::Slot *timer_slot;
+       unsigned index = 0;
+       unsigned last_packet_number = 0;
+       IO::Pipe *event_pipe = 0;
+       Time::Timer::Slot *timer_slot = 0;
 
        static std::vector<unsigned> detected_controllers;
 
-       Private();
-
        bool generate_event();
 
        void update_state(GameController &, const XINPUT_STATE &, bool);