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

Side by Side Diff: chrome/browser/views/find_bar_win.cc

Issue 140064: Revert :... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 6 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
OLDNEW
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-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 "chrome/browser/views/find_bar_win.h" 5 #include "chrome/browser/views/find_bar_win.h"
6 6
7 #include "app/slide_animation.h" 7 #include "app/slide_animation.h"
8 #include "chrome/browser/browser.h" 8 #include "chrome/browser/browser.h"
9 #include "chrome/browser/browser_process.h" 9 #include "chrome/browser/browser_process.h"
10 #include "chrome/browser/find_bar_controller.h" 10 #include "chrome/browser/find_bar_controller.h"
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 88
89 FindBarWin::FindBarWin(BrowserView* browser_view) 89 FindBarWin::FindBarWin(BrowserView* browser_view)
90 : browser_view_(browser_view), 90 : browser_view_(browser_view),
91 find_dialog_animation_offset_(0), 91 find_dialog_animation_offset_(0),
92 esc_accel_target_registered_(false), 92 esc_accel_target_registered_(false),
93 find_bar_controller_(NULL) { 93 find_bar_controller_(NULL) {
94 view_ = new FindBarView(this); 94 view_ = new FindBarView(this);
95 95
96 // Initialize the host. 96 // Initialize the host.
97 host_.reset(new Host(this)); 97 host_.reset(new Host(this));
98 host_->Init(browser_view->GetWidget()->GetNativeView(), gfx::Rect()); 98 host_->Init(browser_view->GetWidget()->GetNativeView(), gfx::Rect(), false);
99 host_->SetContentsView(view_); 99 host_->SetContentsView(view_);
100 100
101 // Start listening to focus changes, so we can register and unregister our 101 // Start listening to focus changes, so we can register and unregister our
102 // own handler for Escape. 102 // own handler for Escape.
103 focus_manager_ = 103 focus_manager_ = views::FocusManager::GetFocusManager(host_->GetNativeView());
104 views::FocusManager::GetFocusManagerForNativeView(host_->GetNativeView());
105 focus_manager_->AddFocusChangeListener(this); 104 focus_manager_->AddFocusChangeListener(this);
106 105
107 // Stores the currently focused view, and tracks focus changes so that we can 106 // Stores the currently focused view, and tracks focus changes so that we can
108 // restore focus when the find box is closed. 107 // restore focus when the find box is closed.
109 focus_tracker_.reset(new views::ExternalFocusTracker(view_, focus_manager_)); 108 focus_tracker_.reset(new views::ExternalFocusTracker(view_, focus_manager_));
110 109
111 // Start the process of animating the opening of the window. 110 // Start the process of animating the opening of the window.
112 animation_.reset(new SlideAnimation(this)); 111 animation_.reset(new SlideAnimation(this));
113 } 112 }
114 113
(...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after
612 focus_tracker_.reset(NULL); 611 focus_tracker_.reset(NULL);
613 } 612 }
614 613
615 void FindBarWin::AudibleAlert() { 614 void FindBarWin::AudibleAlert() {
616 #if defined(OS_WIN) 615 #if defined(OS_WIN)
617 MessageBeep(MB_OK); 616 MessageBeep(MB_OK);
618 #else 617 #else
619 NOTIMPLEMENTED(); 618 NOTIMPLEMENTED();
620 #endif 619 #endif
621 } 620 }
OLDNEW
« no previous file with comments | « chrome/browser/views/download_started_animation_win.cc ('k') | chrome/browser/views/find_bar_win_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698