mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-12-24 01:38:45 +00:00
Added return codes as requested.
This commit is contained in:
parent
3080717012
commit
da6391ec1e
4 changed files with 30 additions and 1 deletions
|
@ -88,5 +88,11 @@ int main( int argc, char **argv )
|
|||
w.setup( params );
|
||||
w.show();
|
||||
|
||||
return app.exec();
|
||||
int ret = app.exec();
|
||||
|
||||
if( ret != EXIT_SUCCESS )
|
||||
return ret;
|
||||
else
|
||||
return w.getReturnValue();
|
||||
|
||||
}
|
|
@ -173,18 +173,26 @@ void CCrashReportWidget::onCBClicked()
|
|||
|
||||
void CCrashReportWidget::onAlwaysIgnoreClicked()
|
||||
{
|
||||
m_returnValue = ERET_ALWAYS_IGNORE;
|
||||
close();
|
||||
}
|
||||
|
||||
void CCrashReportWidget::onIgnoreClicked()
|
||||
{
|
||||
m_returnValue = ERET_IGNORE;
|
||||
close();
|
||||
}
|
||||
|
||||
void CCrashReportWidget::onAbortClicked()
|
||||
{
|
||||
m_returnValue = ERET_ABORT;
|
||||
close();
|
||||
}
|
||||
|
||||
void CCrashReportWidget::onBreakClicked()
|
||||
{
|
||||
m_returnValue = ERET_BREAK;
|
||||
close();
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -31,12 +31,24 @@ class CCrashReportWidget : public QWidget
|
|||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
|
||||
enum EReturnValue
|
||||
{
|
||||
ERET_NULL = 0,
|
||||
ERET_ALWAYS_IGNORE = 21,
|
||||
ERET_IGNORE = 22,
|
||||
ERET_ABORT = 23,
|
||||
ERET_BREAK = 24
|
||||
};
|
||||
|
||||
CCrashReportWidget( QWidget *parent = NULL );
|
||||
~CCrashReportWidget();
|
||||
|
||||
void setFileName( const char *fn ){ m_fileName = fn; }
|
||||
|
||||
void setup( const std::vector< std::pair< std::string, std::string > > ¶ms );
|
||||
|
||||
EReturnValue getReturnValue() const{ return m_returnValue; }
|
||||
|
||||
private Q_SLOTS:
|
||||
void onLoad();
|
||||
|
@ -62,6 +74,7 @@ private:
|
|||
bool m_developerMode;
|
||||
bool m_forceSend;
|
||||
|
||||
EReturnValue m_returnValue;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
@ -538,6 +538,8 @@ void checkDriverVersion()
|
|||
|
||||
void checkDriverDepth ()
|
||||
{
|
||||
nlassert( false );
|
||||
|
||||
// Check desktop is in 32 bit else no window mode allowed.
|
||||
if (ClientCfg.Windowed)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue