]> git.saurik.com Git - wxWidgets.git/commitdiff
cosemtic fixes
authorVadim Zeitlin <vadim@wxwidgets.org>
Sat, 5 Feb 2000 01:55:54 +0000 (01:55 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sat, 5 Feb 2000 01:55:54 +0000 (01:55 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5847 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

samples/statbar/statbar.cpp

index dc3e41156dcf0fd2e959a38ba283daa8127ba64c..ca2cfcda3e18358951db884b841ffafc1a0e8636 100644 (file)
@@ -39,7 +39,6 @@
     #include "wx/app.h"
     #include "wx/frame.h"
     #include "wx/statusbr.h"
-    #include "wx/datetime.h"
     #include "wx/timer.h"
     #include "wx/checkbox.h"
     #include "wx/statbmp.h"
@@ -47,6 +46,8 @@
     #include "wx/msgdlg.h"
 #endif
 
+#include "wx/datetime.h"
+
 // ----------------------------------------------------------------------------
 // resources
 // ----------------------------------------------------------------------------
@@ -315,6 +316,11 @@ void MyFrame::OnAbout(wxCommandEvent& WXUNUSED(event))
 // MyStatusBar
 // ----------------------------------------------------------------------------
 
+#ifdef __VISUALC__
+    // 'this' : used in base member initializer list -- so what??
+    #pragma warning(disable: 4355)
+#endif
+
 MyStatusBar::MyStatusBar(wxWindow *parent)
            : wxStatusBar(parent, -1), m_timer(this)
 {
@@ -326,13 +332,19 @@ MyStatusBar::MyStatusBar(wxWindow *parent)
     m_checkbox = new wxCheckBox(this, StatusBar_Checkbox, _T("&Toggle clock"));
     m_checkbox->SetValue(TRUE);
 
-    m_statbmp = new wxStaticBitmap(this, -1, wxICON(green));
+    m_statbmp = new wxStaticBitmap(this, -1, wxIcon(green_xpm));
 
     m_timer.Start(1000);
 
+    SetMinHeight(BITMAP_SIZE_Y);
+
     UpdateClock();
 }
 
+#ifdef __VISUALC__
+    #pragma warning(default: 4355)
+#endif
+
 MyStatusBar::~MyStatusBar()
 {
     if ( m_timer.IsRunning() )
@@ -361,7 +373,7 @@ void MyStatusBar::OnToggleClock(wxCommandEvent& event)
     {
         m_timer.Start(1000);
 
-        m_statbmp->SetIcon(wxICON(green));
+        m_statbmp->SetIcon(wxIcon(green_xpm));
 
         UpdateClock();
     }
@@ -369,7 +381,7 @@ void MyStatusBar::OnToggleClock(wxCommandEvent& event)
     {
         m_timer.Stop();
 
-        m_statbmp->SetIcon(wxICON(red));
+        m_statbmp->SetIcon(wxIcon(red_xpm));
 
         SetStatusText("", Field_Clock);
     }