mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-14 08:31:23 +00:00
- cleanup SDL fatal error reporting
Output error text to terminal if SDL message box cannot be shown Removed wrong "No IWAD found" message
This commit is contained in:
parent
279b327c6c
commit
b68a9ebef5
1 changed files with 9 additions and 7 deletions
|
@ -117,9 +117,8 @@ void Linux_I_FatalError(const char* errortext)
|
||||||
if((str=getenv("KDE_FULL_SESSION")) && strcmp(str, "true") == 0)
|
if((str=getenv("KDE_FULL_SESSION")) && strcmp(str, "true") == 0)
|
||||||
{
|
{
|
||||||
FString cmd;
|
FString cmd;
|
||||||
cmd << "kdialog --title \"" GAMESIG " ";
|
cmd << "kdialog --title \"" GAMESIG " " << GetVersionString()
|
||||||
cmd << GetVersionString() << ": No IWAD found\" ";
|
<< "\" --msgbox \"" << errortext << "\"";
|
||||||
cmd << "--msgbox \"" << errortext << "\"";
|
|
||||||
popen(cmd, "r");
|
popen(cmd, "r");
|
||||||
}
|
}
|
||||||
#ifndef NO_GTK
|
#ifndef NO_GTK
|
||||||
|
@ -130,10 +129,13 @@ void Linux_I_FatalError(const char* errortext)
|
||||||
#endif
|
#endif
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
FString message;
|
FString title;
|
||||||
message << GAMESIG " ";
|
title << GAMESIG " " << GetVersionString();
|
||||||
message << GetVersionString() << ": No IWAD found";
|
|
||||||
SDL_ShowSimpleMessageBox(SDL_MESSAGEBOX_ERROR, message, errortext, NULL);
|
if (SDL_ShowSimpleMessageBox(SDL_MESSAGEBOX_ERROR, title, errortext, NULL) < 0)
|
||||||
|
{
|
||||||
|
printf("\n%s\n", errortext);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue