Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 29c1d7a1 authored by Laurent Montel's avatar Laurent Montel 😁

Make it compile

parent b23cf437
......@@ -111,7 +111,7 @@ ki18n_wrap_ui(ksirk_SRCS ${ksirk_UI} )
kconfig_add_kcfg_files( ksirk_SRCS ksirksettings.kcfgc )
kde4_add_app_icon(ksirk_SRCS "hi*-app-ksirk.png")
#kde4_add_app_icon(ksirk_SRCS "hi*-app-ksirk.png")
add_executable(ksirk ${ksirk_SRCS})
......@@ -133,10 +133,10 @@ install( TARGETS ksirk ${INSTALL_TARGETS_DEFAULT_ARGS})
########### install files ###############
ecm_install_icons( ${ICON_INSTALL_DIR} )
ecm_install_icons( ICONS hi128-apps-ksirk.png hi16-apps-ksirk.png hi22-apps-ksirk.png hi32-apps-ksirk.png hi48-apps-ksirk.png hi64-apps-ksirk.png lo16-apps-ksirk.png lo32-apps-ksirk.png DESTINATION ${ICON_INSTALL_DIR} )
install( FILES ksirksettings.kcfg DESTINATION ${KCFG_INSTALL_DIR} )
install( PROGRAMS ksirk.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} )
install( PROGRAMS org.kde.ksirk.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} )
install( FILES ksirkui.rc DESTINATION ${KXMLGUI_INSTALL_DIR}/ksirk )
install( FILES jabber.png DESTINATION ${DATA_INSTALL_DIR}/ksirk )
install( FILES ksirk.knsrc DESTINATION ${CONFIG_INSTALL_DIR} )
......@@ -470,12 +470,12 @@ void KGameWindow::initActions()
void KGameWindow::initStatusBar()
{
statusBar()-> setSizeGripEnabled(true);
statusBar()->insertPermanentItem("", ID_STATUS_MSG, 2);
statusBar()-> setItemAlignment(ID_STATUS_MSG, Qt::AlignLeft | Qt::AlignVCenter);
//QT5 statusBar()->insertPermanentItem("", ID_STATUS_MSG, 2);
//QT5 statusBar()-> setItemAlignment(ID_STATUS_MSG, Qt::AlignLeft | Qt::AlignVCenter);
statusBar()->insertPermanentItem("", ID_STATUS_MSG2, 3);
statusBar()-> setItemAlignment(ID_STATUS_MSG2, Qt::AlignLeft | Qt::AlignVCenter);
statusBar()->addPermanentWidget(m_barFlag);
//QT5 statusBar()->insertPermanentItem("", ID_STATUS_MSG2, 3);
//QT5 statusBar()-> setItemAlignment(ID_STATUS_MSG2, Qt::AlignLeft | Qt::AlignVCenter);
//QT5 statusBar()->addPermanentWidget(m_barFlag);
}
Country* KGameWindow::clickIn(const QPointF &pointf)
......@@ -1500,7 +1500,7 @@ void KGameWindow::changeItem( const QString& text, int id, bool log )
{
if (id != ID_NO_STATUS_MSG)
{
statusBar()-> changeItem(text, id);
//QT5 statusBar()-> changeItem(text, id);
}
if (log)
{
......@@ -1614,7 +1614,7 @@ void KGameWindow::changeItem( KMessageParts& strings, int id, bool log )
kError() << "received a (I18N_EMPTY_MESSAGE)";
}
// kDebug() << " argument: " << argument.toString();
statusBar()-> changeItem(argument.toString(), id);
//QT5 statusBar()-> changeItem(argument.toString(), id);
}
}
......
......@@ -111,7 +111,7 @@ void KGameWindow::mouseMoveEvent ( QMouseEvent * event )
status1Text = i18np("%2 belongs to %3. 1 army.","%2 belongs to %3. %1 armies.",mouseLocalisation->nbArmies(),i18n(countryName.toUtf8().data()),player->name());
}
statusBar()-> changeItem(status1Text, ID_STATUS_MSG);
//QT5 statusBar()-> changeItem(status1Text, ID_STATUS_MSG);
}
}
else
......@@ -121,7 +121,7 @@ void KGameWindow::mouseMoveEvent ( QMouseEvent * event )
m_mouseLocalisation->clearHighlighting();
m_mouseLocalisation = 0;
}
statusBar()-> changeItem("", ID_STATUS_MSG); // Reset
//QT5 statusBar()-> changeItem("", ID_STATUS_MSG); // Reset
}
int borderScrollSize = 50;
if ( (!m_timer.isActive())
......@@ -615,8 +615,10 @@ void KGameWindow::slotShowAboutApplication()
/* KAboutApplication kAA;
kAA.exec();*/
#if 0 //QT5
KAboutApplicationDialog dialog(KGlobal::mainComponent().aboutData(), this);
dialog.exec();
#endif
}
void KGameWindow::slotJoinNetworkGame()
......@@ -1003,10 +1005,12 @@ void KGameWindow::slotClientError ( JabberClient::ErrorCode errorCode )
{
case JabberClient::NoTLS:
default:
#if 0 //QT5
KMessageBox::queuedMessageBox ( 0, KMessageBox::Error,
i18n ("An encrypted connection with the Jabber server could not be established."),
i18n ("Jabber Connection Error"));
// disconnect ( 0/*Kopete::Account::Manual*/ );
#endif
break;
}
}
......@@ -1111,18 +1115,18 @@ void KGameWindow::slotGroupChatError (const XMPP::Jid &jid, int error, const QSt
break;
case JabberClient::BannedFromThisMUC:
KMessageBox::queuedMessageBox ( 0, KMessageBox::Error, i18n ("You cannot join the room %1 because you have been banned", jid.node()), i18n ("Jabber Group Chat") );
//QT5 KMessageBox::queuedMessageBox ( 0, KMessageBox::Error, i18n ("You cannot join the room %1 because you have been banned", jid.node()), i18n ("Jabber Group Chat") );
break;
case JabberClient::MaxUsersReachedForThisMuc:
KMessageBox::queuedMessageBox ( 0, KMessageBox::Error, i18n ("You cannot join the room %1 because the maximum number of users has been reached", jid.node()), i18n ("Jabber Group Chat") );
//QT5 KMessageBox::queuedMessageBox ( 0, KMessageBox::Error, i18n ("You cannot join the room %1 because the maximum number of users has been reached", jid.node()), i18n ("Jabber Group Chat") );
break;
default:
{
QString detailedReason = reason.isEmpty () ? i18n ( "No reason given by the server" ) : reason;
KMessageBox::queuedMessageBox ( 0, KMessageBox::Error, i18n ("There was an error processing your request for groupchat %1. (Reason: %2, Code %3)", jid.full (), detailedReason, error ), i18n ("Jabber Group Chat") );
//QT5 KMessageBox::queuedMessageBox ( 0, KMessageBox::Error, i18n ("There was an error processing your request for groupchat %1. (Reason: %2, Code %3)", jid.full (), detailedReason, error ), i18n ("Jabber Group Chat") );
}
}
}
......
......@@ -21,6 +21,7 @@
#include "ksirksettings.h"
#include "ui_preferences.h"
#include <QPushButton>
#include <kfiledialog.h>
#include <kconfig.h>
#include <kurl.h>
......@@ -46,15 +47,15 @@ using namespace Ksirk;
KsirkConfigurationDialog::KsirkConfigurationDialog (
QWidget *parent, const char *name, KConfigSkeleton *config,
FaceType dialogType, ButtonCodes dialogButtons,
ButtonCode defaultButton, bool modal) :
FaceType dialogType, QDialogButtonBox::StandardButtons dialogButtons,
QDialogButtonBox::StandardButton defaultButton, bool modal) :
KConfigDialog (parent, name, config) , m_changed(false),
m_widget(new Ui::KsirkPreferencesWidget())
{
setFaceType(dialogType);
setButtons(dialogButtons);
setDefaultButton(defaultButton);
setStandardButtons(dialogButtons);
button(defaultButton)->setDefault(true);
setModal(modal);
QWidget* w = new QWidget();
m_widget->setupUi(w);
......
......@@ -22,6 +22,7 @@
#include <kconfigdialog.h>
#include <KConfigSkeleton>
#include <QDialogButtonBox>
namespace Ui
{
class KsirkPreferencesWidget;
......@@ -43,8 +44,8 @@ public:
KsirkConfigurationDialog (
QWidget *parent, const char *name, KConfigSkeleton *config,
FaceType faceType=List,
ButtonCodes dialogButtons=Default|Ok|Apply|Cancel|Help,
ButtonCode defaultButton=Ok, bool modal=false);
QDialogButtonBox::StandardButtons dialogButtons=QDialogButtonBox::RestoreDefaults|QDialogButtonBox::Ok|QDialogButtonBox::Apply|QDialogButtonBox::Cancel|QDialogButtonBox::Help,
QDialogButtonBox::StandardButton defaultButton=QDialogButtonBox::Ok, bool modal=false);
/** Destructor */
virtual ~KsirkConfigurationDialog ();
......
......@@ -107,3 +107,4 @@ GenericName[zh_TW]=征服世界戰略遊戲
Categories=Qt;KDE;Game;StrategyGame;
X-KDE-StartupNotify=true
X-DBUS-StartupType=Multi
X-DBUS-ServiceName=org.kde.ksirk
......@@ -41,7 +41,7 @@ ki18n_wrap_ui(ksirkskineditor_SRCS ${ksirkskineditor_UI} )
kconfig_add_kcfg_files( ksirkskineditor_SRCS ksirkskineditorsettings.kcfgc )
kde4_add_app_icon(ksirkskineditor_SRCS "hi*-app-ksirk.png")
#kde4_add_app_icon(ksirkskineditor_SRCS "hi*-app-ksirk.png")
add_executable(ksirkskineditor ${ksirkskineditor_SRCS})
......@@ -62,7 +62,7 @@ install( TARGETS ksirkskineditor ${INSTALL_TARGETS_DEFAULT_ARGS})
ecm_install_icons( ${ICON_INSTALL_DIR} )
install( FILES ksirkskineditorsettings.kcfg DESTINATION ${KCFG_INSTALL_DIR} )
install( PROGRAMS ksirkskineditor.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} )
install( PROGRAMS org.kde.ksirkskineditor.desktop DESTINATION ${XDG_APPS_INSTALL_DIR} )
install( FILES ksirkskineditorui.rc DESTINATION ${KXMLGUI_INSTALL_DIR}/ksirkskineditor )
set (pics_default_DATA
......
......@@ -27,7 +27,7 @@
#include <ktabwidget.h>
#include <kedittoolbar.h>
#include <kdebug.h>
#include <QPushButton>
#include <kstandardaction.h>
#include <klibloader.h>
......@@ -46,15 +46,15 @@ using namespace KsirkSkinEditor;
KsirkSkinEditorConfigurationDialog::KsirkSkinEditorConfigurationDialog (
QWidget *parent, const char *name, KConfigSkeleton *config,
FaceType dialogType, ButtonCodes dialogButtons,
ButtonCode defaultButton, bool modal) :
FaceType dialogType, QDialogButtonBox::StandardButtons dialogButtons,
QDialogButtonBox::StandardButton defaultButton, bool modal) :
KConfigDialog (parent, name, config) , m_changed(false),
m_widget(new Ui::KsirkSkinEditorPreferencesWidget())
{
setFaceType(dialogType);
setButtons(dialogButtons);
setDefaultButton(defaultButton);
setStandardButtons(dialogButtons);
button(defaultButton)->setDefault(true);
setModal(modal);
QWidget* w = new QWidget();
m_widget->setupUi(w);
......
......@@ -22,6 +22,7 @@
#include <kconfigdialog.h>
#include <KConfigSkeleton>
#include <QDialogButtonBox>
namespace Ui
{
class KsirkSkinEditorPreferencesWidget;
......@@ -43,8 +44,8 @@ public:
KsirkSkinEditorConfigurationDialog (
QWidget *parent, const char *name, KConfigSkeleton *config,
FaceType faceType=List,
ButtonCodes dialogButtons=Default|Ok|Apply|Cancel|Help,
ButtonCode defaultButton=Ok, bool modal=false);
QDialogButtonBox::StandardButtons dialogButtons=QDialogButtonBox::RestoreDefaults|QDialogButtonBox::Ok|QDialogButtonBox::Apply|QDialogButtonBox::Cancel|QDialogButtonBox::Help,
QDialogButtonBox::StandardButton defaultButton=QDialogButtonBox::Ok, bool modal=false);
/** Destructor */
virtual ~KsirkSkinEditorConfigurationDialog ();
......
......@@ -584,8 +584,10 @@ void MainWindow::optionsConfigure()
void MainWindow::slotShowAboutApplication()
{
#if 0 //QT5
KAboutApplicationDialog dialog(KGlobal::mainComponent().aboutData(), this);
dialog.exec();
#endif
}
void MainWindow::slotFlagButtonClicked()
......
......@@ -102,3 +102,4 @@ GenericName[zh_TW]=征服世界戰略遊戲的外觀編輯器
Categories=Qt;KDE;Game;StrategyGame;
X-KDE-StartupNotify=true
X-DBUS-StartupType=Multi
X-DBUS-ServiceName=org.kde.ksirkskineditor
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment