Changeset 2995 for vidalia/trunk
- Timestamp:
- 08/18/08 22:12:31 (3 months ago)
- Location:
- vidalia/trunk/src/vidalia
- Files:
-
- 2 removed
- 4 modified
-
CMakeLists.txt (modified) (2 diffs)
-
animatedpixmap.cpp (deleted)
-
animatedpixmap.h (deleted)
-
mainwindow.cpp (modified) (1 diff)
-
vclicklabel.cpp (modified) (3 diffs)
-
vclicklabel.h (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
vidalia/trunk/src/vidalia/CMakeLists.txt
r2986 r2995 178 178 main.cpp 179 179 vidalia.cpp 180 animatedpixmap.cpp181 180 languagesupport.cpp 182 181 mainwindow.cpp … … 188 187 qt4_wrap_cpp(vidalia_SRCS 189 188 vidalia.h 190 animatedpixmap.h191 189 mainwindow.h 192 190 vclicklabel.h -
vidalia/trunk/src/vidalia/mainwindow.cpp
r2983 r2995 50 50 #define IMG_TOR_STARTING_48 ":/images/48x48/tor-starting.png" 51 51 #define IMG_TOR_STOPPING_48 ":/images/48x48/tor-stopping.png" 52 53 //#define //ANIM_PROCESS_WORKING ":/images/32x32/process-working.png"54 52 55 53 /* Decide which of our four sets of tray icons to use. */ -
vidalia/trunk/src/vidalia/vclicklabel.cpp
r2362 r2995 26 26 { 27 27 setCursor(Qt::PointingHandCursor); 28 connect(&_anim, SIGNAL(frameChanged(int)),29 this, SLOT(animationFrameChanged(int)));30 28 } 31 29 … … 71 69 } 72 70 73 /** Sets the widget's image to the animated image file <b>animFile</b>. */74 void75 VClickLabel::setAnimation(const QPixmap &animPixmap)76 {77 _anim.setPixmap(animPixmap);78 _anim.start();79 }80 81 /** Responds to a frame change on the animation. */82 void83 VClickLabel::animationFrameChanged(int frameNumber)84 {85 Q_UNUSED(frameNumber);86 _pixmap = _anim.currentFrame();87 update();88 }89 90 71 /** Overloaded mouse event to catch left mouse button clicks. */ 91 72 void … … 110 91 VClickLabel::setPixmap(const QPixmap &pixmap) 111 92 { 112 _anim.stop();113 93 _pixmap = pixmap; 114 94 update(); -
vidalia/trunk/src/vidalia/vclicklabel.h
r2362 r2995 23 23 #include <QSize> 24 24 25 #include "animatedpixmap.h"26 27 25 28 26 class VClickLabel : public QWidget … … 43 41 /** Sets the widget's image to <b>img</b>. */ 44 42 void setPixmap(const QPixmap &img); 45 /** Sets the widget's image to the animated image file <b>animFile</b>. */46 void setAnimation(const QPixmap &animPixmap);47 43 48 44 signals: … … 56 52 virtual void mouseReleaseEvent(QMouseEvent *e); 57 53 58 private slots:59 /** Responds to a frame change on the animation. */60 void animationFrameChanged(int frameNumber);61 62 54 private: 63 55 QString _text; /**< Text label to display in the widget. */ 64 56 QPixmap _pixmap; /**< Image to display in the widget. */ 65 AnimatedPixmap _anim; /**< Animated pixmap to display. */66 57 }; 67 58
