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

Side by Side Diff: content/shell/browser/shell_aura.cc

Issue 194573006: [Ozone] Get aura::Window from host rather than dispatcher in shell_aura.cc (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/shell/browser/shell.h" 5 #include "content/shell/browser/shell.h"
6 6
7 #include "content/public/browser/web_contents.h" 7 #include "content/public/browser/web_contents.h"
8 #include "content/public/browser/web_contents_view.h" 8 #include "content/public/browser/web_contents_view.h"
9 #include "content/shell/browser/shell_platform_data_aura.h" 9 #include "content/shell/browser/shell_platform_data_aura.h"
10 #include "ui/aura/env.h" 10 #include "ui/aura/env.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 void Shell::PlatformCreateWindow(int width, int height) { 44 void Shell::PlatformCreateWindow(int width, int height) {
45 CHECK(platform_); 45 CHECK(platform_);
46 if (!headless_) 46 if (!headless_)
47 platform_->ShowWindow(); 47 platform_->ShowWindow();
48 platform_->ResizeWindow(gfx::Size(width, height)); 48 platform_->ResizeWindow(gfx::Size(width, height));
49 } 49 }
50 50
51 void Shell::PlatformSetContents() { 51 void Shell::PlatformSetContents() {
52 CHECK(platform_); 52 CHECK(platform_);
53 aura::Window* content = web_contents_->GetView()->GetNativeView(); 53 aura::Window* content = web_contents_->GetView()->GetNativeView();
54 aura::Window* parent = platform_->dispatcher()->window(); 54 aura::Window* parent = platform_->host()->window();
55 if (parent->Contains(content)) 55 if (parent->Contains(content))
56 return; 56 return;
57 parent->AddChild(content); 57 parent->AddChild(content);
58 content->Show(); 58 content->Show();
59 } 59 }
60 60
61 void Shell::PlatformResizeSubViews() { 61 void Shell::PlatformResizeSubViews() {
62 } 62 }
63 63
64 void Shell::Close() { 64 void Shell::Close() {
65 delete this; 65 delete this;
66 } 66 }
67 67
68 void Shell::PlatformSetTitle(const base::string16& title) { 68 void Shell::PlatformSetTitle(const base::string16& title) {
69 } 69 }
70 70
71 bool Shell::PlatformHandleContextMenu( 71 bool Shell::PlatformHandleContextMenu(
72 const content::ContextMenuParams& params) { 72 const content::ContextMenuParams& params) {
73 return false; 73 return false;
74 } 74 }
75 75
76 } // namespace content 76 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698