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

Unified Diff: chrome/browser/extensions/extension_infobar_module.cc

Issue 7635019: Set Extension Infobars to have a fixed height determined by the developer (clamped to sane min an... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/extension_infobar_module.cc
===================================================================
--- chrome/browser/extensions/extension_infobar_module.cc (revision 96544)
+++ chrome/browser/extensions/extension_infobar_module.cc (working copy)
@@ -33,6 +33,10 @@
std::string html_path;
EXTENSION_FUNCTION_VALIDATE(args->GetString(keys::kHtmlPath, &html_path));
+ int height = 0;
+ if (args->HasKey(keys::kHeight))
+ EXTENSION_FUNCTION_VALIDATE(args->GetInteger(keys::kHeight, &height));
+
const Extension* extension = GetExtension();
GURL url = extension->GetResourceURL(extension->url(), html_path);
@@ -54,7 +58,7 @@
tab_contents->AddInfoBar(
new ExtensionInfoBarDelegate(browser, tab_contents->tab_contents(),
- GetExtension(), url));
+ GetExtension(), url, height));
// TODO(finnur): Return the actual DOMWindow object. Bug 26463.
result_.reset(ExtensionTabUtil::CreateWindowValue(browser, false));

Powered by Google App Engine
This is Rietveld 408576698