]> git.saurik.com Git - wxWidgets.git/commitdiff
Always use wxFULL_REPAINT_ON_RESIZE for generic status bar.
authorPaul Cornett <paulcor@bullseye.com>
Wed, 6 Sep 2006 17:36:22 +0000 (17:36 +0000)
committerPaul Cornett <paulcor@bullseye.com>
Wed, 6 Sep 2006 17:36:22 +0000 (17:36 +0000)
Remove undocumented generic status bar ctor/Create.
Bring status bar ctor/Create into sync with docs.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41035 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

docs/latex/wx/statusbr.tex
include/wx/generic/statusbr.h
include/wx/mac/carbon/statusbr.h
include/wx/msw/statbr95.h
include/wx/statusbr.h
src/common/statbar.cpp
src/generic/statusbr.cpp

index 261d7623153d96875c8996177c68a23d1af08421..cc7a3d3b67e29d0b8e31af5548d8b5ad4659096f 100644 (file)
@@ -45,7 +45,7 @@ from an {\bf OnSize} event handler.
 
 Default constructor.
 
 
 Default constructor.
 
-\func{}{wxStatusBar}{\param{wxWindow* }{parent}, \param{wxWindowID }{id},\rtfsp
+\func{}{wxStatusBar}{\param{wxWindow* }{parent}, \param{wxWindowID }{id = wxID\_ANY},\rtfsp
 \param{long}{ style = wxST\_SIZEGRIP},\rtfsp
 \param{const wxString\& }{name = ``statusBar"}}
 
 \param{long}{ style = wxST\_SIZEGRIP},\rtfsp
 \param{const wxString\& }{name = ``statusBar"}}
 
@@ -75,7 +75,7 @@ Destructor.
 
 \membersection{wxStatusBar::Create}\label{wxstatusbarcreate}
 
 
 \membersection{wxStatusBar::Create}\label{wxstatusbarcreate}
 
-\func{bool}{Create}{\param{wxWindow* }{parent}, \param{wxWindowID }{id},\rtfsp
+\func{bool}{Create}{\param{wxWindow* }{parent}, \param{wxWindowID }{id = wxID\_ANY},\rtfsp
 \param{long}{ style = wxST\_SIZEGRIP},\rtfsp
 \param{const wxString\& }{name = ``statusBar"}}
 
 \param{long}{ style = wxST\_SIZEGRIP},\rtfsp
 \param{const wxString\& }{name = ``statusBar"}}
 
index e7aca327b121502890a9e9f3470aacc38a49d835..709e58faa69c7915373b4260ade9be966c1700f1 100644 (file)
 #ifndef _WX_GENERIC_STATUSBR_H_
 #define _WX_GENERIC_STATUSBR_H_
 
 #ifndef _WX_GENERIC_STATUSBR_H_
 #define _WX_GENERIC_STATUSBR_H_
 
-#include "wx/defs.h"
-
-#if wxUSE_STATUSBAR
-
 #include "wx/pen.h"
 #include "wx/pen.h"
-#include "wx/font.h"
-#include "wx/statusbr.h"
 #include "wx/arrstr.h"
 
 #include "wx/arrstr.h"
 
-extern WXDLLEXPORT_DATA(const wxChar) wxPanelNameStr[];
-
 class WXDLLEXPORT wxStatusBarGeneric : public wxStatusBarBase
 {
 public:
     wxStatusBarGeneric() { Init(); }
     wxStatusBarGeneric(wxWindow *parent,
 class WXDLLEXPORT wxStatusBarGeneric : public wxStatusBarBase
 {
 public:
     wxStatusBarGeneric() { Init(); }
     wxStatusBarGeneric(wxWindow *parent,
-                       wxWindowID winid,
-                       const wxPoint& pos = wxDefaultPosition,
-                       const wxSize& size = wxDefaultSize,
-                       long style = wxFULL_REPAINT_ON_RESIZE,
-                       const wxString& name = wxPanelNameStr)
-    {
-        Init();
-
-        Create(parent, winid, pos, size, style, name);
-    }
-    wxStatusBarGeneric(wxWindow *parent,
-                       wxWindowID winid,
-                       long style,
-                       const wxString& name = wxPanelNameStr)
+                       wxWindowID winid = wxID_ANY,
+                       long style = wxST_SIZEGRIP,
+                       const wxString& name = wxStatusBarNameStr)
     {
         Init();
 
     {
         Init();
 
@@ -50,18 +31,9 @@ public:
 
     virtual ~wxStatusBarGeneric();
 
 
     virtual ~wxStatusBarGeneric();
 
-    bool Create(wxWindow *parent, wxWindowID winid,
-                const wxPoint& WXUNUSED(pos) = wxDefaultPosition,
-                const wxSize& WXUNUSED(size) = wxDefaultSize,
-                long style = wxFULL_REPAINT_ON_RESIZE,
-                const wxString& name = wxPanelNameStr)
-    {
-        return Create(parent, winid, style, name);
-    }
-
-    bool Create(wxWindow *parent, wxWindowID winid,
-                long style,
-                const wxString& name = wxPanelNameStr);
+    bool Create(wxWindow *parent, wxWindowID winid = wxID_ANY,
+                long style = wxST_SIZEGRIP,
+                const wxString& name = wxStatusBarNameStr);
 
     // Create status line
     virtual void SetFieldsCount(int number = 1,
 
     // Create status line
     virtual void SetFieldsCount(int number = 1,
@@ -125,7 +97,5 @@ private:
     DECLARE_DYNAMIC_CLASS_NO_COPY(wxStatusBarGeneric)
 };
 
     DECLARE_DYNAMIC_CLASS_NO_COPY(wxStatusBarGeneric)
 };
 
-#endif // wxUSE_STATUSBAR
-
 #endif
     // _WX_GENERIC_STATUSBR_H_
 #endif
     // _WX_GENERIC_STATUSBR_H_
index c5ecf314c3dd13a090c4470985c8b071661d94f4..1ff5901db22890334ad1989a526215b302ddf963 100644 (file)
@@ -18,15 +18,15 @@ class WXDLLEXPORT wxStatusBarMac : public wxStatusBarGeneric
     DECLARE_DYNAMIC_CLASS(wxStatusBarMac)
 
     wxStatusBarMac();
     DECLARE_DYNAMIC_CLASS(wxStatusBarMac)
 
     wxStatusBarMac();
-    wxStatusBarMac(wxWindow *parent, wxWindowID id,
-           long style = 0,
-           const wxString& name = wxPanelNameStr);
+    wxStatusBarMac(wxWindow *parent, wxWindowID id = wxID_ANY,
+           long style = wxST_SIZEGRIP,
+           const wxString& name = wxStatusBarNameStr);
 
     virtual ~wxStatusBarMac();
 
 
     virtual ~wxStatusBarMac();
 
-    bool Create(wxWindow *parent, wxWindowID id,
-              long style ,
-              const wxString& name = wxPanelNameStr);
+    bool Create(wxWindow *parent, wxWindowID id = wxID_ANY,
+              long style = wxST_SIZEGRIP,
+              const wxString& name = wxStatusBarNameStr);
 
     virtual void DrawFieldText(wxDC& dc, int i);
     virtual void DrawField(wxDC& dc, int i);
 
     virtual void DrawFieldText(wxDC& dc, int i);
     virtual void DrawField(wxDC& dc, int i);
index e611e4a00ac1f60bd6d7b63cdafb96aec8750309..afa3db8486e24846bce6e30c1347ecd247c94837 100644 (file)
@@ -22,7 +22,7 @@ public:
     wxStatusBar95(wxWindow *parent,
                   wxWindowID id = wxID_ANY,
                   long style = wxST_SIZEGRIP,
     wxStatusBar95(wxWindow *parent,
                   wxWindowID id = wxID_ANY,
                   long style = wxST_SIZEGRIP,
-                  const wxString& name = wxEmptyString)
+                  const wxString& name = wxStatusBarNameStr)
     {
         (void)Create(parent, id, style, name);
     }
     {
         (void)Create(parent, id, style, name);
     }
@@ -30,7 +30,7 @@ public:
     bool Create(wxWindow *parent,
                 wxWindowID id = wxID_ANY,
                 long style = wxST_SIZEGRIP,
     bool Create(wxWindow *parent,
                 wxWindowID id = wxID_ANY,
                 long style = wxST_SIZEGRIP,
-                const wxString& name = wxEmptyString);
+                const wxString& name = wxStatusBarNameStr);
 
     virtual ~wxStatusBar95();
 
 
     virtual ~wxStatusBar95();
 
index cb07ac1fd12cc325432f8b48b63c179277242230..3c892013ad1b96bd04f1c3496d2962b9e1fdeeff 100644 (file)
@@ -20,6 +20,8 @@
 #include "wx/list.h"
 #include "wx/dynarray.h"
 
 #include "wx/list.h"
 #include "wx/dynarray.h"
 
+extern WXDLLIMPEXP_DATA_CORE(const wxChar) wxStatusBarNameStr[];
+
 WX_DECLARE_LIST(wxString, wxListString);
 
 // ----------------------------------------------------------------------------
 WX_DECLARE_LIST(wxString, wxListString);
 
 // ----------------------------------------------------------------------------
index 8e51e041ba18122c3f83af81317459966ad85c05..e1c4fd3dffb8a5445bfd923143cceeb6805581c4 100644 (file)
     #pragma hdrstop
 #endif
 
     #pragma hdrstop
 #endif
 
+#if wxUSE_STATUSBAR
+
 #include "wx/statusbr.h"
 
 #ifndef WX_PRECOMP
     #include "wx/frame.h"
 #endif //WX_PRECOMP
 
 #include "wx/statusbr.h"
 
 #ifndef WX_PRECOMP
     #include "wx/frame.h"
 #endif //WX_PRECOMP
 
-#if wxUSE_STATUSBAR
-
 #include "wx/listimpl.cpp"
 WX_DEFINE_LIST(wxListString)
 
 #include "wx/listimpl.cpp"
 WX_DEFINE_LIST(wxListString)
 
+const wxChar wxStatusBarNameStr[] = wxT("statusBar");
+
 // ============================================================================
 // wxStatusBarBase implementation
 // ============================================================================
 // ============================================================================
 // wxStatusBarBase implementation
 // ============================================================================
index 281be6f0fddf53005710d8838c3ef8ce8135603e..b963470a674c26b4306c8cacf673901a052832d7 100644 (file)
 #include "wx/statusbr.h"
 
 #ifndef WX_PRECOMP
 #include "wx/statusbr.h"
 
 #ifndef WX_PRECOMP
-    #include "wx/frame.h"
     #include "wx/settings.h"
     #include "wx/dcclient.h"
 #endif
 
 #ifdef __WXGTK20__
     #include "wx/settings.h"
     #include "wx/dcclient.h"
 #endif
 
 #ifdef __WXGTK20__
-#include "wx/gtk/private.h"
-#include "wx/gtk/win_gtk.h"
+    #include <gtk/gtk.h>
+    #include "wx/gtk/win_gtk.h"
 #endif
 
 // we only have to do it here when we use wxStatusBarGeneric in addition to the
 #endif
 
 // we only have to do it here when we use wxStatusBarGeneric in addition to the
@@ -67,9 +66,10 @@ bool wxStatusBarGeneric::Create(wxWindow *parent,
                                 long style,
                                 const wxString& name)
 {
                                 long style,
                                 const wxString& name)
 {
+    style |= wxTAB_TRAVERSAL | wxFULL_REPAINT_ON_RESIZE;
     if ( !wxWindow::Create(parent, id,
                            wxDefaultPosition, wxDefaultSize,
     if ( !wxWindow::Create(parent, id,
                            wxDefaultPosition, wxDefaultSize,
-                           style | wxTAB_TRAVERSAL, name) )
+                           style, name) )
         return false;
 
     // The status bar should have a themed background
         return false;
 
     // The status bar should have a themed background