OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 "keystone_glue.h" | 5 #import "keystone_glue.h" |
6 | 6 |
7 @interface KeystoneGlue(Private) | 7 @interface KeystoneGlue(Private) |
8 | 8 |
9 // Called periodically to announce activity by pinging the Keystone server. | 9 // Called periodically to announce activity by pinging the Keystone server. |
10 - (void)markActive:(NSTimer*)timer; | 10 - (void)markActive:(NSTimer*)timer; |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 } | 66 } |
67 return sDefaultKeystoneGlue; | 67 return sDefaultKeystoneGlue; |
68 } | 68 } |
69 | 69 |
70 - (void)dealloc { | 70 - (void)dealloc { |
71 [url_ release]; | 71 [url_ release]; |
72 [productID_ release]; | 72 [productID_ release]; |
73 [version_ release]; | 73 [version_ release]; |
74 [channel_ release]; | 74 [channel_ release]; |
75 [registration_ release]; | 75 [registration_ release]; |
| 76 [[NSNotificationCenter defaultCenter] removeObserver:self]; |
76 [super dealloc]; | 77 [super dealloc]; |
77 } | 78 } |
78 | 79 |
79 - (NSDictionary*)infoDictionary { | 80 - (NSDictionary*)infoDictionary { |
80 return [[NSBundle mainBundle] infoDictionary]; | 81 return [[NSBundle mainBundle] infoDictionary]; |
81 } | 82 } |
82 | 83 |
83 - (void)loadParameters { | 84 - (void)loadParameters { |
84 NSDictionary* infoDictionary = [self infoDictionary]; | 85 NSDictionary* infoDictionary = [self infoDictionary]; |
85 NSString* url = [infoDictionary objectForKey:@"KSUpdateURL"]; | 86 NSString* url = [infoDictionary objectForKey:@"KSUpdateURL"]; |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
220 [center addObserver:self | 221 [center addObserver:self |
221 selector:@selector(startUpdateComplete:) | 222 selector:@selector(startUpdateComplete:) |
222 name:KSRegistrationStartUpdateNotification | 223 name:KSRegistrationStartUpdateNotification |
223 object:nil]; | 224 object:nil]; |
224 startTarget_ = [target retain]; | 225 startTarget_ = [target retain]; |
225 [registration_ startUpdate]; | 226 [registration_ startUpdate]; |
226 return YES; | 227 return YES; |
227 } | 228 } |
228 | 229 |
229 @end | 230 @end |
OLD | NEW |