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

Unified Diff: chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc

Issue 10580039: Adds ability to render omnibox as a view above the page. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix windows Created 8 years, 6 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/ui/views/omnibox/omnibox_popup_contents_view.cc
diff --git a/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc b/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc
index 75cf9ddaab7f90d8d44f6e61acb9e801594cf6b7..ca077a86413a665cc0de29767adc6bc1fd1a72ec 100644
--- a/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc
+++ b/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc
@@ -16,6 +16,7 @@
#include "chrome/browser/themes/theme_service.h"
#include "chrome/browser/ui/omnibox/omnibox_view.h"
#include "chrome/browser/ui/views/location_bar/location_bar_view.h"
+#include "chrome/browser/ui/views/omnibox/inline_omnibox_popup_view.h"
#include "chrome/browser/ui/views/omnibox/omnibox_result_view.h"
#include "chrome/browser/ui/views/omnibox/touch_omnibox_popup_contents_view.h"
#include "grit/chromium_strings.h"
@@ -78,11 +79,24 @@ class OmniboxPopupContentsView::AutocompletePopupWidget
////////////////////////////////////////////////////////////////////////////////
// OmniboxPopupContentsView, public:
-OmniboxPopupContentsView* OmniboxPopupContentsView::CreateForEnvironment(
+OmniboxPopupView* OmniboxPopupContentsView::Create(
const gfx::Font& font,
OmniboxView* omnibox_view,
AutocompleteEditModel* edit_model,
- views::View* location_bar) {
+ views::View* location_bar,
+ views::View* popup_parent_view) {
+ // TODO(sky): add a flag to enable this.
+ /*
+ if (...) {
+ InlineOmniboxPopupView* inline_view =
+ new InlineOmniboxPopupView(font, omnibox_view, edit_model,
+ location_bar);
+ inline_view->Init();
+ popup_parent_view->AddChildView(inline_view);
+ return inline_view;
+ }
+ */
+
OmniboxPopupContentsView* view = NULL;
if (ui::GetDisplayLayout() == ui::LAYOUT_TOUCH) {
view = new TouchOmniboxPopupContentsView(

Powered by Google App Engine
This is Rietveld 408576698