Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(648)

Side by Side Diff: trunk/src/chrome/browser/mac/keystone_glue.mm

Issue 141583005: Back out trunk r245361. (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | trunk/src/chrome/browser/mac/keystone_glue_unittest.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "chrome/browser/mac/keystone_glue.h" 5 #import "chrome/browser/mac/keystone_glue.h"
6 6
7 #include <sys/mount.h> 7 #include <sys/mount.h>
8 #include <sys/param.h> 8 #include <sys/param.h>
9 #include <sys/stat.h> 9 #include <sys/stat.h>
10 10
(...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after
548 - (void)checkForUpdate { 548 - (void)checkForUpdate {
549 DCHECK(![self asyncOperationPending]); 549 DCHECK(![self asyncOperationPending]);
550 550
551 if (!registration_) { 551 if (!registration_) {
552 [self updateStatus:kAutoupdateCheckFailed version:nil]; 552 [self updateStatus:kAutoupdateCheckFailed version:nil];
553 return; 553 return;
554 } 554 }
555 555
556 [self updateStatus:kAutoupdateChecking version:nil]; 556 [self updateStatus:kAutoupdateChecking version:nil];
557 557
558 // All checks from inside Chrome are considered user-initiated, because they 558 [registration_ checkForUpdate];
559 // only happen following a user action, such as visiting the about page.
560 // Non-user-initiated checks are the periodic checks automatically made by
561 // Keystone, which don't come through this code path (or even this process).
562 [registration_ checkForUpdateWasUserInitiated:YES];
563 559
564 // Upon completion, ksr::KSRegistrationCheckForUpdateNotification will be 560 // Upon completion, ksr::KSRegistrationCheckForUpdateNotification will be
565 // posted, and -checkForUpdateComplete: will be called. 561 // posted, and -checkForUpdateComplete: will be called.
566 } 562 }
567 563
568 - (void)checkForUpdateComplete:(NSNotification*)notification { 564 - (void)checkForUpdateComplete:(NSNotification*)notification {
569 NSDictionary* userInfo = [notification userInfo]; 565 NSDictionary* userInfo = [notification userInfo];
570 566
571 if ([[userInfo objectForKey:ksr::KSRegistrationUpdateCheckErrorKey] 567 if ([[userInfo objectForKey:ksr::KSRegistrationUpdateCheckErrorKey]
572 boolValue]) { 568 boolValue]) {
(...skipping 511 matching lines...) Expand 10 before | Expand all | Expand 10 after
1084 return [KeystoneGlue defaultKeystoneGlue] != nil; 1080 return [KeystoneGlue defaultKeystoneGlue] != nil;
1085 } 1081 }
1086 1082
1087 base::string16 CurrentlyInstalledVersion() { 1083 base::string16 CurrentlyInstalledVersion() {
1088 KeystoneGlue* keystoneGlue = [KeystoneGlue defaultKeystoneGlue]; 1084 KeystoneGlue* keystoneGlue = [KeystoneGlue defaultKeystoneGlue];
1089 NSString* version = [keystoneGlue currentlyInstalledVersion]; 1085 NSString* version = [keystoneGlue currentlyInstalledVersion];
1090 return base::SysNSStringToUTF16(version); 1086 return base::SysNSStringToUTF16(version);
1091 } 1087 }
1092 1088
1093 } // namespace keystone_glue 1089 } // namespace keystone_glue
OLDNEW
« no previous file with comments | « no previous file | trunk/src/chrome/browser/mac/keystone_glue_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698