diff options
Diffstat (limited to 'libtdegames/highscore')
| -rw-r--r-- | libtdegames/highscore/kexthighscore.h | 20 | ||||
| -rw-r--r-- | libtdegames/highscore/kexthighscore_gui.cpp | 38 | ||||
| -rw-r--r-- | libtdegames/highscore/kexthighscore_gui.h | 16 | ||||
| -rw-r--r-- | libtdegames/highscore/kexthighscore_internal.h | 2 | ||||
| -rw-r--r-- | libtdegames/highscore/kexthighscore_item.h | 16 | ||||
| -rw-r--r-- | libtdegames/highscore/kexthighscore_tab.cpp | 8 | ||||
| -rw-r--r-- | libtdegames/highscore/kexthighscore_tab.h | 8 | ||||
| -rw-r--r-- | libtdegames/highscore/khighscore.cpp | 6 | ||||
| -rw-r--r-- | libtdegames/highscore/khighscore.h | 8 | ||||
| -rw-r--r-- | libtdegames/highscore/kscoredialog.cpp | 16 | ||||
| -rw-r--r-- | libtdegames/highscore/kscoredialog.h | 6 | ||||
| -rw-r--r-- | libtdegames/highscore/tdeconfigrawbackend.h | 8 |
12 files changed, 76 insertions, 76 deletions
diff --git a/libtdegames/highscore/kexthighscore.h b/libtdegames/highscore/kexthighscore.h index e4412fe6..a21459db 100644 --- a/libtdegames/highscore/kexthighscore.h +++ b/libtdegames/highscore/kexthighscore.h @@ -23,7 +23,7 @@ #include "kexthighscore_item.h" #include <kurl.h> -#include <kdemacros.h> +#include <tdemacros.h> class TQTabWidget; @@ -40,42 +40,42 @@ extern ManagerPrivate *internal; /** * Get the current game type. */ -KDE_EXPORT uint gameType(); +TDE_EXPORT uint gameType(); /** * Set the current game type. */ -KDE_EXPORT void setGameType(uint gameType); +TDE_EXPORT void setGameType(uint gameType); /** * Configure the highscores. * @return true if the configuration has been modified and saved */ -KDE_EXPORT bool configure(TQWidget *parent); +TDE_EXPORT bool configure(TQWidget *parent); /** * Show the highscores lists. */ -KDE_EXPORT void show(TQWidget *parent); +TDE_EXPORT void show(TQWidget *parent); /** * Submit a score. See @ref Manager for usage example. * * @param widget a widget used as parent for error message box. */ -KDE_EXPORT void submitScore(const Score &score, TQWidget *widget); +TDE_EXPORT void submitScore(const Score &score, TQWidget *widget); /** * @return the last score in the local list of highscores. The worst possible * score if there are less items than the maximum number. */ -KDE_EXPORT Score lastScore(); +TDE_EXPORT Score lastScore(); /** * @return the first score in the local list of highscores (the worst possible * score if there is no entry). */ -KDE_EXPORT Score firstScore(); +TDE_EXPORT Score firstScore(); /** * This class manages highscores and players entries (several players can @@ -136,7 +136,7 @@ KDE_EXPORT Score firstScore(); * and the value of the items that you have optionnally added * with Score::setData() ; player name and date are set automatically. */ -class KDE_EXPORT Manager +class TDE_EXPORT Manager { public: /** @@ -195,7 +195,7 @@ class KDE_EXPORT Manager /** @obsolete */ // KDE4 remove this - void showStatistics(bool show) KDE_DEPRECATED; + void showStatistics(bool show) TDE_DEPRECATED; /** * @since 3.3 diff --git a/libtdegames/highscore/kexthighscore_gui.cpp b/libtdegames/highscore/kexthighscore_gui.cpp index 5b7e08c0..2a598a21 100644 --- a/libtdegames/highscore/kexthighscore_gui.cpp +++ b/libtdegames/highscore/kexthighscore_gui.cpp @@ -130,7 +130,7 @@ HighscoresWidget::HighscoresWidget(TQWidget *parent) TQVBoxLayout *vbox = new TQVBoxLayout(this, KDialogBase::spacingHint()); _tw = new TQTabWidget(this); - connect(_tw, TQT_SIGNAL(currentChanged(TQWidget *)), TQT_SLOT(tabChanged())); + connect(_tw, TQ_SIGNAL(currentChanged(TQWidget *)), TQ_SLOT(tabChanged())); vbox->addWidget(_tw); // scores tab @@ -160,15 +160,15 @@ HighscoresWidget::HighscoresWidget(TQWidget *parent) KURL url = internal->queryURL(ManagerPrivate::Scores); _scoresUrl = new KURLLabel(url.url(), i18n("View world-wide highscores"), this); - connect(_scoresUrl, TQT_SIGNAL(leftClickedURL(const TQString &)), - TQT_SLOT(showURL(const TQString &))); + connect(_scoresUrl, TQ_SIGNAL(leftClickedURL(const TQString &)), + TQ_SLOT(showURL(const TQString &))); vbox->addWidget(_scoresUrl); url = internal->queryURL(ManagerPrivate::Players); _playersUrl = new KURLLabel(url.url(), i18n("View world-wide players"), this); - connect(_playersUrl, TQT_SIGNAL(leftClickedURL(const TQString &)), - TQT_SLOT(showURL(const TQString &))); + connect(_playersUrl, TQ_SIGNAL(leftClickedURL(const TQString &)), + TQ_SLOT(showURL(const TQString &))); vbox->addWidget(_playersUrl); } } @@ -215,8 +215,8 @@ HighscoresDialog::HighscoresDialog(int rank, TQWidget *parent) if ( i==internal->gameType() ) createPage(w); } - connect(this, TQT_SIGNAL(aboutToShowPage(TQWidget *)), - TQT_SLOT(createPage(TQWidget *))); + connect(this, TQ_SIGNAL(aboutToShowPage(TQWidget *)), + TQ_SLOT(createPage(TQWidget *))); showPage(internal->gameType()); } else { TQVBoxLayout *vbox = new TQVBoxLayout(plainPage()); @@ -234,7 +234,7 @@ void HighscoresDialog::createPage(TQWidget *page) int i = (several ? pageIndex(page) : 0); if ( _widgets[i]==0 ) { _widgets[i] = new HighscoresWidget(page); - connect(_widgets[i], TQT_SIGNAL(tabChanged(int)), TQT_SLOT(tabChanged(int))); + connect(_widgets[i], TQ_SIGNAL(tabChanged(int)), TQ_SLOT(tabChanged(int))); } uint type = internal->gameType(); if (several) internal->setGameType(i); @@ -376,10 +376,10 @@ ConfigDialog::ConfigDialog(TQWidget *parent) TQLabel *label = new TQLabel(i18n("Nickname:"), page); pageTop->addWidget(label, 0, 0); _nickname = new TQLineEdit(page); - connect(_nickname, TQT_SIGNAL(textChanged(const TQString &)), - TQT_SLOT(modifiedSlot())); - connect(_nickname, TQT_SIGNAL(textChanged(const TQString &)), - TQT_SLOT(nickNameChanged(const TQString &))); + connect(_nickname, TQ_SIGNAL(textChanged(const TQString &)), + TQ_SLOT(modifiedSlot())); + connect(_nickname, TQ_SIGNAL(textChanged(const TQString &)), + TQ_SLOT(nickNameChanged(const TQString &))); _nickname->setMaxLength(16); pageTop->addWidget(_nickname, 0, 1); @@ -387,16 +387,16 @@ ConfigDialog::ConfigDialog(TQWidget *parent) label = new TQLabel(i18n("Comment:"), page); pageTop->addWidget(label, 1, 0); _comment = new TQLineEdit(page); - connect(_comment, TQT_SIGNAL(textChanged(const TQString &)), - TQT_SLOT(modifiedSlot())); + connect(_comment, TQ_SIGNAL(textChanged(const TQString &)), + TQ_SLOT(modifiedSlot())); _comment->setMaxLength(50); pageTop->addWidget(_comment, 1, 1); if (tab) { _WWHEnabled = new TQCheckBox(i18n("World-wide highscores enabled"), page); - connect(_WWHEnabled, TQT_SIGNAL(toggled(bool)), - TQT_SLOT(modifiedSlot())); + connect(_WWHEnabled, TQ_SIGNAL(toggled(bool)), + TQ_SLOT(modifiedSlot())); pageTop->addMultiCellWidget(_WWHEnabled, 2, 2, 0, 1); // advanced tab @@ -421,7 +421,7 @@ ConfigDialog::ConfigDialog(TQWidget *parent) KGuiItem gi = KStdGuiItem::clear(); gi.setText(i18n("Remove")); _removeButton = new KPushButton(gi, grid); - connect(_removeButton, TQT_SIGNAL(clicked()), TQT_SLOT(removeSlot())); + connect(_removeButton, TQ_SIGNAL(clicked()), TQ_SLOT(removeSlot())); } load(); @@ -444,7 +444,7 @@ void ConfigDialog::accept() { if ( save() ) { KDialogBase::accept(); - kapp->config()->sync(); // safer + tdeApp->config()->sync(); // safer } } @@ -533,7 +533,7 @@ AskNameDialog::AskNameDialog(TQWidget *parent) hbox->addWidget(label); _edit = new TQLineEdit(plainPage()); _edit->setFocus(); - connect(_edit, TQT_SIGNAL(textChanged(const TQString &)), TQT_SLOT(nameChanged())); + connect(_edit, TQ_SIGNAL(textChanged(const TQString &)), TQ_SLOT(nameChanged())); hbox->addWidget(_edit); top->addSpacing(spacingHint()); diff --git a/libtdegames/highscore/kexthighscore_gui.h b/libtdegames/highscore/kexthighscore_gui.h index 0749d682..d0f742f1 100644 --- a/libtdegames/highscore/kexthighscore_gui.h +++ b/libtdegames/highscore/kexthighscore_gui.h @@ -57,7 +57,7 @@ class ShowItem : public TDEListViewItem class ScoresList : public TDEListView { - Q_OBJECT + TQ_OBJECT public: ScoresList(TQWidget *parent); @@ -76,7 +76,7 @@ class ScoresList : public TDEListView //----------------------------------------------------------------------------- class HighscoresList : public ScoresList { - Q_OBJECT + TQ_OBJECT public: HighscoresList(TQWidget *parent); @@ -89,7 +89,7 @@ class HighscoresList : public ScoresList class HighscoresWidget : public TQWidget { - Q_OBJECT + TQ_OBJECT public: HighscoresWidget(TQWidget *parent); @@ -115,7 +115,7 @@ class HighscoresWidget : public TQWidget class HighscoresDialog : public KDialogBase { - Q_OBJECT + TQ_OBJECT public: HighscoresDialog(int rank, TQWidget *parent); @@ -135,7 +135,7 @@ class HighscoresDialog : public KDialogBase //----------------------------------------------------------------------------- class LastMultipleScoresList : public ScoresList { - Q_OBJECT + TQ_OBJECT public: LastMultipleScoresList(const TQValueVector<Score> &, TQWidget *parent); @@ -150,7 +150,7 @@ private: class TotalMultipleScoresList : public ScoresList { - Q_OBJECT + TQ_OBJECT public: TotalMultipleScoresList(const TQValueVector<Score> &, TQWidget *parent); @@ -166,7 +166,7 @@ private: //----------------------------------------------------------------------------- class ConfigDialog : public KDialogBase { - Q_OBJECT + TQ_OBJECT public: ConfigDialog(TQWidget *parent); @@ -194,7 +194,7 @@ class ConfigDialog : public KDialogBase //----------------------------------------------------------------------------- class AskNameDialog : public KDialogBase { - Q_OBJECT + TQ_OBJECT public: AskNameDialog(TQWidget *parent); diff --git a/libtdegames/highscore/kexthighscore_internal.h b/libtdegames/highscore/kexthighscore_internal.h index c1d166bb..76f4eb65 100644 --- a/libtdegames/highscore/kexthighscore_internal.h +++ b/libtdegames/highscore/kexthighscore_internal.h @@ -177,7 +177,7 @@ class ConfigGroup : public TDEConfigGroupSaver { public: ConfigGroup(const TQString &group = TQString()) - : TDEConfigGroupSaver(kapp->config(), group) {} + : TDEConfigGroupSaver(tdeApp->config(), group) {} }; //----------------------------------------------------------------------------- diff --git a/libtdegames/highscore/kexthighscore_item.h b/libtdegames/highscore/kexthighscore_item.h index ac24ef83..df3219b5 100644 --- a/libtdegames/highscore/kexthighscore_item.h +++ b/libtdegames/highscore/kexthighscore_item.h @@ -24,7 +24,7 @@ #include <tqnamespace.h> #include <tqmap.h> #include <tqvaluevector.h> -#include <kdemacros.h> +#include <tdemacros.h> class TQWidget; @@ -37,7 +37,7 @@ namespace KExtHighscore * a highscore element (such as the score, the date, ...) or a player * info (such as the player name, the best score, ...). */ -class KDE_EXPORT Item +class TDE_EXPORT Item { public: /** @@ -172,7 +172,7 @@ enum ScoreType { Won = 0, Lost = -1, Draw = -2 }; * This class contains data for a score. You should not inherit from * this class but reimplement the methods in Highscores. */ -class KDE_EXPORT Score +class TDE_EXPORT Score { public: Score(ScoreType type = Won); @@ -241,8 +241,8 @@ class KDE_EXPORT Score friend TQDataStream &operator >>(TQDataStream &stream, Score &score); }; -KDE_EXPORT TQDataStream &operator <<(TQDataStream &stream, const Score &score); -KDE_EXPORT TQDataStream &operator >>(TQDataStream &stream, Score &score); +TDE_EXPORT TQDataStream &operator <<(TQDataStream &stream, const Score &score); +TDE_EXPORT TQDataStream &operator >>(TQDataStream &stream, Score &score); /** * This class is used to store and show scores for multiplayer games. @@ -264,7 +264,7 @@ KDE_EXPORT TQDataStream &operator >>(TQDataStream &stream, Score &score); * ms.addScore(1, score); * </pre> */ -class KDE_EXPORT MultiplayerScores +class TDE_EXPORT MultiplayerScores { public: MultiplayerScores(); @@ -309,8 +309,8 @@ class KDE_EXPORT MultiplayerScores MultiplayerScores &score); }; -KDE_EXPORT TQDataStream &operator <<(TQDataStream &stream, const MultiplayerScores &score); -KDE_EXPORT TQDataStream &operator >>(TQDataStream &stream, MultiplayerScores &score); +TDE_EXPORT TQDataStream &operator <<(TQDataStream &stream, const MultiplayerScores &score); +TDE_EXPORT TQDataStream &operator >>(TQDataStream &stream, MultiplayerScores &score); } // namespace diff --git a/libtdegames/highscore/kexthighscore_tab.cpp b/libtdegames/highscore/kexthighscore_tab.cpp index e48db436..b45a86b0 100644 --- a/libtdegames/highscore/kexthighscore_tab.cpp +++ b/libtdegames/highscore/kexthighscore_tab.cpp @@ -46,7 +46,7 @@ PlayersCombo::PlayersCombo(TQWidget *parent, const char *name) for (uint i = 0; i<p.nbEntries(); i++) insertItem(p.prettyName(i)); insertItem(TQString("<") + i18n("all") + '>'); - connect(this, TQT_SIGNAL(activated(int)), TQT_SLOT(activatedSlot(int))); + connect(this, TQ_SIGNAL(activated(int)), TQ_SLOT(activatedSlot(int))); } void PlayersCombo::activatedSlot(int i) @@ -75,9 +75,9 @@ AdditionalTab::AdditionalTab(TQWidget *parent, const char *name) TQLabel *label = new TQLabel(i18n("Select player:"), this); hbox->addWidget(label); _combo = new PlayersCombo(this); - connect(_combo, TQT_SIGNAL(playerSelected(uint)), - TQT_SLOT(playerSelected(uint))); - connect(_combo, TQT_SIGNAL(allSelected()), TQT_SLOT(allSelected())); + connect(_combo, TQ_SIGNAL(playerSelected(uint)), + TQ_SLOT(playerSelected(uint))); + connect(_combo, TQ_SIGNAL(allSelected()), TQ_SLOT(allSelected())); hbox->addWidget(_combo); hbox->addStretch(1); } diff --git a/libtdegames/highscore/kexthighscore_tab.h b/libtdegames/highscore/kexthighscore_tab.h index bb84f155..3ba1c720 100644 --- a/libtdegames/highscore/kexthighscore_tab.h +++ b/libtdegames/highscore/kexthighscore_tab.h @@ -33,7 +33,7 @@ namespace KExtHighscore //----------------------------------------------------------------------------- class PlayersCombo : public TQComboBox { - Q_OBJECT + TQ_OBJECT public: PlayersCombo(TQWidget *parent = 0, const char *name = 0); @@ -52,7 +52,7 @@ class PlayersCombo : public TQComboBox //----------------------------------------------------------------------------- class AdditionalTab : public TQWidget { - Q_OBJECT + TQ_OBJECT public: AdditionalTab(TQWidget *parent, const char *name); @@ -75,7 +75,7 @@ class AdditionalTab : public TQWidget //----------------------------------------------------------------------------- class StatisticsTab : public AdditionalTab { - Q_OBJECT + TQ_OBJECT public: StatisticsTab(TQWidget *parent); @@ -101,7 +101,7 @@ class StatisticsTab : public AdditionalTab //----------------------------------------------------------------------------- class HistogramTab : public AdditionalTab { - Q_OBJECT + TQ_OBJECT public: HistogramTab(TQWidget *parent); diff --git a/libtdegames/highscore/khighscore.cpp b/libtdegames/highscore/khighscore.cpp index bfed1534..bdc82845 100644 --- a/libtdegames/highscore/khighscore.cpp +++ b/libtdegames/highscore/khighscore.cpp @@ -27,7 +27,7 @@ #include <sys/file.h> #include <tdeapplication.h> -#include <ksimpleconfig.h> +#include <tdesimpleconfig.h> #include <tdeglobal.h> #include <kstdguiitem.h> #include <tdelocale.h> @@ -143,7 +143,7 @@ bool KHighscore::lockForWriting(TQWidget *widget) void KHighscore::writeAndUnlock() { if ( !d->global ) { - kapp->config()->sync(); + tdeApp->config()->sync(); return; } if ( !isLocked() ) return; @@ -162,7 +162,7 @@ KHighscore::~KHighscore() TDEConfig* KHighscore::config() const { - return (d->global ? _config : kapp->config()); + return (d->global ? _config : tdeApp->config()); } void KHighscore::writeEntry(int entry, const TQString& key, const TQVariant& value) diff --git a/libtdegames/highscore/khighscore.h b/libtdegames/highscore/khighscore.h index 4cf5778c..f3b3473e 100644 --- a/libtdegames/highscore/khighscore.h +++ b/libtdegames/highscore/khighscore.h @@ -25,7 +25,7 @@ #include <tqstring.h> #include <tqobject.h> -#include <kdemacros.h> +#include <tdemacros.h> class TDEConfig; class KFileLock; class KRawConfig; @@ -81,9 +81,9 @@ class KHighscorePrivate; * Easy, what? * @author Andreas Beckermann <b_mann@gmx.de> **/ -class KDE_EXPORT KHighscore : public TQObject +class TDE_EXPORT KHighscore : public TQObject { - Q_OBJECT + TQ_OBJECT public: /** @obsolete @@ -295,7 +295,7 @@ protected: /** * @return A pointer to the TDEConfig object to be used. This is - * either kapp->config() (default) or a KSimpleConfig object for + * either tdeApp->config() (default) or a TDESimpleConfig object for * a system-wide highscore file. **/ TDEConfig* config() const; diff --git a/libtdegames/highscore/kscoredialog.cpp b/libtdegames/highscore/kscoredialog.cpp index 518d0084..98aab883 100644 --- a/libtdegames/highscore/kscoredialog.cpp +++ b/libtdegames/highscore/kscoredialog.cpp @@ -90,7 +90,7 @@ KScoreDialog::KScoreDialog(int fields, TQWidget *parent, const char *oname) d->key[Score] = "Score"; d->page = makeMainWidget(); - connect(this, TQT_SIGNAL(okClicked()), TQT_SLOT(slotGotName())); + connect(this, TQ_SIGNAL(okClicked()), TQ_SLOT(slotGotName())); } KScoreDialog::~KScoreDialog() @@ -154,7 +154,7 @@ void KScoreDialog::setupDialog() } } - KSeparator *sep = new KSeparator(Qt::Horizontal, d->page); + KSeparator *sep = new KSeparator(TQt::Horizontal, d->page); d->layout->addMultiCellWidget(sep, 4, 4, 0, d->nrCols-1); d->labels.resize(d->nrCols * 10); @@ -239,8 +239,8 @@ void KScoreDialog::aboutToShow() stack->addWidget(d->edit); stack->raiseWidget(d->edit); d->edit->setFocus(); - connect(d->edit, TQT_SIGNAL(returnPressed()), - this, TQT_SLOT(slotGotReturn())); + connect(d->edit, TQ_SIGNAL(returnPressed()), + this, TQ_SLOT(slotGotReturn())); } else { @@ -275,7 +275,7 @@ void KScoreDialog::loadScores() TQString key, value; d->loaded = true; d->scores.clear(); - TDEConfigGroup config(kapp->config(), d->configGroup.utf8()); + TDEConfigGroup config(tdeApp->config(), d->configGroup.utf8()); d->player = config.readEntry("LastPlayer"); @@ -298,7 +298,7 @@ void KScoreDialog::loadScores() void KScoreDialog::saveScores() { TQString key, value; - TDEConfigGroup config(kapp->config(), d->configGroup.utf8()); + TDEConfigGroup config(tdeApp->config(), d->configGroup.utf8()); config.writeEntry("LastPlayer", d->player); @@ -315,7 +315,7 @@ void KScoreDialog::saveScores() } } } - kapp->config()->sync(); + tdeApp->config()->sync(); } int KScoreDialog::addScore(int newScore, const FieldInfo &newInfo, bool askName) @@ -365,7 +365,7 @@ void KScoreDialog::show() void KScoreDialog::slotGotReturn() { - TQTimer::singleShot(0, this, TQT_SLOT(slotGotName())); + TQTimer::singleShot(0, this, TQ_SLOT(slotGotName())); } void KScoreDialog::slotGotName() diff --git a/libtdegames/highscore/kscoredialog.h b/libtdegames/highscore/kscoredialog.h index 51cdb479..30222b14 100644 --- a/libtdegames/highscore/kscoredialog.h +++ b/libtdegames/highscore/kscoredialog.h @@ -29,7 +29,7 @@ this software. #include <tqptrlist.h> #include <kdialogbase.h> -#include <kdemacros.h> +#include <tdemacros.h> class TQGridLayout; class TQLineEdit; class TQWidgetStack; @@ -37,8 +37,8 @@ class TQWidgetStack; /** * A simple high score dialog. */ -class KDE_EXPORT KScoreDialog : public KDialogBase { - Q_OBJECT +class TDE_EXPORT KScoreDialog : public KDialogBase { + TQ_OBJECT public: diff --git a/libtdegames/highscore/tdeconfigrawbackend.h b/libtdegames/highscore/tdeconfigrawbackend.h index 7e8f2790..4ae90f8f 100644 --- a/libtdegames/highscore/tdeconfigrawbackend.h +++ b/libtdegames/highscore/tdeconfigrawbackend.h @@ -23,7 +23,7 @@ #include <tqfile.h> #include <tdeconfigbackend.h> -#include <ksimpleconfig.h> +#include <tdesimpleconfig.h> class TDEConfigRawBackEnd : public TDEConfigINIBackEnd @@ -45,13 +45,13 @@ private: TDEConfigRawBackEndPrivate *d; }; -class KRawConfig : public KSimpleConfig +class KRawConfig : public TDESimpleConfig { - Q_OBJECT + TQ_OBJECT public: KRawConfig(int fd, bool readOnly) - : KSimpleConfig(new TDEConfigRawBackEnd(this, fd), readOnly) {} + : TDESimpleConfig(new TDEConfigRawBackEnd(this, fd), readOnly) {} }; |
