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

Side by Side Diff: third_party/WebKit/Source/core/events/KeyboardEvent.h

Issue 2855613002: Removed |which| from KeyboardEvent and MouseEvent. (Closed)
Patch Set: Removed FIXME, counters. Rebased. Created 3 years, 7 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 /* 1 /*
2 * Copyright (C) 2001 Peter Kelly (pmk@post.com) 2 * Copyright (C) 2001 Peter Kelly (pmk@post.com)
3 * Copyright (C) 2001 Tobias Anton (anton@stud.fbi.fh-darmstadt.de) 3 * Copyright (C) 2001 Tobias Anton (anton@stud.fbi.fh-darmstadt.de)
4 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) 4 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com)
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights
6 * reserved. 6 * reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 77
78 const WebKeyboardEvent* KeyEvent() const { return key_event_.get(); } 78 const WebKeyboardEvent* KeyEvent() const { return key_event_.get(); }
79 79
80 int keyCode() 80 int keyCode()
81 const; // key code for keydown and keyup, character for keypress 81 const; // key code for keydown and keyup, character for keypress
82 int charCode() const; // character code for keypress, 0 for keydown and keyup 82 int charCode() const; // character code for keypress, 0 for keydown and keyup
83 bool repeat() const { return GetModifiers() & WebInputEvent::kIsAutoRepeat; } 83 bool repeat() const { return GetModifiers() & WebInputEvent::kIsAutoRepeat; }
84 84
85 const AtomicString& InterfaceName() const override; 85 const AtomicString& InterfaceName() const override;
86 bool IsKeyboardEvent() const override; 86 bool IsKeyboardEvent() const override;
87 int which() const override; 87 unsigned which() const override;
88 bool isComposing() const { return is_composing_; } 88 bool isComposing() const { return is_composing_; }
89 89
90 DECLARE_VIRTUAL_TRACE(); 90 DECLARE_VIRTUAL_TRACE();
91 91
92 private: 92 private:
93 KeyboardEvent(); 93 KeyboardEvent();
94 KeyboardEvent(const WebKeyboardEvent&, LocalDOMWindow*); 94 KeyboardEvent(const WebKeyboardEvent&, LocalDOMWindow*);
95 95
96 void InitLocationModifiers(unsigned location); 96 void InitLocationModifiers(unsigned location);
97 97
98 std::unique_ptr<WebKeyboardEvent> key_event_; 98 std::unique_ptr<WebKeyboardEvent> key_event_;
99 String code_; 99 String code_;
100 String key_; 100 String key_;
101 unsigned location_; 101 unsigned location_;
102 bool is_composing_; 102 bool is_composing_;
103 }; 103 };
104 104
105 DEFINE_EVENT_TYPE_CASTS(KeyboardEvent); 105 DEFINE_EVENT_TYPE_CASTS(KeyboardEvent);
106 106
107 } // namespace blink 107 } // namespace blink
108 108
109 #endif // KeyboardEvent_h 109 #endif // KeyboardEvent_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698