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

Unified Diff: mandoline/ui/browser/android/android_ui.cc

Issue 1133893003: Omnibox app (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 years, 7 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: mandoline/ui/browser/android/android_ui.cc
diff --git a/mandoline/ui/browser/android/android_ui.cc b/mandoline/ui/browser/android/android_ui.cc
index 7cdbc72201e099e59427f6d3956a8b45528a0ff1..3ee950fcab443e3634f6d15d27e0d439221b02c0 100644
--- a/mandoline/ui/browser/android/android_ui.cc
+++ b/mandoline/ui/browser/android/android_ui.cc
@@ -10,9 +10,11 @@
namespace mandoline {
-AndroidUI::AndroidUI(Browser* browser, mojo::Shell* shell)
+class Browser;
+
+AndroidUI::AndroidUI(Browser* browser, mojo::ApplicationImpl* application_impl)
: browser_(browser),
- shell_(shell),
+ application_impl_(application_impl),
root_(nullptr),
content_(nullptr) {}
@@ -20,12 +22,14 @@ AndroidUI::~AndroidUI() {
root_->RemoveObserver(this);
}
-void AndroidUI::Init(mojo::View* root, mojo::View* content) {
+void AndroidUI::Init(mojo::View* root) {
root_ = root;
root_->AddObserver(this);
- content_ = content;
- content_->SetBounds(root_->bounds());
+ browser_->content()->SetBounds(root_->bounds());
+}
+
+void AndroidUI::OnURLChanged() override {
}
void AndroidUI::OnViewBoundsChanged(mojo::View* view,
@@ -36,8 +40,9 @@ void AndroidUI::OnViewBoundsChanged(mojo::View* view,
}
// static
-BrowserUI* BrowserUI::Create(Browser* browser, mojo::Shell* shell) {
- return new AndroidUI(browser, shell);
+BrowserUI* BrowserUI::Create(Browser* browser,
+ mojo::ApplicationImpl* application_impl) {
+ return new AndroidUI(browser, application_impl);
}
} // namespace mandoline

Powered by Google App Engine
This is Rietveld 408576698