QTfrontend/HWApplication.cpp
changeset 8803 b3f37e7f9ff4
parent 8799 44e520374cfc
child 9163 67334acaaac7
equal deleted inserted replaced
8801:c38ce9cf4c3a 8803:b3f37e7f9ff4
    33     Q_UNUSED(signal);
    33     Q_UNUSED(signal);
    34     QCoreApplication::exit(0);
    34     QCoreApplication::exit(0);
    35 }
    35 }
    36 #endif
    36 #endif
    37 
    37 
    38 HWApplication::HWApplication(int &argc,  char **argv):
    38 HWApplication::HWApplication(int &argc, char **argv) :
    39     QApplication(argc, argv)
    39     QApplication(argc, argv)
    40 {
    40 {
    41 #if !defined(Q_WS_WIN)
    41 #if !defined(Q_WS_WIN)
    42     signal(SIGINT, &terminateFrontend);
    42     signal(SIGINT, &terminateFrontend);
    43 #endif
    43 #endif
    83             form->PlayDemoQuick(path);
    83             form->PlayDemoQuick(path);
    84             return true;
    84             return true;
    85         } else if (scheme == "hwplay") {
    85         } else if (scheme == "hwplay") {
    86             int port = openEvent->url().port(NETGAME_DEFAULT_PORT);
    86             int port = openEvent->url().port(NETGAME_DEFAULT_PORT);
    87             if (address == "")
    87             if (address == "")
    88                 address = "netserver.hedgewars.org";
    88                 address = NETGAME_DEFAULT_SERVER;
    89             form->NetConnectQuick(address, (quint16) port);
    89             form->NetConnectQuick(address, (quint16) port);
    90             return true;
    90             return true;
    91         } else {
    91         } else {
    92             const QString errmsg = tr("Scheme '%1' not supported").arg(scheme);
    92             const QString errmsg = tr("Scheme '%1' not supported").arg(scheme);
    93             MessageDialog::ShowErrorMessage(errmsg, form);
    93             MessageDialog::ShowErrorMessage(errmsg, form);