OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) | 7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) |
8 * Copyright (C) 2010 Google Inc. All rights reserved. | 8 * Copyright (C) 2010 Google Inc. All rights reserved. |
9 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 9 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
10 * Copyright (C) 2012 Samsung Electronics. All rights reserved. | 10 * Copyright (C) 2012 Samsung Electronics. All rights reserved. |
(...skipping 1123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1134 } | 1134 } |
1135 | 1135 |
1136 EventDispatchHandlingState* HTMLInputElement::preDispatchEventHandler(Event* eve
nt) | 1136 EventDispatchHandlingState* HTMLInputElement::preDispatchEventHandler(Event* eve
nt) |
1137 { | 1137 { |
1138 if (event->type() == EventTypeNames::textInput && m_inputTypeView->shouldSub
mitImplicitly(event)) { | 1138 if (event->type() == EventTypeNames::textInput && m_inputTypeView->shouldSub
mitImplicitly(event)) { |
1139 event->stopPropagation(); | 1139 event->stopPropagation(); |
1140 return nullptr; | 1140 return nullptr; |
1141 } | 1141 } |
1142 if (event->type() != EventTypeNames::click) | 1142 if (event->type() != EventTypeNames::click) |
1143 return nullptr; | 1143 return nullptr; |
1144 if (!event->isMouseEvent() || toMouseEvent(event)->button() != LeftButton) | 1144 if (!event->isMouseEvent() || toMouseEvent(event)->button() != static_cast<s
hort>(WebPointerProperties::Button::Left)) |
1145 return nullptr; | 1145 return nullptr; |
1146 return m_inputTypeView->willDispatchClick(); | 1146 return m_inputTypeView->willDispatchClick(); |
1147 } | 1147 } |
1148 | 1148 |
1149 void HTMLInputElement::postDispatchEventHandler(Event* event, EventDispatchHandl
ingState* state) | 1149 void HTMLInputElement::postDispatchEventHandler(Event* event, EventDispatchHandl
ingState* state) |
1150 { | 1150 { |
1151 if (!state) | 1151 if (!state) |
1152 return; | 1152 return; |
1153 m_inputTypeView->didDispatchClick(event, *static_cast<ClickHandlingState*>(s
tate)); | 1153 m_inputTypeView->didDispatchClick(event, *static_cast<ClickHandlingState*>(s
tate)); |
1154 } | 1154 } |
1155 | 1155 |
1156 void HTMLInputElement::defaultEventHandler(Event* evt) | 1156 void HTMLInputElement::defaultEventHandler(Event* evt) |
1157 { | 1157 { |
1158 if (evt->isMouseEvent() && evt->type() == EventTypeNames::click && toMouseEv
ent(evt)->button() == LeftButton) { | 1158 if (evt->isMouseEvent() && evt->type() == EventTypeNames::click && toMouseEv
ent(evt)->button() == static_cast<short>(WebPointerProperties::Button::Left)) { |
1159 m_inputTypeView->handleClickEvent(toMouseEvent(evt)); | 1159 m_inputTypeView->handleClickEvent(toMouseEvent(evt)); |
1160 if (evt->defaultHandled()) | 1160 if (evt->defaultHandled()) |
1161 return; | 1161 return; |
1162 } | 1162 } |
1163 | 1163 |
1164 if (evt->isTouchEvent() && m_inputTypeView->hasTouchEventHandler()) { | 1164 if (evt->isTouchEvent() && m_inputTypeView->hasTouchEventHandler()) { |
1165 m_inputTypeView->handleTouchEvent(toTouchEvent(evt)); | 1165 m_inputTypeView->handleTouchEvent(toTouchEvent(evt)); |
1166 if (evt->defaultHandled()) | 1166 if (evt->defaultHandled()) |
1167 return; | 1167 return; |
1168 } | 1168 } |
(...skipping 780 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1949 { | 1949 { |
1950 return m_inputTypeView->hasFallbackContent(); | 1950 return m_inputTypeView->hasFallbackContent(); |
1951 } | 1951 } |
1952 | 1952 |
1953 void HTMLInputElement::setFilesFromPaths(const Vector<String>& paths) | 1953 void HTMLInputElement::setFilesFromPaths(const Vector<String>& paths) |
1954 { | 1954 { |
1955 return m_inputType->setFilesFromPaths(paths); | 1955 return m_inputType->setFilesFromPaths(paths); |
1956 } | 1956 } |
1957 | 1957 |
1958 } // namespace blink | 1958 } // namespace blink |
OLD | NEW |