allow programmatic access to start pane dragging
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43528 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
2522d52917
commit
cf37c9a90d
@ -476,15 +476,22 @@ public:
|
||||
void Update();
|
||||
|
||||
public:
|
||||
|
||||
virtual wxAuiFloatingFrame* CreateFloatingFrame(wxWindow* parent, const wxAuiPaneInfo& p);
|
||||
|
||||
wxRect CalculateHintRect(wxWindow* pane_window,
|
||||
const wxPoint& pt,
|
||||
const wxPoint& offset);
|
||||
void StartPaneDrag(
|
||||
wxWindow* pane_window,
|
||||
const wxPoint& offset);
|
||||
|
||||
wxRect CalculateHintRect(
|
||||
wxWindow* pane_window,
|
||||
const wxPoint& pt,
|
||||
const wxPoint& offset);
|
||||
|
||||
void DrawHintRect(wxWindow* pane_window,
|
||||
const wxPoint& pt,
|
||||
const wxPoint& offset);
|
||||
void DrawHintRect(
|
||||
wxWindow* pane_window,
|
||||
const wxPoint& pt,
|
||||
const wxPoint& offset);
|
||||
|
||||
virtual void ShowHint(const wxRect& rect);
|
||||
virtual void HideHint();
|
||||
|
@ -3074,6 +3074,27 @@ void wxAuiManager::HideHint()
|
||||
|
||||
|
||||
|
||||
void wxAuiManager::StartPaneDrag(wxWindow* pane_window,
|
||||
const wxPoint& offset)
|
||||
{
|
||||
wxAuiPaneInfo& pane = GetPane(pane_window);
|
||||
if (!pane.IsOk())
|
||||
return;
|
||||
|
||||
if (pane.IsToolbar())
|
||||
{
|
||||
m_action = actionDragToolbarPane;
|
||||
}
|
||||
else
|
||||
{
|
||||
m_action = actionDragFloatingPane;
|
||||
}
|
||||
|
||||
m_action_window = pane_window;
|
||||
m_action_offset = offset;
|
||||
m_frame->CaptureMouse();
|
||||
}
|
||||
|
||||
|
||||
// CalculateHintRect() calculates the drop hint rectangle. The method
|
||||
// first calls DoDrop() to determine the exact position the pane would
|
||||
@ -4041,9 +4062,8 @@ void wxAuiManager::OnMotion(wxMouseEvent& event)
|
||||
pt.y - m_action_offset.y);
|
||||
|
||||
// float the window
|
||||
if(pane_info->IsMaximized()) {
|
||||
if (pane_info->IsMaximized())
|
||||
RestorePane(*pane_info);
|
||||
}
|
||||
pane_info->Float();
|
||||
Update();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user