diff options
Diffstat (limited to 'chrome')
19 files changed, 87 insertions, 328 deletions
diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc index 8f4145b..edca8df 100644 --- a/chrome/browser/browser.cc +++ b/chrome/browser/browser.cc @@ -11,10 +11,12 @@ #include "base/idle_timer.h" #include "base/logging.h" #include "base/string_util.h" +#include "chrome/app/chrome_dll_resource.h" #include "chrome/browser/browser_list.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/browser_shutdown.h" #include "chrome/browser/browser_url_handler.h" +#include "chrome/browser/browser_window.h" #include "chrome/browser/cert_store.h" #include "chrome/browser/debugger/debugger_window.h" #include "chrome/browser/dom_ui/new_tab_ui.h" @@ -35,9 +37,9 @@ #include "chrome/browser/views/bookmark_bar_view.h" #include "chrome/browser/views/html_dialog_view.h" #include "chrome/browser/views/location_bar_view.h" +#include "chrome/browser/views/status_bubble.h" #include "chrome/browser/views/tabs/tab_strip.h" #include "chrome/browser/views/toolbar_star_toggle.h" -#include "chrome/browser/vista_frame.h" #include "chrome/browser/window_sizer.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/chrome_switches.h" diff --git a/chrome/browser/browser.vcproj b/chrome/browser/browser.vcproj index e98fea0..5ab27dd 100644 --- a/chrome/browser/browser.vcproj +++ b/chrome/browser/browser.vcproj @@ -1062,14 +1062,6 @@ > </File> <File - RelativePath=".\frame_view.cc" - > - </File> - <File - RelativePath=".\frame_view.h" - > - </File> - <File RelativePath=".\js_before_unload_handler.cc" > </File> @@ -1162,14 +1154,6 @@ > </File> <File - RelativePath=".\window_clipping_info.cc" - > - </File> - <File - RelativePath=".\window_clipping_info.h" - > - </File> - <File RelativePath=".\window_sizer.cc" > </File> @@ -1199,34 +1183,6 @@ </File> </Filter> <Filter - Name="XPFrame" - > - <File - RelativePath=".\point_buffer.cc" - > - </File> - <File - RelativePath=".\point_buffer.h" - > - </File> - <File - RelativePath=".\simple_xp_frame.cc" - > - </File> - <File - RelativePath=".\simple_xp_frame.h" - > - </File> - <File - RelativePath=".\xp_frame.cc" - > - </File> - <File - RelativePath=".\xp_frame.h" - > - </File> - </Filter> - <Filter Name="Destination" > <File @@ -1583,26 +1539,6 @@ </File> </Filter> <Filter - Name="VistaFrame" - > - <File - RelativePath=".\simple_vista_frame.cc" - > - </File> - <File - RelativePath=".\simple_vista_frame.h" - > - </File> - <File - RelativePath=".\vista_frame.cc" - > - </File> - <File - RelativePath=".\vista_frame.h" - > - </File> - </Filter> - <Filter Name="WebData" > <File diff --git a/chrome/browser/frame_util.cc b/chrome/browser/frame_util.cc index 7e8c94b..63f27f0 100644 --- a/chrome/browser/frame_util.cc +++ b/chrome/browser/frame_util.cc @@ -15,11 +15,11 @@ #include "chrome/browser/profile.h" #include "chrome/browser/profile_manager.h" #include "chrome/browser/render_view_host.h" -#include "chrome/browser/simple_vista_frame.h" -#include "chrome/browser/simple_xp_frame.h" -#include "chrome/browser/vista_frame.h" +#include "chrome/browser/views/old_frames/simple_vista_frame.h" +#include "chrome/browser/views/old_frames/simple_xp_frame.h" +#include "chrome/browser/views/old_frames/vista_frame.h" +#include "chrome/browser/views/old_frames/xp_frame.h" #include "chrome/browser/web_contents.h" -#include "chrome/browser/xp_frame.h" #include "chrome/common/notification_source.h" #include "chrome/common/win_util.h" #include "chrome/views/focus_manager.h" diff --git a/chrome/browser/views/browser_views.vcproj b/chrome/browser/views/browser_views.vcproj index d7072d7..15054b5 100644 --- a/chrome/browser/views/browser_views.vcproj +++ b/chrome/browser/views/browser_views.vcproj @@ -381,6 +381,58 @@ > </File> </Filter> + <Filter + Name="Frame (Old)" + > + <File + RelativePath=".\old_frames\frame_view.cc" + > + </File> + <File + RelativePath=".\old_frames\frame_view.h" + > + </File> + <File + RelativePath=".\old_frames\point_buffer.cc" + > + </File> + <File + RelativePath=".\old_frames\point_buffer.h" + > + </File> + <File + RelativePath=".\old_frames\simple_vista_frame.cc" + > + </File> + <File + RelativePath=".\old_frames\simple_vista_frame.h" + > + </File> + <File + RelativePath=".\old_frames\simple_xp_frame.cc" + > + </File> + <File + RelativePath=".\old_frames\simple_xp_frame.h" + > + </File> + <File + RelativePath=".\old_frames\vista_frame.cc" + > + </File> + <File + RelativePath=".\old_frames\vista_frame.h" + > + </File> + <File + RelativePath=".\old_frames\xp_frame.cc" + > + </File> + <File + RelativePath=".\old_frames\xp_frame.h" + > + </File> + </Filter> <File RelativePath=".\about_chrome_view.cc" > diff --git a/chrome/browser/frame_view.cc b/chrome/browser/views/old_frames/frame_view.cc index 9dd4872..3375d07 100644 --- a/chrome/browser/frame_view.cc +++ b/chrome/browser/views/old_frames/frame_view.cc @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "chrome/browser/frame_view.h" +#include "chrome/browser/views/old_frames/frame_view.h" #include "chrome/browser/browser_window.h" #include "chrome/browser/views/tabs/tab_strip.h" diff --git a/chrome/browser/frame_view.h b/chrome/browser/views/old_frames/frame_view.h index 81e3010..81e3010 100644 --- a/chrome/browser/frame_view.h +++ b/chrome/browser/views/old_frames/frame_view.h diff --git a/chrome/browser/point_buffer.cc b/chrome/browser/views/old_frames/point_buffer.cc index 93b3b47..e9ff263 100644 --- a/chrome/browser/point_buffer.cc +++ b/chrome/browser/views/old_frames/point_buffer.cc @@ -2,7 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "chrome/browser/point_buffer.h" +#include "chrome/browser/views/old_frames/point_buffer.h" + #include "base/logging.h" PointBuffer::PointBuffer() : points_(NULL), diff --git a/chrome/browser/point_buffer.h b/chrome/browser/views/old_frames/point_buffer.h index 721a922..94a0808 100644 --- a/chrome/browser/point_buffer.h +++ b/chrome/browser/views/old_frames/point_buffer.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_POINT_BUFFER_H__ -#define CHROME_BROWSER_POINT_BUFFER_H__ +#ifndef CHROME_BROWSER_VIEWS_OLD_FRAMES_POINT_BUFFER_H__ +#define CHROME_BROWSER_VIEWS_OLD_FRAMES_POINT_BUFFER_H__ #include <windows.h> @@ -57,5 +57,5 @@ class PointBuffer { DISALLOW_EVIL_CONSTRUCTORS(PointBuffer); }; -#endif // CHROME_BROWSER_PATH_BUFFER_H__ +#endif // CHROME_BROWSER_VIEWS_OLD_FRAMES_POINT_BUFFER_H__ diff --git a/chrome/browser/simple_vista_frame.cc b/chrome/browser/views/old_frames/simple_vista_frame.cc index 8f5a1eb..fc25e6a 100644 --- a/chrome/browser/simple_vista_frame.cc +++ b/chrome/browser/views/old_frames/simple_vista_frame.cc @@ -2,8 +2,9 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +#include "chrome/browser/views/old_frames/simple_vista_frame.h" + #include "chrome/app/theme/theme_resources.h" -#include "chrome/browser/simple_vista_frame.h" #include "chrome/browser/browser.h" #include "chrome/browser/profile.h" #include "chrome/browser/tab_contents.h" diff --git a/chrome/browser/simple_vista_frame.h b/chrome/browser/views/old_frames/simple_vista_frame.h index 7b92418..c267f7d 100644 --- a/chrome/browser/simple_vista_frame.h +++ b/chrome/browser/views/old_frames/simple_vista_frame.h @@ -2,11 +2,11 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef CHROME_BROWSER_SIMPLE_VISTA_FRAME_H__ -#define CHROME_BROWSER_SIMPLE_VISTA_FRAME_H__ +#ifndef CHROME_BROWSER_VIEWS_OLD_FRAMES_SIMPLE_VISTA_FRAME_H__ +#define CHROME_BROWSER_VIEWS_OLD_FRAMES_SIMPLE_VISTA_FRAME_H__ #include "chrome/browser/views/location_bar_view.h" -#include "chrome/browser/vista_frame.h" +#include "chrome/browser/views/old_frames/vista_frame.h" class WebAppIconManager; @@ -81,5 +81,5 @@ class SimpleVistaFrame : public VistaFrame, DISALLOW_EVIL_CONSTRUCTORS(SimpleVistaFrame); }; -#endif // CHROME_BROWSER_SIMPLE_VISTA_FRAME_H__ +#endif // CHROME_BROWSER_VIEWS_OLD_FRAMES_SIMPLE_VISTA_FRAME_H__ diff --git a/chrome/browser/simple_xp_frame.cc b/chrome/browser/views/old_frames/simple_xp_frame.cc index 19d7f7b..4c4d506 100644 --- a/chrome/browser/simple_xp_frame.cc +++ b/chrome/browser/views/old_frames/simple_xp_frame.cc @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "chrome/browser/simple_xp_frame.h" +#include "chrome/browser/views/old_frames/simple_xp_frame.h" #include "chrome/app/theme/theme_resources.h" #include "base/string_util.h" diff --git a/chrome/browser/simple_xp_frame.h b/chrome/browser/views/old_frames/simple_xp_frame.h index 7e5b7c2..24a8a25 100644 --- a/chrome/browser/simple_xp_frame.h +++ b/chrome/browser/views/old_frames/simple_xp_frame.h @@ -2,12 +2,12 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef CHROME_BROWSER_SIMPLE_XP_FRAME_H__ -#define CHROME_BROWSER_SIMPLE_XP_FRAME_H__ +#ifndef CHROME_BROWSER_VIEWS_OLD_FRAMES_SIMPLE_XP_FRAME_H__ +#define CHROME_BROWSER_VIEWS_OLD_FRAMES_SIMPLE_XP_FRAME_H__ #include "chrome/browser/views/location_bar_view.h" +#include "chrome/browser/views/old_frames/xp_frame.h" #include "chrome/browser/views/tab_icon_view.h" -#include "chrome/browser/xp_frame.h" #include "chrome/views/menu_button.h" #include "chrome/views/view_menu_delegate.h" @@ -173,5 +173,5 @@ class SimpleXPFrameTitleBar : public ChromeViews::View, DISALLOW_EVIL_CONSTRUCTORS(SimpleXPFrameTitleBar); }; -#endif // CHROME_BROWSER_SIMPLE_XP_FRAME_H__ +#endif // CHROME_BROWSER_VIEWS_OLD_FRAMES_SIMPLE_XP_FRAME_H__ diff --git a/chrome/browser/vista_frame.cc b/chrome/browser/views/old_frames/vista_frame.cc index 2ff4964..faa1213 100644 --- a/chrome/browser/vista_frame.cc +++ b/chrome/browser/views/old_frames/vista_frame.cc @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "chrome/browser/vista_frame.h" +#include "chrome/browser/views/old_frames/vista_frame.h" #include <windows.h> #include <atlbase.h> @@ -21,7 +21,6 @@ #include "chrome/browser/suspend_controller.h" #include "chrome/browser/tab_contents.h" #include "chrome/browser/tab_contents_container_view.h" -#include "chrome/browser/window_clipping_info.h" #include "chrome/browser/view_ids.h" #include "chrome/browser/views/bookmark_bar_view.h" #include "chrome/browser/views/download_shelf_view.h" diff --git a/chrome/browser/vista_frame.h b/chrome/browser/views/old_frames/vista_frame.h index d913b6e..b812db1 100644 --- a/chrome/browser/vista_frame.h +++ b/chrome/browser/views/old_frames/vista_frame.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_VISTA_FRAME_H__ -#define CHROME_BROWSER_VISTA_FRAME_H__ +#ifndef CHROME_BROWSER_VIEWS_OLD_FRAMES_VISTA_FRAME_H__ +#define CHROME_BROWSER_VIEWS_OLD_FRAMES_VISTA_FRAME_H__ #include <windows.h> #include <atlbase.h> @@ -14,7 +14,7 @@ #include "base/message_loop.h" #include "chrome/app/chrome_dll_resource.h" #include "chrome/browser/browser_window.h" -#include "chrome/browser/frame_view.h" +#include "chrome/browser/views/old_frames/frame_view.h" #include "chrome/browser/views/status_bubble.h" #include "chrome/views/view_container.h" #include "chrome/views/root_view.h" @@ -410,5 +410,5 @@ class VistaFrame : public BrowserWindow, DISALLOW_EVIL_CONSTRUCTORS(VistaFrame); }; -#endif // CHROME_BROWSER_VISTA_FRAME_H__ +#endif // CHROME_BROWSER_VIEWS_OLD_FRAMES_VISTA_FRAME_H__ diff --git a/chrome/browser/xp_frame.cc b/chrome/browser/views/old_frames/xp_frame.cc index 6770a7a..6a33d77 100644 --- a/chrome/browser/xp_frame.cc +++ b/chrome/browser/views/old_frames/xp_frame.cc @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "chrome/browser/xp_frame.h" +#include "chrome/browser/views/old_frames/xp_frame.h" #include <windows.h> @@ -13,7 +13,6 @@ #include "chrome/browser/browser.h" #include "chrome/browser/browser_list.h" #include "chrome/browser/frame_util.h" -#include "chrome/browser/point_buffer.h" #include "chrome/browser/suspend_controller.h" #include "chrome/browser/tab_contents.h" #include "chrome/browser/tab_contents_container_view.h" @@ -22,8 +21,8 @@ #include "chrome/browser/views/bookmark_bar_view.h" #include "chrome/browser/views/download_shelf_view.h" #include "chrome/browser/views/frame/browser_view.h" +#include "chrome/browser/views/old_frames/point_buffer.h" #include "chrome/browser/views/tabs/tab_strip.h" -#include "chrome/browser/window_clipping_info.h" #include "chrome/common/chrome_constants.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/gfx/chrome_canvas.h" diff --git a/chrome/browser/xp_frame.h b/chrome/browser/views/old_frames/xp_frame.h index 622a65f..e91ffff 100644 --- a/chrome/browser/xp_frame.h +++ b/chrome/browser/views/old_frames/xp_frame.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_XP_FRAME_H__ -#define CHROME_BROWSER_XP_FRAME_H__ +#ifndef CHROME_BROWSER_VIEWS_OLD_FRAMES_XP_FRAME_H__ +#define CHROME_BROWSER_VIEWS_OLD_FRAMES_XP_FRAME_H__ #include <windows.h> #include <atlbase.h> @@ -14,7 +14,7 @@ #include "base/message_loop.h" #include "chrome/app/chrome_dll_resource.h" #include "chrome/browser/browser_window.h" -#include "chrome/browser/frame_view.h" +#include "chrome/browser/views/old_frames/frame_view.h" #include "chrome/browser/views/status_bubble.h" #include "chrome/views/view_container.h" #include "chrome/views/button.h" @@ -524,5 +524,5 @@ class XPFrame : public BrowserWindow, DISALLOW_EVIL_CONSTRUCTORS(XPFrame); }; -#endif // CHROME_BROWSER_XP_FRAME_H__ +#endif // CHROME_BROWSER_VIEWS_OLD_FRAMES_XP_FRAME_H__ diff --git a/chrome/browser/views/tabs/tab_strip.cc b/chrome/browser/views/tabs/tab_strip.cc index 2b8dc61..1bafdca 100644 --- a/chrome/browser/views/tabs/tab_strip.cc +++ b/chrome/browser/views/tabs/tab_strip.cc @@ -13,7 +13,6 @@ #include "chrome/browser/view_ids.h" #include "chrome/browser/views/tabs/dragged_tab_controller.h" #include "chrome/browser/views/tabs/tab.h" -#include "chrome/browser/vista_frame.h" #include "chrome/browser/web_contents.h" #include "chrome/common/drag_drop_types.h" #include "chrome/common/gfx/chrome_canvas.h" diff --git a/chrome/browser/window_clipping_info.cc b/chrome/browser/window_clipping_info.cc deleted file mode 100644 index 1e147178..0000000 --- a/chrome/browser/window_clipping_info.cc +++ /dev/null @@ -1,165 +0,0 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "chrome/browser/window_clipping_info.h" - -#define DEBUG_WINDOW_CLIPPING_INFO 0 - -WindowClippingInfo::WindowClippingInfo(HWND aWindow, - HWND ignore_wnd) : hwnd_(aWindow), - ignore_(ignore_wnd), - rgn_(NULL) { - ::GetWindowRect(hwnd_, &hwnd_rect_); - ComputeScreenClipping(); - ComputeWindowsClipping(); - if (rgn_) { - ::OffsetRgn(rgn_, -hwnd_rect_.left, -hwnd_rect_.top); -#if DEBUG_WINDOW_CLIPPING_INFO - RECT r; - ::GetRgnBox(rgn_, &r); - LOG(INFO) << "Window clip rect is (" << r.left << ", " << r.top << ", " - << r.right << ", " << r.bottom << ")"; -#endif - } -} - -WindowClippingInfo::~WindowClippingInfo() { - if (rgn_) { - DeleteObject(rgn_); - } -} - -HRGN WindowClippingInfo::GetClippedRegion() const { - return rgn_; -} - -BOOL WindowClippingInfo::IsClipped() const { - if (rgn_ == NULL) { - return FALSE; - } else { - CRect r; - ::GetRgnBox(rgn_, &r); - if (r.Width() > 0 && r.Height() > 0) { - return TRUE; - } else { - return FALSE; - } - } -} - -HRGN WindowClippingInfo::CombineRegions(HRGN existing, HRGN additional) const { - if (existing == NULL) { - return additional; - } else { - HRGN new_dest = CreateRectRgn(0, 0, 0, 0); - ::CombineRgn(new_dest, existing, additional, RGN_OR); - DeleteObject(existing); - DeleteObject(additional); - return new_dest; - } -} - -void WindowClippingInfo::ComputeScreenClipping() { - int screen_width = GetSystemMetrics(SM_CXVIRTUALSCREEN); - int screen_height = GetSystemMetrics(SM_CYVIRTUALSCREEN); - CRect c; - - if (hwnd_rect_.left < 0) { - c.left = 0; - c.right = -hwnd_rect_.left; - c.top = 0; - c.bottom = hwnd_rect_.Height(); - rgn_ = CombineRegions(rgn_, - CreateRectRgn(c.left, c.top, c.right, c.bottom)); - } - - if (hwnd_rect_.top < 0) { - c.left = 0; - c.right = hwnd_rect_.Width(); - c.top = 0; - c.bottom = -hwnd_rect_.top; - rgn_ = CombineRegions(rgn_, - CreateRectRgn(c.left, c.top, c.right, c.bottom)); - } - - if (hwnd_rect_.right > screen_width) { - c.left = screen_width - hwnd_rect_.left; - c.right = hwnd_rect_.right - screen_width + c.left; - c.top = 0; - c.bottom = hwnd_rect_.Height(); - rgn_ = CombineRegions(rgn_, - CreateRectRgn(c.left, c.top, c.right, c.bottom)); - } - - if (hwnd_rect_.bottom > screen_height) { - c.left = 0; - c.right = hwnd_rect_.Width(); - c.top = screen_height - hwnd_rect_.top; - c.bottom = hwnd_rect_.bottom - screen_height + c.top; - rgn_ = CombineRegions(rgn_, - CreateRectRgn(c.left, c.top, c.right, c.bottom)); - } - - if (rgn_) { - // Convert the region in screen coordinate system to be compatible with - // the the windows clipping regions - ::OffsetRgn(rgn_, hwnd_rect_.left, hwnd_rect_.top); -#if DEBUG_WINDOW_CLIPPING_INFO - RECT cr; - ::GetRgnBox(rgn_, &cr); - LOG(INFO) << "Screen Clip is (" << cr.left << ", " << cr.top << ", " << - cr.right << ", " << cr.bottom << ")"; -#endif - } else { -#if DEBUG_WINDOW_CLIPPING_INFO - LOG(INFO) << "Screen Clip is null"; -#endif - } -} - - -// WindowEnumProc is called for every top level windows until we -// return FALSE or all top level windows have been enumerated. -// -// Windows are ordered per Z-Order with higher level windows first and -// lower level windows last. -// -//static -BOOL CALLBACK WindowClippingInfo::WindowEnumProc(HWND hwnd, LPARAM lParam) { - WindowClippingInfo* wci = - reinterpret_cast<WindowClippingInfo*>(lParam); - - if (hwnd == wci->ignore_) { - return TRUE; - } - - if (hwnd == wci->hwnd_) { - // We have enumerated all the windows above us so we are done - return FALSE; - } - - if (::IsWindowVisible(hwnd)) { - RECT r; - ::GetWindowRect(hwnd, &r); - RECT intersection; - if (::IntersectRect(&intersection, &r, &wci->hwnd_rect_)) { - HRGN rgn = CreateRectRgn(intersection.left, - intersection.top, - intersection.right, - intersection.bottom); - if (wci->rgn_ == NULL) { - wci->rgn_ = rgn; - } else { - ::CombineRgn(wci->rgn_, wci->rgn_, rgn, RGN_OR); - ::DeleteObject(rgn); - } - } - } - return TRUE; -} - -void WindowClippingInfo::ComputeWindowsClipping() { - ::EnumWindows(WindowEnumProc, reinterpret_cast<LPARAM>(this)); -} - diff --git a/chrome/browser/window_clipping_info.h b/chrome/browser/window_clipping_info.h deleted file mode 100644 index a387cd9..0000000 --- a/chrome/browser/window_clipping_info.h +++ /dev/null @@ -1,65 +0,0 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef CHROME_BROWSER_WINDOW_CLIPPING_INFO_H__ -#define CHROME_BROWSER_WINDOW_CLIPPING_INFO_H__ - -#include <windows.h> -#include <atlbase.h> -#include <atlapp.h> -#include <atlmisc.h> - -#include "base/basictypes.h" - -//////////////////////////////////////////////////////////////////////////////// -// -// WindowClippingInfo class -// -// A facility to compute the invisible areas of a window. Given a window, -// this helper class computes all the areas which are obscured or clipped -// by the screen bounds and return them within a single HRGN. -// -//////////////////////////////////////////////////////////////////////////////// -class WindowClippingInfo { - public: - // - // Create a new WindowClippingInfo instance to compute clipping info for HWND - // If ignore_wnd is provided, obstruction from that window will be ignored - // - WindowClippingInfo(HWND aWindow, HWND ignore_wnd); - ~WindowClippingInfo(); - - // - // Return a single region containing all the clipped areas - // of the HWND. The region is in HWND coordinate system - // - HRGN GetClippedRegion() const; - - // - // Convenience to test whether the window is clipped - // - BOOL IsClipped() const; - - private: - // Combine 2 regions - HRGN CombineRegions(HRGN existing, HRGN additional) const; - - // Compute the clipping caused by the screen boundaries - void ComputeScreenClipping(); - - static BOOL CALLBACK WindowEnumProc(HWND hwnd, LPARAM lParam); - - // Compute the clipping caused by higher level windows - void ComputeWindowsClipping(); - - HWND hwnd_; - HWND ignore_; - HRGN rgn_; - CRect hwnd_rect_; - - DISALLOW_EVIL_CONSTRUCTORS(WindowClippingInfo); -}; - -#endif // CHROME_BROWSER_WINDOW_CLIPPING_INFO_H__ - |