]> git.saurik.com Git - wxWidgets.git/commitdiff
Don't use themed border for the generic info bar.
authorVadim Zeitlin <vadim@wxwidgets.org>
Mon, 5 Oct 2009 22:56:22 +0000 (22:56 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Mon, 5 Oct 2009 22:56:22 +0000 (22:56 +0000)
Since the switch to deriving from wxControl instead of wxWindow, the info bar
gained a themed border which doesn't look nice for it, especially when it is
shown progressively, as happens under Windows.

Restore the old behaviour by overriding GetDefaultBorder() to return
wxBORDER_NONE for it. This doesn't look perfect neither however, we may want
to draw a separator line between it and the parent window ourselves as even
wxBORDER_SIMPLE looks too heavy for it (and there should be definitely no
border on its sides as it always touches the parent window edges).

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

include/wx/generic/infobar.h

index a858c6d0d7591a40c101a817cbd0fe00bb690d45..aef0e8c9fb22d7468fc86a5917a245e79c000aa3 100644 (file)
@@ -81,6 +81,11 @@ public:
     virtual bool SetFont(const wxFont& font);
 
 protected:
+    // info bar shouldn't have any border by default, the colour difference
+    // between it and the main window separates it well enough
+    virtual wxBorder GetDefaultBorder() const { return wxBORDER_NONE; }
+
+
     // update the parent to take our new or changed size into account (notably
     // should be called when we're shown or hidden)
     void UpdateParent();