QtPass 1.6.0
Multi-platform GUI for pass, the standard unix password manager.
Loading...
Searching...
No Matches
DeselectableTreeView Class Reference

#include <deselectabletreeview.h>

Inheritance diagram for DeselectableTreeView:
Collaboration diagram for DeselectableTreeView:

Signals

void emptyClicked ()
 emptyClicked event

Public Member Functions

 DeselectableTreeView (QWidget *parent)
 DeselectableTreeView standard constructor.
 ~DeselectableTreeView () override=default
 ~DeselectableTreeView standard destructor

Detailed Description

A QTreeView subclass that clears selection and emits a signal when the user clicks an empty area or clicks a selected item in empty space.

The view tracks press/release sequences to distinguish single- from double-clicks and only clears selection for qualifying single-clicks. Construct a DeselectableTreeView.

Parameters
parentParent widget forwarded to QTreeView. Default destructor. Emitted after the view clears its selection in response to a qualifying click on empty space or on an already-selected item. Record whether the item under the press position was selected.
eventMouse press event containing the press position. Clear selection and emit emptyClicked() when a qualifying single-click releases over empty space or over a selected item; otherwise, handle the release normally.
eventMouse release event containing the release position. Mark that a double-click occurred and handle the double-click normally.
eventMouse double-click event.

Definition at line 49 of file deselectabletreeview.h.

Constructor & Destructor Documentation

◆ DeselectableTreeView()

DeselectableTreeView::DeselectableTreeView ( QWidget * parent)
inline

DeselectableTreeView standard constructor.

Parameters
parent

Definition at line 57 of file deselectabletreeview.h.

◆ ~DeselectableTreeView()

DeselectableTreeView::~DeselectableTreeView ( )
overridedefault

~DeselectableTreeView standard destructor

Member Function Documentation

◆ emptyClicked

void DeselectableTreeView::emptyClicked ( )
signal

emptyClicked event

Examples
/home/annejan/Projects/QtPass/src/mainwindow.cpp.
Here is the caller graph for this function:

The documentation for this class was generated from the following file: