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

Unified Diff: sky/tools/debugger/debugger.cc

Issue 673073002: Fix border parsing to work again (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Remove included change Created 6 years, 2 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
« no previous file with comments | « sky/engine/core/css/parser/BisonCSSParser-in.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/tools/debugger/debugger.cc
diff --git a/sky/tools/debugger/debugger.cc b/sky/tools/debugger/debugger.cc
index 29bae26af7e5def7a352bd60daf3a6ea60ce408f..52d00447dbc5a965c9a246c22e3cade317babe5b 100644
--- a/sky/tools/debugger/debugger.cc
+++ b/sky/tools/debugger/debugger.cc
@@ -70,6 +70,9 @@ class SkyDebugger : public mojo::ApplicationDelegate,
window_manager_app_->InitFocus(
new FocusRules(window_manager_app_.get(), content_));
+
+ if (!pending_url_.empty())
+ NavigateToURL(pending_url_);
}
virtual void OnViewManagerDisconnected(
@@ -98,7 +101,13 @@ class SkyDebugger : public mojo::ApplicationDelegate,
// Overridden from Debugger
virtual void NavigateToURL(const mojo::String& url) override {
- content_->Embed(url);
+ // We can get Navigate commands before we've actually been
+ // embedded into the view and content_ created.
+ // Just save the last one.
+ if (content_)
+ content_->Embed(url);
+ else
+ pending_url_ = url;
}
scoped_ptr<mojo::WindowManagerApp> window_manager_app_;
@@ -106,6 +115,7 @@ class SkyDebugger : public mojo::ApplicationDelegate,
mojo::ViewManager* view_manager_;
mojo::View* root_;
mojo::View* content_;
+ std::string pending_url_;
DISALLOW_COPY_AND_ASSIGN(SkyDebugger);
};
« no previous file with comments | « sky/engine/core/css/parser/BisonCSSParser-in.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698