Experimental font size increase and decrease added to Cmd-+ and Cmd--, fixed small bug in skipping to previous album, updated KnownIssues
This commit is contained in:
parent
085130dd34
commit
b317d0ba01
6 changed files with 1825 additions and 1703 deletions
|
@ -84,4 +84,9 @@ OSStatus handleHotKey(EventHandlerCallRef nextHandler,EventRef theEvent,void *us
|
|||
- (void)clickPrev;
|
||||
- (void)clickNext;
|
||||
|
||||
- (IBAction)increaseFontSize:(id)sender;
|
||||
- (IBAction)decreaseFontSize:(id)sender;
|
||||
- (void)changeFontSize:(float)size;
|
||||
|
||||
|
||||
@end
|
||||
|
|
|
@ -474,4 +474,42 @@ increase/decrease as long as the user holds the left/right, plus/minus button */
|
|||
[playbackController next:nil];
|
||||
}
|
||||
|
||||
- (void)changeFontSize:(float)size
|
||||
{
|
||||
|
||||
|
||||
NSFont *f = [[NSFontManager sharedFontManager] selectedFont];
|
||||
float origFontSize = [[f fontDescriptor] pointSize];
|
||||
|
||||
f = [[NSFontManager sharedFontManager] convertFont:f toSize:origFontSize+size];
|
||||
|
||||
NSEnumerator *oe = [[playlistView tableColumns] objectEnumerator];
|
||||
id c;
|
||||
|
||||
NSLayoutManager *layoutManager = [[NSLayoutManager alloc] init];
|
||||
[playlistView setRowHeight:[layoutManager defaultLineHeightForFont:f]];
|
||||
[layoutManager release];
|
||||
|
||||
while (c = [oe nextObject])
|
||||
{
|
||||
[[c dataCell] setFont:f];
|
||||
}
|
||||
|
||||
// we must set the selectedFont so that we have updated font information
|
||||
// next time we want to change it
|
||||
[[NSFontManager sharedFontManager] setSelectedFont:f isMultiple:NO];
|
||||
|
||||
|
||||
}
|
||||
|
||||
- (IBAction)increaseFontSize:(id)sender
|
||||
{
|
||||
[self changeFontSize:1];
|
||||
}
|
||||
|
||||
- (IBAction)decreaseFontSize:(id)sender
|
||||
{
|
||||
[self changeFontSize:-1];
|
||||
|
||||
}
|
||||
@end
|
||||
|
|
|
@ -408,6 +408,8 @@ double linearToLogarithmic(double linear)
|
|||
if (foundAlbum == NO)
|
||||
{
|
||||
foundAlbum = YES;
|
||||
// now we need to move up to the first song in the album, so we'll
|
||||
// go till we either find index 0, or the first song in the album
|
||||
origAlbum = [[playlistController entryAtIndex:i] album];
|
||||
i--;
|
||||
}
|
||||
|
@ -417,7 +419,7 @@ double linearToLogarithmic(double linear)
|
|||
}
|
||||
}
|
||||
|
||||
if (foundAlbum == YES)
|
||||
if ((foundAlbum == YES) && i != 0)
|
||||
i++;
|
||||
[self playEntryAtIndex:i];
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load diff
10
KnownIssues
10
KnownIssues
|
@ -1,2 +1,12 @@
|
|||
Undo is broken badly when filtering.
|
||||
|
||||
Font resize of playlist does not change filedrawer, and
|
||||
does not resize columns (needs a lower bound)
|
||||
|
||||
Code for fading and seeking should be moved into the AudioPlayer,
|
||||
so we can escape ugly event* functions
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -40,6 +40,8 @@
|
|||
[[c dataCell] setFont:bf];
|
||||
}
|
||||
|
||||
[[NSFontManager sharedFontManager] setSelectedFont:bf isMultiple:NO];
|
||||
|
||||
NSTableHeaderView *currentTableHeaderView = [self headerView];
|
||||
PlaylistHeaderView *customTableHeaderView = [[PlaylistHeaderView alloc] init];
|
||||
|
||||
|
|
Loading…
Reference in a new issue