From 0cf259cd89ea9cfb300df98e10746b465b380c7f Mon Sep 17 00:00:00 2001 From: struktured Date: Sat, 25 Apr 2026 10:32:43 -0400 Subject: [PATCH] Fix #3: suppress status tips from playlist dock when floating When the playlist dock widget is undocked and moved to a separate screen (typical multi-monitor setup with a beamer/projector), Qt's default behavior propagates QStatusTipEvents from the playlist's items up to the main window's status bar. The hover info appears on the wrong screen. Install an event filter on the dock widget and table view that consumes QStatusTipEvent when the dock is floating, preventing propagation to the main window's status bar. Tooltips still work normally and appear at the cursor on the correct screen. Closes #3 Co-Authored-By: Claude Opus 4.6 (1M context) --- src/common/qprojectm_mainwindow.cpp | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/common/qprojectm_mainwindow.cpp b/src/common/qprojectm_mainwindow.cpp index 4e7d764..609d446 100644 --- a/src/common/qprojectm_mainwindow.cpp +++ b/src/common/qprojectm_mainwindow.cpp @@ -115,6 +115,13 @@ m_QPlaylistFileDialog( new QPlaylistFileDialog ( this )) setCentralWidget ( m_QProjectMWidget ); m_QProjectMWidget->installEventFilter(this); + // When the playlist dock is floating on a separate screen, hover events + // would otherwise propagate status tips to the main window's status bar + // (issue #3). Filter them at the dock so the info doesn't appear on the + // wrong screen. + ui->presetPlayListDockWidget->installEventFilter(this); + ui->tableView->installEventFilter(this); + m_timer->start ( 0 ); createActions(); @@ -1407,7 +1414,14 @@ void QProjectM_MainWindow::handleFailedPresetSwitch(const QString & filename, co bool QProjectM_MainWindow::eventFilter(QObject *obj, QEvent *event) { - Q_UNUSED(obj); + // Suppress status tips originating from the playlist when the dock is + // floating on a different screen, so they don't appear on the main + // window's status bar (issue #3). + if (event->type() == QEvent::StatusTip + && ui->presetPlayListDockWidget->isFloating() + && (obj == ui->presetPlayListDockWidget || obj == ui->tableView)) { + return true; + } if (event->type() == QEvent::MouseButtonDblClick && ((QMouseEvent*)event)->button() == Qt::LeftButton) { this->setWindowState ( this->windowState() ^ Qt::WindowFullScreen );