20 #include "tdehtml_events.h"
21 #include "rendering/render_object.h"
22 #include "xml/dom_nodeimpl.h"
24 using namespace tdehtml;
26 class tdehtml::MouseEvent::MouseEventPrivate
30 tdehtml::MouseEvent::MouseEvent(
const char *name, TQMouseEvent *qmouseEvent,
int x,
int y,
33 : KParts::Event(
name ), m_qmouseEvent( qmouseEvent ), m_x( x ), m_y( y ),
34 m_url( url ), m_target(target), m_innerNode( innerNode )
37 if (innerNode.handle() && innerNode.handle()->renderer())
38 innerNode.handle()->renderer()->absolutePosition(m_nodeAbsX, m_nodeAbsY);
41 tdehtml::MouseEvent::~MouseEvent()
46 long tdehtml::MouseEvent::offset()
const
49 DOM::NodeImpl* tempNode = 0;
52 if (innerNode().handle()->renderer()) {
53 innerNode().handle()->renderer()->absolutePosition(absX, absY);
54 tdehtml::RenderObject::SelPointState state;
55 innerNode().handle()->renderer()->checkSelectionPoint( x(), y(), absX, absY, tempNode, offset, state );
60 const char *tdehtml::MousePressEvent::s_strMousePressEvent =
"tdehtml/Events/MousePressEvent";
62 const char *tdehtml::MouseDoubleClickEvent::s_strMouseDoubleClickEvent =
"tdehtml/Events/MouseDoubleClickEvent";
64 const char *tdehtml::MouseMoveEvent::s_strMouseMoveEvent =
"tdehtml/Events/MouseMoveEvent";
66 const char *tdehtml::MouseReleaseEvent::s_strMouseReleaseEvent =
"tdehtml/Events/MouseReleaseEvent";
68 const char *tdehtml::DrawContentsEvent::s_strDrawContentsEvent =
"tdehtml/Events/DrawContentsEvent";
70 class tdehtml::DrawContentsEvent::DrawContentsEventPrivate
73 DrawContentsEventPrivate()
76 ~DrawContentsEventPrivate()
81 tdehtml::DrawContentsEvent::DrawContentsEvent( TQPainter *painter,
int clipx,
int clipy,
int clipw,
int cliph )
82 : KParts::Event( s_strDrawContentsEvent ), m_painter( painter ), m_clipx( clipx ), m_clipy( clipy ),
83 m_clipw( clipw ), m_cliph( cliph )
85 d =
new DrawContentsEventPrivate;
88 tdehtml::DrawContentsEvent::~DrawContentsEvent()
This class implements the basic string we use in the DOM.
The Node interface is the primary datatype for the entire Document Object Model.
TQString name(StdAccel id)