mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-28 11:50:45 +00:00
* Headers/Additions/GNUstepGUI/GSTheme.h: Added new method
declaration for updateAllWindowsWithMenu: * Source/GSThemeMenu.m: Added default implementation of updateAllWindowsWithMenu: * Source/NSMenu.m: Added call to updateAllWindowsWithMenu: on current theme. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29445 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
f886235d70
commit
94ea683223
4 changed files with 45 additions and 0 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
2010-01-29 22:14-EST Gregory John Casamento <greg.casamento@gmail.com>
|
||||||
|
|
||||||
|
* Headers/Additions/GNUstepGUI/GSTheme.h: Added new method
|
||||||
|
declaration for updateAllWindowsWithMenu:
|
||||||
|
* Source/GSThemeMenu.m: Added default implementation of
|
||||||
|
updateAllWindowsWithMenu:
|
||||||
|
* Source/NSMenu.m: Added call to updateAllWindowsWithMenu: on
|
||||||
|
current theme.
|
||||||
|
|
||||||
2010-01-29 Eric Wasylishen <ewasylishen@gmail.com>
|
2010-01-29 Eric Wasylishen <ewasylishen@gmail.com>
|
||||||
|
|
||||||
* Source/NSTableHeaderCell.m:
|
* Source/NSTableHeaderCell.m:
|
||||||
|
|
|
@ -1015,10 +1015,38 @@ withRepeatedImage: (NSImage*)image
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@interface GSTheme (Menus)
|
@interface GSTheme (Menus)
|
||||||
|
/**
|
||||||
|
* This method sets the menu for the window using the current theme
|
||||||
|
* In the default theme this calls the setMenu: method on the window
|
||||||
|
* giving the menu parameter as the argument.
|
||||||
|
*/
|
||||||
- (void) setMenu: (NSMenu *)menu forWindow: (NSWindow *)window;
|
- (void) setMenu: (NSMenu *)menu forWindow: (NSWindow *)window;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Processes menu events for the theme. The default implementation
|
||||||
|
* does nothing.
|
||||||
|
*/
|
||||||
- (void) processCommand: (void *)context;
|
- (void) processCommand: (void *)context;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calculate the height of the menu for in-window menus. The default
|
||||||
|
* implementation returns [NSMenuView menuBarHeight];
|
||||||
|
*/
|
||||||
- (float) menuHeightForWindow: (NSWindow *)window;
|
- (float) menuHeightForWindow: (NSWindow *)window;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update the menu for the window. This refreshes the menu contents.
|
||||||
|
* The default implementation of this method does nothing.
|
||||||
|
*/
|
||||||
- (void) updateMenu: (NSMenu *)menu forWindow: (NSWindow *)window;
|
- (void) updateMenu: (NSMenu *)menu forWindow: (NSWindow *)window;
|
||||||
|
- (void) updateAllWindowsWithMenu: (NSMenu *) menu;
|
||||||
|
@end
|
||||||
|
|
||||||
|
@interface GSTheme (OpenSavePanels)
|
||||||
|
/**
|
||||||
|
* This method displays and returns the open panel needed by the
|
||||||
|
* native environment.
|
||||||
|
*/
|
||||||
@end
|
@end
|
||||||
|
|
||||||
#endif /* OS_API_VERSION */
|
#endif /* OS_API_VERSION */
|
||||||
|
|
|
@ -94,5 +94,10 @@
|
||||||
{
|
{
|
||||||
// default implementation of this method does nothing.
|
// default implementation of this method does nothing.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (void) updateAllWindowsWithMenu: (NSMenu *) menu
|
||||||
|
{
|
||||||
|
// default implementation of this method does nothing.
|
||||||
|
}
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
|
|
@ -57,6 +57,7 @@
|
||||||
#include "AppKit/NSAttributedString.h"
|
#include "AppKit/NSAttributedString.h"
|
||||||
|
|
||||||
#include "GSGuiPrivate.h"
|
#include "GSGuiPrivate.h"
|
||||||
|
#include "GNUstepGUI/GSTheme.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Drawing related:
|
Drawing related:
|
||||||
|
@ -1064,6 +1065,8 @@ static BOOL menuBarVisible = YES;
|
||||||
{
|
{
|
||||||
[w setMenu: self];
|
[w setMenu: self];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[[GSTheme theme] updateAllWindowsWithMenu: self];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (_delegate)
|
if (_delegate)
|
||||||
|
|
Loading…
Reference in a new issue