summaryrefslogtreecommitdiffstats
path: root/chrome/views/window.cc
diff options
context:
space:
mode:
authorjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-08 01:13:25 +0000
committerjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-11-08 01:13:25 +0000
commite8e0f3691a410d6de40bfff021b0da33425f36cb (patch)
treeeba7275ce7aac42fb014896f2b65a09026c0499c /chrome/views/window.cc
parent4adc70599db32d760184ec908f11c7d000b6b79c (diff)
downloadchromium_src-e8e0f3691a410d6de40bfff021b0da33425f36cb.zip
chromium_src-e8e0f3691a410d6de40bfff021b0da33425f36cb.tar.gz
chromium_src-e8e0f3691a410d6de40bfff021b0da33425f36cb.tar.bz2
In dialogs, when the focus moves to a button, that button should become the default button.
When the focus is not a button, then the default button should be the one the delegate specifies. BUG=4132 TEST=Open the option dialog. OK should be the default and focused button. Move the focus around by pressing tab. When a button is selected, it should be the default button. Review URL: http://codereview.chromium.org/10230 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5056 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/views/window.cc')
-rw-r--r--chrome/views/window.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/chrome/views/window.cc b/chrome/views/window.cc
index 1566584..2f7b4f6 100644
--- a/chrome/views/window.cc
+++ b/chrome/views/window.cc
@@ -378,8 +378,8 @@ void Window::OnCommand(UINT notification_code, int command_id, HWND window) {
}
void Window::OnDestroy() {
- if (window_delegate_) {
- window_delegate_->WindowClosing();
+ if (client_view_) {
+ client_view_->WindowClosing();
window_delegate_ = NULL;
}
RestoreEnabledIfNecessary();