summaryrefslogtreecommitdiffstats
path: root/views/window/native_frame_view.cc
diff options
context:
space:
mode:
Diffstat (limited to 'views/window/native_frame_view.cc')
-rw-r--r--views/window/native_frame_view.cc12
1 files changed, 8 insertions, 4 deletions
diff --git a/views/window/native_frame_view.cc b/views/window/native_frame_view.cc
index 397b6f3..c78d6d1 100644
--- a/views/window/native_frame_view.cc
+++ b/views/window/native_frame_view.cc
@@ -4,14 +4,16 @@
#include "views/window/native_frame_view.h"
-#include "views/window/window_win.h"
+#include "views/widget/widget_win.h"
+#include "views/window/native_window.h"
+#include "views/window/window.h"
namespace views {
////////////////////////////////////////////////////////////////////////////////
// NativeFrameView, public:
-NativeFrameView::NativeFrameView(WindowWin* frame)
+NativeFrameView::NativeFrameView(Window* frame)
: NonClientFrameView(),
frame_(frame) {
}
@@ -29,8 +31,10 @@ gfx::Rect NativeFrameView::GetBoundsForClientView() const {
gfx::Rect NativeFrameView::GetWindowBoundsForClientBounds(
const gfx::Rect& client_bounds) const {
RECT rect = client_bounds.ToRECT();
- AdjustWindowRectEx(&rect, frame_->window_style(), FALSE,
- frame_->window_ex_style());
+ WidgetWin* widget_win =
+ static_cast<WidgetWin*>(frame_->native_window()->AsNativeWidget());
+ AdjustWindowRectEx(&rect, widget_win->window_style(), FALSE,
+ widget_win->window_ex_style());
return gfx::Rect(rect);
}