mirror of
https://invent.kde.org/system/dolphin
synced 2024-11-05 18:47:12 +00:00
request the activation of a column also on directories if not the left mouse button is pressed
svn path=/trunk/KDE/kdebase/apps/; revision=696094
This commit is contained in:
parent
b5a1200417
commit
94594d2a08
1 changed files with 10 additions and 2 deletions
|
@ -60,7 +60,7 @@ public:
|
|||
|
||||
void obtainSelectionModel();
|
||||
void releaseSelectionModel();
|
||||
|
||||
|
||||
protected:
|
||||
virtual QStyleOptionViewItem viewOptions() const;
|
||||
virtual void dragEnterEvent(QDragEnterEvent* event);
|
||||
|
@ -144,7 +144,7 @@ void ColumnWidget::setActive(bool active)
|
|||
} else {
|
||||
releaseSelectionModel();
|
||||
}
|
||||
|
||||
|
||||
if (m_active == active) {
|
||||
return;
|
||||
}
|
||||
|
@ -255,6 +255,14 @@ void ColumnWidget::mousePressEvent(QMouseEvent* event)
|
|||
} else if (item->isDir()) {
|
||||
m_childUrl = item->url();
|
||||
viewport()->update();
|
||||
|
||||
// Only request the activation if not the left button is pressed.
|
||||
// The left button on a directory opens a new column, hence requesting
|
||||
// an activation is useless as the new column will request the activation
|
||||
// afterwards.
|
||||
if (event->button() != Qt::LeftButton) {
|
||||
m_view->requestActivation(this);
|
||||
}
|
||||
} else {
|
||||
m_view->requestActivation(this);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue