mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-06-02 12:30:59 +00:00
Merge change from the testplant_1 branch:
Do not include the toolbar in a window's saved frame. Makes saving and restoring window frame sizes independent of whether the toolbar is present at the time when the frame is saved or restored. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@31939 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
2d2edfca4f
commit
c1c4e6e3ea
2 changed files with 25 additions and 0 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
2011-01-24 Wolfgang Lux <wolfgang.lux@gmail.com>
|
||||||
|
|
||||||
|
* Source/NSWindow.m (-setFrameFromString:, -stringWithSavedFrame):
|
||||||
|
Merge change from the testplant_1 branch:
|
||||||
|
Do not include the toolbar in a window's saved frame. Makes saving
|
||||||
|
and restoring window frame sizes independent of whether the
|
||||||
|
toolbar is present at the time when the frame is saved or restored.
|
||||||
|
Patch by Doug Simons <doug.simons@@testplant.com>
|
||||||
|
|
||||||
2011-01-24 German Arias <german@xelalug.org>
|
2011-01-24 German Arias <german@xelalug.org>
|
||||||
|
|
||||||
* Source/NSMenuView.m (-trackWithEvent:): Fixed problems with
|
* Source/NSMenuView.m (-trackWithEvent:): Fixed problems with
|
||||||
|
|
|
@ -4603,6 +4603,14 @@ current key view.<br />
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// if toolbar is showing, adjust saved frame to add the toolbar back in
|
||||||
|
if ([_toolbar isVisible])
|
||||||
|
{
|
||||||
|
int toolbarHeight = [[_toolbar _toolbarView] frame].size.height;
|
||||||
|
fRect.size.height += toolbarHeight;
|
||||||
|
fRect.origin.y -= toolbarHeight;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Scan in the frame for the area the window was placed in in screen.
|
* Scan in the frame for the area the window was placed in in screen.
|
||||||
*/
|
*/
|
||||||
|
@ -4728,6 +4736,14 @@ current key view.<br />
|
||||||
|
|
||||||
fRect = _frame;
|
fRect = _frame;
|
||||||
|
|
||||||
|
// if toolbar is showing, adjust saved frame to not include the toolbar
|
||||||
|
if ([_toolbar isVisible])
|
||||||
|
{
|
||||||
|
int toolbarHeight = [[_toolbar _toolbarView] frame].size.height;
|
||||||
|
fRect.size.height -= toolbarHeight;
|
||||||
|
fRect.origin.y += toolbarHeight;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The screen rectangle should give the area of the screen in which
|
* The screen rectangle should give the area of the screen in which
|
||||||
* the window could be placed (ie a rectangle excluding the dock).
|
* the window could be placed (ie a rectangle excluding the dock).
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue