diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/ui/alsa/alsadevicewidget.cpp | 5 | ||||
| -rw-r--r-- | src/ui/devicewidget.cpp | 6 | ||||
| -rw-r--r-- | src/ui/oss/ossdevicewidget.cpp | 5 |
3 files changed, 12 insertions, 4 deletions
diff --git a/src/ui/alsa/alsadevicewidget.cpp b/src/ui/alsa/alsadevicewidget.cpp index 214d931..6297640 100644 --- a/src/ui/alsa/alsadevicewidget.cpp +++ b/src/ui/alsa/alsadevicewidget.cpp @@ -99,7 +99,10 @@ AlsaDeviceWidget::AlsaDeviceWidget( AlsaDevice *dev, TQWidget *parent ) TQPixmap px = iconForDevice(dev); if ( !px.isNull() ) icon->setPixmap(px); topRow->addWidget(icon, 0, TQt::AlignVCenter); - m_volLabel = new TQLabel(TQString("%1%").arg(dev->volume()), this); + m_volLabel = new TQLabel("100%", this); + m_volLabel->setFixedWidth( m_volLabel->sizeHint().width() + 2 ); + m_volLabel->setAlignment( TQt::AlignRight | TQt::AlignVCenter ); + m_volLabel->setText( TQString("%1%").arg(dev->volume()) ); topRow->addWidget(m_volLabel, 0, TQt::AlignVCenter); col->addLayout(topRow); diff --git a/src/ui/devicewidget.cpp b/src/ui/devicewidget.cpp index 645ffaa..6bcef6d 100644 --- a/src/ui/devicewidget.cpp +++ b/src/ui/devicewidget.cpp @@ -128,8 +128,10 @@ DeviceWidget::DeviceWidget( AudioDevice *device, PulseModel *model, TQWidget *pa m_iconLabel->setPixmap( px ); } - m_volLabel = new TQLabel( TQString::number(device->volume()) + "%", this ); - m_volLabel->setAlignment( TQLabel::AlignHCenter ); + m_volLabel = new TQLabel( "100%", this ); + m_volLabel->setFixedWidth( m_volLabel->sizeHint().width() + 2 ); + m_volLabel->setAlignment( TQLabel::AlignRight | TQLabel::AlignVCenter ); + m_volLabel->setText( TQString::number(device->volume()) + "%" ); m_levelMeter = new LevelMeter( this ); m_levelMeter->setFixedWidth( 14 ); diff --git a/src/ui/oss/ossdevicewidget.cpp b/src/ui/oss/ossdevicewidget.cpp index 03fd91b..7a08698 100644 --- a/src/ui/oss/ossdevicewidget.cpp +++ b/src/ui/oss/ossdevicewidget.cpp @@ -81,7 +81,10 @@ OssDeviceWidget::OssDeviceWidget( OssDevice *dev, TQWidget *parent ) TQPixmap px = iconForDevice(dev); if ( !px.isNull() ) icon->setPixmap(px); topRow->addWidget(icon, 0, TQt::AlignVCenter); - m_volLabel = new TQLabel(TQString("%1%").arg(dev->volume()), this); + m_volLabel = new TQLabel("100%", this); + m_volLabel->setFixedWidth( m_volLabel->sizeHint().width() + 2 ); + m_volLabel->setAlignment( TQt::AlignRight | TQt::AlignVCenter ); + m_volLabel->setText( TQString("%1%").arg(dev->volume()) ); topRow->addWidget(m_volLabel, 0, TQt::AlignVCenter); col->addLayout(topRow); |
