mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 06:51:44 +00:00
Add NSPathControlItem
This commit is contained in:
parent
3dc3feda41
commit
5811355c00
3 changed files with 63 additions and 0 deletions
|
@ -33,9 +33,27 @@
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
@class NSURL, NSAttributedString, NSImage, NSString;
|
||||
|
||||
@interface NSPathControlItem : NSObject
|
||||
{
|
||||
NSURL *_url;
|
||||
NSAttributedString *_attributedTitle;
|
||||
NSImage *_image;
|
||||
NSString *_title;
|
||||
}
|
||||
|
||||
- (NSURL *) URL;
|
||||
- (void) setURL: (NSURL *)url;
|
||||
|
||||
- (NSAttributedString *) attributedTitle;
|
||||
- (void) setAttributedTitle: (NSAttributedString *)attributedTitle;
|
||||
|
||||
- (NSImage *) image;
|
||||
- (void) setImage: (NSImage *)image;
|
||||
|
||||
- (NSString *) title;
|
||||
- (void) setTitle: (NSString *)title;
|
||||
|
||||
@end
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
*/
|
||||
|
||||
#import <Foundation/NSURL.h>
|
||||
|
||||
#import "AppKit/NSPathComponentCell.h"
|
||||
#import "AppKit/NSImage.h"
|
||||
|
||||
|
|
|
@ -22,9 +22,53 @@
|
|||
Boston, MA 02110 USA.
|
||||
*/
|
||||
|
||||
#import <Foundation/NSString.h>
|
||||
#import <Foundation/NSURL.h>
|
||||
#import "AppKit/NSPathControlItem.h"
|
||||
#import "AppKit/NSImage.h"
|
||||
#import "AppKit/NSAttributedString.h"
|
||||
|
||||
@implementation NSPathControlItem
|
||||
|
||||
- (NSAttributedString *) attributedTitle
|
||||
{
|
||||
return _attributedTitle;
|
||||
}
|
||||
|
||||
- (void) setAttributedTitle: (NSAttributedString *)attributedTitle
|
||||
{
|
||||
ASSIGNCOPY(_attributedTitle, attributedTitle);
|
||||
}
|
||||
|
||||
- (NSImage *) image
|
||||
{
|
||||
return _image;
|
||||
}
|
||||
|
||||
- (void) setImage: (NSImage *)image
|
||||
{
|
||||
ASSIGNCOPY(_image, image);
|
||||
}
|
||||
|
||||
- (NSURL *) URL
|
||||
{
|
||||
return _url;
|
||||
}
|
||||
|
||||
- (void) setURL: (NSURL *)url
|
||||
{
|
||||
ASSIGNCOPY(_url, url);
|
||||
}
|
||||
|
||||
- (NSString *) title
|
||||
{
|
||||
return _title;
|
||||
}
|
||||
|
||||
- (void) setTitle: (NSString *)title
|
||||
{
|
||||
ASSIGNCOPY(_title, title);
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
|
|
Loading…
Reference in a new issue