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

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

Issue 9224002: Make WebUI objects not derive from WebUI. WebUI objects own the controller. This is the ownership... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: sync to head to clear linux_chromeos browsertest failures Created 8 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
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 #include "chrome/browser/ui/webui/options/pack_extension_handler.h" 5 #include "chrome/browser/ui/webui/options/pack_extension_handler.h"
6 6
7 #include "chrome/browser/extensions/extension_creator.h" 7 #include "chrome/browser/extensions/extension_creator.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/utf_string_conversions.h" 9 #include "base/utf_string_conversions.h"
10 #include "content/browser/webui/web_ui.h"
10 #include "grit/generated_resources.h" 11 #include "grit/generated_resources.h"
11 #include "ui/base/l10n/l10n_util.h" 12 #include "ui/base/l10n/l10n_util.h"
12 13
13 PackExtensionHandler::PackExtensionHandler() { 14 PackExtensionHandler::PackExtensionHandler() {
14 } 15 }
15 16
16 PackExtensionHandler::~PackExtensionHandler() { 17 PackExtensionHandler::~PackExtensionHandler() {
17 if (pack_job_.get()) 18 if (pack_job_.get())
18 pack_job_->ClearClient(); 19 pack_job_->ClearClient();
19 } 20 }
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 114
114 pack_job_ = new PackExtensionJob(this, root_directory, key_file, run_flags); 115 pack_job_ = new PackExtensionJob(this, root_directory, key_file, run_flags);
115 pack_job_->Start(); 116 pack_job_->Start();
116 } 117 }
117 118
118 void PackExtensionHandler::ShowAlert(const std::string& message) { 119 void PackExtensionHandler::ShowAlert(const std::string& message) {
119 ListValue arguments; 120 ListValue arguments;
120 arguments.Append(Value::CreateStringValue(message)); 121 arguments.Append(Value::CreateStringValue(message));
121 web_ui()->CallJavascriptFunction("alert", arguments); 122 web_ui()->CallJavascriptFunction("alert", arguments);
122 } 123 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698