diff --git a/qt/file-tree.cc b/qt/file-tree.cc index 619ddd166..9a3b623f2 100644 --- a/qt/file-tree.cc +++ b/qt/file-tree.cc @@ -533,7 +533,7 @@ FileTreeDelegate :: paint( QPainter * painter, else if( column == COL_PROGRESS ) { QStyleOptionProgressBar p; - p.state = QStyle::State_Enabled; + p.state = option.state | QStyle::State_Small; p.direction = QApplication::layoutDirection(); p.rect = option.rect; p.rect.setSize( QSize( option.rect.width()-2, option.rect.height()-2 ) ); @@ -550,7 +550,7 @@ FileTreeDelegate :: paint( QPainter * painter, else if( column == COL_WANTED ) { QStyleOptionButton o; - o.state = QStyle::State_Enabled; + o.state = option.state; o.direction = QApplication::layoutDirection(); o.rect.setSize( QSize( 20, option.rect.height( ) ) ); o.rect.moveCenter( option.rect.center( ) ); diff --git a/qt/torrent-delegate-min.cc b/qt/torrent-delegate-min.cc index 026d0955b..4c973f6f5 100644 --- a/qt/torrent-delegate-min.cc +++ b/qt/torrent-delegate-min.cc @@ -149,7 +149,7 @@ TorrentDelegateMin :: drawTorrent( QPainter * painter, const QStyleOptionViewIte myProgressBarStyle->direction = option.direction; myProgressBarStyle->palette = option.palette; myProgressBarStyle->palette.setCurrentColorGroup( QPalette::Disabled ); - myProgressBarStyle->state = QStyle::State_Off; + myProgressBarStyle->state = option.state | QStyle::State_Small; myProgressBarStyle->progress = int(myProgressBarStyle->minimum + ((tor.percentDone() * (myProgressBarStyle->maximum - myProgressBarStyle->minimum)))); style->drawControl( QStyle::CE_ProgressBar, myProgressBarStyle, painter ); diff --git a/qt/torrent-delegate.cc b/qt/torrent-delegate.cc index 82081f938..d8b9fadf8 100644 --- a/qt/torrent-delegate.cc +++ b/qt/torrent-delegate.cc @@ -364,7 +364,7 @@ TorrentDelegate :: drawTorrent( QPainter * painter, const QStyleOptionViewItem& myProgressBarStyle->direction = option.direction; myProgressBarStyle->palette = option.palette; myProgressBarStyle->palette.setCurrentColorGroup( QPalette::Disabled ); - myProgressBarStyle->state = QStyle::State_Off; + myProgressBarStyle->state = option.state | QStyle::State_Small; myProgressBarStyle->progress = int(myProgressBarStyle->minimum + ((tor.percentDone() * (myProgressBarStyle->maximum - myProgressBarStyle->minimum)))); style->drawControl( QStyle::CE_ProgressBar, myProgressBarStyle, painter );