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

Side by Side Diff: ui/aura/demo/demo_main.cc

Issue 12342028: make menus, bubbles, etc. top level windows on aura (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review fixes Created 7 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "base/at_exit.h" 5 #include "base/at_exit.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "base/i18n/icu_util.h" 7 #include "base/i18n/icu_util.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "third_party/skia/include/core/SkXfermode.h" 10 #include "third_party/skia/include/core/SkXfermode.h"
(...skipping 25 matching lines...) Expand all
36 36
37 // Overridden from WindowDelegate: 37 // Overridden from WindowDelegate:
38 virtual gfx::Size GetMinimumSize() const OVERRIDE { 38 virtual gfx::Size GetMinimumSize() const OVERRIDE {
39 return gfx::Size(); 39 return gfx::Size();
40 } 40 }
41 41
42 virtual gfx::Size GetMaximumSize() const OVERRIDE { 42 virtual gfx::Size GetMaximumSize() const OVERRIDE {
43 return gfx::Size(); 43 return gfx::Size();
44 } 44 }
45 45
46 virtual void SetHostTransitionBounds(const gfx::Rect& bounds) OVERRIDE {}
47
46 virtual void OnBoundsChanged(const gfx::Rect& old_bounds, 48 virtual void OnBoundsChanged(const gfx::Rect& old_bounds,
47 const gfx::Rect& new_bounds) OVERRIDE {} 49 const gfx::Rect& new_bounds) OVERRIDE {}
48 virtual gfx::NativeCursor GetCursor(const gfx::Point& point) OVERRIDE { 50 virtual gfx::NativeCursor GetCursor(const gfx::Point& point) OVERRIDE {
49 return gfx::kNullCursor; 51 return gfx::kNullCursor;
50 } 52 }
51 virtual int GetNonClientComponent(const gfx::Point& point) const OVERRIDE { 53 virtual int GetNonClientComponent(const gfx::Point& point) const OVERRIDE {
52 return HTCAPTION; 54 return HTCAPTION;
53 } 55 }
54 virtual bool ShouldDescendIntoChildForEventHandling( 56 virtual bool ShouldDescendIntoChildForEventHandling(
55 aura::Window* child, 57 aura::Window* child,
56 const gfx::Point& location) OVERRIDE { 58 const gfx::Point& location) OVERRIDE {
57 return true; 59 return true;
58 } 60 }
59 virtual bool CanFocus() OVERRIDE { return true; } 61 virtual bool CanFocus() OVERRIDE { return true; }
60 virtual void OnCaptureLost() OVERRIDE {} 62 virtual void OnCaptureLost() OVERRIDE {}
61 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE { 63 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE {
62 canvas->DrawColor(color_, SkXfermode::kSrc_Mode); 64 canvas->DrawColor(color_, SkXfermode::kSrc_Mode);
63 } 65 }
64 virtual void OnDeviceScaleFactorChanged(float device_scale_factor) OVERRIDE {} 66 virtual void OnDeviceScaleFactorChanged(float device_scale_factor) OVERRIDE {}
67 virtual void OnWindowHidingAnimationCompleted() OVERRIDE {}
65 virtual void OnWindowDestroying() OVERRIDE {} 68 virtual void OnWindowDestroying() OVERRIDE {}
66 virtual void OnWindowDestroyed() OVERRIDE {} 69 virtual void OnWindowDestroyed() OVERRIDE {}
67 virtual void OnWindowTargetVisibilityChanged(bool visible) OVERRIDE {} 70 virtual void OnWindowTargetVisibilityChanged(bool visible) OVERRIDE {}
68 virtual bool HasHitTestMask() const OVERRIDE { return false; } 71 virtual bool HasHitTestMask() const OVERRIDE { return false; }
69 virtual void GetHitTestMask(gfx::Path* mask) const OVERRIDE {} 72 virtual void GetHitTestMask(gfx::Path* mask) const OVERRIDE {}
70 virtual scoped_refptr<ui::Texture> CopyTexture() OVERRIDE { 73 virtual scoped_refptr<ui::Texture> CopyTexture() OVERRIDE {
71 return scoped_refptr<ui::Texture>(); 74 return scoped_refptr<ui::Texture>();
72 } 75 }
73 76
74 private: 77 private:
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 162
160 // The exit manager is in charge of calling the dtors of singleton objects. 163 // The exit manager is in charge of calling the dtors of singleton objects.
161 base::AtExitManager exit_manager; 164 base::AtExitManager exit_manager;
162 165
163 ui::RegisterPathProvider(); 166 ui::RegisterPathProvider();
164 icu_util::Initialize(); 167 icu_util::Initialize();
165 ResourceBundle::InitSharedInstanceWithLocale("en-US", NULL); 168 ResourceBundle::InitSharedInstanceWithLocale("en-US", NULL);
166 169
167 return DemoMain(); 170 return DemoMain();
168 } 171 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698