]> git.saurik.com Git - wxWidgets.git/blob - include/wx/aui/floatpane.h
while we're at it, rename wxAuiFloatingPane to the more correct wxAuiFloatingFrame
[wxWidgets.git] / include / wx / aui / floatpane.h
1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: wx/aui/floatpane.h
3 // Purpose: wxaui: wx advanced user interface - docking window manager
4 // Author: Benjamin I. Williams
5 // Modified by:
6 // Created: 2005-05-17
7 // RCS-ID: $Id$
8 // Copyright: (C) Copyright 2005, Kirix Corporation, All Rights Reserved.
9 // Licence: wxWindows Library Licence, Version 3.1
10 ///////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_FLOATPANE_H_
13 #define _WX_FLOATPANE_H_
14
15 // ----------------------------------------------------------------------------
16 // headers
17 // ----------------------------------------------------------------------------
18
19 #include "wx/defs.h"
20
21 #if wxUSE_AUI
22
23 #include "wx/frame.h"
24
25 #if defined( __WXMSW__ ) || defined( __WXMAC__ ) || defined( __WXGTK__ )
26 #include "wx/minifram.h"
27 #define wxAuiFloatingFrameBaseClass wxMiniFrame
28 #else
29 #define wxAuiFloatingFrameBaseClass wxFrame
30 #endif
31
32 class WXDLLIMPEXP_AUI wxAuiFloatingFrame : public wxAuiFloatingFrameBaseClass
33 {
34 public:
35 wxAuiFloatingFrame(wxWindow* parent,
36 wxAuiManager* owner_mgr,
37 const wxAuiPaneInfo& pane,
38 wxWindowID id = wxID_ANY,
39 long style = wxRESIZE_BORDER | wxSYSTEM_MENU | wxCAPTION |
40 wxFRAME_NO_TASKBAR | wxFRAME_FLOAT_ON_PARENT |
41 wxCLIP_CHILDREN
42 );
43 virtual ~wxAuiFloatingFrame();
44 void SetPaneWindow(const wxAuiPaneInfo& pane);
45
46 protected:
47 virtual void OnMoveStart();
48 virtual void OnMoving(const wxRect& window_rect, wxDirection dir);
49 virtual void OnMoveFinished();
50
51 private:
52 void OnSize(wxSizeEvent& event);
53 void OnClose(wxCloseEvent& event);
54 void OnMoveEvent(wxMoveEvent& event);
55 void OnIdle(wxIdleEvent& event);
56 void OnActivate(wxActivateEvent& event);
57 static bool isMouseDown();
58 private:
59 wxWindow* m_pane_window; // pane window being managed
60 bool m_solid_drag; // true if system uses solid window drag
61 bool m_moving;
62 wxRect m_last_rect;
63 wxRect m_last2_rect;
64 wxRect m_last3_rect;
65 wxSize m_last_size;
66 wxDirection m_lastDirection;
67
68 wxAuiManager* m_owner_mgr;
69 wxAuiManager m_mgr;
70
71 #ifndef SWIG
72 DECLARE_EVENT_TABLE()
73 DECLARE_CLASS(wxAuiFloatingFrameBaseClass)
74 #endif // SWIG
75 };
76
77 #endif // wxUSE_AUI
78 #endif //_WX_FLOATPANE_H_
79