Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Tidy up MythConfirmationDialog::ShowOkPopup()

Signed-off-by: Stuart Morgan <smorgan@mythtv.org>
  • Loading branch information...
commit 2699d8650c783c8a22fcfe017c9295855916e370 1 parent ca27332
Lawrence Rust authored stuartm committed
Showing with 12 additions and 16 deletions.
  1. +12 −16 mythtv/libs/libmythui/mythdialogbox.cpp
View
28 mythtv/libs/libmythui/mythdialogbox.cpp
@@ -575,25 +575,21 @@ MythConfirmationDialog *ShowOkPopup(const QString &message, QObject *parent,
MythConfirmationDialog *pop;
MythScreenStack *stk = NULL;
+ MythMainWindow *win = GetMythMainWindow();
- if (!stk)
+ if (win)
+ stk = win->GetStack("popup stack");
+ else
{
- MythMainWindow *win = GetMythMainWindow();
-
- if (win)
- stk = win->GetStack("popup stack");
- else
- {
- LOG(VB_GENERAL, LOG_ERR, LOC + "no main window?");
- return NULL;
- }
+ LOG(VB_GENERAL, LOG_ERR, LOC + "no main window?");
+ return NULL;
+ }
- if (!stk)
- {
- LOG(VB_GENERAL, LOG_ERR, LOC + "no popup stack? "
- "Is there a MythThemeBase?");
- return NULL;
- }
+ if (!stk)
+ {
+ LOG(VB_GENERAL, LOG_ERR, LOC + "no popup stack? "
+ "Is there a MythThemeBase?");
+ return NULL;
}
pop = new MythConfirmationDialog(stk, message, showCancel);
Please sign in to comment.
Something went wrong with that request. Please try again.