mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 03:11:18 +00:00
Make drawing use the component cell to render
This commit is contained in:
parent
c67ca273a9
commit
7764903d6d
3 changed files with 12 additions and 12 deletions
|
@ -252,6 +252,8 @@
|
|||
@class NSProgressIndicator;
|
||||
@class NSTableHeaderCell;
|
||||
@class NSTabViewItem;
|
||||
@class NSPathControl;
|
||||
@class NSPathComponentCell;
|
||||
@class GSDrawTiles;
|
||||
@class GSTitleView;
|
||||
|
||||
|
@ -975,9 +977,8 @@ APPKIT_EXPORT NSString *GSThemeWillDeactivateNotification;
|
|||
// NSPathComponentCell
|
||||
|
||||
- (void) drawPathComponentCellWithFrame: (NSRect)f
|
||||
inView: (NSView *)v
|
||||
withURL: (NSURL *)u
|
||||
image: (NSImage *)i
|
||||
inView: (NSPathControl *)pc
|
||||
withCell: (NSPathComponentCell *)cell
|
||||
isLastComponent: (BOOL)last;
|
||||
|
||||
// NSSegmentedControl drawing methods
|
||||
|
|
|
@ -954,19 +954,19 @@
|
|||
// NSPathComponentCell
|
||||
|
||||
- (void) drawPathComponentCellWithFrame: (NSRect)f
|
||||
inView: (NSView *)v
|
||||
withURL: (NSURL *)u
|
||||
image: (NSImage *)i
|
||||
inView: (NSPathControl *)pc
|
||||
withCell: (NSPathComponentCell *)cell
|
||||
isLastComponent: (BOOL)lc
|
||||
{
|
||||
NSImage *i = [cell image];
|
||||
NSURL *u = [cell URL];
|
||||
NSString *string = [[u path] lastPathComponent];
|
||||
NSRect textFrame = f;
|
||||
NSRect imgFrame = f;
|
||||
NSRect arrowFrame = f;
|
||||
NSImage *arrowImage = [NSImage imageNamed: @"NSMenuArrow"];
|
||||
NSPathControl *pc = (NSPathControl *)v;
|
||||
NSPathStyle s = [pc pathStyle];
|
||||
|
||||
|
||||
if (s == NSPathStyleStandard || s == NSPathStyleNavigationBar)
|
||||
{
|
||||
if (s == NSPathStyleNavigationBar)
|
||||
|
@ -1005,7 +1005,7 @@
|
|||
{
|
||||
if (lc == YES)
|
||||
{
|
||||
NSRect newFrame = [v frame];
|
||||
NSRect newFrame = [pc frame];
|
||||
|
||||
arrowImage = [NSImage imageNamed: @"common_ArrowDown"];
|
||||
|
||||
|
|
|
@ -58,9 +58,8 @@
|
|||
{
|
||||
[super drawInteriorWithFrame: f inView: v];
|
||||
[[GSTheme theme] drawPathComponentCellWithFrame: f
|
||||
inView: v
|
||||
withURL: _url
|
||||
image: _image
|
||||
inView: (NSPathControl *)v
|
||||
withCell: self
|
||||
isLastComponent: _lastComponent];
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue