Diffstat (limited to 'noncore/graphics/opie-eye/lib/oimagezoomer.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/graphics/opie-eye/lib/oimagezoomer.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/noncore/graphics/opie-eye/lib/oimagezoomer.h b/noncore/graphics/opie-eye/lib/oimagezoomer.h index 2516c61..0b356c9 100644 --- a/noncore/graphics/opie-eye/lib/oimagezoomer.h +++ b/noncore/graphics/opie-eye/lib/oimagezoomer.h @@ -62,25 +62,26 @@ signals: * * * @param x The way to move relative on the X-Axis * @param y The way to move relative on the Y-Axis * * @see setVisiblePoint * @see QScrollView::scrollBy */ void zoomAreaRel( int x,int y); /** * Here you get absolute coordinates. - * This slot will be emitted from within the mouseMoveEvent of this widget. + * This slot will be emitted from within the mouseReleaseEvent of this widget. + * if no mouse move where done. * So you may not delete this widget * * @param x The absolute X Coordinate to scroll to. * @param y The absolute Y Coordinate to scroll to. * */ void zoomArea( int x,int y); public: /** * make sure to call these if you reimplement * @internal @@ -89,40 +90,46 @@ public: protected: /** * make sure to call these if you reimplement * @internal */ void drawContents( QPainter* p ); /** * make sure to call these if you reimplememt * @internal */ - void mousePressEvent( QMouseEvent* ev ); + virtual void mousePressEvent( QMouseEvent* ev ); /** * make sure to call these if you reimplement * @internal */ - void mouseMoveEvent( QMouseEvent* ev ); + virtual void mouseMoveEvent( QMouseEvent* ev ); + /** + * make sure to call these if you reimplement + * @internal + */ + virtual void mouseReleaseEvent( QMouseEvent* ev ); private: /** * @internal */ void init(); QImage m_img; QSize m_imgSize, m_visSize; QPoint m_visPt; int m_mouseX, m_mouseY; + bool m_mevent; }; /** * This slot is present for convience. You can connect the * QScrollView::contentsMoved to this slot and it calls the QPoint * version for you * This realtes to QScrollView::contentsX() and QScrollView::contentsY() * * @param x The top left x coordinate * @param y The top left y coorisnate */ inline void OImageZoomer::setVisiblePoint( int x, int y ) { |