-rw-r--r-- | libopie2/opiecore/device/odevice_simpad.cpp | 27 | ||||
-rw-r--r-- | libopie2/opiecore/device/odevice_simpad.h | 12 |
2 files changed, 23 insertions, 16 deletions
diff --git a/libopie2/opiecore/device/odevice_simpad.cpp b/libopie2/opiecore/device/odevice_simpad.cpp index ebf0cbb..9fde7f9 100644 --- a/libopie2/opiecore/device/odevice_simpad.cpp +++ b/libopie2/opiecore/device/odevice_simpad.cpp @@ -57,6 +57,18 @@ -using namespace Opie::Core; -using namespace Opie::Core::Internal; +namespace Opie { +namespace Core { +namespace Internal { +namespace { +struct s_button { + uint model; + Qt::Key code; + char *utext; + char *pix; + char *fpressedservice; + char *fpressedaction; + char *fheldservice; + char *fheldaction; +}; -struct s_button simpad_buttons [] = { +static struct s_button simpad_buttons [] = { { Model_SIMpad_CL4 | Model_SIMpad_SL4 | Model_SIMpad_SLC | Model_SIMpad_TSinus, @@ -115,2 +127,4 @@ struct s_button simpad_buttons [] = { }; +} + @@ -151,3 +165,4 @@ void SIMpad::initButtons() - for ( uint i = 0; i < ( sizeof( simpad_buttons ) / sizeof( s_button )); i++ ) { + uint size = sizeof(simpad_buttons)/sizeof(s_button); + for ( uint i = 0; i < size; i++ ) { s_button *sb = simpad_buttons + i; @@ -383 +398,5 @@ void SIMpad::updateAllWidgets() { } + +} +} +} diff --git a/libopie2/opiecore/device/odevice_simpad.h b/libopie2/opiecore/device/odevice_simpad.h index c25b911..41b94d1 100644 --- a/libopie2/opiecore/device/odevice_simpad.h +++ b/libopie2/opiecore/device/odevice_simpad.h @@ -70,14 +70,2 @@ private: }; - -struct s_button { - uint model; - Qt::Key code; - char *utext; - char *pix; - char *fpressedservice; - char *fpressedaction; - char *fheldservice; - char *fheldaction; -}; - } |