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

Unified Diff: apps/ui/views/shell_window_frame_view.h

Issue 27029006: apps: Move chrome's ShellWindowFrameView into apps/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 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
Index: apps/ui/views/shell_window_frame_view.h
diff --git a/chrome/browser/ui/views/extensions/shell_window_frame_view.h b/apps/ui/views/shell_window_frame_view.h
similarity index 72%
rename from chrome/browser/ui/views/extensions/shell_window_frame_view.h
rename to apps/ui/views/shell_window_frame_view.h
index a244b02a3b55e757364a1d646c36918d80c5ab52..433371c58cb03120b9762b3dc3d98159b1c804a9 100644
--- a/chrome/browser/ui/views/extensions/shell_window_frame_view.h
+++ b/apps/ui/views/shell_window_frame_view.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CHROME_BROWSER_UI_VIEWS_EXTENSIONS_SHELL_WINDOW_FRAME_VIEW_H_
-#define CHROME_BROWSER_UI_VIEWS_EXTENSIONS_SHELL_WINDOW_FRAME_VIEW_H_
+#ifndef APPS_UI_VIEWS_SHELL_WINDOW_FRAME_VIEW_H_
+#define APPS_UI_VIEWS_SHELL_WINDOW_FRAME_VIEW_H_
#include <string>
@@ -29,6 +29,8 @@ class Widget;
class NativeAppWindowViews;
+namespace apps {
+
// A frameless or non-Ash, non-panel NonClientFrameView for app windows.
class ShellWindowFrameView : public views::NonClientFrameView,
public views::ButtonListener {
@@ -38,7 +40,14 @@ class ShellWindowFrameView : public views::NonClientFrameView,
explicit ShellWindowFrameView(NativeAppWindowViews* window);
virtual ~ShellWindowFrameView();
- void Init(views::Widget* frame);
+ // Initializes this for the window |frame|. Sets the number of pixels for
+ // which a click is interpreted as a resize for the inner and outer border of
+ // the window and the lower-right corner resize handle.
+ void Init(views::Widget* frame,
+ int resize_inside_bounds_size,
+ int resize_outside_bounds_size,
+ int resize_outside_scale_for_touch,
+ int resize_area_corner_size);
private:
// views::NonClientFrameView implementation.
@@ -71,7 +80,15 @@ class ShellWindowFrameView : public views::NonClientFrameView,
views::ImageButton* restore_button_;
views::ImageButton* minimize_button_;
+ // Allow resize for clicks this many pixels inside the bounds.
+ int resize_inside_bounds_size_;
+
+ // Size in pixels of the lower-right corner resize handle.
+ int resize_area_corner_size_;
+
DISALLOW_COPY_AND_ASSIGN(ShellWindowFrameView);
};
-#endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_SHELL_WINDOW_FRAME_VIEW_H_
+} // namespace apps
+
+#endif // APPS_UI_VIEWS_SHELL_WINDOW_FRAME_VIEW_H_

Powered by Google App Engine
This is Rietveld 408576698