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

Side by Side Diff: components/exo/shell_surface.h

Issue 1492803004: exo: Add SetGeometry function to ShellSurface class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@exosphere-xdg-shell
Patch Set: implement xdg_surface_set_window_geometry Created 5 years 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
« no previous file with comments | « no previous file | components/exo/shell_surface.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef COMPONENTS_EXO_SHELL_SURFACE_H_ 5 #ifndef COMPONENTS_EXO_SHELL_SURFACE_H_
6 #define COMPONENTS_EXO_SHELL_SURFACE_H_ 6 #define COMPONENTS_EXO_SHELL_SURFACE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 static void SetApplicationId(aura::Window* window, 51 static void SetApplicationId(aura::Window* window,
52 std::string* application_id); 52 std::string* application_id);
53 static const std::string GetApplicationId(aura::Window* window); 53 static const std::string GetApplicationId(aura::Window* window);
54 54
55 // Set application id for surface. 55 // Set application id for surface.
56 void SetApplicationId(const std::string& application_id); 56 void SetApplicationId(const std::string& application_id);
57 57
58 // Start an interactive move of surface. 58 // Start an interactive move of surface.
59 void Move(); 59 void Move();
60 60
61 // Set geometry for surface. The geometry represents the "visible bounds"
62 // for the surface from the user's perspective.
63 void SetGeometry(const gfx::Rect& geometry);
64
61 // Returns a trace value representing the state of the surface. 65 // Returns a trace value representing the state of the surface.
62 scoped_refptr<base::trace_event::TracedValue> AsTracedValue() const; 66 scoped_refptr<base::trace_event::TracedValue> AsTracedValue() const;
63 67
64 // Overridden from SurfaceDelegate: 68 // Overridden from SurfaceDelegate:
65 void OnSurfaceCommit() override; 69 void OnSurfaceCommit() override;
66 bool IsSurfaceSynchronized() const override; 70 bool IsSurfaceSynchronized() const override;
67 71
68 // Overridden from SurfaceObserver: 72 // Overridden from SurfaceObserver:
69 void OnSurfaceDestroying(Surface* surface) override; 73 void OnSurfaceDestroying(Surface* surface) override;
70 74
71 // Overridden from views::WidgetDelegate: 75 // Overridden from views::WidgetDelegate:
72 base::string16 GetWindowTitle() const override; 76 base::string16 GetWindowTitle() const override;
73 views::Widget* GetWidget() override; 77 views::Widget* GetWidget() override;
74 const views::Widget* GetWidget() const override; 78 const views::Widget* GetWidget() const override;
75 views::View* GetContentsView() override; 79 views::View* GetContentsView() override;
76 views::NonClientFrameView* CreateNonClientFrameView( 80 views::NonClientFrameView* CreateNonClientFrameView(
77 views::Widget* widget) override; 81 views::Widget* widget) override;
78 82
79 // Overridden from views::View: 83 // Overridden from views::View:
80 gfx::Size GetPreferredSize() const override; 84 gfx::Size GetPreferredSize() const override;
81 85
82 private: 86 private:
83 scoped_ptr<views::Widget> widget_; 87 scoped_ptr<views::Widget> widget_;
84 Surface* surface_; 88 Surface* surface_;
85 base::string16 title_; 89 base::string16 title_;
86 std::string application_id_; 90 std::string application_id_;
91 gfx::Rect geometry_;
87 92
88 DISALLOW_COPY_AND_ASSIGN(ShellSurface); 93 DISALLOW_COPY_AND_ASSIGN(ShellSurface);
89 }; 94 };
90 95
91 } // namespace exo 96 } // namespace exo
92 97
93 #endif // COMPONENTS_EXO_SHELL_SURFACE_H_ 98 #endif // COMPONENTS_EXO_SHELL_SURFACE_H_
OLDNEW
« no previous file with comments | « no previous file | components/exo/shell_surface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698