fixed bugs with setting the client size when the difference between the total and client size changes as the result (e.g. because the scrollbars [dis]appear or the menu bar [un]wraps
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12934 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -148,12 +148,13 @@ wxPoint wxFrameBase::GetClientAreaOrigin() const
|
||||
wxPoint pt = wxTopLevelWindow::GetClientAreaOrigin();
|
||||
|
||||
#if wxUSE_TOOLBAR
|
||||
if ( GetToolBar() && GetToolBar()->IsShown() )
|
||||
wxToolBar *toolbar = GetToolBar();
|
||||
if ( toolbar && toolbar->IsShown() )
|
||||
{
|
||||
int w, h;
|
||||
GetToolBar()->GetSize(& w, & h);
|
||||
toolbar->GetSize(&w, &h);
|
||||
|
||||
if ( GetToolBar()->GetWindowStyleFlag() & wxTB_VERTICAL )
|
||||
if ( toolbar->GetWindowStyleFlag() & wxTB_VERTICAL )
|
||||
{
|
||||
pt.x += w;
|
||||
}
|
||||
@@ -186,7 +187,7 @@ bool wxFrameBase::ProcessCommand(int id)
|
||||
{
|
||||
if (!item->IsEnabled())
|
||||
return TRUE;
|
||||
|
||||
|
||||
if (item->IsCheckable())
|
||||
{
|
||||
item->Toggle();
|
||||
|
Reference in New Issue
Block a user