mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-24 06:28:54 +00:00
Use tiles for drawing scroller slots, if available
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@29443 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
a3835dbe56
commit
cd3d1785e3
2 changed files with 20 additions and 10 deletions
|
@ -1,3 +1,9 @@
|
|||
2010-01-29 Eric Wasylishen <ewasylishen@gmail.com>
|
||||
|
||||
* Source/GSThemeDrawing.m (-cellForScrollerKnobSlot:): If there are
|
||||
tiles available, set the button cell as bordered so the tiles are
|
||||
used in drawing the scroller slot.
|
||||
|
||||
2010-01-29 Eric Wasylishen <ewasylishen@gmail.com>
|
||||
|
||||
* Source/GSTheme.m:
|
||||
|
|
|
@ -386,25 +386,29 @@
|
|||
|
||||
- (NSCell*) cellForScrollerKnobSlot: (BOOL)horizontal
|
||||
{
|
||||
GSDrawTiles *tiles;
|
||||
NSButtonCell *cell;
|
||||
NSColor *color;
|
||||
|
||||
cell = [NSButtonCell new];
|
||||
[cell setBordered: NO];
|
||||
[cell setTitle: nil];
|
||||
NSString *name;
|
||||
|
||||
if (horizontal)
|
||||
{
|
||||
color = [self colorNamed: GSScrollerHorizontalSlot
|
||||
state: GSThemeNormalState];
|
||||
[self setName: GSScrollerHorizontalSlot forElement: cell temporary: YES];
|
||||
name = GSScrollerHorizontalSlot;
|
||||
}
|
||||
else
|
||||
{
|
||||
color = [self colorNamed: GSScrollerVerticalSlot
|
||||
state: GSThemeNormalState];
|
||||
[self setName: GSScrollerVerticalSlot forElement: cell temporary: YES];
|
||||
name = GSScrollerVerticalSlot;
|
||||
}
|
||||
|
||||
tiles = [self tilesNamed: name state: GSThemeNormalState];
|
||||
color = [self colorNamed: name state: GSThemeNormalState];
|
||||
|
||||
cell = [NSButtonCell new];
|
||||
[cell setBordered: (tiles != nil)];
|
||||
[cell setTitle: nil];
|
||||
|
||||
[self setName: name forElement: cell temporary: YES];
|
||||
|
||||
if (color == nil)
|
||||
{
|
||||
color = [NSColor scrollBarColor];
|
||||
|
|
Loading…
Reference in a new issue