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

Side by Side Diff: views/controls/scrollbar/native_scroll_bar_win.cc

Issue 273017: Move native_widget_types and gtk_native_view_id_manager from base/gfx to... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « views/controls/native/native_view_host.h ('k') | views/controls/slider/native_slider_wrapper.h » ('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 (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #include "views/controls/scrollbar/native_scroll_bar_win.h" 5 #include "views/controls/scrollbar/native_scroll_bar_win.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "app/win/window_impl.h"
10 #include "base/keyboard_codes.h" 11 #include "base/keyboard_codes.h"
11 #include "base/message_loop.h" 12 #include "base/message_loop.h"
12 #include "base/window_impl.h"
13 #include "views/controls/scrollbar/native_scroll_bar.h" 13 #include "views/controls/scrollbar/native_scroll_bar.h"
14 #include "views/controls/scrollbar/scroll_bar.h" 14 #include "views/controls/scrollbar/scroll_bar.h"
15 #include "views/widget/widget.h" 15 #include "views/widget/widget.h"
16 16
17 namespace views { 17 namespace views {
18 18
19 ///////////////////////////////////////////////////////////////////////////// 19 /////////////////////////////////////////////////////////////////////////////
20 // 20 //
21 // ScrollBarContainer 21 // ScrollBarContainer
22 // 22 //
23 // Since windows scrollbars only send notifications to their parent hwnd, we 23 // Since windows scrollbars only send notifications to their parent hwnd, we
24 // use instances of this class to wrap native scrollbars. 24 // use instances of this class to wrap native scrollbars.
25 // 25 //
26 ///////////////////////////////////////////////////////////////////////////// 26 /////////////////////////////////////////////////////////////////////////////
27 class ScrollBarContainer : public base::WindowImpl { 27 class ScrollBarContainer : public app::WindowImpl {
28 public: 28 public:
29 explicit ScrollBarContainer(ScrollBar* parent) 29 explicit ScrollBarContainer(ScrollBar* parent)
30 : parent_(parent), 30 : parent_(parent),
31 scrollbar_(NULL) { 31 scrollbar_(NULL) {
32 set_window_style(WS_CHILD); 32 set_window_style(WS_CHILD);
33 Init(parent->GetWidget()->GetNativeView(), gfx::Rect()); 33 Init(parent->GetWidget()->GetNativeView(), gfx::Rect());
34 ShowWindow(hwnd(), SW_SHOW); 34 ShowWindow(hwnd(), SW_SHOW);
35 } 35 }
36 36
37 virtual ~ScrollBarContainer() { 37 virtual ~ScrollBarContainer() {
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
338 return GetSystemMetrics(SM_CYHSCROLL); 338 return GetSystemMetrics(SM_CYHSCROLL);
339 } 339 }
340 340
341 // static 341 // static
342 int NativeScrollBarWrapper::GetVerticalScrollBarWidth() { 342 int NativeScrollBarWrapper::GetVerticalScrollBarWidth() {
343 return GetSystemMetrics(SM_CXVSCROLL); 343 return GetSystemMetrics(SM_CXVSCROLL);
344 } 344 }
345 345
346 } // namespace views 346 } // namespace views
347 347
OLDNEW
« no previous file with comments | « views/controls/native/native_view_host.h ('k') | views/controls/slider/native_slider_wrapper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698