]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/window.h
added generic implementation and documentation for wxFindReplaceDialog
[wxWidgets.git] / include / wx / window.h
index f1534578e3b01b425189a9f8a793844ece7f28b9..fb8971a94c690482e8243b3cbc675bbfc5b186bb 100644 (file)
@@ -172,8 +172,8 @@ public:
 
         // the title (or label, see below) of the window: the text which the
         // window shows
-    virtual void SetTitle( const wxString & WXUNUSED(title) ) { }
-    virtual wxString GetTitle() const { return ""; }
+    virtual void SetTitle( const wxString& title ) { m_title = title; }
+    virtual wxString GetTitle() const { return m_title; }
 
         // label is just the same as the title (but for, e.g., buttons it
         // makes more sense to speak about labels)
@@ -664,13 +664,16 @@ public:
                                const wxRect* rect = (wxRect *) NULL ) = 0;
 
         // scrolls window by line/page: note that not all controls support this
-    virtual void ScrollLines(int WXUNUSED(lines)) { }
-    virtual void ScrollPages(int WXUNUSED(pages)) { }
+        //
+        // return TRUE if the position changed, FALSE otherwise
+    virtual bool ScrollLines(int WXUNUSED(lines)) { return FALSE; }
+    virtual bool ScrollPages(int WXUNUSED(pages)) { return FALSE; }
 
-    void LineUp() { ScrollLines(-1); }
-    void LineDown() { ScrollLines(1); }
-    void PageUp() { ScrollPages(-1); }
-    void PageDown() { ScrollPages(1); }
+        // convenient wrappers for ScrollLines/Pages
+    bool LineUp() { return ScrollLines(-1); }
+    bool LineDown() { return ScrollLines(1); }
+    bool PageUp() { return ScrollPages(-1); }
+    bool PageDown() { return ScrollPages(1); }
 
     // context-sensitive help
     // ----------------------
@@ -783,6 +786,9 @@ protected:
     // the window id - a number which uniquely identifies a window among
     // its siblings unless it is -1
     wxWindowID           m_windowId;
+    
+    // the window label
+    wxString             m_title;
 
     // the parent window of this window (or NULL) and the list of the children
     // of this window
@@ -993,7 +999,7 @@ private:
         #define sm_classwxWindowGTK sm_classwxWindow
     #endif // wxUniv
     #include "wx/gtk/window.h"
-#elif defined(__WXGL__)
+#elif defined(__WXMGL__)
     #ifdef __WXUNIVERSAL__
         #define wxWindowNative wxWindowMGL
     #else // !wxUniv