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

Side by Side Diff: ui/base/ime/linux/text_edit_key_bindings_delegate_auralinux.h

Issue 2029733003: Views: Replace resource ids with ui::TextEditCommand enum for text editing commands in Textfield. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: === Created 4 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef UI_EVENTS_X_TEXT_EDIT_KEY_BINDINGS_DELEGATE_X11_H_ 5 #ifndef UI_BASE_IME_LINUX_TEXT_EDIT_KEY_BINDINGS_DELEGATE_AURALINUX_H_
6 #define UI_EVENTS_X_TEXT_EDIT_KEY_BINDINGS_DELEGATE_X11_H_ 6 #define UI_BASE_IME_LINUX_TEXT_EDIT_KEY_BINDINGS_DELEGATE_AURALINUX_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "ui/events/events_export.h" 10 #include "ui/base/ime/ui_base_ime_export.h"
11 11
12 namespace ui { 12 namespace ui {
13 class Event; 13 class Event;
14 class TextEditCommandAuraLinux; 14 class TextEditCommandAuraLinux;
15 15
16 // An interface which can interpret various text editing commands out of key 16 // An interface which can interpret various text editing commands out of key
17 // events. 17 // events.
18 // 18 //
19 // On desktop Linux, we've traditionally supported the user's custom 19 // On desktop Linux, we've traditionally supported the user's custom
20 // keybindings. We need to support this in both content/ and in views/. 20 // keybindings. We need to support this in both content/ and in views/.
21 class EVENTS_EXPORT TextEditKeyBindingsDelegateAuraLinux { 21 class UI_BASE_IME_EXPORT TextEditKeyBindingsDelegateAuraLinux {
22 public: 22 public:
23 // Matches a key event against the users' platform specific key bindings, 23 // Matches a key event against the users' platform specific key bindings,
24 // false will be returned if the key event doesn't correspond to a predefined 24 // false will be returned if the key event doesn't correspond to a predefined
25 // key binding. Edit commands matched with |event| will be stored in 25 // key binding. Edit commands matched with |event| will be stored in
26 // |edit_commands|, if |edit_commands| is non-NULL. 26 // |edit_commands|, if |edit_commands| is non-NULL.
27 virtual bool MatchEvent(const ui::Event& event, 27 virtual bool MatchEvent(const ui::Event& event,
28 std::vector<TextEditCommandAuraLinux>* commands) = 0; 28 std::vector<TextEditCommandAuraLinux>* commands) = 0;
29 29
30 protected: 30 protected:
31 virtual ~TextEditKeyBindingsDelegateAuraLinux() {} 31 virtual ~TextEditKeyBindingsDelegateAuraLinux() {}
32 }; 32 };
33 33
34 // Sets/Gets the global TextEditKeyBindingsDelegateAuraLinux. No ownership 34 // Sets/Gets the global TextEditKeyBindingsDelegateAuraLinux. No ownership
35 // changes. Can be NULL. 35 // changes. Can be NULL.
36 EVENTS_EXPORT void SetTextEditKeyBindingsDelegate( 36 UI_BASE_IME_EXPORT void SetTextEditKeyBindingsDelegate(
37 TextEditKeyBindingsDelegateAuraLinux* delegate); 37 TextEditKeyBindingsDelegateAuraLinux* delegate);
38 EVENTS_EXPORT TextEditKeyBindingsDelegateAuraLinux* 38 UI_BASE_IME_EXPORT TextEditKeyBindingsDelegateAuraLinux*
39 GetTextEditKeyBindingsDelegate(); 39 GetTextEditKeyBindingsDelegate();
40 40
41 } // namespace ui 41 } // namespace ui
42 42
43 #endif // UI_EVENTS_X_TEXT_EDIT_KEY_BINDINGS_DELEGATE_X11_H_ 43 #endif // UI_BASE_IME_LINUX_TEXT_EDIT_KEY_BINDINGS_DELEGATE_AURALINUX_H_
OLDNEW
« no previous file with comments | « ui/base/ime/linux/text_edit_command_auralinux.cc ('k') | ui/base/ime/linux/text_edit_key_bindings_delegate_auralinux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698