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

Side by Side Diff: chrome/browser/extensions/extension_disabled_ui.cc

Issue 18854021: Making the extension permissions dialog scrollable, when needed (adding expandable sections for thi… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Polishing Created 7 years, 5 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/extensions/extension_disabled_ui.h" 5 #include "chrome/browser/extensions/extension_disabled_ui.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 std::vector<string16> ExtensionDisabledGlobalError::GetBubbleViewMessages() { 259 std::vector<string16> ExtensionDisabledGlobalError::GetBubbleViewMessages() {
260 std::vector<string16> messages; 260 std::vector<string16> messages;
261 messages.push_back(l10n_util::GetStringFUTF16( 261 messages.push_back(l10n_util::GetStringFUTF16(
262 extension_->is_app() ? 262 extension_->is_app() ?
263 IDS_APP_DISABLED_ERROR_LABEL : IDS_EXTENSION_DISABLED_ERROR_LABEL, 263 IDS_APP_DISABLED_ERROR_LABEL : IDS_EXTENSION_DISABLED_ERROR_LABEL,
264 UTF8ToUTF16(extension_->name()))); 264 UTF8ToUTF16(extension_->name())));
265 messages.push_back(l10n_util::GetStringUTF16( 265 messages.push_back(l10n_util::GetStringUTF16(
266 IDS_EXTENSION_PROMPT_WILL_NOW_HAVE_ACCESS_TO)); 266 IDS_EXTENSION_PROMPT_WILL_NOW_HAVE_ACCESS_TO));
267 std::vector<string16> permission_warnings = 267 std::vector<string16> permission_warnings =
268 extension_->GetActivePermissions()->GetWarningMessages( 268 extension_->GetActivePermissions()->GetWarningMessages(
269 extension_->GetType()); 269 extension_->GetType(), false);
270 for (size_t i = 0; i < permission_warnings.size(); ++i) { 270 for (size_t i = 0; i < permission_warnings.size(); ++i) {
271 messages.push_back(l10n_util::GetStringFUTF16( 271 messages.push_back(l10n_util::GetStringFUTF16(
272 IDS_EXTENSION_PERMISSION_LINE, permission_warnings[i])); 272 IDS_EXTENSION_PERMISSION_LINE, permission_warnings[i]));
273 } 273 }
274 return messages; 274 return messages;
275 } 275 }
276 276
277 string16 ExtensionDisabledGlobalError::GetBubbleViewAcceptButtonLabel() { 277 string16 ExtensionDisabledGlobalError::GetBubbleViewAcceptButtonLabel() {
278 return l10n_util::GetStringUTF16(IDS_EXTENSION_PROMPT_RE_ENABLE_BUTTON); 278 return l10n_util::GetStringUTF16(IDS_EXTENSION_PROMPT_RE_ENABLE_BUTTON);
279 } 279 }
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 void ShowExtensionDisabledDialog(ExtensionService* service, 372 void ShowExtensionDisabledDialog(ExtensionService* service,
373 content::WebContents* web_contents, 373 content::WebContents* web_contents,
374 const Extension* extension) { 374 const Extension* extension) {
375 scoped_ptr<ExtensionInstallPrompt> install_ui( 375 scoped_ptr<ExtensionInstallPrompt> install_ui(
376 new ExtensionInstallPrompt(web_contents)); 376 new ExtensionInstallPrompt(web_contents));
377 // This object manages its own lifetime. 377 // This object manages its own lifetime.
378 new ExtensionDisabledDialogDelegate(service, install_ui.Pass(), extension); 378 new ExtensionDisabledDialogDelegate(service, install_ui.Pass(), extension);
379 } 379 }
380 380
381 } // namespace extensions 381 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698