summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <[email protected]>2014-12-08 13:21:08 +0100
committerMontel Laurent <[email protected]>2014-12-08 13:21:08 +0100
commit1ab1352aa91e95d044de0885df9e54331365294c (patch)
tree41d60f31cb6e003fb8553e64443e179e1ce9ec74
parent6ae56673ab707aa83ecfbbdda0d1ccd8d927f87c (diff)
kdelibs4support--
-rw-r--r--src/kiriki.cpp2
-rw-r--r--src/kiriki.kcfg2
-rw-r--r--src/lateralwidget.cpp6
-rw-r--r--src/main.cpp27
-rw-r--r--src/scores.cpp2
5 files changed, 24 insertions, 15 deletions
diff --git a/src/kiriki.cpp b/src/kiriki.cpp
index 53ac9ed..c9a687b 100644
--- a/src/kiriki.cpp
+++ b/src/kiriki.cpp
@@ -32,7 +32,7 @@
#include <kstandardgameaction.h>
#include <kactioncollection.h>
#include <QAction>
-#include <KStatusBar>
+#include <QStatusBar>
#include <KToggleAction>
#include <KToolBar>
#include <kdeprintdialog.h>
diff --git a/src/kiriki.kcfg b/src/kiriki.kcfg
index d9ee449..b47f6d5 100644
--- a/src/kiriki.kcfg
+++ b/src/kiriki.kcfg
@@ -4,7 +4,7 @@
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
<kcfgfile name="kirikirc" />
- <include>klocale.h</include>
+ <include>KLocalizedString</include>
<include>QFont</include>
<group name="general">
<entry key="waitTime" type="Int" >
diff --git a/src/lateralwidget.cpp b/src/lateralwidget.cpp
index 41f8991..2fcaf49 100644
--- a/src/lateralwidget.cpp
+++ b/src/lateralwidget.cpp
@@ -15,9 +15,9 @@
#include <QVBoxLayout>
#include <QAction>
-#include <kicon.h>
+#include <QIcon>
#include <kstandardgameaction.h>
-#include <klocale.h>
+#include <KLocalizedString>
#include "diceswidget.h"
@@ -27,7 +27,7 @@ lateralWidget::lateralWidget(QWidget *parent) : QWidget(parent), m_demoMode(fals
m_rolls = new QLabel(this);
m_dices = new dicesWidget(this);
m_buttons = new QStackedWidget(this);
- m_rollButton = new QPushButton(KIcon( QLatin1String( "roll") ), i18n("&Roll" ), this);
+ m_rollButton = new QPushButton(QIcon::fromTheme( QLatin1String( "roll") ), i18n("&Roll" ), this);
QAction *dummyAction = KStandardGameAction::gameNew(0, 0, 0);
m_newGameButton = new QPushButton(dummyAction->icon(), dummyAction->text(), this);
diff --git a/src/main.cpp b/src/main.cpp
index 9a533b5..11b5902 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -7,19 +7,28 @@
* (at your option) any later version. *
***************************************************************************/
-#include <K4AboutData>
-#include <kapplication.h>
-#include <kcmdlineargs.h>
-#include <klocale.h>
+#include <KAboutData>
+
+
+#include <KLocalizedString>
+#include <QApplication>
+#include <QCommandLineParser>
#include "kiriki.h"
int main(int argc, char *argv[])
{
- K4AboutData about("kiriki", 0, ki18n("Kiriki"), "0.2.1", ki18n("A Yahtzee dice game for KDE"), K4AboutData::License_GPL, ki18n("© 2005-2007 Albert Astals Cid"), KLocalizedString(), "http://games.kde.org/kiriki" );
- about.addAuthor(ki18n("Albert Astals Cid"), KLocalizedString(), "[email protected]");
- KCmdLineArgs::init(argc, argv, &about);
- KApplication app;
- app.setTopWidget(new kiriki());
+ KAboutData about("kiriki", i18n("Kiriki"), "0.2.1", i18n("A Yahtzee dice game for KDE"), KAboutLicense::GPL, i18n("© 2005-2007 Albert Astals Cid"), "http://games.kde.org/kiriki" );
+ about.addAuthor(i18n("Albert Astals Cid"), QString(), "[email protected]");
+ QApplication app(argc, argv);
+ QCommandLineParser parser;
+ KAboutData::setApplicationData(about);
+ parser.addVersionOption();
+ parser.addHelpOption();
+ about.setupCommandLine(&parser);
+ parser.process(app);
+ about.processCommandLine(&parser);
+ kiriki *w = new kiriki();
+ w->show();
return app.exec();
}
diff --git a/src/scores.cpp b/src/scores.cpp
index d45089a..e6e90c2 100644
--- a/src/scores.cpp
+++ b/src/scores.cpp
@@ -14,7 +14,7 @@
#include <QPalette>
#include <kiconloader.h>
-#include <klocale.h>
+#include <KLocalizedString>
#include "settings.h"