mirror of
https://github.com/Palakis/obs-websocket.git
synced 2024-08-30 18:12:16 +00:00
Forms: Use QHideEvent instead of QCloseEvent
QCloseEvent is the wrong event to use here. If the `Ok` button is pressed for example, QCloseEvent is not emitted. QHideEvent is always called when the dialog is hidden.
This commit is contained in:
parent
a4e62acf25
commit
342164dfb5
@ -90,8 +90,10 @@ void SettingsDialog::showEvent(QShowEvent *event)
|
||||
sessionTableTimer->start(1000);
|
||||
}
|
||||
|
||||
void SettingsDialog::closeEvent(QCloseEvent *event)
|
||||
void SettingsDialog::hideEvent(QHideEvent *event)
|
||||
{
|
||||
UNUSED_PARAMETER(event);
|
||||
|
||||
if (sessionTableTimer->isActive())
|
||||
sessionTableTimer->stop();
|
||||
|
||||
|
@ -16,7 +16,7 @@ public:
|
||||
explicit SettingsDialog(QWidget* parent = 0);
|
||||
~SettingsDialog();
|
||||
void showEvent(QShowEvent *event);
|
||||
void closeEvent(QCloseEvent *event);
|
||||
void hideEvent(QHideEvent *event);
|
||||
void ToggleShowHide();
|
||||
|
||||
private Q_SLOTS:
|
||||
|
Loading…
Reference in New Issue
Block a user