/* * Copyright (C) 2008, 2009, Apple Inc. All rights reserved. * * Permission is granted by Apple to use this file to the extent * necessary to relink with LGPL WebKit files. * * No license or rights are granted by Apple expressly or by * implication, estoppel, or otherwise, to Apple patents and * trademarks. For the sake of clarity, no license or rights are * granted by Apple expressly or by implication, estoppel, or otherwise, * under any Apple patents, copyrights and trademarks to underlying * implementations of any application programming interfaces (APIs) * or to any functionality that is invoked by calling any API. */ public: PassRefPtr createTouch(DOMWindow* view, EventTarget* target, long identifier, long pageX, long pageY, long screenX, long screenY, ExceptionCode&); PassRefPtr createTouchList(ExceptionCode&); typedef HashCountedSet TouchListenerMap; void setInTouchEventHandling(bool handling); void addTouchEventListener(Node*); void removeTouchEventListener(Node*, bool removeAll = false); void dirtyTouchEventRects(); void clearTouchEventListeners(); const TouchListenerMap& touchEventListeners() const; void getTouchRects(Vector&); private: void setTouchEventListenersDirty(bool); IntRect eventRectRelativeToRoot(Node*, RenderObject*); void touchEventsChangedTimerFired(Timer*); void checkChildRenderers(RenderObject*, const IntRect& containingRect, Vector& nodeRects); void removeTouchEventListenersInDocument(Document*); typedef HashMap< RefPtr, Vector > TouchEventRectMap; bool m_handlingTouchEvent; bool m_touchEventRegionsDirty; TouchListenerMap m_touchEventListenersCounts; TouchEventRectMap m_touchEventRects; Mutex m_touchEventsRectMutex; Timer m_touchEventsChangedTimer; public: