]> git.saurik.com Git - wxWidgets.git/blobdiff - src/palmos/settings.cpp
fixed problem with non-const methods not working on wxRegKey initially opened in...
[wxWidgets.git] / src / palmos / settings.cpp
index 4191175eb34c5011ee74ab891ca10a6248fb3f6b..bb050eb1075b0dcaa19fe8d5676c737d3a59ece4 100644 (file)
@@ -2,10 +2,10 @@
 // Name:        src/palmos/settings.cpp
 // Purpose:     wxSystemSettingsNative implementation for Palm OS
 // Author:      William Osborne - minimal working wxPalmOS port
-// Modified by:
+// Modified by: Wlodzimierz ABX Skiba - native implementation
 // Created:     10/13/04
 // RCS-ID:      $Id$
-// Copyright:   (c) William Osborne
+// Copyright:   (c) William Osborne, Wlodzimierz Skiba
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
@@ -123,9 +123,25 @@ wxFont wxSystemSettingsNative::GetFont(wxSystemFont index)
 // ----------------------------------------------------------------------------
 
 // Get a system metric, e.g. scrollbar size
-int wxSystemSettingsNative::GetMetric(wxSystemMetric index)
+int wxSystemSettingsNative::GetMetric(wxSystemMetric index, wxWindow* WXUNUSED(win))
 {
-    return -1;
+    int metric = -1;
+    uint32_t attrP;
+
+    switch( index )
+    {
+        case wxSYS_SCREEN_X:
+            WinScreenGetAttribute(winScreenWidth, &attrP);
+            metric = attrP;
+            break;
+
+        case wxSYS_SCREEN_Y:
+            WinScreenGetAttribute(winScreenHeight, &attrP);
+            metric = attrP;
+            break;
+    }
+
+    return metric;
 }
 
 bool wxSystemSettingsNative::HasFeature(wxSystemFeature index)