summaryrefslogtreecommitdiffstats
path: root/libksirtet
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:12:46 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:12:46 -0600
commit58a97ed3af5e4df6c4a58d043b0c267bd97056a9 (patch)
tree5a2fde6842fd422cae2d8670d382be965098cc32 /libksirtet
parent2ce15ee76fd2d9d18a63c035a0f5b00b94c60cdc (diff)
downloadtdegames-58a97ed3af5e4df6c4a58d043b0c267bd97056a9.tar.gz
tdegames-58a97ed3af5e4df6c4a58d043b0c267bd97056a9.zip
Rename a number of classes to enhance compatibility with KDE4
Diffstat (limited to 'libksirtet')
-rw-r--r--libksirtet/base/kzoommainwindow.cpp6
-rw-r--r--libksirtet/base/kzoommainwindow.h8
-rw-r--r--libksirtet/base/main.h4
-rw-r--r--libksirtet/common/main.cpp10
-rw-r--r--libksirtet/lib/keys.cpp8
-rw-r--r--libksirtet/lib/keys.h4
-rw-r--r--libksirtet/lib/mp_interface.h2
-rw-r--r--libksirtet/lib/mp_simple_interface.cpp2
8 files changed, 22 insertions, 22 deletions
diff --git a/libksirtet/base/kzoommainwindow.cpp b/libksirtet/base/kzoommainwindow.cpp
index 95b5b359..3bab5661 100644
--- a/libksirtet/base/kzoommainwindow.cpp
+++ b/libksirtet/base/kzoommainwindow.cpp
@@ -26,7 +26,7 @@
#include <kcmenumngr.h>
KZoomMainWindow::KZoomMainWindow(uint min, uint max, uint step, const char *name)
- : KMainWindow(0, name), _zoomStep(step), _minZoom(min), _maxZoom(max)
+ : TDEMainWindow(0, name), _zoomStep(step), _minZoom(min), _maxZoom(max)
{
installEventFilter(this);
@@ -77,7 +77,7 @@ bool KZoomMainWindow::eventFilter(TQObject *o, TQEvent *e)
setFixedSize(minimumSize()); // because K/TQMainWindow
// does not manage fixed central widget
// with hidden menubar...
- return KMainWindow::eventFilter(o, e);
+ return TDEMainWindow::eventFilter(o, e);
}
void KZoomMainWindow::setZoom(uint zoom)
@@ -111,5 +111,5 @@ void KZoomMainWindow::toggleMenubar()
bool KZoomMainWindow::queryExit()
{
writeMenubarVisibleSetting(_menu->isChecked());
- return KMainWindow::queryExit();
+ return TDEMainWindow::queryExit();
}
diff --git a/libksirtet/base/kzoommainwindow.h b/libksirtet/base/kzoommainwindow.h
index b0d6aba4..3e47cb0d 100644
--- a/libksirtet/base/kzoommainwindow.h
+++ b/libksirtet/base/kzoommainwindow.h
@@ -24,7 +24,7 @@
#include <kdemacros.h>
-class KToggleAction;
+class TDEToggleAction;
/**
* KZoomMainWindow is a main window of fixed size. Its size can be
@@ -41,7 +41,7 @@ class KToggleAction;
* This class also has a "show/hide menubar" action and allows the use
* of a context popup menu (useful to restore the menubar when hidden).
*/
-class KDE_EXPORT KZoomMainWindow : public KMainWindow
+class KDE_EXPORT KZoomMainWindow : public TDEMainWindow
{
Q_OBJECT
@@ -119,8 +119,8 @@ private slots:
private:
uint _zoom, _zoomStep, _minZoom, _maxZoom;
TQPtrList<TQWidget> _widgets;
- KAction *_zoomInAction, *_zoomOutAction;
- KToggleAction *_menu;
+ TDEAction *_zoomInAction, *_zoomOutAction;
+ TDEToggleAction *_menu;
class KZoomMainWindowPrivate;
KZoomMainWindowPrivate *d;
diff --git a/libksirtet/base/main.h b/libksirtet/base/main.h
index 33b5f9d9..2c48439b 100644
--- a/libksirtet/base/main.h
+++ b/libksirtet/base/main.h
@@ -6,7 +6,7 @@
#include <kdemacros.h>
class BaseInterface;
-class KToggleAction;
+class TDEToggleAction;
class KKeyDialog;
class TDEConfigDialog;
@@ -44,7 +44,7 @@ protected:
virtual bool menubarVisibleSetting() const;
private:
- KToggleAction *_pause;
+ TDEToggleAction *_pause;
};
#endif
diff --git a/libksirtet/common/main.cpp b/libksirtet/common/main.cpp
index 7342255b..0b3aa414 100644
--- a/libksirtet/common/main.cpp
+++ b/libksirtet/common/main.cpp
@@ -25,17 +25,17 @@ void MainWindow::init()
// Modes
bool ama = ( bfactory->bbi.nbArcadeStages!=0 );
TQString s = (ama ? i18n("&Single Human (Normal)") : i18n("&Single Human"));
- (void)new KAction(s, 0, TQT_TQOBJECT(inter), TQT_SLOT(normalGame()),
+ (void)new TDEAction(s, 0, TQT_TQOBJECT(inter), TQT_SLOT(normalGame()),
actionCollection(), "mp_single_human");
- if (ama) (void)new KAction(i18n("&Single Human (Arcade)"), 0,
+ if (ama) (void)new TDEAction(i18n("&Single Human (Arcade)"), 0,
TQT_TQOBJECT(inter), TQT_SLOT(arcadeGame()),
actionCollection(), "mp_arcade");
- (void)new KAction(i18n("Human vs &Human"), 0, TQT_TQOBJECT(inter), TQT_SLOT(humanVsHuman()),
+ (void)new TDEAction(i18n("Human vs &Human"), 0, TQT_TQOBJECT(inter), TQT_SLOT(humanVsHuman()),
actionCollection(), "mp_human_vs_human");
- (void)new KAction(i18n("Human vs &Computer"), 0,
+ (void)new TDEAction(i18n("Human vs &Computer"), 0,
TQT_TQOBJECT(inter), TQT_SLOT(humanVsComputer()),
actionCollection(), "mp_human_vs_computer");
- (void)new KAction(i18n("&More..."), 0, TQT_TQOBJECT(inter), TQT_SLOT(dialog()),
+ (void)new TDEAction(i18n("&More..."), 0, TQT_TQOBJECT(inter), TQT_SLOT(dialog()),
actionCollection(), "mp_more");
buildGUI(inter);
diff --git a/libksirtet/lib/keys.cpp b/libksirtet/lib/keys.cpp
index acf4d7ac..801d46d0 100644
--- a/libksirtet/lib/keys.cpp
+++ b/libksirtet/lib/keys.cpp
@@ -43,12 +43,12 @@ void KeyData::clear()
void KeyData::createActionCollection(uint index, TQWidget *receiver)
{
Q_ASSERT( index<_cols.size() );
- _cols[index] = new KActionCollection(receiver, this);
+ _cols[index] = new TDEActionCollection(receiver, this);
for (uint k=0; k<_data.size(); k++) {
TQString label = i18n(_data[k].label);
TQString name = TQString("%2 %3").arg(index+1).arg(_data[k].name);
const char *slot = (_data[k].slotRelease ? 0 : _data[k].slot);
- KAction *a = new KAction(label, _keycodes[_cols.size()-1][index][k],
+ TDEAction *a = new TDEAction(label, _keycodes[_cols.size()-1][index][k],
TQT_TQOBJECT(receiver), slot, _cols[index], name.utf8());
a->setEnabled(false);
if ( slot==0 ) {
@@ -67,7 +67,7 @@ void KeyData::createActionCollection(uint index, TQWidget *receiver)
void KeyData::setEnabled(uint index, bool enabled)
{
for (uint k=0; k<_cols[index]->count(); k++) {
- TQMap<KAction *, SpecialData>::Iterator it =
+ TQMap<TDEAction *, SpecialData>::Iterator it =
_specActions.find(_cols[index]->action(k));
if ( it==_specActions.end() )
_cols[index]->action(k)->setEnabled(enabled);
@@ -93,7 +93,7 @@ void KeyData::keyEvent(TQKeyEvent *e, bool pressed)
if ( e->isAutoRepeat() ) return;
KKey key(e);
- TQMap<KAction *, SpecialData>::Iterator it = _specActions.begin();
+ TQMap<TDEAction *, SpecialData>::Iterator it = _specActions.begin();
for(; it!=_specActions.end(); ++it) {
if ( !it.data().enabled ) continue;
if ( !it.key()->shortcut().contains(key) ) continue;
diff --git a/libksirtet/lib/keys.h b/libksirtet/lib/keys.h
index ff2a1c5e..83b63e49 100644
--- a/libksirtet/lib/keys.h
+++ b/libksirtet/lib/keys.h
@@ -29,12 +29,12 @@ class KeyData : public TQObject
uint _maxNb;
TQMemArray<ActionData> _data;
TQMap<int, TQMap<int, TQMemArray<int> > > _keycodes;
- TQMemArray<KActionCollection *> _cols;
+ TQMemArray<TDEActionCollection *> _cols;
struct SpecialData {
bool enabled;
TQSignal *pressed, *released;
};
- TQMap<KAction *, SpecialData> _specActions;
+ TQMap<TDEAction *, SpecialData> _specActions;
TQString group() const
{ return TQString("Keys (%1 humans)").arg(_cols.size()); }
diff --git a/libksirtet/lib/mp_interface.h b/libksirtet/lib/mp_interface.h
index 7f61d13d..3ae8a0bc 100644
--- a/libksirtet/lib/mp_interface.h
+++ b/libksirtet/lib/mp_interface.h
@@ -15,7 +15,7 @@ class RemoteHostData;
class KeyData;
class KeyCollection;
class KKeyDialog;
-class KAction;
+class TDEAction;
struct ActionData {
const char *label, *name;
diff --git a/libksirtet/lib/mp_simple_interface.cpp b/libksirtet/lib/mp_simple_interface.cpp
index 1b83be40..bf81d750 100644
--- a/libksirtet/lib/mp_simple_interface.cpp
+++ b/libksirtet/lib/mp_simple_interface.cpp
@@ -9,7 +9,7 @@
#define PAUSE_ACTION \
- ((KToggleAction *)((KMainWindow *)topLevelWidget())->action("game_pause"))
+ ((TDEToggleAction *)((TDEMainWindow *)topLevelWidget())->action("game_pause"))
MPSimpleInterface::MPSimpleInterface(const MPGameInfo &gi,
uint nbActions, const ActionData *data,