X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bb6290e3514a84a7b50860d1c75d4623696ff601..da468d387db3b7e22b008bf08be2ff6b202508fb:/include/wx/msw/window.h?ds=sidebyside diff --git a/include/wx/msw/window.h b/include/wx/msw/window.h index a0792f8a06..82c7516980 100644 --- a/include/wx/msw/window.h +++ b/include/wx/msw/window.h @@ -25,6 +25,7 @@ #include "wx/event.h" #include "wx/string.h" #include "wx/list.h" +#include "wx/region.h" #define wxKEY_SHIFT 1 #define wxKEY_CTRL 2 @@ -202,6 +203,12 @@ public: // Accept files for dragging virtual void DragAcceptFiles(bool accept); + // Update region access + virtual wxRegion GetUpdateRegion() const; + virtual bool IsExposed(int x, int y, int w, int h) const; + virtual bool IsExposed(const wxPoint& pt) const; + virtual bool IsExposed(const wxRect& rect) const; + // Set/get the window title virtual inline void SetTitle(const wxString& WXUNUSED(title)) {}; inline virtual wxString GetTitle(void) const { return wxString(""); }; @@ -386,16 +393,26 @@ public: // Do Update UI processing for controls void UpdateWindowUI(void); - void OnSize(wxSizeEvent& event); void OnEraseBackground(wxEraseEvent& event); void OnChar(wxKeyEvent& event); void OnPaint(wxPaintEvent& event); void OnIdle(wxIdleEvent& event); + // Does this window want to accept keyboard focus? + virtual bool AcceptsFocus() const; + public: //////////////////////////////////////////////////////////////////////// //// IMPLEMENTATION + // For implementation purposes - sometimes decorations make the client area + // smaller + virtual wxPoint GetClientAreaOrigin() const; + + // Makes an adjustment to the window position (for example, a frame that has + // a toolbar that it manages itself). + virtual void AdjustForParentClientOrigin(int& x, int& y, int sizeFlags); + // Windows subclassing void SubclassWin(WXHWND hWnd); void UnsubclassWin(void); @@ -486,6 +503,8 @@ public: virtual WXHBRUSH MSWOnCtlColor(WXHDC dc, WXHWND pWnd, WXUINT nCtlColor, WXUINT message, WXWPARAM wParam, WXLPARAM lParam); virtual bool MSWOnColorChange(WXHWND hWnd, WXUINT message, WXWPARAM wParam, WXLPARAM lParam); + virtual long MSWOnPaletteChanged(WXHWND hWndPalChange); + virtual long MSWOnQueryNewPalette(); virtual bool MSWOnEraseBkgnd(WXHDC pDC); virtual void MSWOnMenuHighlight(WXWORD item, WXWORD flags, WXHMENU sysmenu); virtual void MSWOnInitMenuPopup(WXHMENU menu, int pos, bool isSystem); @@ -528,6 +547,8 @@ public: virtual void MSWOnJoyMove(int joystick, int x, int y, WXUINT flags); virtual void MSWOnJoyZMove(int joystick, int z, WXUINT flags); + virtual long MSWGetDlgCode(); + // Window procedure virtual long MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam); @@ -635,10 +656,15 @@ public: WXUINT m_lastMsg; WXWPARAM m_lastWParam; WXLPARAM m_lastLParam; + + wxRegion m_updateRegion; +/* wxRectangle m_updateRect; // Bounding box for screen damage area #ifdef __WIN32__ WXHRGN m_updateRgn; // NT allows access to the rectangle list #endif +*/ + WXHANDLE m_acceleratorTable; WXHMENU m_hMenu; // Menu, if any wxList * m_children; // Window's children @@ -702,6 +728,8 @@ inline bool wxWindow::IsBeingDeleted(void) { return m_isBeingDeleted; } // Window specific (so far) wxWindow* WXDLLEXPORT wxGetActiveWindow(void); +// OBSOLETE +#if 0 // Allows iteration through damaged rectangles in OnPaint class WXDLLEXPORT wxUpdateIterator { @@ -724,6 +752,7 @@ class WXDLLEXPORT wxUpdateIterator int GetW(); int GetH(); }; +#endif WXDLLEXPORT_DATA(extern wxList) wxTopLevelWindows;