mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 13:10:19 +00:00
Start editing Dive Notes when clicking on Rating or Visibility
Those widgets respond to MouseButtonPress and not FocusIn. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
a5b14304f2
commit
33135e37a5
1 changed files with 2 additions and 1 deletions
|
@ -36,6 +36,7 @@ MainTab::MainTab(QWidget *parent) : QTabWidget(parent),
|
||||||
ui->notes->setReadOnly(true);
|
ui->notes->setReadOnly(true);
|
||||||
ui->rating->setReadOnly(true);
|
ui->rating->setReadOnly(true);
|
||||||
ui->visibility->setReadOnly(true);
|
ui->visibility->setReadOnly(true);
|
||||||
|
|
||||||
ui->editAccept->hide();
|
ui->editAccept->hide();
|
||||||
ui->editReset->hide();
|
ui->editReset->hide();
|
||||||
|
|
||||||
|
@ -107,7 +108,7 @@ void MainTab::showEvent(QShowEvent* event)
|
||||||
|
|
||||||
bool MainTab::eventFilter(QObject* object, QEvent* event)
|
bool MainTab::eventFilter(QObject* object, QEvent* event)
|
||||||
{
|
{
|
||||||
if (event->type() == QEvent::FocusIn) {
|
if (event->type() == QEvent::FocusIn || event->type() == QEvent::MouseButtonPress) {
|
||||||
if (ui->editAccept->isVisible() || !currentDive)
|
if (ui->editAccept->isVisible() || !currentDive)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue