summaryrefslogtreecommitdiffstats
path: root/atlantik/client/main.cpp
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commitc90c389a8a8d9d8661e9772ec4144c5cf2039f23 (patch)
tree6d8391395bce9eaea4ad78958617edb20c6a7573 /atlantik/client/main.cpp
downloadtdegames-c90c389a8a8d9d8661e9772ec4144c5cf2039f23.tar.gz
tdegames-c90c389a8a8d9d8661e9772ec4144c5cf2039f23.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegames@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'atlantik/client/main.cpp')
-rw-r--r--atlantik/client/main.cpp78
1 files changed, 78 insertions, 0 deletions
diff --git a/atlantik/client/main.cpp b/atlantik/client/main.cpp
new file mode 100644
index 00000000..5f0e2fc6
--- /dev/null
+++ b/atlantik/client/main.cpp
@@ -0,0 +1,78 @@
+// Copyright (c) 2002-2003 Rob Kaper <cap@capsi.com>
+//
+// This program is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public License
+// version 2 as published by the Free Software Foundation.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program; see the file COPYING. If not, write to
+// the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+// Boston, MA 02110-1301, USA.
+
+#include <kaboutdata.h>
+#include <kcmdlineargs.h>
+#include <klocale.h>
+#include <kapplication.h>
+#include <kglobal.h>
+
+#include "main.h"
+#include "atlantik.h"
+
+static KCmdLineOptions options[] =
+{
+ { "h", 0, 0 },
+ { "host <argument>", I18N_NOOP("Connect to this host"), 0 },
+ { "p", 0, 0 },
+ { "port <argument>", I18N_NOOP("Connect at this port"), "1234" },
+ { "g", 0, 0 },
+ { "game <argument>", I18N_NOOP("Join this game"), 0 },
+ KCmdLineLastOption
+};
+
+int main(int argc, char *argv[])
+{
+ KAboutData aboutData(
+ "atlantik",
+ I18N_NOOP("Atlantik"), ATLANTIK_VERSION_STRING,
+ I18N_NOOP("The Atlantic board game"),
+ KAboutData::License_GPL,
+ I18N_NOOP("(c) 1998-2004 Rob Kaper"),
+ I18N_NOOP("KDE client for playing Monopoly-like games on the monopd network."),
+ "http://unixcode.org/atlantik/"
+ );
+
+ aboutData.addAuthor("Rob Kaper", I18N_NOOP("main author"), "cap@capsi.com", "http://capsi.com/");
+
+ // Patches and artists
+ aboutData.addCredit("Thiago Macieira", I18N_NOOP("KExtendedSocket support"), "thiagom@wanadoo.fr");
+ aboutData.addCredit("Albert Astals Cid", I18N_NOOP("various patches"), "tsdgeos@terra.es");
+
+ aboutData.addCredit("Bart Szyszka", I18N_NOOP("application icon"), "bart@gigabee.com", "http://www.gigabee.com/");
+ aboutData.addCredit("Rob Malda", I18N_NOOP("token icons"), "", "http://cmdrtaco.net/");
+ aboutData.addCredit("Elhay Achiam", I18N_NOOP("icons"), "elhay_a@bezeqint.net");
+ aboutData.addCredit("Carlo Caneva", I18N_NOOP("icons"), "webmaster@molecola.com", "http://www.molecola.com/");
+
+ KCmdLineArgs::init(argc, argv, &aboutData);
+ KCmdLineArgs::addCmdLineOptions (options);
+
+ KApplication::addCmdLineOptions();
+ KApplication kapplication;
+ KGlobal::locale()->insertCatalogue("libkdegames");
+
+ if (kapplication.isRestored())
+ RESTORE(Atlantik)
+ else
+ {
+ Atlantik *atlantik = new Atlantik;
+ atlantik->setMinimumSize(640, 480);
+ atlantik->setCaption(i18n("The Atlantic Board Game"));
+ atlantik->show();
+ }
+
+ return kapplication.exec();
+}