Swap dir pause and rescan buttons
Looks better with Breeze icon theme
This commit is contained in:
parent
02c4c778e5
commit
6c62bf946b
|
@ -52,8 +52,8 @@ void DirButtonsItemDelegate::paint(QPainter *painter, const QStyleOptionViewItem
|
|||
|
||||
// draw buttons
|
||||
const int buttonY = option.rect.y() + centerObj(option.rect.height(), 16);
|
||||
painter->drawPixmap(option.rect.right() - 52, buttonY, 16, 16, index.data(SyncthingDirectoryModel::DirectoryPaused).toBool() ? m_resumeIcon : m_pauseIcon);
|
||||
painter->drawPixmap(option.rect.right() - 34, buttonY, 16, 16, m_refreshIcon);
|
||||
painter->drawPixmap(option.rect.right() - 52, buttonY, 16, 16, m_refreshIcon);
|
||||
painter->drawPixmap(option.rect.right() - 34, buttonY, 16, 16, index.data(SyncthingDirectoryModel::DirectoryPaused).toBool() ? m_resumeIcon : m_pauseIcon);
|
||||
painter->drawPixmap(option.rect.right() - 16, buttonY, 16, 16, m_folderIcon);
|
||||
}
|
||||
|
||||
|
|
|
@ -41,9 +41,9 @@ void DirView::mouseReleaseEvent(QMouseEvent *event)
|
|||
const QRect itemRect(visualRect(clickedIndex));
|
||||
if(pos.x() > itemRect.right() - 58) {
|
||||
if(pos.x() < itemRect.right() - 34) {
|
||||
emit pauseResumeDir(*dir);
|
||||
} else if(pos.x() < itemRect.right() - 17) {
|
||||
emit scanDir(*dir);
|
||||
} else if(pos.x() < itemRect.right() - 17) {
|
||||
emit pauseResumeDir(*dir);
|
||||
} else {
|
||||
emit openDir(*dir);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue