X-Git-Url: http://git.ithinksw.org/MenuTunes.git/blobdiff_plain/9d8dbcc95c9e3ea959f034d5ddb2edcc71fe1f59..4ede0106c6259161090d2d868d79218df942669e:/MTShizzleWindow.m?ds=inline diff --git a/MTShizzleWindow.m b/MTShizzleWindow.m index b5241c8..a0903a5 100755 --- a/MTShizzleWindow.m +++ b/MTShizzleWindow.m @@ -1,4 +1,5 @@ #import "MTShizzleWindow.h" +#import "MainController.h" @interface MTShizzleWindow (Private) - (void)setBling:(id)bling; @@ -37,6 +38,15 @@ static MTShizzleWindow *_privateSharedWindow = nil; return self; } +- (void)makeKeyAndOrderFront:(id)sender { + if ( ( [[NSDate date] timeIntervalSinceDate:[[MainController sharedController] getBlingTime]] >= 604800 ) && ([[regLater title] isEqualToString:@"Register Later"]) ) { + [regLater setTitle:@"Quit"]; + [regLater setTarget:[NSApplication sharedApplication]]; + [regLater setAction:@selector(terminate:)]; + } + [super makeKeyAndOrderFront:sender]; +} + - (void)dealloc { [regMessage release]; @@ -144,6 +154,7 @@ static MTShizzleWindow *_privateSharedWindow = nil; regLater = [[NSButton alloc] initWithFrame:NSMakeRect(138, 16, 116, 25)]; [regLater setTitle:@"Register Later"]; + [regLater setFont:[NSFont systemFontOfSize:[NSFont systemFontSize]]]; [regLater setTarget:_sender]; [regLater setAction:@selector(registerLater:)]; [regLater setBezelStyle:NSRoundedBezelStyle]; @@ -151,6 +162,7 @@ static MTShizzleWindow *_privateSharedWindow = nil; verifyKey = [[NSButton alloc] initWithFrame:NSMakeRect(255, 16, 116, 25)]; [verifyKey setTitle:@"Verify Key"]; + [verifyKey setFont:[NSFont systemFontOfSize:[NSFont systemFontSize]]]; [verifyKey setTarget:_sender]; [verifyKey setAction:@selector(verifyKey:)]; [verifyKey setBezelStyle:NSRoundedBezelStyle];