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

Side by Side Diff: ui/aura/event.h

Issue 8576005: IME (input method editor) support for Aura, part 3 of 3: Use ui::InputMethod in ash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: move to ash/ime/ Created 8 years, 12 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
« no previous file with comments | « ui/aura/client/aura_constants.cc ('k') | ui/aura/event.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_AURA_EVENT_H_ 5 #ifndef UI_AURA_EVENT_H_
6 #define UI_AURA_EVENT_H_ 6 #define UI_AURA_EVENT_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/event_types.h" 10 #include "base/event_types.h"
(...skipping 21 matching lines...) Expand all
32 const base::Time& time_stamp() const { return time_stamp_; } 32 const base::Time& time_stamp() const { return time_stamp_; }
33 int flags() const { return flags_; } 33 int flags() const { return flags_; }
34 34
35 // The following methods return true if the respective keys were pressed at 35 // The following methods return true if the respective keys were pressed at
36 // the time the event was created. 36 // the time the event was created.
37 bool IsShiftDown() const { return (flags_ & ui::EF_SHIFT_DOWN) != 0; } 37 bool IsShiftDown() const { return (flags_ & ui::EF_SHIFT_DOWN) != 0; }
38 bool IsControlDown() const { return (flags_ & ui::EF_CONTROL_DOWN) != 0; } 38 bool IsControlDown() const { return (flags_ & ui::EF_CONTROL_DOWN) != 0; }
39 bool IsCapsLockDown() const { return (flags_ & ui::EF_CAPS_LOCK_DOWN) != 0; } 39 bool IsCapsLockDown() const { return (flags_ & ui::EF_CAPS_LOCK_DOWN) != 0; }
40 bool IsAltDown() const { return (flags_ & ui::EF_ALT_DOWN) != 0; } 40 bool IsAltDown() const { return (flags_ & ui::EF_ALT_DOWN) != 0; }
41 41
42 // Returns true if the event has a valid |native_event_|.
43 bool HasNativeEvent() const;
44
42 protected: 45 protected:
43 Event(ui::EventType type, int flags); 46 Event(ui::EventType type, int flags);
44 Event(const base::NativeEvent& native_event, ui::EventType type, int flags); 47 Event(const base::NativeEvent& native_event, ui::EventType type, int flags);
45 Event(const Event& copy); 48 Event(const Event& copy);
46 void set_type(ui::EventType type) { type_ = type; } 49 void set_type(ui::EventType type) { type_ = type; }
47 void set_flags(int flags) { flags_ = flags; } 50 void set_flags(int flags) { flags_ = flags; }
48 void set_delete_native_event(bool delete_native_event) { 51 void set_delete_native_event(bool delete_native_event) {
49 delete_native_event_ = delete_native_event; 52 delete_native_event_ = delete_native_event;
50 } 53 }
51 54
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 private: 235 private:
233 float x_offset_; 236 float x_offset_;
234 float y_offset_; 237 float y_offset_;
235 238
236 DISALLOW_COPY_AND_ASSIGN(ScrollEvent); 239 DISALLOW_COPY_AND_ASSIGN(ScrollEvent);
237 }; 240 };
238 241
239 } // namespace aura 242 } // namespace aura
240 243
241 #endif // UI_AURA_EVENT_H_ 244 #endif // UI_AURA_EVENT_H_
OLDNEW
« no previous file with comments | « ui/aura/client/aura_constants.cc ('k') | ui/aura/event.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698