server sleep

This commit is contained in:
Volker Fischer 2006-02-18 12:19:27 +00:00
parent 3615d9e0b7
commit a79354dc99
4 changed files with 16 additions and 5 deletions

View file

@ -115,6 +115,7 @@ int main ( int argc, char** argv )
else else
{ {
// only start application without using the GUI // only start application without using the GUI
qDebug ( CAboutDlg::GetVersionAndNameStr () );
app.exec (); app.exec ();
} }
} }

View file

@ -56,6 +56,8 @@ void CServer::Stop ()
{ {
/* stop main timer */ /* stop main timer */
Timer.stop (); Timer.stop ();
qDebug("Server stopped");
} }
void CServer::OnTimer () void CServer::OnTimer ()
@ -103,8 +105,6 @@ void CServer::OnTimer ()
// Disable server if no clients are connected. In this case the server // Disable server if no clients are connected. In this case the server
// does not consume any significant CPU when no client is connected. // does not consume any significant CPU when no client is connected.
Stop (); Stop ();
qDebug("Server stopped");
} }
} }

View file

@ -254,14 +254,22 @@ CAboutDlg::CAboutDlg(QWidget* parent, const char* name, bool modal, WFlags f)
"</center><br>"); "</center><br>");
/* Set version number in about dialog */ /* Set version number in about dialog */
TextLabelVersion->setText(GetVersionAndNameStr());
}
QString CAboutDlg::GetVersionAndNameStr()
{
QString strVersionText; QString strVersionText;
// name, short description and GPL hint
strVersionText = "<center><b>" + tr("llcon, Version "); strVersionText = "<center><b>" + tr("llcon, Version ");
strVersionText += VERSION; strVersionText += VERSION;
strVersionText += "</b><br> " + strVersionText += "</b><br> " +
tr("llcon, Low-Latency (Internet) Connection") + "<br>"; tr("llcon, Low-Latency (Internet) Connection") + "<br>";
strVersionText += tr("Under the GNU General Public License (GPL)") + strVersionText += tr("Under the GNU General Public License (GPL)") +
"</center>"; "</center>";
TextLabelVersion->setText(strVersionText);
return strVersionText;
} }

View file

@ -303,6 +303,8 @@ class CAboutDlg : public CAboutDlgBase
public: public:
CAboutDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, CAboutDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE,
WFlags f = 0); WFlags f = 0);
static QString GetVersionAndNameStr();
}; };