diff options
author | Slávek Banko <slavek.banko@axis.cz> | 2016-03-26 12:41:49 +0100 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2016-03-26 14:15:13 +0100 |
commit | ea0a6815c10291d1ae30029f5183e3eaaf838fda (patch) | |
tree | e522c735ad703edee863c5d490f519f9cf713120 /kxmleditor | |
parent | 38dca4b75c471ddf950e2f9f03801c550d7d26fd (diff) | |
download | kxmleditor-ea0a6815c10291d1ae30029f5183e3eaaf838fda.tar.gz kxmleditor-ea0a6815c10291d1ae30029f5183e3eaaf838fda.zip |
Initial TDE conversion
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
Diffstat (limited to 'kxmleditor')
-rw-r--r-- | kxmleditor/Makefile.am | 6 | ||||
-rw-r--r-- | kxmleditor/kxmleditor.desktop | 4 | ||||
-rw-r--r-- | kxmleditor/kxmleditorshell.cpp | 38 | ||||
-rw-r--r-- | kxmleditor/kxmleditorshell.h | 24 | ||||
-rw-r--r-- | kxmleditor/main.cpp | 22 |
5 files changed, 47 insertions, 47 deletions
diff --git a/kxmleditor/Makefile.am b/kxmleditor/Makefile.am index 16a0017..f0ae227 100644 --- a/kxmleditor/Makefile.am +++ b/kxmleditor/Makefile.am @@ -1,10 +1,10 @@ -####### kdevelop will overwrite this part!!! (begin)########## +####### tdevelop will overwrite this part!!! (begin)########## bin_PROGRAMS = kxmleditor kxmleditor_SOURCES = dcopiface_shell.skel dcopiface_shell.cpp kxmleditorshell.cpp main.cpp kxeshellmanager.cpp kxmleditor_LDFLAGS = $(all_libraries) $(KDE_RPATH) -kxmleditor_LDADD = $(LIB_KPARTS) $(LIB_KIO) $(LIB_KDEUI) $(LIB_KDECORE) $(LIB_QT) $(LIBSOCKET) -lDCOP +kxmleditor_LDADD = $(LIB_TDEPARTS) $(LIB_TDEIO) $(LIB_TDEUI) $(LIB_TDECORE) $(LIB_QT) $(LIBSOCKET) -lDCOP EXTRA_DIST = main.cpp \ kxmleditor.desktop \ @@ -19,7 +19,7 @@ uninstall-local: -rm -f $(kde_appsdir)/Applications/kxmleditor.desktop -rmdir $(kde_appsdir)/Applications -####### kdevelop will overwrite this part!!! (end)############ +####### tdevelop will overwrite this part!!! (end)############ # this 10 paths are KDE specific. Use them: # kde_htmldir Where your docs should go to. (contains lang subdirs) # kde_appsdir Where your application file (.kdelnk) should go to. diff --git a/kxmleditor/kxmleditor.desktop b/kxmleditor/kxmleditor.desktop index 556f62a..ed28f4d 100644 --- a/kxmleditor/kxmleditor.desktop +++ b/kxmleditor/kxmleditor.desktop @@ -2,11 +2,11 @@ Type=Application Exec=kxmleditor -caption "%c" %i %m Icon=kxmleditor.png -DocPath=kxmleditor/index.html +X-DocPath=kxmleditor/index.html Comment=XML editor Comment[fi]=XML-editori Terminal=false Name=KXML Editor MimeType=text/xml; Encoding=UTF-8 -Categories=Application;Development;TextEditor;KDE; +Categories=Application;Development;TextEditor;TDE; diff --git a/kxmleditor/kxmleditorshell.cpp b/kxmleditor/kxmleditorshell.cpp index 8299bc3..5e6b2ba 100644 --- a/kxmleditor/kxmleditorshell.cpp +++ b/kxmleditor/kxmleditorshell.cpp @@ -25,18 +25,18 @@ #include <klibloader.h> #include <kstdaction.h> -#include <kapplication.h> -#include <klocale.h> +#include <tdeapplication.h> +#include <tdelocale.h> #include <kdebug.h> -#include <kfiledialog.h> +#include <tdefiledialog.h> #include <kkeydialog.h> #include <kedittoolbar.h> #include <kstatusbar.h> -#include <kparts/browserextension.h> -#include <kparts/partmanager.h> -#include <kmessagebox.h> +#include <tdeparts/browserextension.h> +#include <tdeparts/partmanager.h> +#include <tdemessagebox.h> -#include <kpopupmenu.h> +#include <tdepopupmenu.h> #include <tqevent.h> @@ -60,10 +60,10 @@ KXMLEditorShell::KXMLEditorShell( const char * name, WFlags f ) KStdAction::open( this, SLOT(slotFileOpen()), actionCollection() ); m_pActFileOpenRecent = KStdAction::openRecent( this, SLOT(slotFileOpenRecent(const KURL&)), actionCollection() ); m_pActFileOpenRecent->loadEntries( instance()->config() ); - m_pActReload = new KAction( i18n("Reloa&d"), "reload", Key_F5, this, SLOT(slotFileReload()), actionCollection(), "reload" ); + m_pActReload = new TDEAction( i18n("Reloa&d"), "reload", Key_F5, this, SLOT(slotFileReload()), actionCollection(), "reload" ); - KToggleAction * pActToggleMainToolBar = KStdAction::showToolbar( this, SLOT(slotToggleMainToolBar()), actionCollection() ); - KToggleAction * pActToggleStatusBar = KStdAction::showStatusbar( this, SLOT(slotToggleStatusBar()), actionCollection() ); + TDEToggleAction * pActToggleMainToolBar = KStdAction::showToolbar( this, SLOT(slotToggleMainToolBar()), actionCollection() ); + TDEToggleAction * pActToggleStatusBar = KStdAction::showStatusbar( this, SLOT(slotToggleStatusBar()), actionCollection() ); KStdAction::keyBindings( this, SLOT(slotConfigureKeys()), actionCollection() ); KStdAction::configureToolbars( this, SLOT(slotConfigureToolbars()), actionCollection() ); @@ -73,9 +73,9 @@ KXMLEditorShell::KXMLEditorShell( const char * name, WFlags f ) // L.V. moved to part pActPrint = KStdAction::print( 0, 0, actionCollection(), "print" ); - pActCloseW = new KAction( i18n("&Close"), 0, 0, this,SLOT(slotActWindowClose()), actionCollection(), "window_close" ); - pActCloseAllW = new KAction( i18n("Close &all"), 0, 0, this,SLOT(slotActWindowCloseAll()), actionCollection(), "window_close_all" ); - pActCloseAllO = new KAction( i18n("Close all &others"), 0, 0, this,SLOT(slotActWindowCloseAllOthers()), actionCollection(), "window_close_all_others" ); + pActCloseW = new TDEAction( i18n("&Close"), 0, 0, this,SLOT(slotActWindowClose()), actionCollection(), "window_close" ); + pActCloseAllW = new TDEAction( i18n("Close &all"), 0, 0, this,SLOT(slotActWindowCloseAll()), actionCollection(), "window_close_all" ); + pActCloseAllO = new TDEAction( i18n("Close all &others"), 0, 0, this,SLOT(slotActWindowCloseAllOthers()), actionCollection(), "window_close_all_others" ); ////////////////////////////// // CREATE STATUSBAR @@ -247,7 +247,7 @@ bool KXMLEditorShell::queryClose() return KParts::MainWindow::queryClose(); } -void KXMLEditorShell::saveProperties( KConfig * pConfig ) +void KXMLEditorShell::saveProperties( TDEConfig * pConfig ) { if (part()) { @@ -256,7 +256,7 @@ void KXMLEditorShell::saveProperties( KConfig * pConfig ) KParts::MainWindow::saveProperties(pConfig); } -void KXMLEditorShell::readProperties( KConfig * pConfig ) +void KXMLEditorShell::readProperties( TDEConfig * pConfig ) { KParts::MainWindow::readProperties(pConfig); @@ -268,7 +268,7 @@ void KXMLEditorShell::readProperties( KConfig * pConfig ) void KXMLEditorShell::slotEnableBrowserExtActions( const char * pszName, bool bEnabled ) { - KAction * pAct = actionCollection()->action( pszName ); + TDEAction * pAct = actionCollection()->action( pszName ); if ( pAct ) pAct->setEnabled( bEnabled ); else @@ -391,7 +391,7 @@ void KXMLEditorShell::setPart(KParts::ReadWritePart* pPart) } // keep pointer to window menu - m_windowMenu = static_cast<KPopupMenu*>(factory()->container("window", this)); + m_windowMenu = static_cast<TDEPopupMenu*>(factory()->container("window", this)); if(!m_windowMenu) kdDebug() << "KXMLEditorShell::setPart - m_windowMenu is NULL" << endl; else @@ -424,7 +424,7 @@ void KXMLEditorShell::close() { if (queryClose()) { - if (KMainWindow::memberList->count()==1) + if (TDEMainWindow::memberList->count()==1) kapp->deref(); delete this; } @@ -432,7 +432,7 @@ void KXMLEditorShell::close() void KXMLEditorShell::slotActWindowCloseAllOthers() { - TQPtrListIterator<KMainWindow> it(*KMainWindow::memberList); + TQPtrListIterator<TDEMainWindow> it(*TDEMainWindow::memberList); for (it.toFirst();it.current();++it) { if (it.current()!=this) diff --git a/kxmleditor/kxmleditorshell.h b/kxmleditor/kxmleditorshell.h index 1f0f0a1..b5f47e0 100644 --- a/kxmleditor/kxmleditorshell.h +++ b/kxmleditor/kxmleditorshell.h @@ -22,11 +22,11 @@ #ifndef KXMLEDITORSHELL_H #define KXMLEDITORSHELL_H -#include <kparts/mainwindow.h> +#include <tdeparts/mainwindow.h> class KParts::ReadWritePart; class KXMLEditorShellIface; -class KAction; +class TDEAction; class KXEShellManager; @@ -103,7 +103,7 @@ class KXMLEditorShell : public KParts::MainWindow The application will try to start default mail client and prepare new empty mail with currently opened file as an attachment. The file have to be saved first on a disc. - @sa KApplication::invokeMailer() + @sa TDEApplication::invokeMailer() */ void mail(); @@ -128,24 +128,24 @@ class KXMLEditorShell : public KParts::MainWindow protected: virtual bool queryClose(); - virtual void saveProperties( KConfig * ); - virtual void readProperties( KConfig * ); + virtual void saveProperties( TDEConfig * ); + virtual void readProperties( TDEConfig * ); /** @short Stores pointer to currenly shown part. */ KParts::ReadWritePart * m_pPart; /** @short Action for recently opened files. */ - KRecentFilesAction * m_pActFileOpenRecent; + TDERecentFilesAction * m_pActFileOpenRecent; /** @short Action for reloading the document currently open. */ - KAction * m_pActReload; + TDEAction * m_pActReload; /** @short Action for printing complete XML files.*/ - // L.V. moved to part. KAction* pActPrint; + // L.V. moved to part. TDEAction* pActPrint; - KAction* pActCloseW; - KAction* pActCloseAllW; - KAction* pActCloseAllO; + TDEAction* pActCloseW; + TDEAction* pActCloseAllW; + TDEAction* pActCloseAllO; /** @short DCOP interface pointer (if no such iface pointer == 0).*/ KXMLEditorShellIface * m_pKXEShellIface; @@ -153,7 +153,7 @@ class KXMLEditorShell : public KParts::MainWindow /** @short Stores pointer to window menu. This menu is expanded everytime new shell is shown. */ - KPopupMenu* m_windowMenu; + TDEPopupMenu* m_windowMenu; /** @short Returns currently shown part. */ KParts::ReadWritePart* part() const {return m_pPart;} diff --git a/kxmleditor/main.cpp b/kxmleditor/main.cpp index 0bbfc79..7c7726f 100644 --- a/kxmleditor/main.cpp +++ b/kxmleditor/main.cpp @@ -15,12 +15,12 @@ * * ***************************************************************************/ -#include <kapplication.h> -#include <kcmdlineargs.h> -#include <kaboutdata.h> -#include <klocale.h> +#include <tdeapplication.h> +#include <tdecmdlineargs.h> +#include <tdeaboutdata.h> +#include <tdelocale.h> #include <kdebug.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <dcopclient.h> //#include "kxmleditor.h" @@ -28,7 +28,7 @@ #include "kxmleditorshell.h" -static KCmdLineOptions options[] = +static TDECmdLineOptions options[] = { { "+[File(s)]", I18N_NOOP("XML file(s) to open"), 0 }, { 0, 0, 0 } @@ -40,10 +40,10 @@ static KCmdLineOptions options[] = /** @short Main application function that starts-up the application */ int main(int argc, char *argv[]) { - KCmdLineArgs::init( argc, argv, new KXMLEditorAboutData() ); - KCmdLineArgs::addCmdLineOptions( options ); // Add our own options. + TDECmdLineArgs::init( argc, argv, new KXMLEditorAboutData() ); + TDECmdLineArgs::addCmdLineOptions( options ); // Add our own options. - KApplication app; + TDEApplication app; // comment the following lines to use KXMLEditorShell instead of KXMLEditorApp #if ! USE_KPART @@ -55,7 +55,7 @@ int main(int argc, char *argv[]) KXMLEditorApp *kxmleditor = new KXMLEditorApp(); kxmleditor->show(); - KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); + TDECmdLineArgs *args = TDECmdLineArgs::parsedArgs(); if(args->count()) { TQString strPath; @@ -84,7 +84,7 @@ int main(int argc, char *argv[]) } else { - KCmdLineArgs * pArgs = KCmdLineArgs::parsedArgs(); + TDECmdLineArgs * pArgs = TDECmdLineArgs::parsedArgs(); KXMLEditorShell * pShell; bool bNoCorrectInstance = true; if ( pArgs->count() > 0 ) |