Makes views be initially hidden

This better matches what other toolkits do and lets the client
configure the view before we attempt to show something for it.

BUG=434429
TEST=covered by test
R=erg@chromium.org

Review URL: https://codereview.chromium.org/745743002
This commit is contained in:
Scott Violet
2014-11-20 13:04:25 -08:00
parent 2017aace78
commit 00886da677
2 changed files with 2 additions and 0 deletions

View File

@@ -59,6 +59,7 @@ void SkyDebugger::OnEmbed(
content_ = mojo::View::Create(view_manager_);
content_->SetBounds(root_->bounds());
root_->AddChild(content_);
content_->SetVisible(true);
window_manager_app_->InitFocus(
scoped_ptr<mojo::FocusRules>(new mojo::BasicFocusRules(content_)));

View File

@@ -74,6 +74,7 @@ class SkyTester : public mojo::ApplicationDelegate,
content_ = mojo::View::Create(view_manager_);
content_->SetBounds(root_->bounds());
root_->AddChild(content_);
content_->SetVisible(true);
std::cout << "#READY\n";
std::cout.flush();