Fixed [ 1645203 ] Problem with resizing floating panes

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@48255 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2007-08-21 08:35:08 +00:00
parent 2ff8932f92
commit 97008f4b93

View File

@@ -776,7 +776,7 @@ void wxAuiManager::SetManagedWindow(wxWindow* wnd)
wxAuiPaneInfo().Name(wxT("mdiclient")). wxAuiPaneInfo().Name(wxT("mdiclient")).
CenterPane().PaneBorder(false)); CenterPane().PaneBorder(false));
} }
else if (m_frame->IsKindOf(CLASSINFO(wxAuiMDIParentFrame))) else if (m_frame->IsKindOf(CLASSINFO(wxAuiMDIParentFrame)))
{ {
wxAuiMDIParentFrame* mdi_frame = (wxAuiMDIParentFrame*)m_frame; wxAuiMDIParentFrame* mdi_frame = (wxAuiMDIParentFrame*)m_frame;
wxAuiMDIClientWindow* client_window = mdi_frame->GetClientWindow(); wxAuiMDIClientWindow* client_window = mdi_frame->GetClientWindow();
@@ -2311,21 +2311,21 @@ void wxAuiManager::Update()
p.window->SetSize(1,1); p.window->SetSize(1,1);
// the following block is a workaround for bug #1531361 // the following block is a workaround for bug #1531361
// (see wxWidgets sourceforge page). On wxGTK (only), when // (see wxWidgets sourceforge page). On wxGTK (only), when
// a frame is shown/hidden, a move event unfortunately // a frame is shown/hidden, a move event unfortunately
// also gets fired. Because we may be dragging around // also gets fired. Because we may be dragging around
// a pane, we need to cancel that action here to prevent // a pane, we need to cancel that action here to prevent
// a spurious crash. // a spurious crash.
if (m_action_window == p.frame) if (m_action_window == p.frame)
{ {
if (wxWindow::GetCapture() == m_frame) if (wxWindow::GetCapture() == m_frame)
m_frame->ReleaseMouse(); m_frame->ReleaseMouse();
m_action = actionNone; m_action = actionNone;
m_action_window = NULL; m_action_window = NULL;
} }
// hide the frame // hide the frame
if (p.frame->IsShown()) if (p.frame->IsShown())
p.frame->Show(false); p.frame->Show(false);
@@ -2380,7 +2380,7 @@ void wxAuiManager::Update()
{ {
// frame already exists, make sure it's position // frame already exists, make sure it's position
// and size reflect the information in wxAuiPaneInfo // and size reflect the information in wxAuiPaneInfo
if (p.frame->GetPosition() != p.floating_pos) if ((p.frame->GetPosition() != p.floating_pos) || (p.frame->GetSize() != p.floating_size))
{ {
p.frame->SetSize(p.floating_pos.x, p.floating_pos.y, p.frame->SetSize(p.floating_pos.x, p.floating_pos.y,
p.floating_size.x, p.floating_size.y, p.floating_size.x, p.floating_size.y,
@@ -3566,7 +3566,7 @@ void wxAuiManager::OnRender(wxAuiManagerEvent& evt)
{ {
// if the frame is about to be deleted, don't bother // if the frame is about to be deleted, don't bother
if (!m_frame || wxPendingDelete.Member(m_frame)) if (!m_frame || wxPendingDelete.Member(m_frame))
return; return;
wxDC* dc = evt.GetDC(); wxDC* dc = evt.GetDC();