| OLD | NEW |
| 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 "chrome/browser/autocomplete/autocomplete_edit_view_win.h" | 5 #include "chrome/browser/autocomplete/autocomplete_edit_view_win.h" |
| 6 | 6 |
| 7 #include <locale> | 7 #include <locale> |
| 8 #include <richedit.h> | 8 #include <richedit.h> |
| 9 #include <textserv.h> | 9 #include <textserv.h> |
| 10 | 10 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 #include "base/basictypes.h" | 21 #include "base/basictypes.h" |
| 22 #include "base/i18n/rtl.h" | 22 #include "base/i18n/rtl.h" |
| 23 #include "base/iat_patch.h" | 23 #include "base/iat_patch.h" |
| 24 #include "base/keyboard_codes.h" | 24 #include "base/keyboard_codes.h" |
| 25 #include "base/lazy_instance.h" | 25 #include "base/lazy_instance.h" |
| 26 #include "base/ref_counted.h" | 26 #include "base/ref_counted.h" |
| 27 #include "base/utf_string_conversions.h" | 27 #include "base/utf_string_conversions.h" |
| 28 #include "chrome/app/chrome_dll_resource.h" | 28 #include "chrome/app/chrome_dll_resource.h" |
| 29 #include "chrome/browser/autocomplete/autocomplete_accessibility.h" | 29 #include "chrome/browser/autocomplete/autocomplete_accessibility.h" |
| 30 #include "chrome/browser/autocomplete/autocomplete_popup_model.h" | 30 #include "chrome/browser/autocomplete/autocomplete_popup_model.h" |
| 31 #include "chrome/browser/autocomplete/autocomplete_popup_view.h" | |
| 32 #include "chrome/browser/autocomplete/keyword_provider.h" | 31 #include "chrome/browser/autocomplete/keyword_provider.h" |
| 33 #include "chrome/browser/browser_process.h" | 32 #include "chrome/browser/browser_process.h" |
| 34 #include "chrome/browser/command_updater.h" | 33 #include "chrome/browser/command_updater.h" |
| 35 #include "chrome/browser/metrics/user_metrics.h" | 34 #include "chrome/browser/metrics/user_metrics.h" |
| 36 #include "chrome/browser/net/url_fixer_upper.h" | 35 #include "chrome/browser/net/url_fixer_upper.h" |
| 37 #include "chrome/browser/profile.h" | 36 #include "chrome/browser/profile.h" |
| 38 #include "chrome/browser/search_engines/template_url.h" | 37 #include "chrome/browser/search_engines/template_url.h" |
| 39 #include "chrome/browser/search_engines/template_url_model.h" | 38 #include "chrome/browser/search_engines/template_url_model.h" |
| 40 #include "chrome/browser/tab_contents/tab_contents.h" | 39 #include "chrome/browser/tab_contents/tab_contents.h" |
| 41 #include "chrome/browser/views/location_bar_view.h" | 40 #include "chrome/browser/views/location_bar_view.h" |
| (...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 380 | 379 |
| 381 AutocompleteEditViewWin::AutocompleteEditViewWin( | 380 AutocompleteEditViewWin::AutocompleteEditViewWin( |
| 382 const gfx::Font& font, | 381 const gfx::Font& font, |
| 383 AutocompleteEditController* controller, | 382 AutocompleteEditController* controller, |
| 384 ToolbarModel* toolbar_model, | 383 ToolbarModel* toolbar_model, |
| 385 views::View* parent_view, | 384 views::View* parent_view, |
| 386 HWND hwnd, | 385 HWND hwnd, |
| 387 Profile* profile, | 386 Profile* profile, |
| 388 CommandUpdater* command_updater, | 387 CommandUpdater* command_updater, |
| 389 bool popup_window_mode, | 388 bool popup_window_mode, |
| 390 const BubblePositioner* bubble_positioner) | 389 const views::View* location_bar) |
| 391 : model_(new AutocompleteEditModel(this, controller, profile)), | 390 : model_(new AutocompleteEditModel(this, controller, profile)), |
| 392 popup_view_(AutocompletePopupView::CreatePopupView( | 391 popup_view_(new AutocompletePopupContentsView(font, this, model_.get(), |
| 393 font, this, model_.get(), profile, bubble_positioner)), | 392 profile, location_bar)), |
| 394 controller_(controller), | 393 controller_(controller), |
| 395 parent_view_(parent_view), | 394 parent_view_(parent_view), |
| 396 toolbar_model_(toolbar_model), | 395 toolbar_model_(toolbar_model), |
| 397 command_updater_(command_updater), | 396 command_updater_(command_updater), |
| 398 popup_window_mode_(popup_window_mode), | 397 popup_window_mode_(popup_window_mode), |
| 399 force_hidden_(false), | 398 force_hidden_(false), |
| 400 tracking_click_(false), | 399 tracking_click_(false), |
| 401 tracking_double_click_(false), | 400 tracking_double_click_(false), |
| 402 double_click_time_(0), | 401 double_click_time_(0), |
| 403 can_discard_mousemove_(false), | 402 can_discard_mousemove_(false), |
| (...skipping 2028 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2432 context_menu_contents_->AddItemWithStringId(IDS_PASTE_AND_GO, | 2431 context_menu_contents_->AddItemWithStringId(IDS_PASTE_AND_GO, |
| 2433 IDS_PASTE_AND_GO); | 2432 IDS_PASTE_AND_GO); |
| 2434 context_menu_contents_->AddSeparator(); | 2433 context_menu_contents_->AddSeparator(); |
| 2435 context_menu_contents_->AddItemWithStringId(IDS_SELECT_ALL, IDS_SELECT_ALL); | 2434 context_menu_contents_->AddItemWithStringId(IDS_SELECT_ALL, IDS_SELECT_ALL); |
| 2436 context_menu_contents_->AddSeparator(); | 2435 context_menu_contents_->AddSeparator(); |
| 2437 context_menu_contents_->AddItemWithStringId(IDS_EDIT_SEARCH_ENGINES, | 2436 context_menu_contents_->AddItemWithStringId(IDS_EDIT_SEARCH_ENGINES, |
| 2438 IDS_EDIT_SEARCH_ENGINES); | 2437 IDS_EDIT_SEARCH_ENGINES); |
| 2439 } | 2438 } |
| 2440 context_menu_.reset(new views::Menu2(context_menu_contents_.get())); | 2439 context_menu_.reset(new views::Menu2(context_menu_contents_.get())); |
| 2441 } | 2440 } |
| OLD | NEW |