]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/window.h
More resource files
[wxWidgets.git] / include / wx / window.h
index 4be6c62c9557121e74e89c73b72a9cd8b3a5b187..905327ad1ac2562ed5e82822ae3490c668bd0ae7 100644 (file)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// Name:        window.h
+// Name:        wx/window.h
 // Purpose:     wxWindowBase class - the interface of wxWindow
 // Author:      Vadim Zeitlin
 // Modified by:
@@ -460,9 +460,12 @@ public:
         // move the mouse to the specified position
     virtual void WarpPointer(int x, int y) = 0;
 
-        // start or end mouse capture
-    virtual void CaptureMouse() = 0;
-    virtual void ReleaseMouse() = 0;
+        // start or end mouse capture, these functions maintain the stack of
+        // windows having captured the mouse and after calling ReleaseMouse()
+        // the mouse is not released but returns to the window which had had
+        // captured it previously (if any)
+    void CaptureMouse();
+    void ReleaseMouse();
 
         // get the window which currently captures the mouse or NULL
     static wxWindow *GetCapture();
@@ -823,6 +826,11 @@ protected:
     bool                 m_isEnabled:1;
     bool                 m_isBeingDeleted:1;
 
+    // was the window colours/font explicitly changed by user?
+    bool                 m_hasBgCol:1;
+    bool                 m_hasFgCol:1;
+    bool                 m_hasFont:1;
+
     // window attributes
     long                 m_windowStyle,
                          m_exStyle;
@@ -878,6 +886,10 @@ protected:
 
     virtual wxHitTest DoHitTest(wxCoord x, wxCoord y) const;
 
+    // capture/release the mouse, used by Capture/ReleaseMouse()
+    virtual void DoCaptureMouse() = 0;
+    virtual void DoReleaseMouse() = 0;
+
     // retrieve the position/size of the window
     virtual void DoGetPosition( int *x, int *y ) const = 0;
     virtual void DoGetSize( int *width, int *height ) const = 0;
@@ -920,6 +932,9 @@ private:
     // contains the last id generated by NewControlId
     static int ms_lastControlId;
 
+    // the stack of windows which have captured the mouse
+    static struct WXDLLEXPORT wxWindowNext *ms_winCaptureNext;
+
     DECLARE_ABSTRACT_CLASS(wxWindowBase)
     DECLARE_NO_COPY_CLASS(wxWindowBase)
     DECLARE_EVENT_TABLE()