mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-22 12:00:45 +00:00
Merge ChangeLog
This commit is contained in:
commit
9a91d04bc0
9 changed files with 164 additions and 2 deletions
12
ChangeLog
12
ChangeLog
|
@ -16,6 +16,18 @@
|
|||
* Source/NSTreeController.m: Implement new methods.
|
||||
* Source/NSTreeNode.m: Implement new methods
|
||||
|
||||
2024-05-04 Gregory John Casamento <greg.casamento@gmail.com>
|
||||
|
||||
* Headers/AppKit/AppKit.h: Add NSMenuToolbarItem.h
|
||||
* Headers/AppKit/NSMenuToolbarItem.h: Declarations
|
||||
for NSMenuToolbarItem.
|
||||
* Images/GNUmakefile: Add new image
|
||||
* Images/nsmapping.strings: Add image mapping
|
||||
* MISSING: Remove this class from the list
|
||||
* Source/GNUmakefile: Add class to build
|
||||
* Source/NSMenuToolbarItem.m: Implementation of
|
||||
NSMenuToolbarItem.
|
||||
|
||||
2024-06-07 Gregory John Casamento <greg.casamento@gmail.com>
|
||||
|
||||
* Headers/Additions/GNUstepGUI/GSTheme.h: Add new methods
|
||||
|
|
|
@ -101,6 +101,7 @@
|
|||
#import <AppKit/NSMenu.h>
|
||||
#import <AppKit/NSMenuItem.h>
|
||||
#import <AppKit/NSMenuItemCell.h>
|
||||
#import <AppKit/NSMenuToolbarItem.h>
|
||||
#import <AppKit/NSMenuView.h>
|
||||
#import <AppKit/NSNibLoading.h>
|
||||
#import <AppKit/NSOpenPanel.h>
|
||||
|
|
60
Headers/AppKit/NSMenuToolbarItem.h
Normal file
60
Headers/AppKit/NSMenuToolbarItem.h
Normal file
|
@ -0,0 +1,60 @@
|
|||
/* Definition of class NSMenuToolbarItem
|
||||
Copyright (C) 2024 Free Software Foundation, Inc.
|
||||
|
||||
By: Gregory John Casamento
|
||||
Date: 03-05-2024
|
||||
|
||||
This file is part of the GNUstep Library.
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
This library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free
|
||||
Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
||||
Boston, MA 02110 USA.
|
||||
*/
|
||||
|
||||
#ifndef _NSMenuToolbarItem_h_GNUSTEP_GUI_INCLUDE
|
||||
#define _NSMenuToolbarItem_h_GNUSTEP_GUI_INCLUDE
|
||||
|
||||
#import <AppKit/NSToolbarItem.h>
|
||||
#import <AppKit/AppKitDefines.h>
|
||||
|
||||
#if OS_API_VERSION(MAC_OS_X_VERSION_10_15, GS_API_LATEST)
|
||||
|
||||
#if defined(__cplusplus)
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
@class NSMenu;
|
||||
|
||||
APPKIT_EXPORT_CLASS
|
||||
@interface NSMenuToolbarItem : NSToolbarItem
|
||||
{
|
||||
BOOL _showsIndicator;
|
||||
NSMenu *_menu;
|
||||
}
|
||||
|
||||
- (BOOL) showsIndicator;
|
||||
- (void) setShowsIndicator: (BOOL)flag;
|
||||
|
||||
- (NSMenu *) menu;
|
||||
- (void) setMenu: (NSMenu *)menu;
|
||||
|
||||
@end
|
||||
|
||||
#if defined(__cplusplus)
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* GS_API_MACOSX */
|
||||
|
||||
#endif /* _NSMenuToolbarItem_h_GNUSTEP_GUI_INCLUDE */
|
|
@ -90,6 +90,7 @@ Images_RESOURCE_FILES = \
|
|||
common_Info.tiff\
|
||||
common_LeftTabStop.tiff \
|
||||
common_LibraryFolder.tiff \
|
||||
common_MenuToolbarItem.tiff \
|
||||
common_MiniWindowTile.tiff \
|
||||
common_Miniaturize.tiff \
|
||||
common_MiniaturizeH.tiff \
|
||||
|
|
BIN
Images/common_MenuToolbarItem.tiff
Normal file
BIN
Images/common_MenuToolbarItem.tiff
Normal file
Binary file not shown.
|
@ -45,7 +45,8 @@ common_ToolbarShowColorsItem = NSToolbarShowColors;
|
|||
common_ToolbarShowFontsItem = NSToolbarShowFonts;
|
||||
common_RecyclerEmpty = NSImageTrashEmpty;
|
||||
common_RecyclerFull = NSImageTrashFull;
|
||||
|
||||
common_MenuToolbarItem = NSMenuToolbarItem;
|
||||
|
||||
/* Misc. */
|
||||
|
||||
common_MultipleSelection = NSImageNameMultipleDocuments;
|
||||
|
|
1
MISSING
1
MISSING
|
@ -7,7 +7,6 @@ MISSING HEADERS ( * = difficult, - = quick, + = placeholder, x = won't do )
|
|||
> NSFilePromiseProvider.h -
|
||||
> NSFilePromiseReceiver.h -
|
||||
> NSItemProvider.h +
|
||||
> NSMenuToolbarItem.h -
|
||||
> NSOpenGLLayer.h +
|
||||
> NSTypesetter.h +
|
||||
> NSUserActivity.h -
|
||||
|
|
|
@ -180,6 +180,7 @@ NSStoryboardSegue.m \
|
|||
NSMagnificationGestureRecognizer.m \
|
||||
NSMatrix.m \
|
||||
NSMenu.m \
|
||||
NSMenuToolbarItem.m \
|
||||
NSMenuView.m \
|
||||
NSMenuItem.m \
|
||||
NSMenuItemCell.m \
|
||||
|
@ -497,6 +498,7 @@ NSMediaLibraryBrowserController.h \
|
|||
NSMenu.h \
|
||||
NSMenuItem.h \
|
||||
NSMenuItemCell.h \
|
||||
NSMenuToolbarItem.h \
|
||||
NSMenuView.h \
|
||||
NSMovie.h \
|
||||
NSMovieView.h \
|
||||
|
|
86
Source/NSMenuToolbarItem.m
Normal file
86
Source/NSMenuToolbarItem.m
Normal file
|
@ -0,0 +1,86 @@
|
|||
/* Implementation of class NSMenuToolbarItem
|
||||
Copyright (C) 2024 Free Software Foundation, Inc.
|
||||
|
||||
By: Gregory John Casamento
|
||||
Date: 03-05-2024
|
||||
|
||||
This file is part of the GNUstep Library.
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
This library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, write to the Free
|
||||
Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
||||
Boston, MA 02110 USA.
|
||||
*/
|
||||
|
||||
#import "AppKit/NSMenuToolbarItem.h"
|
||||
#import "AppKit/NSMenu.h"
|
||||
#import "AppKit/NSImage.h"
|
||||
|
||||
#import "GNUstepGUI/GSTheme.h"
|
||||
|
||||
@implementation NSMenuToolbarItem
|
||||
|
||||
- (instancetype) initWithItemIdentifier: (NSString *)identifier
|
||||
{
|
||||
self = [super initWithItemIdentifier: identifier];
|
||||
if (self != nil)
|
||||
{
|
||||
[self setImage: [NSImage imageNamed: @"NSMenuToolbarItem"]];
|
||||
[self setTarget: self];
|
||||
[self setAction: @selector(_showMenu:)];
|
||||
}
|
||||
return self;
|
||||
}
|
||||
|
||||
- (void) dealloc
|
||||
{
|
||||
RELEASE(_menu);
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (BOOL) showsIndicator
|
||||
{
|
||||
return _showsIndicator;
|
||||
}
|
||||
|
||||
- (void) setShowsIndicator: (BOOL)flag
|
||||
{
|
||||
_showsIndicator = flag;
|
||||
|
||||
if (_showsIndicator == YES)
|
||||
{
|
||||
[self setImage: [NSImage imageNamed: @"NSMenuToolbarItem"]];
|
||||
}
|
||||
else
|
||||
{
|
||||
[self setImage: nil];
|
||||
}
|
||||
}
|
||||
|
||||
- (NSMenu *) menu
|
||||
{
|
||||
return _menu;
|
||||
}
|
||||
|
||||
- (void) setMenu: (NSMenu *)menu
|
||||
{
|
||||
ASSIGN(_menu, menu);
|
||||
}
|
||||
|
||||
- (void) _showMenu: (id)sender
|
||||
{
|
||||
[[GSTheme theme] rightMouseDisplay: _menu
|
||||
forEvent: nil];
|
||||
}
|
||||
|
||||
@end
|
Loading…
Reference in a new issue