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

Side by Side Diff: gfx/window_impl.cc

Issue 5139006: FBTF: Remove unneeded headers from base/ (part 10) (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix mac, cros build Created 10 years 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 | « gfx/window_impl.h ('k') | gpu/command_buffer/service/buffer_manager.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "gfx/window_impl.h" 5 #include "gfx/window_impl.h"
6 6
7 #include <list> 7 #include <list>
8 8
9 #include "base/logging.h"
9 #include "base/singleton.h" 10 #include "base/singleton.h"
10 #include "base/string_number_conversions.h" 11 #include "base/string_number_conversions.h"
11 #include "base/win_util.h" 12 #include "base/win_util.h"
12 13
13 namespace gfx { 14 namespace gfx {
14 15
15 static const DWORD kWindowDefaultChildStyle = 16 static const DWORD kWindowDefaultChildStyle =
16 WS_CHILD | WS_VISIBLE | WS_CLIPCHILDREN | WS_CLIPSIBLINGS; 17 WS_CHILD | WS_VISIBLE | WS_CLIPCHILDREN | WS_CLIPSIBLINGS;
17 static const DWORD kWindowDefaultStyle = WS_OVERLAPPEDWINDOW; 18 static const DWORD kWindowDefaultStyle = WS_OVERLAPPEDWINDOW;
18 static const DWORD kWindowDefaultExStyle = 0; 19 static const DWORD kWindowDefaultExStyle = 0;
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 DCHECK(hwnd_); 146 DCHECK(hwnd_);
146 147
147 // The window procedure should have set the data for us. 148 // The window procedure should have set the data for us.
148 DCHECK(win_util::GetWindowUserData(hwnd_) == this); 149 DCHECK(win_util::GetWindowUserData(hwnd_) == this);
149 } 150 }
150 151
151 HICON WindowImpl::GetDefaultWindowIcon() const { 152 HICON WindowImpl::GetDefaultWindowIcon() const {
152 return NULL; 153 return NULL;
153 } 154 }
154 155
156 void WindowImpl::set_initial_class_style(UINT class_style) {
157 // We dynamically generate the class name, so don't register it globally!
158 DCHECK_EQ((class_style & CS_GLOBALCLASS), 0u);
159 class_style_ = class_style;
160 }
161
155 // static 162 // static
156 bool WindowImpl::IsWindowImpl(HWND hwnd) { 163 bool WindowImpl::IsWindowImpl(HWND hwnd) {
157 wchar_t tmp[128]; 164 wchar_t tmp[128];
158 if (!::GetClassName(hwnd, tmp, 128)) 165 if (!::GetClassName(hwnd, tmp, 128))
159 return false; 166 return false;
160 167
161 std::wstring class_name(tmp); 168 std::wstring class_name(tmp);
162 return class_name.find(kBaseClassName) == 0; 169 return class_name.find(kBaseClassName) == 0;
163 } 170 }
164 171
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 class_ex.hIconSm = class_ex.hIcon; 224 class_ex.hIconSm = class_ex.hIcon;
218 ATOM atom = RegisterClassEx(&class_ex); 225 ATOM atom = RegisterClassEx(&class_ex);
219 DCHECK(atom); 226 DCHECK(atom);
220 227
221 Singleton<ClassRegistrar>()->RegisterClass(class_info, name, atom); 228 Singleton<ClassRegistrar>()->RegisterClass(class_info, name, atom);
222 229
223 return name; 230 return name;
224 } 231 }
225 232
226 } // namespace gfx 233 } // namespace gfx
OLDNEW
« no previous file with comments | « gfx/window_impl.h ('k') | gpu/command_buffer/service/buffer_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698