Camino only - Bug 404161: Handle the Leopard status bar look correctly when hiding the status bar. r/sr=mento

This commit is contained in:
stuart.morgan%alumni.case.edu 2008-01-16 15:45:59 +00:00
Родитель ba17099974
Коммит 0ac5e0109b
1 изменённых файлов: 8 добавлений и 1 удалений

Просмотреть файл

@ -883,7 +883,8 @@ enum BWCOpenDest {
mustResizeChrome = YES;
}
if ([NSWorkspace isLeopardOrHigher]) {
[[self window] setContentBorderThickness:NSHeight([mStatusBar bounds]) forEdge:NSMinYEdge];
if (![mStatusBar isHidden])
[[self window] setContentBorderThickness:NSHeight([mStatusBar bounds]) forEdge:NSMinYEdge];
}
else {
// due to a cocoa issue with it updating the bounding box of two rects
@ -2525,6 +2526,12 @@ enum BWCOpenDest {
[[NSUserDefaults standardUserDefaults] setBool:shouldHide forKey:USER_DEFAULTS_HIDE_STATUS_BAR_KEY];
[mStatusBar setHidden:shouldHide];
if ([NSWorkspace isLeopardOrHigher]) {
if (shouldHide)
[[self window] setContentBorderThickness:0 forEdge:NSMinYEdge];
else
[[self window] setContentBorderThickness:NSHeight([mStatusBar bounds]) forEdge:NSMinYEdge];
}
NSSize oldContentSize = [mContentView frame].size;
NSRect windowRect = [[self window] frame];