diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-04 05:42:11 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-04 05:42:11 +0000 |
commit | 0e7992cbfcf2922eb42cc85a4ccc8a9dfce2d252 (patch) | |
tree | a023736d890db05978a3403d4b010c2e948a72c3 /chrome/browser/views/frame | |
parent | 08df0f2fc34a4abc51e7d5f5f37bcdaaef82cab6 (diff) | |
download | chromium_src-0e7992cbfcf2922eb42cc85a4ccc8a9dfce2d252.zip chromium_src-0e7992cbfcf2922eb42cc85a4ccc8a9dfce2d252.tar.gz chromium_src-0e7992cbfcf2922eb42cc85a4ccc8a9dfce2d252.tar.bz2 |
Allow WindowGtks to be moved and sized when the mouse is over the caption or sizing border.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/118218
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17608 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views/frame')
-rw-r--r-- | chrome/browser/views/frame/browser_view.cc | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/chrome/browser/views/frame/browser_view.cc b/chrome/browser/views/frame/browser_view.cc index 9d41882..d122af1 100644 --- a/chrome/browser/views/frame/browser_view.cc +++ b/chrome/browser/views/frame/browser_view.cc @@ -57,17 +57,19 @@ #include "grit/theme_resources.h" #include "grit/webkit_resources.h" #include "views/controls/menu/menu.h" +#if defined(OS_WIN) +#include "views/controls/scrollbar/native_scroll_bar.h" +#endif #include "views/fill_layout.h" #include "views/view.h" #include "views/widget/root_view.h" #include "views/window/dialog_delegate.h" +#if !defined(OS_WIN) +#include "views/window/hit_test.h" +#endif #include "views/window/non_client_view.h" #include "views/window/window.h" -#if defined(OS_WIN) -#include "views/controls/scrollbar/native_scroll_bar.h" -#endif - using base::TimeDelta; // static @@ -1177,7 +1179,6 @@ bool BrowserView::CanClose() const { } int BrowserView::NonClientHitTest(const gfx::Point& point) { -#if defined(OS_WIN) // Since the TabStrip only renders in some parts of the top of the window, // the un-obscured area is considered to be part of the non-client caption // area of the window. So we need to treat hit-tests in these regions as @@ -1185,6 +1186,7 @@ int BrowserView::NonClientHitTest(const gfx::Point& point) { if (!frame_->GetWindow()->IsMaximized() && !frame_->GetWindow()->IsFullscreen()) { +#if defined(OS_WIN) CRect client_rect; ::GetClientRect(frame_->GetWindow()->GetNativeWindow(), &client_rect); gfx::Size resize_corner_size = ResizeCorner::GetSize(); @@ -1199,6 +1201,7 @@ int BrowserView::NonClientHitTest(const gfx::Point& point) { return HTBOTTOMLEFT; return HTBOTTOMRIGHT; } +#endif } // Determine if the TabStrip exists and is capable of being clicked on. We @@ -1254,10 +1257,6 @@ int BrowserView::NonClientHitTest(const gfx::Point& point) { // If the point is somewhere else, delegate to the default implementation. return views::ClientView::NonClientHitTest(point); -#else - NOTIMPLEMENTED(); - return 0; -#endif } gfx::Size BrowserView::GetMinimumSize() { |