summaryrefslogtreecommitdiffstats
path: root/ksayit/src
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:09:56 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:09:56 -0600
commit5ca50f0ef6000d132b45fc6a50cf3062245bd070 (patch)
tree99c6b7de89d289e0a80ec21f7525dc514bc759d1 /ksayit/src
parent722a076e84b860a947f4c68417db82526b03b1a1 (diff)
downloadtdeaccessibility-5ca50f0ef6000d132b45fc6a50cf3062245bd070.tar.gz
tdeaccessibility-5ca50f0ef6000d132b45fc6a50cf3062245bd070.zip
Rename a number of classes to enhance compatibility with KDE4
Diffstat (limited to 'ksayit/src')
-rw-r--r--ksayit/src/DocTreeView.ui2
-rw-r--r--ksayit/src/Types.h4
-rw-r--r--ksayit/src/contextmenuhandler.cpp48
-rw-r--r--ksayit/src/contextmenuhandler.h46
-rw-r--r--ksayit/src/docbookclasses.cpp10
-rw-r--r--ksayit/src/docbookclasses.h2
-rw-r--r--ksayit/src/doctreeviewimpl.cpp12
-rw-r--r--ksayit/src/doctreeviewimpl.h2
-rw-r--r--ksayit/src/ksayit.cpp20
-rw-r--r--ksayit/src/ksayit.h44
-rw-r--r--ksayit/src/ksayitsystemtray.cpp10
-rw-r--r--ksayit/src/ksayitsystemtray.h20
12 files changed, 110 insertions, 110 deletions
diff --git a/ksayit/src/DocTreeView.ui b/ksayit/src/DocTreeView.ui
index 7897b9f..bc5e2c6 100644
--- a/ksayit/src/DocTreeView.ui
+++ b/ksayit/src/DocTreeView.ui
@@ -39,7 +39,7 @@
<property name="resizeMode">
<enum>Minimum</enum>
</property>
- <widget class="KListView" row="0" column="0">
+ <widget class="TDEListView" row="0" column="0">
<column>
<property name="text">
<string>Chapter</string>
diff --git a/ksayit/src/Types.h b/ksayit/src/Types.h
index ec4475a..ff9ca65 100644
--- a/ksayit/src/Types.h
+++ b/ksayit/src/Types.h
@@ -51,12 +51,12 @@ namespace KSayItGlobal {
This abstract class is the interface to access the items of the TreeView.
@author Robert Vogl
*/
-class ListViewInterface : public KListViewItem
+class ListViewInterface : public TDEListViewItem
{
public:
ListViewInterface(ListViewInterface *parent=0, TQString label=TQString());
ListViewInterface(ListViewInterface *parent=0, ListViewInterface *after=0, TQString label=TQString());
- ListViewInterface(KListView *lv=0, TQString label=TQString());
+ ListViewInterface(TDEListView *lv=0, TQString label=TQString());
// ~ListViewItemInterface();
diff --git a/ksayit/src/contextmenuhandler.cpp b/ksayit/src/contextmenuhandler.cpp
index 5a83404..9961b18 100644
--- a/ksayit/src/contextmenuhandler.cpp
+++ b/ksayit/src/contextmenuhandler.cpp
@@ -92,7 +92,7 @@ bool ContextActionHandler::endElement( const TQString &,
return true;
if ( qName == "Action" ){
- KAction* newAction = m_menuhandler->ActionFactory(m_actionName, m_qty);
+ TDEAction* newAction = m_menuhandler->ActionFactory(m_actionName, m_qty);
if ( newAction )
newAction->plug( m_popup );
} else if ( qName == "Submenu" ){
@@ -156,81 +156,81 @@ ContextMenuHandler::~ContextMenuHandler()
void ContextMenuHandler::initActions()
{
// User defined actions
- renameItem = new KAction (i18n("Rename..."),
+ renameItem = new TDEAction (i18n("Rename..."),
0,
m_DocTreeView, TQT_SLOT (slotRenameItem()), NULL );
- deleteItem = new KAction (i18n("Delete..."),
+ deleteItem = new TDEAction (i18n("Delete..."),
0,
m_DocTreeView, TQT_SLOT (slotDeleteItem()), NULL );
- newBookInfo = new KAction ( i18n("Overview"),
+ newBookInfo = new TDEAction ( i18n("Overview"),
0,
m_DocTreeView, TQT_SLOT (slotNewBookInfo()), NULL );
- newChapter = new KAction ( i18n("Chapter"),
+ newChapter = new TDEAction ( i18n("Chapter"),
0,
m_DocTreeView, TQT_SLOT (slotNewChapter()), NULL );
- newKeywordSet = new KAction ( i18n("Keywords"),
+ newKeywordSet = new TDEAction ( i18n("Keywords"),
0,
m_DocTreeView, TQT_SLOT (slotNewKeywordSet()), NULL );
- newKeyword = new KAction ( i18n("Keyword"),
+ newKeyword = new TDEAction ( i18n("Keyword"),
0,
m_DocTreeView, TQT_SLOT (slotNewKeyword()), NULL );
- newAbstract = new KAction ( i18n("Abstract"),
+ newAbstract = new TDEAction ( i18n("Abstract"),
0,
m_DocTreeView, TQT_SLOT (slotNewAbstract()), NULL );
- newAuthorGroup = new KAction ( i18n("Authors"),
+ newAuthorGroup = new TDEAction ( i18n("Authors"),
0,
m_DocTreeView, TQT_SLOT (slotNewAuthorGroup()), NULL );
- newAuthor = new KAction ( i18n("Author"),
+ newAuthor = new TDEAction ( i18n("Author"),
0,
m_DocTreeView, TQT_SLOT (slotNewAuthor()), NULL );
- newDate = new KAction ( i18n("Date"),
+ newDate = new TDEAction ( i18n("Date"),
0,
m_DocTreeView, TQT_SLOT (slotNewDate()), NULL );
- newReleaseInfo = new KAction ( i18n("Release Info"),
+ newReleaseInfo = new TDEAction ( i18n("Release Info"),
0,
m_DocTreeView, TQT_SLOT (slotNewReleaseInfo()), NULL );
- newTitle = new KAction ( i18n("Title"),
+ newTitle = new TDEAction ( i18n("Title"),
0,
m_DocTreeView, TQT_SLOT (slotNewTitle()), NULL );
- newParagraph = new KAction ( i18n("Paragraph"),
+ newParagraph = new TDEAction ( i18n("Paragraph"),
0,
m_DocTreeView, TQT_SLOT (slotNewParagraph()), NULL );
- newSection_1 = new KAction ( i18n("Section Level 1"),
+ newSection_1 = new TDEAction ( i18n("Section Level 1"),
0,
m_DocTreeView, TQT_SLOT (slotNewSection_1()), NULL );
- newSection_2 = new KAction ( i18n("Section Level 2"),
+ newSection_2 = new TDEAction ( i18n("Section Level 2"),
0,
m_DocTreeView, TQT_SLOT (slotNewSection_2()), NULL );
- newSection_3 = new KAction ( i18n("Section Level 3"),
+ newSection_3 = new TDEAction ( i18n("Section Level 3"),
0,
m_DocTreeView, TQT_SLOT (slotNewSection_3()), NULL );
- newSection_4 = new KAction ( i18n("Section Level 4"),
+ newSection_4 = new TDEAction ( i18n("Section Level 4"),
0,
m_DocTreeView, TQT_SLOT (slotNewSection_4()), NULL );
- newSection_5 = new KAction ( i18n("Section Level 5"),
+ newSection_5 = new TDEAction ( i18n("Section Level 5"),
0,
m_DocTreeView, TQT_SLOT (slotNewSection_5()), NULL );
}
-KPopupMenu* ContextMenuHandler::getPopupMenu(ListViewInterface *item)
+TDEPopupMenu* ContextMenuHandler::getPopupMenu(ListViewInterface *item)
{
if ( !item )
return NULL;
@@ -246,7 +246,7 @@ KPopupMenu* ContextMenuHandler::getPopupMenu(ListViewInterface *item)
delete m_popupmenu;
m_popupmenu = NULL;
}
- m_popupmenu = new KPopupMenu(0);
+ m_popupmenu = new TDEPopupMenu(0);
bool res;
res = parseXmlFile(xmlID);
@@ -297,7 +297,7 @@ bool ContextMenuHandler::parseXmlFile(const TQString &xmlID)
}
-KAction* ContextMenuHandler::ActionFactory( const TQString &actionName, const TQString &qty )
+TDEAction* ContextMenuHandler::ActionFactory( const TQString &actionName, const TQString &qty )
{
bool enabled;
if ( qty.lower() == "n" ){
@@ -378,9 +378,9 @@ KAction* ContextMenuHandler::ActionFactory( const TQString &actionName, const TQ
}
-KPopupMenu* ContextMenuHandler::SubMenuFactory(KPopupMenu *parent)
+TDEPopupMenu* ContextMenuHandler::SubMenuFactory(TDEPopupMenu *parent)
{
- return new KPopupMenu(parent);
+ return new TDEPopupMenu(parent);
}
diff --git a/ksayit/src/contextmenuhandler.h b/ksayit/src/contextmenuhandler.h
index fdf6955..bd0f2f3 100644
--- a/ksayit/src/contextmenuhandler.h
+++ b/ksayit/src/contextmenuhandler.h
@@ -55,7 +55,7 @@ private:
TQString m_subName;
TQString m_actionName;
TQString m_qty;
- KPopupMenu *m_popup;
+ TDEPopupMenu *m_popup;
bool m_hit;
TQString m_searchID;
};
@@ -77,13 +77,13 @@ public:
* \param item The selected TreeView item.
* \returns A pointer to the popup-menu.
*/
- KPopupMenu* getPopupMenu(ListViewInterface *item);
+ TDEPopupMenu* getPopupMenu(ListViewInterface *item);
/**
* \returns A pointer to the Submenu as a child of the parent
* \p parent.
*/
- KPopupMenu* SubMenuFactory(KPopupMenu *parent);
+ TDEPopupMenu* SubMenuFactory(TDEPopupMenu *parent);
/**
* Creates an action sufficiant to the given name.
@@ -95,7 +95,7 @@ public:
* given element.
* \returns A Pointer to the action.
*/
- KAction* ActionFactory( const TQString &actionName, const TQString &qty );
+ TDEAction* ActionFactory( const TQString &actionName, const TQString &qty );
/**
* Creates a Popup context menu for the given item and stores a
@@ -119,29 +119,29 @@ private: // Methods
bool parseXmlFile(const TQString &xmlID);
public: // Attributes
- KPopupMenu* m_popupmenu;
+ TDEPopupMenu* m_popupmenu;
private:
// Basic actions
- KAction* renameItem;
- KAction* deleteItem;
+ TDEAction* renameItem;
+ TDEAction* deleteItem;
// Actions to create new items
- KAction* newBookInfo;
- KAction* newChapter;
- KAction* newKeywordSet;
- KAction* newKeyword;
- KAction* newAbstract;
- KAction* newAuthorGroup;
- KAction* newAuthor;
- KAction* newDate;
- KAction* newReleaseInfo;
- KAction* newTitle;
- KAction* newParagraph;
- KAction* newSection_1;
- KAction* newSection_2;
- KAction* newSection_3;
- KAction* newSection_4;
- KAction* newSection_5;
+ TDEAction* newBookInfo;
+ TDEAction* newChapter;
+ TDEAction* newKeywordSet;
+ TDEAction* newKeyword;
+ TDEAction* newAbstract;
+ TDEAction* newAuthorGroup;
+ TDEAction* newAuthor;
+ TDEAction* newDate;
+ TDEAction* newReleaseInfo;
+ TDEAction* newTitle;
+ TDEAction* newParagraph;
+ TDEAction* newSection_1;
+ TDEAction* newSection_2;
+ TDEAction* newSection_3;
+ TDEAction* newSection_4;
+ TDEAction* newSection_5;
// mixed stuff
TQString m_XmlFilePath;
diff --git a/ksayit/src/docbookclasses.cpp b/ksayit/src/docbookclasses.cpp
index afe83a7..3e1f091 100644
--- a/ksayit/src/docbookclasses.cpp
+++ b/ksayit/src/docbookclasses.cpp
@@ -32,16 +32,16 @@
// Interface
//////////////////////////////////////
ListViewInterface::ListViewInterface(ListViewInterface *parent, TQString label)
- : KListViewItem( parent, label )
+ : TDEListViewItem( parent, label )
{
}
-ListViewInterface::ListViewInterface(ListViewInterface *parent, ListViewInterface *after, TQString label) : KListViewItem( parent, after, label )
+ListViewInterface::ListViewInterface(ListViewInterface *parent, ListViewInterface *after, TQString label) : TDEListViewItem( parent, after, label )
{
}
-ListViewInterface::ListViewInterface(KListView *lv, TQString label)
- : KListViewItem( lv, label )
+ListViewInterface::ListViewInterface(TDEListView *lv, TQString label)
+ : TDEListViewItem( lv, label )
{
}
@@ -52,7 +52,7 @@ ListViewInterface::ListViewInterface(KListView *lv, TQString label)
/**
* RobDocument
*/
-RobDocument::RobDocument(KListView *lv, TQString label)
+RobDocument::RobDocument(TDEListView *lv, TQString label)
: ListViewInterface( lv, label )
{
TQPixmap pixmap = TDEGlobal::iconLoader()->loadIcon("contents", KIcon::Small);
diff --git a/ksayit/src/docbookclasses.h b/ksayit/src/docbookclasses.h
index f19f9f0..89d104e 100644
--- a/ksayit/src/docbookclasses.h
+++ b/ksayit/src/docbookclasses.h
@@ -45,7 +45,7 @@ public:
* \param label The label is shown in column 0 of the TreeView and is also
* used as bookmark title.
*/
- RobDocument(KListView *lv=0, TQString label=TQString());
+ RobDocument(TDEListView *lv=0, TQString label=TQString());
~RobDocument();
bool setValue( unsigned int index, TQVariant data );
diff --git a/ksayit/src/doctreeviewimpl.cpp b/ksayit/src/doctreeviewimpl.cpp
index 57e5d8b..9f343b2 100644
--- a/ksayit/src/doctreeviewimpl.cpp
+++ b/ksayit/src/doctreeviewimpl.cpp
@@ -52,14 +52,14 @@ DocTreeViewImpl::DocTreeViewImpl(TQWidget* parent, const char* name, WFlags fl)
listView->setColumnText(1, i18n("Info"));
listView->setColumnText(2, i18n("Page"));
listView->setColumnText(3, "");
- listView->setResizeMode( KListView::NoColumn );
- listView->setColumnWidthMode(0, KListView::Maximum );
- listView->setColumnWidthMode(1, KListView::Maximum );
- listView->setColumnWidthMode(2, KListView::Maximum );
- listView->setColumnWidthMode(3, KListView::Manual );
+ listView->setResizeMode( TDEListView::NoColumn );
+ listView->setColumnWidthMode(0, TDEListView::Maximum );
+ listView->setColumnWidthMode(1, TDEListView::Maximum );
+ listView->setColumnWidthMode(2, TDEListView::Maximum );
+ listView->setColumnWidthMode(3, TDEListView::Manual );
listView->setColumnWidth(3, 0);
listView->setAlternateBackground( TQColor(230, 230, 240) );
- listView->setSelectionModeExt( KListView::Single );
+ listView->setSelectionModeExt( TDEListView::Single );
m_idCounter = KSayItGlobal::item_initial_id;
m_stopped = false;
diff --git a/ksayit/src/doctreeviewimpl.h b/ksayit/src/doctreeviewimpl.h
index 3021dc8..b0f7a35 100644
--- a/ksayit/src/doctreeviewimpl.h
+++ b/ksayit/src/doctreeviewimpl.h
@@ -173,7 +173,7 @@ private: // Methods
private: // Attributes
ContextMenuHandler *m_contextmenuhandler;
- KPopupMenu *m_contextmenu;
+ TDEPopupMenu *m_contextmenu;
ListViewInterface *m_rootItem;
ListViewInterface *m_currentItem;
TQString m_changedContent;
diff --git a/ksayit/src/ksayit.cpp b/ksayit/src/ksayit.cpp
index e2e931d..c5be390 100644
--- a/ksayit/src/ksayit.cpp
+++ b/ksayit/src/ksayit.cpp
@@ -57,7 +57,7 @@
KSayItApp::KSayItApp(TQWidget* parent, const char* name, WFlags f,
const TQCString &objID)
- : KMainWindow(parent, name, f), DCOPObject(objID)
+ : TDEMainWindow(parent, name, f), DCOPObject(objID)
{
config = NULL;
view = NULL;
@@ -156,50 +156,50 @@ void KSayItApp::initActions()
statusBarAction = KStdAction::showStatusbar(TQT_TQOBJECT(this), TQT_SLOT(slotToggleStatusBar()), actionCollection());
// User defined actions
- say = new KAction (i18n("Say"),
+ say = new TDEAction (i18n("Say"),
TQt::Key_F9,
TQT_TQOBJECT(this), TQT_SLOT (slotSayText()),
actionCollection(),
"say_it");
- pause = new KAction (i18n("Pause"),
+ pause = new TDEAction (i18n("Pause"),
TQt::Key_Pause,
TQT_TQOBJECT(this), TQT_SLOT (slotPauseActivated()),
actionCollection(),
"pause");
- shutup = new KAction (i18n("Shut Up"),
+ shutup = new TDEAction (i18n("Shut Up"),
TQt::Key_F10,
TQT_TQOBJECT(this), TQT_SLOT (slotStopActivated()),
actionCollection(),
"shut_up");
- next_sentence = new KAction (i18n("Next Sentence"),
+ next_sentence = new TDEAction (i18n("Next Sentence"),
TQt::Key_Next,
TQT_TQOBJECT(this), TQT_SLOT (slotNextSentenceActivated()),
actionCollection(),
"next_sentence");
- prev_sentence = new KAction (i18n("Previous Sentence"),
+ prev_sentence = new TDEAction (i18n("Previous Sentence"),
TQt::Key_Prior,
TQT_TQOBJECT(this), TQT_SLOT(slotPrevSentenceActivated()),
actionCollection(),
"prev_sentence");
- clear = new KAction (i18n("Clear"),
+ clear = new TDEAction (i18n("Clear"),
TQt::Key_F12,
TQT_TQOBJECT(this), TQT_SLOT(slotClear()),
actionCollection(),
"clear");
- edit = new KToggleAction( i18n("Edit Text"),
+ edit = new TDEToggleAction( i18n("Edit Text"),
0,
TQT_TQOBJECT(this), TQT_SLOT(slotEditToggled()),
actionCollection(),
"edittext");
- bookmarkmenu = new KActionMenu( i18n("Bookmarks"),
+ bookmarkmenu = new TDEActionMenu( i18n("Bookmarks"),
"bookmark", // icon
actionCollection(),
"bookmarks"); // name
@@ -240,7 +240,7 @@ void KSayItApp::initBookmarkManager(const TQString &filename)
bkHandler = new KSayItBookmarkHandler(bkManager, this);
// create Bookmarkmenu
- KPopupMenu *bkPopupMenu = bookmarkmenu->popupMenu();
+ TDEPopupMenu *bkPopupMenu = bookmarkmenu->popupMenu();
if ( bkMenu )
delete bkMenu;
bkMenu = new KBookmarkMenu(bkManager, bkHandler, bkPopupMenu, 0, true );
diff --git a/ksayit/src/ksayit.h b/ksayit/src/ksayit.h
index d1150bf..451cf36 100644
--- a/ksayit/src/ksayit.h
+++ b/ksayit/src/ksayit.h
@@ -57,15 +57,15 @@ class KSayItBookmarkHandler;
* The base class for KSayIt application windows. It sets up the main
* window and reads the config file as well as providing a menubar, toolbar
* and statusbar. An instance of KSayItView creates the center view.
- * KSayItApp reimplements the methods that KMainWindow provides for main window handling and supports
- * full session management as well as using KActions.
- * @see KMainWindow
+ * KSayItApp reimplements the methods that TDEMainWindow provides for main window handling and supports
+ * full session management as well as using TDEActions.
+ * @see TDEMainWindow
* @see TDEApplication
* @see TDEConfig
*
* @author Robert Vogl
*/
-class KSayItApp : public KMainWindow, public DCOPObject
+class KSayItApp : public TDEMainWindow, public DCOPObject
{
Q_OBJECT
//
@@ -276,7 +276,7 @@ private: // Methods
*/
void readOptions();
- /** initializes the KActions of the application */
+ /** initializes the TDEActions of the application */
void initActions();
/** sets up the statusbar for the main window by initialzing a statuslabel.
@@ -331,23 +331,23 @@ private:
KSayItBookmarkHandler *bkHandler;
KBookmarkMenu *bkMenu;
- // KAction pointers
- KToggleAction *statusBarAction;
- KAction *say;
- KAction *pause;
- KAction *shutup;
- KAction *next_sentence;
- KAction *prev_sentence;
- KAction *clear;
- KAction *copy;
- KAction *cut;
- KAction *paste;
- KAction *open;
- KAction *save;
- KAction *saveAs;
- KAction *preferences;
- KToggleAction *edit;
- KActionMenu *bookmarkmenu;
+ // TDEAction pointers
+ TDEToggleAction *statusBarAction;
+ TDEAction *say;
+ TDEAction *pause;
+ TDEAction *shutup;
+ TDEAction *next_sentence;
+ TDEAction *prev_sentence;
+ TDEAction *clear;
+ TDEAction *copy;
+ TDEAction *cut;
+ TDEAction *paste;
+ TDEAction *open;
+ TDEAction *save;
+ TDEAction *saveAs;
+ TDEAction *preferences;
+ TDEToggleAction *edit;
+ TDEActionMenu *bookmarkmenu;
// Misc stuff
TQClipboard *cb;
diff --git a/ksayit/src/ksayitsystemtray.cpp b/ksayit/src/ksayitsystemtray.cpp
index ca8196c..589eb5d 100644
--- a/ksayit/src/ksayitsystemtray.cpp
+++ b/ksayit/src/ksayitsystemtray.cpp
@@ -51,28 +51,28 @@ void KSayItSystemTray::initActions()
help_kde = KStdAction::aboutKDE(help, TQT_SLOT(aboutKDE()), actionCollection());
// User defined actions
- say = new KAction(i18n("Say"),
+ say = new TDEAction(i18n("Say"),
"player_play",
0,
TQT_TQOBJECT(this), TQT_SLOT (slotSayActivated()),
actionCollection(),
"say_it");
- shutup = new KAction(i18n("Shut Up"),
+ shutup = new TDEAction(i18n("Shut Up"),
"player_stop",
0,
TQT_TQOBJECT(this), TQT_SLOT (slotStopActivated()),
actionCollection(),
"shut_up");
- pause = new KAction (i18n("Pause"),
+ pause = new TDEAction (i18n("Pause"),
"player_pause",
0,
TQT_TQOBJECT(this), TQT_SLOT (slotPauseActivated()),
actionCollection(),
"pause");
- next_sentence = new KAction (i18n("Next Sentence"),
+ next_sentence = new TDEAction (i18n("Next Sentence"),
"2rightarrow",
0,
TQT_TQOBJECT(this), TQT_SLOT (slotNextSentenceActivated()),
@@ -80,7 +80,7 @@ void KSayItSystemTray::initActions()
"next_sentence");
- prev_sentence = new KAction (i18n("Previous Sentence"),
+ prev_sentence = new TDEAction (i18n("Previous Sentence"),
"2leftarrow",
0,
TQT_TQOBJECT(this), TQT_SLOT(slotPrevSentenceActivated()),
diff --git a/ksayit/src/ksayitsystemtray.h b/ksayit/src/ksayitsystemtray.h
index 79a6e03..ebef2d6 100644
--- a/ksayit/src/ksayitsystemtray.h
+++ b/ksayit/src/ksayitsystemtray.h
@@ -125,22 +125,22 @@ protected: // Methods
void sayClipboard();
private: // Methods
- /** initializes the KActions of the application */
+ /** initializes the TDEActions of the application */
void initActions();
public:
- KAction *say;
- KAction *shutup;
- KAction *pause;
- KAction *next_sentence;
- KAction *prev_sentence;
+ TDEAction *say;
+ TDEAction *shutup;
+ TDEAction *pause;
+ TDEAction *next_sentence;
+ TDEAction *prev_sentence;
private:
- KPopupMenu *menu;
+ TDEPopupMenu *menu;
KHelpMenu *help;
- KAction *settings;
- KAction *help_about;
- KAction *help_kde;
+ TDEAction *settings;
+ TDEAction *help_about;
+ TDEAction *help_kde;
State *_state;
};