- Do not add GHOST_NDOFManager.cpp to list of sources if
authorSergey Sharybin <sergey.vfx@gmail.com>
Wed, 3 Aug 2011 07:30:24 +0000 (07:30 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Wed, 3 Aug 2011 07:30:24 +0000 (07:30 +0000)
  NDOF is disabled in CMake.
- Added "default" section to switch in sendMotionEvent.
  It's what strict gcc rules don't like much and it's
  And it's good practice in general, imo.

intern/ghost/CMakeLists.txt
intern/ghost/intern/GHOST_NDOFManager.cpp

index 2180ddb..d7658c5 100644 (file)
@@ -44,7 +44,6 @@ set(SRC
        intern/GHOST_ISystem.cpp
        intern/GHOST_ISystemPaths.cpp
        intern/GHOST_ModifierKeys.cpp
-       intern/GHOST_NDOFManager.cpp
        intern/GHOST_Path-api.cpp
        intern/GHOST_Path-api.cpp
        intern/GHOST_Rect.cpp
@@ -74,12 +73,10 @@ set(SRC
        intern/GHOST_EventDragnDrop.h
        intern/GHOST_EventKey.h
        intern/GHOST_EventManager.h
-       intern/GHOST_EventNDOF.h
        intern/GHOST_EventString.h
        intern/GHOST_EventTrackpad.h
        intern/GHOST_EventWheel.h
        intern/GHOST_ModifierKeys.h
-       intern/GHOST_NDOFManager.h
        intern/GHOST_System.h
        intern/GHOST_SystemPaths.h
        intern/GHOST_TimerManager.h
@@ -99,6 +96,14 @@ endif()
 
 if(WITH_INPUT_NDOF)
        add_definitions(-DWITH_INPUT_NDOF)
+
+       list(APPEND SRC
+               intern/GHOST_NDOFManager.cpp
+
+               intern/GHOST_EventNDOF.h
+               intern/GHOST_NDOFManager.h
+       )
+
        list(APPEND INC_SYS
                ${NDOF_INCLUDE_DIRS}
        )
index db87e1f..855e27b 100644 (file)
@@ -452,6 +452,8 @@ bool GHOST_NDOFManager::sendMotionEvent()
                                m_motionState = GHOST_kFinished;
                        }
                        break;
+               default:
+                       break;
        }
 
 #ifdef DEBUG_NDOF_MOTION