diff options
author | sky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-11 20:59:15 +0000 |
---|---|---|
committer | sky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-11 20:59:15 +0000 |
commit | 957d29985117977bc7eddbdf9cd39df0ed2d7fe2 (patch) | |
tree | 897a469ca93584209999e45458de5be0b3a142b1 /ui/base/win/window_impl.cc | |
parent | 18c92e001c72180ef6153c9bf148fb6fa9f5ecb4 (diff) | |
download | chromium_src-957d29985117977bc7eddbdf9cd39df0ed2d7fe2.zip chromium_src-957d29985117977bc7eddbdf9cd39df0ed2d7fe2.tar.gz chromium_src-957d29985117977bc7eddbdf9cd39df0ed2d7fe2.tar.bz2 |
Adds more debugging code in hopes of figuring out a crash. Most common
reason for crash appears to be because we can't find the WindowWin for
an hwnd.
I'm also removing a comment that is no longer relevant, and nuking a
call in window_win to ui::SetWindowUserData that is already done in
WindowImpl.
BUG=77651
TEST=none
R=ben@chromium.org
Review URL: http://codereview.chromium.org/6825045
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81150 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/base/win/window_impl.cc')
-rw-r--r-- | ui/base/win/window_impl.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ui/base/win/window_impl.cc b/ui/base/win/window_impl.cc index 4cd54bd..0f48b89 100644 --- a/ui/base/win/window_impl.cc +++ b/ui/base/win/window_impl.cc @@ -147,10 +147,12 @@ void WindowImpl::Init(HWND parent, const gfx::Rect& bounds) { hwnd_ = CreateWindowEx(window_ex_style_, GetWindowClassName().c_str(), NULL, window_style_, x, y, width, height, parent, NULL, NULL, this); - DCHECK(hwnd_); + CHECK(hwnd_); // The window procedure should have set the data for us. - DCHECK(ui::GetWindowUserData(hwnd_) == this); + CHECK_EQ(this, ui::GetWindowUserData(hwnd_)); + + CHECK(IsWindowImpl(hwnd_)); } HICON WindowImpl::GetDefaultWindowIcon() const { |