Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(718)

Unified Diff: Source/EmUpAppController.m

Issue 764041: Add Release Notes button to Update alert; change Update destination to Downloads page Base URL: http://google-email-uploader-mac.googlecode.com/svn/trunk/
Patch Set: Created 15 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/English.lproj/Localizable.strings » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/EmUpAppController.m
===================================================================
--- Source/EmUpAppController.m (revision 31)
+++ Source/EmUpAppController.m (working copy)
@@ -165,8 +165,9 @@
NSString *msg = NSLocalizedString(@"UpdateAvailableMsg", nil);
NSString *updateBtn = NSLocalizedString(@"UpdateButton", nil); // "Update Now"
NSString *dontUpdateBtn = NSLocalizedString(@"DontUpdateButton", nil); // "Don't Update"
+ NSString *releaseNotesBtn = NSLocalizedString(@"ReleaseNotesButton", nil); // "Release Notes"
- NSBeginAlertSheet(title, updateBtn, dontUpdateBtn, nil,
+ NSBeginAlertSheet(title, updateBtn, dontUpdateBtn, releaseNotesBtn,
[windowController window], self,
@selector(updateSheetDidEnd:returnCode:contextInfo:),
nil, nil, msg, thisVersion, latestVersion);
@@ -178,9 +179,16 @@
- (void)updateSheetDidEnd:(NSWindow *)sheet returnCode:(int)returnCode contextInfo:(void *)contextInfo {
- if (returnCode == NSOKButton) {
- // open the project page
- NSString *urlStr = @"https://code.google.com/p/google-email-uploader-mac/";
+ NSString *urlStr = nil;
+ if (returnCode == NSAlertDefaultReturn) {
+ // downloads page
+ urlStr = @"https://code.google.com/p/google-email-uploader-mac/downloads/list";
+ } else if (returnCode == NSAlertOtherReturn) {
+ // release notes file in the source tree
+ urlStr = @"https://code.google.com/p/google-email-uploader-mac/source/browse/trunk/Source/ReleaseNotes.txt";
TVL 2010/03/26 00:41:01 do you want the revision history, etc? or would h
Greg Robbins 2010/03/26 00:46:17 Done.
+ }
+
+ if (urlStr) {
[[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:urlStr]];
}
}
« no previous file with comments | « no previous file | Source/English.lproj/Localizable.strings » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b