mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-20 04:25:42 +08:00
refs #735, allow to reset highlighting
(some leftovers of DB object highlighting also deleted)
This commit is contained in:
committed by
Mathew Sutcliffe
parent
2434c7bbe2
commit
b324a26747
@@ -357,6 +357,9 @@ namespace BlackGui
|
||||
actionInteractiveResize->setChecked(autoResize);
|
||||
actionInteractiveResize->setEnabled(enabled);
|
||||
connect(actionInteractiveResize, &QAction::toggled, this, &CViewBaseNonTemplate::ps_toggleResizeMode);
|
||||
|
||||
// Clear highlighting
|
||||
menuActions.addAction(CIcons::refresh16(), "Clear highlighting", CMenuAction::pathViewClearHighlighting(), nullptr , { this, &CViewBaseNonTemplate::clearHighlighting });
|
||||
}
|
||||
|
||||
void CViewBaseNonTemplate::showEvent(QShowEvent *event)
|
||||
@@ -957,6 +960,13 @@ namespace BlackGui
|
||||
}
|
||||
}
|
||||
|
||||
template <class ModelClass, class ContainerType, class ObjectType>
|
||||
void CViewBase<ModelClass, ContainerType, ObjectType>::clearHighlighting()
|
||||
{
|
||||
Q_ASSERT(this->m_model);
|
||||
return this->m_model->clearHighlighting();
|
||||
}
|
||||
|
||||
template <class ModelClass, class ContainerType, class ObjectType>
|
||||
int CViewBase<ModelClass, ContainerType, ObjectType>::rowCount() const
|
||||
{
|
||||
|
||||
@@ -309,6 +309,9 @@ namespace BlackGui
|
||||
//! Remove selected rows
|
||||
virtual int removeSelectedRows() = 0;
|
||||
|
||||
//! Clear any highlighted objects
|
||||
virtual void clearHighlighting() = 0;
|
||||
|
||||
protected:
|
||||
//! Constructor
|
||||
CViewBaseNonTemplate(QWidget *parent);
|
||||
@@ -543,6 +546,7 @@ namespace BlackGui
|
||||
//! @{
|
||||
virtual int removeSelectedRows() override;
|
||||
virtual void presizeOrFullResizeToContents() override;
|
||||
virtual void clearHighlighting() override;
|
||||
//! @}
|
||||
|
||||
//! \name BlackGui::Views::CViewBaseNonTemplate implementations
|
||||
|
||||
Reference in New Issue
Block a user