| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/ui/views/omnibox/omnibox_view_views.h" | 5 #include "chrome/browser/ui/views/omnibox/omnibox_view_views.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
| 9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
| 10 #include "chrome/app/chrome_command_ids.h" | 10 #include "chrome/app/chrome_command_ids.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 #include "googleurl/src/gurl.h" | 27 #include "googleurl/src/gurl.h" |
| 28 #include "grit/app_locale_settings.h" | 28 #include "grit/app_locale_settings.h" |
| 29 #include "grit/generated_resources.h" | 29 #include "grit/generated_resources.h" |
| 30 #include "grit/ui_strings.h" | 30 #include "grit/ui_strings.h" |
| 31 #include "net/base/escape.h" | 31 #include "net/base/escape.h" |
| 32 #include "third_party/skia/include/core/SkColor.h" | 32 #include "third_party/skia/include/core/SkColor.h" |
| 33 #include "ui/base/accessibility/accessible_view_state.h" | 33 #include "ui/base/accessibility/accessible_view_state.h" |
| 34 #include "ui/base/clipboard/scoped_clipboard_writer.h" | 34 #include "ui/base/clipboard/scoped_clipboard_writer.h" |
| 35 #include "ui/base/dragdrop/drag_drop_types.h" | 35 #include "ui/base/dragdrop/drag_drop_types.h" |
| 36 #include "ui/base/dragdrop/os_exchange_data.h" | 36 #include "ui/base/dragdrop/os_exchange_data.h" |
| 37 #include "ui/base/event.h" | 37 #include "ui/base/events/event.h" |
| 38 #include "ui/base/ime/text_input_client.h" | 38 #include "ui/base/ime/text_input_client.h" |
| 39 #include "ui/base/ime/text_input_type.h" | 39 #include "ui/base/ime/text_input_type.h" |
| 40 #include "ui/base/l10n/l10n_util.h" | 40 #include "ui/base/l10n/l10n_util.h" |
| 41 #include "ui/base/models/simple_menu_model.h" | 41 #include "ui/base/models/simple_menu_model.h" |
| 42 #include "ui/base/resource/resource_bundle.h" | 42 #include "ui/base/resource/resource_bundle.h" |
| 43 #include "ui/gfx/canvas.h" | 43 #include "ui/gfx/canvas.h" |
| 44 #include "ui/gfx/font.h" | 44 #include "ui/gfx/font.h" |
| 45 #include "ui/gfx/render_text.h" | 45 #include "ui/gfx/render_text.h" |
| 46 #include "ui/views/border.h" | 46 #include "ui/views/border.h" |
| 47 #include "ui/views/controls/textfield/textfield.h" | 47 #include "ui/views/controls/textfield/textfield.h" |
| (...skipping 850 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 898 const ui::Range& range) { | 898 const ui::Range& range) { |
| 899 if (text != GetText()) | 899 if (text != GetText()) |
| 900 textfield_->SetText(text); | 900 textfield_->SetText(text); |
| 901 textfield_->SelectRange(range); | 901 textfield_->SelectRange(range); |
| 902 } | 902 } |
| 903 | 903 |
| 904 string16 OmniboxViewViews::GetSelectedText() const { | 904 string16 OmniboxViewViews::GetSelectedText() const { |
| 905 // TODO(oshima): Support instant, IME. | 905 // TODO(oshima): Support instant, IME. |
| 906 return textfield_->GetSelectedText(); | 906 return textfield_->GetSelectedText(); |
| 907 } | 907 } |
| OLD | NEW |