summaryrefslogtreecommitdiffstats
path: root/klettres
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:12:18 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:12:18 -0600
commitee52bb567f32fefdcf06e083c76562ea40ccf174 (patch)
tree8926667faaed3a18bec210ec14ffb9392ea8930d /klettres
parent088cc453ec425bf86d610880d09645ea166a14fa (diff)
downloadtdeedu-ee52bb567f32fefdcf06e083c76562ea40ccf174.tar.gz
tdeedu-ee52bb567f32fefdcf06e083c76562ea40ccf174.zip
Rename a number of classes to enhance compatibility with KDE4
Diffstat (limited to 'klettres')
-rw-r--r--klettres/ChangeLog2
-rw-r--r--klettres/klettres/fontsdlg.ui2
-rw-r--r--klettres/klettres/klettres.cpp26
-rw-r--r--klettres/klettres/klettres.h26
4 files changed, 28 insertions, 28 deletions
diff --git a/klettres/ChangeLog b/klettres/ChangeLog
index 52ca488f..e03a4463 100644
--- a/klettres/ChangeLog
+++ b/klettres/ChangeLog
@@ -7,7 +7,7 @@ Buttons appear consequently in the 2 styles to allow menuBar and other style.
- better internationalization
- i18n() the KLettres on the splash-screen
- suppress the sound with the splash-screen as it was too long
-- add menubar, toolbar and statusbar, configurable using KAction
+- add menubar, toolbar and statusbar, configurable using TDEAction
- settings allow to choose the language and the level from the menuBar and toolBar
- statusBar indicates level and language
- suppressed the .ui file
diff --git a/klettres/klettres/fontsdlg.ui b/klettres/klettres/fontsdlg.ui
index 5853adfd..181b9a1b 100644
--- a/klettres/klettres/fontsdlg.ui
+++ b/klettres/klettres/fontsdlg.ui
@@ -16,7 +16,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="KFontChooser" row="0" column="0">
+ <widget class="TDEFontChooser" row="0" column="0">
<property name="name">
<cstring>kcfg_Font</cstring>
</property>
diff --git a/klettres/klettres/klettres.cpp b/klettres/klettres/klettres.cpp
index ca005800..eaba8fc2 100644
--- a/klettres/klettres/klettres.cpp
+++ b/klettres/klettres/klettres.cpp
@@ -54,11 +54,11 @@ const int ID_GROWNB = 101;
const int ID_MENUBARB = 102;
KLettres::KLettres()
- : KMainWindow( 0, "KLettres" )
+ : TDEMainWindow( 0, "KLettres" )
{
mNewStuff = 0;
m_view = new KLettresView(this);
- // tell the KMainWindow that this is indeed the main widget
+ // tell the TDEMainWindow that this is indeed the main widget
setCentralWidget(m_view);
//Scan for existing languages -> m_languages
findLanguages();
@@ -195,25 +195,25 @@ bool KLettres::loadLayout(TQDomDocument &layoutDocument)
void KLettres::setupActions()
{
- KAction *m_newAction = new KAction(i18n("New Sound"), "file_new", CTRL+Key_N, TQT_TQOBJECT(m_view), TQT_SLOT(game()), actionCollection(), "play_new");
+ TDEAction *m_newAction = new TDEAction(i18n("New Sound"), "file_new", CTRL+Key_N, TQT_TQOBJECT(m_view), TQT_SLOT(game()), actionCollection(), "play_new");
m_newAction->setToolTip(i18n("Play a new sound"));
m_newAction->setWhatsThis(i18n("You can play a new sound by clicking this button or using the File menu, New Sound."));
- new KAction( i18n("Get Alphabet in New Language..."), "knewstuff", 0, TQT_TQOBJECT(this), TQT_SLOT( slotDownloadNewStuff() ), actionCollection(), "downloadnewstuff" );
- KAction *m_playAgainAction = new KAction(i18n("Replay Sound"),"player_play", CTRL+Key_P, TQT_TQOBJECT(m_view), TQT_SLOT(slotPlayAgain()), actionCollection(), "play_again");
+ new TDEAction( i18n("Get Alphabet in New Language..."), "knewstuff", 0, TQT_TQOBJECT(this), TQT_SLOT( slotDownloadNewStuff() ), actionCollection(), "downloadnewstuff" );
+ TDEAction *m_playAgainAction = new TDEAction(i18n("Replay Sound"),"player_play", CTRL+Key_P, TQT_TQOBJECT(m_view), TQT_SLOT(slotPlayAgain()), actionCollection(), "play_again");
m_playAgainAction->setToolTip(i18n("Play the same sound again"));
m_playAgainAction->setWhatsThis(i18n("You can replay the same sound again by clicking this button or using the File menu, Replay Sound."));
KStdAction::quit(TQT_TQOBJECT(kapp), TQT_SLOT(quit()), actionCollection());
- m_menubarAction = new KToggleAction(i18n("Show &Menubar"),"editclear", CTRL+Key_M, TQT_TQOBJECT(this), TQT_SLOT(slotMenubar()), actionCollection(), "menubar");
+ m_menubarAction = new TDEToggleAction(i18n("Show &Menubar"),"editclear", CTRL+Key_M, TQT_TQOBJECT(this), TQT_SLOT(slotMenubar()), actionCollection(), "menubar");
m_menubarAction->setCheckedState(i18n("Hide &Menubar"));
m_menubarAction->setChecked(true);
m_menubarAction->setWhatsThis(i18n("You can show or hide the menubar as you wish by clicking this button."));
- m_levelAction = new KSelectAction(i18n("L&evel"), KShortcut(), actionCollection(), "levels");
+ m_levelAction = new TDESelectAction(i18n("L&evel"), TDEShortcut(), actionCollection(), "levels");
m_levelAction->setToolTip(i18n("Select the level"));
m_levelAction->setWhatsThis(i18n("You can select the level: level 1 displays a letter and you hear it; level 2 does not display the letter, you only hear it; level 3 displays a syllable and you hear it; level 4 does not display the syllable, you only hear it."));
- m_languageAction = new KSelectAction(i18n("&Language"), KShortcut(), actionCollection(), "languages");
+ m_languageAction = new TDESelectAction(i18n("&Language"), TDEShortcut(), actionCollection(), "languages");
m_languageAction->setItems(m_languageNames);
m_levelsNames.append(i18n( "Level 1" ));
@@ -222,7 +222,7 @@ void KLettres::setupActions()
m_levelsNames.append(i18n( "Level 4" ));
m_levelAction->setItems(m_levelsNames);
- m_themeAction = new KSelectAction(i18n("Themes"), KShortcut(), actionCollection(), "looks");
+ m_themeAction = new TDESelectAction(i18n("Themes"), TDEShortcut(), actionCollection(), "looks");
m_themesNames.append(i18n("Classroom"));
m_themesNames.append(i18n("Arctic"));
m_themesNames.append(i18n("Desert"));
@@ -230,9 +230,9 @@ void KLettres::setupActions()
m_themeAction->setToolTip(i18n("Select the theme"));
m_themeAction->setWhatsThis(i18n("Here you can change the theme for KLettres. A theme consists in the background picture and the font color for the letter displayed."));
- m_kidAction = new KToggleAction(i18n("Mode Kid"), "klettres_kids", CTRL+Key_K, TQT_TQOBJECT(this), TQT_SLOT(slotModeKid()), actionCollection(), "mode_kid");
+ m_kidAction = new TDEToggleAction(i18n("Mode Kid"), "klettres_kids", CTRL+Key_K, TQT_TQOBJECT(this), TQT_SLOT(slotModeKid()), actionCollection(), "mode_kid");
m_kidAction->setWhatsThis(i18n("If you are in the Grown-up mode, clicking on this button will set up the Kid mode. The Kid mode has no menubar and the font is bigger in the statusbar."));
- m_grownupAction = new KToggleAction(i18n("Mode Grown-up"), "klettres_grownup", CTRL+Key_G, TQT_TQOBJECT(this), TQT_SLOT(slotModeGrownup()), actionCollection(), "mode_grownup");
+ m_grownupAction = new TDEToggleAction(i18n("Mode Grown-up"), "klettres_grownup", CTRL+Key_G, TQT_TQOBJECT(this), TQT_SLOT(slotModeGrownup()), actionCollection(), "mode_grownup");
m_grownupAction->setWhatsThis(i18n("The Grown-up mode is the normal mode where you can see the menubar."));
connect(m_levelAction, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotChangeLevel(int)));
@@ -259,7 +259,7 @@ void KLettres::setupToolbars()
{
//toolbar for special characters
m_secondToolbar = toolBar("secondToolbar");
- m_secondToolbar->setBarPos(KToolBar::Bottom);
+ m_secondToolbar->setBarPos(TDEToolBar::Bottom);
}
void KLettres::optionsPreferences()
@@ -482,7 +482,7 @@ void KLettres::loadLangToolBar()
void KLettres::slotPasteChar()
{
- KToolBarButton *charBut = (KToolBarButton* ) sender();
+ TDEToolBarButton *charBut = (TDEToolBarButton* ) sender();
m_view->m_letterEdit->insert(allData[charBut->id()]);
}
diff --git a/klettres/klettres/klettres.h b/klettres/klettres/klettres.h
index e717433f..02ff5197 100644
--- a/klettres/klettres/klettres.h
+++ b/klettres/klettres/klettres.h
@@ -32,10 +32,10 @@
#include "soundfactory.h"
class TQLabel;
-class KToggleAction;
-class KSelectAction;
+class TDEToggleAction;
+class TDESelectAction;
class KComboBox;
-class KToolBar;
+class TDEToolBar;
class KLNewStuff;
/**
@@ -43,7 +43,7 @@ class KLNewStuff;
* @author Anne-Marie Mahfouf <annemarie.mahfouf@free.fr>
* @version 1.4
*/
-class KLettres : public KMainWindow
+class KLettres : public TDEMainWindow
{
Q_OBJECT
@@ -69,7 +69,7 @@ public:
///Number corresponding to the selected language: 0 is Czech, 1 is Danish, 2 is English (default), 3 is French, 4 is Dutch, 5 is Slovak
//uint selectedLanguage;
///Action that sets up the Language menu
- KSelectAction *m_languageAction;
+ TDESelectAction *m_languageAction;
///Look for all languages available
void findLanguages();
@@ -81,15 +81,15 @@ protected:
///Call an instance of the KLettresView widget
KLettresView *m_view;
///Action that enables the ShowMenuBar item in the Settings menu
- KToggleAction *m_menubarAction;
+ TDEToggleAction *m_menubarAction;
///Action that sets up the Level menu
- KSelectAction *m_levelAction;
+ TDESelectAction *m_levelAction;
///Action that sets up the Look menu
- KSelectAction *m_themeAction;
+ TDESelectAction *m_themeAction;
///Action allow the Kid mode
- KToggleAction *m_kidAction;
+ TDEToggleAction *m_kidAction;
///Action allow the Grownup mode
- KToggleAction *m_grownupAction;
+ TDEToggleAction *m_grownupAction;
///Label stating the language in the statusbar
TQLabel *m_langLabel;
///Label stating the level in the statusbar
@@ -98,10 +98,10 @@ protected:
TQStringList m_levelsNames;
///Holds the looks
TQStringList m_themesNames;
- ///Create an instance of a KToolBar
- KToolBar *m_mainToolbar;
+ ///Create an instance of a TDEToolBar
+ TDEToolBar *m_mainToolbar;
///Second toolbar with buttons of special characters per language
- KToolBar *m_secondToolbar;
+ TDEToolBar *m_secondToolbar;
///is false when menubar button is not shown
bool menuBool;
///Build the main window menus