Permalink
Browse files

Moved the drawer to the right hand side of the Spotify window and pre…

…ttied up the buttons etc.
  • Loading branch information...
1 parent 871d933 commit 94705b73f4c225e988cec80d9bc03be1b5898802 @georgebrock committed Feb 11, 2009
View
@@ -7,3 +7,11 @@ otherwise noted in the individual files.
Full details of this license can be found at:
http://creativecommons.org/licenses/by-sa/3.0/
+
+
+
+The Last.fm logo is property of Last.fm
+
+The love, ban and tag icons are part of the famfamfam.com Silk icon set
+They are provided under a Creative Commons Attribution license
+See http://www.famfamfam.com/lab/icons/silk/ for more information
@@ -9,6 +9,11 @@
/* Begin PBXBuildFile section */
8D5B49B0048680CD000E48DA /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C167DFE841241C02AAC07 /* InfoPlist.strings */; };
8D5B49B4048680CD000E48DA /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7ADFEA557BF11CA2CBB /* Cocoa.framework */; };
+ C6BE8FF10F431AB5004BBEB7 /* icon_tag.png in Resources */ = {isa = PBXBuildFile; fileRef = C6BE8FEE0F431AB5004BBEB7 /* icon_tag.png */; };
+ C6BE8FF20F431AB5004BBEB7 /* icon_ban.png in Resources */ = {isa = PBXBuildFile; fileRef = C6BE8FEF0F431AB5004BBEB7 /* icon_ban.png */; };
+ C6BE8FF30F431AB5004BBEB7 /* icon_love.png in Resources */ = {isa = PBXBuildFile; fileRef = C6BE8FF00F431AB5004BBEB7 /* icon_love.png */; };
+ C6BE900D0F4321AE004BBEB7 /* LastifyDrawerView.m in Sources */ = {isa = PBXBuildFile; fileRef = C6BE900C0F4321AE004BBEB7 /* LastifyDrawerView.m */; };
+ C6BE903B0F4327E4004BBEB7 /* NSButton+Lastify.m in Sources */ = {isa = PBXBuildFile; fileRef = C6BE903A0F4327E4004BBEB7 /* NSButton+Lastify.m */; };
C6D68B570F212558000CB3C6 /* LastifyController.m in Sources */ = {isa = PBXBuildFile; fileRef = C6D68B560F212558000CB3C6 /* LastifyController.m */; };
C6D68B5E0F212820000CB3C6 /* LastifyInterface.xib in Resources */ = {isa = PBXBuildFile; fileRef = C6D68B5D0F212820000CB3C6 /* LastifyInterface.xib */; };
C6D68B9E0F2136BE000CB3C6 /* SPController+Lastify.m in Sources */ = {isa = PBXBuildFile; fileRef = C6D68B9D0F2136BE000CB3C6 /* SPController+Lastify.m */; };
@@ -26,6 +31,13 @@
32DBCF630370AF2F00C91783 /* Lastify_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Lastify_Prefix.pch; sourceTree = "<group>"; };
8D5B49B6048680CD000E48DA /* Lastify.bundle */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = Lastify.bundle; sourceTree = BUILT_PRODUCTS_DIR; };
8D5B49B7048680CD000E48DA /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
+ C6BE8FEE0F431AB5004BBEB7 /* icon_tag.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = icon_tag.png; sourceTree = "<group>"; };
+ C6BE8FEF0F431AB5004BBEB7 /* icon_ban.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = icon_ban.png; sourceTree = "<group>"; };
+ C6BE8FF00F431AB5004BBEB7 /* icon_love.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = icon_love.png; sourceTree = "<group>"; };
+ C6BE900B0F4321AE004BBEB7 /* LastifyDrawerView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LastifyDrawerView.h; sourceTree = "<group>"; };
+ C6BE900C0F4321AE004BBEB7 /* LastifyDrawerView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LastifyDrawerView.m; sourceTree = "<group>"; };
+ C6BE90390F4327E4004BBEB7 /* NSButton+Lastify.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSButton+Lastify.h"; sourceTree = "<group>"; };
+ C6BE903A0F4327E4004BBEB7 /* NSButton+Lastify.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSButton+Lastify.m"; sourceTree = "<group>"; };
C6D68B550F212558000CB3C6 /* LastifyController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LastifyController.h; sourceTree = "<group>"; };
C6D68B560F212558000CB3C6 /* LastifyController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = LastifyController.m; sourceTree = "<group>"; };
C6D68B5D0F212820000CB3C6 /* LastifyInterface.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = LastifyInterface.xib; sourceTree = "<group>"; };
@@ -80,6 +92,9 @@
089C167CFE841241C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
+ C6BE8FEE0F431AB5004BBEB7 /* icon_tag.png */,
+ C6BE8FEF0F431AB5004BBEB7 /* icon_ban.png */,
+ C6BE8FF00F431AB5004BBEB7 /* icon_love.png */,
C6D68BF90F21418D000CB3C6 /* lastfm_black.png */,
8D5B49B7048680CD000E48DA /* Info.plist */,
089C167DFE841241C02AAC07 /* InfoPlist.strings */,
@@ -100,10 +115,14 @@
C6D68B9A0F213660000CB3C6 /* SPController.h */,
C6D68B9C0F2136BE000CB3C6 /* SPController+Lastify.h */,
C6D68B9D0F2136BE000CB3C6 /* SPController+Lastify.m */,
+ C6BE90390F4327E4004BBEB7 /* NSButton+Lastify.h */,
+ C6BE903A0F4327E4004BBEB7 /* NSButton+Lastify.m */,
C6D68B550F212558000CB3C6 /* LastifyController.h */,
C6D68B560F212558000CB3C6 /* LastifyController.m */,
C6D68C040F214DAA000CB3C6 /* LastifyLastfmClient.h */,
C6D68C050F214DAA000CB3C6 /* LastifyLastfmClient.m */,
+ C6BE900B0F4321AE004BBEB7 /* LastifyDrawerView.h */,
+ C6BE900C0F4321AE004BBEB7 /* LastifyDrawerView.m */,
);
name = Classes;
sourceTree = "<group>";
@@ -188,6 +207,9 @@
8D5B49B0048680CD000E48DA /* InfoPlist.strings in Resources */,
C6D68B5E0F212820000CB3C6 /* LastifyInterface.xib in Resources */,
C6D68BFA0F21418D000CB3C6 /* lastfm_black.png in Resources */,
+ C6BE8FF10F431AB5004BBEB7 /* icon_tag.png in Resources */,
+ C6BE8FF20F431AB5004BBEB7 /* icon_ban.png in Resources */,
+ C6BE8FF30F431AB5004BBEB7 /* icon_love.png in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -203,6 +225,8 @@
C6D68C060F214DAA000CB3C6 /* LastifyLastfmClient.m in Sources */,
C6D68C9A0F21EF55000CB3C6 /* NSString+Lastify.m in Sources */,
C6D68CF90F21FE2C000CB3C6 /* SPGrowlDelegate+Lastify.m in Sources */,
+ C6BE900D0F4321AE004BBEB7 /* LastifyDrawerView.m in Sources */,
+ C6BE903B0F4327E4004BBEB7 /* NSButton+Lastify.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
View
@@ -17,6 +17,10 @@
IBOutlet NSTokenField *tagField;
LastifyLastfmClient *lastfm;
+ IBOutlet NSButton *loveButton;
+ IBOutlet NSButton *banButton;
+ IBOutlet NSButton *tagButton;
+
NSString *currentTrack;
NSString *currentArtist;
NSArray *currentTags;
View
@@ -11,6 +11,7 @@
#import "SPController.h"
#import "SPController+Lastify.h"
#import "SPGrowlDelegate+Lastify.h"
+#import "NSButton+Lastify.h"
@implementation LastifyController
@@ -67,15 +68,21 @@ - (void)initLastfmConnection
- (void)loadUserInterface
{
[NSBundle loadNibNamed:@"LastifyInterface" owner:self];
+
+ [loveButton setTextColor:[NSColor whiteColor]];
+ [banButton setTextColor:[NSColor whiteColor]];
+ [tagButton setTextColor:[NSColor whiteColor]];
+
[drawer setParentWindow:[[SPController sharedController] mainWindow]];
- NSSize contentSize = NSMakeSize(382, 30);
+ NSSize contentSize = NSMakeSize(71, 200);
[drawer setMaxContentSize:contentSize];
[drawer setMinContentSize:contentSize];
- [drawer setContentSize:contentSize];
- [drawer setLeadingOffset:10];
- [drawer setTrailingOffset:10];
- [drawer openOnEdge:NSMinYEdge];
+ [drawer setLeadingOffset:0];
+ [drawer setTrailingOffset:0];
+ [drawer openOnEdge:NSMaxXEdge];
[drawer setDelegate:self];
+
+ [drawer setContentSize:contentSize];
}
- (IBAction)authComplete:(id)sender
View
@@ -0,0 +1,16 @@
+//
+// LastifyDrawerView.h
+// Lastify
+//
+// Created by George on 11/02/2009.
+// Copyright 2008 George Brocklehurst. Some rights reserved (see accompanying LICENSE file for details).
+//
+
+#import <Cocoa/Cocoa.h>
+
+
+@interface LastifyDrawerView : NSView {
+
+}
+
+@end
View
@@ -0,0 +1,24 @@
+//
+// LastifyDrawerView.m
+// Lastify
+//
+// Created by George on 11/02/2009.
+// Copyright 2008 George Brocklehurst. Some rights reserved (see accompanying LICENSE file for details).
+//
+
+#import "LastifyDrawerView.h"
+
+
+@implementation LastifyDrawerView
+
+- (void)drawRect:(NSRect)rect
+{
+ [self lockFocus];
+ [[NSColor blackColor] set];
+ [NSBezierPath fillRect:rect];
+ [self unlockFocus];
+
+ [super drawRect:rect];
+}
+
+@end
Oops, something went wrong.

0 comments on commit 94705b7

Please sign in to comment.