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 Peter Kelly (pmk@post.com) | 4 * (C) 2001 Peter Kelly (pmk@post.com) |
5 * (C) 2001 Dirk Mueller (mueller@kde.org) | 5 * (C) 2001 Dirk Mueller (mueller@kde.org) |
6 * (C) 2007 David Smith (catfish.man@gmail.com) | 6 * (C) 2007 David Smith (catfish.man@gmail.com) |
7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc. All rights reserved. | 7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc. All rights reserved. |
8 * (C) 2007 Eric Seidel (eric@webkit.org) | 8 * (C) 2007 Eric Seidel (eric@webkit.org) |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 2633 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2644 insertAdjacent(where, fragment.get(), exceptionState); | 2644 insertAdjacent(where, fragment.get(), exceptionState); |
2645 } | 2645 } |
2646 | 2646 |
2647 void Element::setPointerCapture(int pointerId, ExceptionState& exceptionState) | 2647 void Element::setPointerCapture(int pointerId, ExceptionState& exceptionState) |
2648 { | 2648 { |
2649 if (document().frame()) { | 2649 if (document().frame()) { |
2650 if (!document().frame()->eventHandler().isPointerEventActive(pointerId)) | 2650 if (!document().frame()->eventHandler().isPointerEventActive(pointerId)) |
2651 exceptionState.throwDOMException(InvalidPointerId, "InvalidPointerId "); | 2651 exceptionState.throwDOMException(InvalidPointerId, "InvalidPointerId "); |
2652 else if (!inDocument()) | 2652 else if (!inDocument()) |
2653 exceptionState.throwDOMException(InvalidStateError, "InvalidStateErr or"); | 2653 exceptionState.throwDOMException(InvalidStateError, "InvalidStateErr or"); |
2654 // TODO(crbug.com/579553): This next "else if" is a hack to suppress cap turing for touches | |
mustaq
2016/04/04 15:37:26
...hack to notify JS that we don't (yet) support e
Navid Zolghadr
2016/04/04 16:26:57
Done.
| |
2655 else if (document().frame()->eventHandler().getPointerEventType(pointerI d) == WebPointerProperties::PointerType::Touch) | |
2656 exceptionState.throwDOMException(InvalidPointerId, "InvalidPointerId "); | |
2654 else | 2657 else |
2655 document().frame()->eventHandler().setPointerCapture(pointerId, this ); | 2658 document().frame()->eventHandler().setPointerCapture(pointerId, this ); |
2656 } | 2659 } |
2657 } | 2660 } |
2658 | 2661 |
2659 void Element::releasePointerCapture(int pointerId, ExceptionState& exceptionStat e) | 2662 void Element::releasePointerCapture(int pointerId, ExceptionState& exceptionStat e) |
2660 { | 2663 { |
2661 if (document().frame()) { | 2664 if (document().frame()) { |
2662 if (!document().frame()->eventHandler().isPointerEventActive(pointerId)) | 2665 if (!document().frame()->eventHandler().isPointerEventActive(pointerId)) |
2663 exceptionState.throwDOMException(InvalidPointerId, "InvalidPointerId "); | 2666 exceptionState.throwDOMException(InvalidPointerId, "InvalidPointerId "); |
2667 // TODO(crbug.com/579553): This next "else if" is a hack to suppress cap turing for touches | |
mustaq
2016/04/04 15:37:26
Ditto.
Navid Zolghadr
2016/04/04 16:26:57
Done.
| |
2668 else if (document().frame()->eventHandler().getPointerEventType(pointerI d) == WebPointerProperties::PointerType::Touch) | |
2669 exceptionState.throwDOMException(InvalidPointerId, "InvalidPointerId "); | |
2664 else | 2670 else |
2665 document().frame()->eventHandler().releasePointerCapture(pointerId, this); | 2671 document().frame()->eventHandler().releasePointerCapture(pointerId, this); |
2666 } | 2672 } |
2667 } | 2673 } |
2668 | 2674 |
2669 String Element::innerText() | 2675 String Element::innerText() |
2670 { | 2676 { |
2671 // We need to update layout, since plainText uses line boxes in the layout t ree. | 2677 // We need to update layout, since plainText uses line boxes in the layout t ree. |
2672 document().updateLayoutIgnorePendingStylesheets(); | 2678 document().updateLayoutIgnorePendingStylesheets(); |
2673 | 2679 |
(...skipping 995 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3669 { | 3675 { |
3670 #if ENABLE(OILPAN) | 3676 #if ENABLE(OILPAN) |
3671 if (hasRareData()) | 3677 if (hasRareData()) |
3672 visitor->trace(elementRareData()); | 3678 visitor->trace(elementRareData()); |
3673 visitor->trace(m_elementData); | 3679 visitor->trace(m_elementData); |
3674 #endif | 3680 #endif |
3675 ContainerNode::trace(visitor); | 3681 ContainerNode::trace(visitor); |
3676 } | 3682 } |
3677 | 3683 |
3678 } // namespace blink | 3684 } // namespace blink |
OLD | NEW |