From b3435f62d7dd189165538cbc1fd7b82baed7fe00 Mon Sep 17 00:00:00 2001 From: jp9000 Date: Sat, 13 May 2017 20:45:48 -0700 Subject: [PATCH] UI: Bring stats to front if it already exists If the menu item is triggered again, just bring it to the front instead of trying to recreate it again. --- UI/window-basic-main.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/UI/window-basic-main.cpp b/UI/window-basic-main.cpp index 71f432950..9e1495040 100644 --- a/UI/window-basic-main.cpp +++ b/UI/window-basic-main.cpp @@ -5492,7 +5492,12 @@ void OBSBasic::on_autoConfigure_triggered() void OBSBasic::on_stats_triggered() { - stats.clear(); + if (!stats.isNull()) { + stats->show(); + stats->raise(); + return; + } + OBSBasicStats *statsDlg; statsDlg = new OBSBasicStats(nullptr); statsDlg->setModal(false);