summaryrefslogtreecommitdiffstats
path: root/kodo/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
commitae2a03c2941bf92573f89b88ef73f8aa842bea0a (patch)
tree3566563f3fb6ac3cb3496669d8f233062d3091bc /kodo/main.cpp
downloadtdetoys-ae2a03c2941bf92573f89b88ef73f8aa842bea0a.tar.gz
tdetoys-ae2a03c2941bf92573f89b88ef73f8aa842bea0a.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/kdetoys@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kodo/main.cpp')
-rw-r--r--kodo/main.cpp100
1 files changed, 100 insertions, 0 deletions
diff --git a/kodo/main.cpp b/kodo/main.cpp
new file mode 100644
index 0000000..72f8802
--- /dev/null
+++ b/kodo/main.cpp
@@ -0,0 +1,100 @@
+/*
+ * Mouspedometa
+ * Based on the original Xodometer VMS/Motif sources.
+ *
+ * Written by Armen Nakashian
+ * Compaq Computer Corporation
+ * Houston TX
+ * 22 May 1998
+ *
+ * If you make improvements or enhancements to Mouspedometa, please send
+ * them back to the author at any of the following addresses:
+ *
+ * armen@nakashian.com
+ *
+ * Thanks to Mark Granoff for writing the original Xodometer, and
+ * the whole KDE team for making such a nice environment to write
+ * programs in.
+ *
+ *
+ * This software is provided as is with no warranty of any kind,
+ * expressed or implied. Neither Digital Equipment Corporation nor
+ * Armen Nakashian will be held accountable for your use of this
+ * software.
+ */
+
+/*
+** Xodometer
+** Written by Mark H. Granoff/mhg
+** Digital Equipment Corporation
+** Littleton, MA, USA
+** 17 March 1993
+**
+** If you make improvements or enhancements to Xodometer, please send them
+** back to the author at any of the following addresses:
+**
+** granoff@keptin.lkg.dec.com
+** granoff@UltraNet.com
+** 72301.1177@CompuServe.com
+**
+** Thanks to my friend and colleague Bob Harris for his suggestions and help.
+**
+** This software is provided as is with no warranty of any kind, expressed or
+** implied. Neither Digital Equipment Corporation nor Mark Granoff will be
+** held accountable for your use of this software.
+**
+** This software is released into the public domain and may be redistributed
+** freely provided that all source module headers remain intact in their
+** entirety, and that all components of this kit are redistributed together.
+**
+** Modification History
+** --------------------
+** See ChangeLog
+*/
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "kodometer.h"
+#include <stdlib.h>
+
+int main(int argc, char *argv[])
+{
+ /* Top level details */
+
+ KAboutData *aboutData = new KAboutData("kodo",
+ I18N_NOOP("KOdometer"), "3.2",
+ I18N_NOOP("KOdometer measures your desktop mileage"),
+ KAboutData::License_GPL,
+ "(c) 1998, Armen Nakashian",
+ I18N_NOOP("A mouse odometer"), 0,
+ "dev@gioelebarabucci.com");
+ aboutData->addAuthor("Armen Nakashian", 0,
+ "armen@tourismo.com",
+ "http://yawara.anime.net/kodo/");
+ aboutData->addCredit("Gioele Barabucci",
+ I18N_NOOP("KDE 2 porting and some code cleanups"),
+ "dev@gioelebarabucci.com", "http://www.gioelebarabucci.com");
+ KCmdLineArgs::init( argc, argv, aboutData );
+
+ if (!KUniqueApplication::start())
+ exit(0);
+
+ KUniqueApplication a;
+
+ Kodometer *o = new Kodometer();
+
+ // Get rid of the title bar.
+ KWin::setType(o->winId(), NET::Override );
+ KWin::setState(o->winId(), NET::Sticky);
+ // FIXME is this a hack?
+// o->setGeometry(0, 0, 0, 0);
+ a.setMainWidget(o);
+ // is the following this needed?
+ // a.setTopWidget(o);
+
+ o->show();
+
+ return a.exec();
+}