summaryrefslogtreecommitdiff
path: root/core/applets
authordrw <drw>2005-03-02 18:54:28 (UTC)
committer drw <drw>2005-03-02 18:54:28 (UTC)
commit9f1589f7c83aed5f307b2f99018198661e84a95b (patch) (side-by-side diff)
tree1c5c4297d88a96deba367f73c095f798bdb1c5b6 /core/applets
parentb9d921e98946ee787ec995f44eb1b937d669b430 (diff)
downloadopie-9f1589f7c83aed5f307b2f99018198661e84a95b.zip
opie-9f1589f7c83aed5f307b2f99018198661e84a95b.tar.gz
opie-9f1589f7c83aed5f307b2f99018198661e84a95b.tar.bz2
Scale icons approprtely
Diffstat (limited to 'core/applets') (more/less context) (ignore whitespace changes)
-rw-r--r--core/applets/volumeapplet/volume.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/core/applets/volumeapplet/volume.cpp b/core/applets/volumeapplet/volume.cpp
index 23c847d..11ba2f6 100644
--- a/core/applets/volumeapplet/volume.cpp
+++ b/core/applets/volumeapplet/volume.cpp
@@ -272,14 +272,17 @@ VolumeControl::VolumeControl ( VolumeApplet *icon, bool /*showMic*/, QWidget *pa
upButton = new QPushButton ( this );
upButton-> setSizePolicy ( QSizePolicy ( QSizePolicy::Minimum, QSizePolicy::Expanding ));
- upButton-> setPixmap ( Resource::loadPixmap ( "up" ));
+ QPixmap pic;
+ pic.convertFromImage( Resource::loadImage( "up" ).smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) );
+ upButton-> setPixmap ( pic );
upButton-> setFocusPolicy ( QWidget::NoFocus );
vbox-> addWidget ( upButton );
downButton = new QPushButton ( this );
downButton-> setSizePolicy ( QSizePolicy ( QSizePolicy::Minimum, QSizePolicy::Expanding ));
- downButton-> setPixmap ( Resource::loadPixmap ( "down" ));
+ pic.convertFromImage( Resource::loadImage( "down" ).smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) );
+ downButton-> setPixmap ( pic );
downButton-> setFocusPolicy ( QWidget::NoFocus );
vbox-> addWidget ( downButton );
@@ -724,7 +727,9 @@ VolumeApplet::VolumeApplet( QWidget *parent, const char *name )
setFixedWidth ( AppLnk::smallIconSize() );
setFixedHeight ( AppLnk::smallIconSize()+4 );
- m_pixmap = new QPixmap ( Resource::loadPixmap ( "volume" ));
+ QPixmap pic;
+ pic.convertFromImage( Resource::loadImage( "volume" ).smoothScale( AppLnk::smallIconSize(), AppLnk::smallIconSize() ) );
+ m_pixmap = new QPixmap ( pic );
m_dialog = new VolumeControl ( this, true, this, "volumecontrol" );
connect ( qApp, SIGNAL( volumeChanged(bool)), m_dialog, SLOT( volumeChanged(bool)));