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

Side by Side Diff: chrome/browser/ui/webui/options/chromeos/about_page_handler.cc

Issue 7867044: PART1: Initiated the SignedSettings refactoring. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased to ToT and cleaned up some tests. Created 9 years, 2 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "chrome/browser/ui/webui/options/chromeos/about_page_handler.h" 5 #include "chrome/browser/ui/webui/options/chromeos/about_page_handler.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 virtual void UpdateStatusChanged(UpdateLibrary* object) { 73 virtual void UpdateStatusChanged(UpdateLibrary* object) {
74 page_handler_->UpdateStatus(object->status()); 74 page_handler_->UpdateStatus(object->status());
75 } 75 }
76 76
77 AboutPageHandler* page_handler_; 77 AboutPageHandler* page_handler_;
78 78
79 DISALLOW_COPY_AND_ASSIGN(UpdateObserver); 79 DISALLOW_COPY_AND_ASSIGN(UpdateObserver);
80 }; 80 };
81 81
82 AboutPageHandler::AboutPageHandler() 82 AboutPageHandler::AboutPageHandler()
83 : CrosOptionsPageUIHandler( 83 : progress_(-1),
84 new UserCrosSettingsProvider),
85 progress_(-1),
86 sticky_(false), 84 sticky_(false),
87 started_(false) 85 started_(false)
88 {} 86 {}
89 87
90 AboutPageHandler::~AboutPageHandler() { 88 AboutPageHandler::~AboutPageHandler() {
91 if (update_observer_.get()) { 89 if (update_observer_.get()) {
92 CrosLibrary::Get()->GetUpdateLibrary()-> 90 CrosLibrary::Get()->GetUpdateLibrary()->
93 RemoveObserver(update_observer_.get()); 91 RemoveObserver(update_observer_.get());
94 } 92 }
95 } 93 }
(...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after
413 if (CrosLibrary::Get()->GetUpdateLibrary()->HasObserver(observer)) { 411 if (CrosLibrary::Get()->GetUpdateLibrary()->HasObserver(observer)) {
414 // If UpdateLibrary still has the observer, then the page handler is valid. 412 // If UpdateLibrary still has the observer, then the page handler is valid.
415 AboutPageHandler* handler = observer->page_handler(); 413 AboutPageHandler* handler = observer->page_handler();
416 scoped_ptr<Value> channel_string(Value::CreateStringValue(channel)); 414 scoped_ptr<Value> channel_string(Value::CreateStringValue(channel));
417 handler->web_ui_->CallJavascriptFunction( 415 handler->web_ui_->CallJavascriptFunction(
418 "AboutPage.updateSelectedOptionCallback", *channel_string); 416 "AboutPage.updateSelectedOptionCallback", *channel_string);
419 } 417 }
420 } 418 }
421 419
422 } // namespace chromeos 420 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698