diff options
Diffstat (limited to 'doc/html/popup-example.html')
-rw-r--r-- | doc/html/popup-example.html | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/doc/html/popup-example.html b/doc/html/popup-example.html index 7d3979d9f..22d4864c9 100644 --- a/doc/html/popup-example.html +++ b/doc/html/popup-example.html @@ -65,8 +65,8 @@ public: void popup( <a href="tqwidget.html">TQWidget</a>* parent = 0); protected: - virtual void mouseMoveEvent( <a href="qmouseevent.html">TQMouseEvent</a> * ); - virtual void mouseReleaseEvent( <a href="qmouseevent.html">TQMouseEvent</a> * ); + virtual void mouseMoveEvent( <a href="tqmouseevent.html">TQMouseEvent</a> * ); + virtual void mouseReleaseEvent( <a href="tqmouseevent.html">TQMouseEvent</a> * ); virtual void closeEvent( <a href="tqcloseevent.html">TQCloseEvent</a> * ); private: @@ -123,17 +123,17 @@ private: <a href="tqwidget.html#setMouseTracking">setMouseTracking</a>( TRUE ); } -<a name="x1620"></a>void FancyPopup::<a href="tqwidget.html#mouseMoveEvent">mouseMoveEvent</a>( <a href="qmouseevent.html">TQMouseEvent</a> * e){ +<a name="x1620"></a>void FancyPopup::<a href="tqwidget.html#mouseMoveEvent">mouseMoveEvent</a>( <a href="tqmouseevent.html">TQMouseEvent</a> * e){ moves++; <a href="tqstring.html">TQString</a> s; -<a name="x1611"></a> s.<a href="tqstring.html#sprintf">sprintf</a>("%d/%d", e-><a href="qmouseevent.html#pos">pos</a>().x(), e-><a href="qmouseevent.html#pos">pos</a>().y()); -<a name="x1612"></a> if (e-><a href="qmouseevent.html#state">state</a>() & TQMouseEvent::LeftButton) +<a name="x1611"></a> s.<a href="tqstring.html#sprintf">sprintf</a>("%d/%d", e-><a href="tqmouseevent.html#pos">pos</a>().x(), e-><a href="tqmouseevent.html#pos">pos</a>().y()); +<a name="x1612"></a> if (e-><a href="tqmouseevent.html#state">state</a>() & TQMouseEvent::LeftButton) s += " (down)"; <a href="tqlabel.html#setText">setText</a>(s); } -<a name="x1621"></a>void FancyPopup::<a href="tqwidget.html#mouseReleaseEvent">mouseReleaseEvent</a>( <a href="qmouseevent.html">TQMouseEvent</a> * e){ - if (<a href="tqwidget.html#rect">rect</a>().contains( e-><a href="qmouseevent.html#pos">pos</a>() ) || moves > 5) +<a name="x1621"></a>void FancyPopup::<a href="tqwidget.html#mouseReleaseEvent">mouseReleaseEvent</a>( <a href="tqmouseevent.html">TQMouseEvent</a> * e){ + if (<a href="tqwidget.html#rect">rect</a>().contains( e-><a href="tqmouseevent.html#pos">pos</a>() ) || moves > 5) <a href="tqwidget.html#close">close</a>(); } @@ -148,7 +148,7 @@ private: // the popupParent popped us up in its mousePressEvent handler. To // avoid the button remaining in pressed state we simply send a // faked mouse button release event to it. - <a href="qmouseevent.html">TQMouseEvent</a> me( TQEvent::MouseButtonRelease, TQPoint(0,0), TQPoint(0,0), TQMouseEvent::LeftButton, TQMouseEvent::NoButton); + <a href="tqmouseevent.html">TQMouseEvent</a> me( TQEvent::MouseButtonRelease, TQPoint(0,0), TQPoint(0,0), TQMouseEvent::LeftButton, TQMouseEvent::NoButton); <a name="x1602"></a> TQApplication::<a href="ntqapplication.html#sendEvent">sendEvent</a>( popupParent, &me ); } |