]> git.saurik.com Git - wxWidgets.git/blobdiff - src/os2/statline.cpp
using new API (no visual difference)
[wxWidgets.git] / src / os2 / statline.cpp
index effb7de3505bfb725eeb0410f82adc36711208b4..ab764d8dcefd3ae4be7805ed42938421781a090a 100644 (file)
 // headers
 // ----------------------------------------------------------------------------
 
-#ifdef __GNUG__
-    #pragma implementation "statline.h"
-#endif
-
 // For compilers that support precompilation, includes "wx.h".
 #include "wx/wxprec.h"
 
@@ -60,12 +56,26 @@ bool wxStaticLine::Create(
                         ,rsName
                        ))
         return FALSE;
-    return OS2CreateControl( _T("STATIC")
-                            ,_T("")
-                            ,rPos
-                            ,vSize
-                            ,lStyle
-                           );
+    if (!OS2CreateControl( wxT("STATIC")
+                          ,SS_FGNDFRAME
+                          ,rPos
+                          ,rSize
+                          ,rsName
+                         ))
+        return FALSE;
+
+    wxColour                        vColour;
+
+    vColour.Set(wxString(wxT("GREY")));
+
+    LONG                            lColor = (LONG)vColour.GetPixel();
+
+    ::WinSetPresParam( m_hWnd
+                      ,PP_FOREGROUNDCOLOR
+                      ,sizeof(LONG)
+                      ,(PVOID)&lColor
+                     );
+    return TRUE;
 } // end of wxStaticLine::Create
 
 WXDWORD wxStaticLine::OS2GetStyle(