summaryrefslogtreecommitdiffstats
path: root/languages/cpp/app_templates/kpartapp
diff options
context:
space:
mode:
Diffstat (limited to 'languages/cpp/app_templates/kpartapp')
-rw-r--r--languages/cpp/app_templates/kpartapp/app.cpp24
-rw-r--r--languages/cpp/app_templates/kpartapp/app.h2
-rw-r--r--languages/cpp/app_templates/kpartapp/app_part.cpp26
-rw-r--r--languages/cpp/app_templates/kpartapp/app_part.h4
4 files changed, 28 insertions, 28 deletions
diff --git a/languages/cpp/app_templates/kpartapp/app.cpp b/languages/cpp/app_templates/kpartapp/app.cpp
index 759cbf5a..671017ee 100644
--- a/languages/cpp/app_templates/kpartapp/app.cpp
+++ b/languages/cpp/app_templates/kpartapp/app.cpp
@@ -53,8 +53,8 @@
// if we couldn't find our Part, we exit since the Shell by
// itself can't do anything useful
KMessageBox::error(this, i18n("Could not find our part."));
- kapp->quit();
- // we return here, cause kapp->quit() only means "exit the
+ tdeApp->quit();
+ // we return here, cause tdeApp->quit() only means "exit the
// next time we enter the event loop...
return;
}
@@ -76,16 +76,16 @@ void %{APPNAME}::load(const KURL& url)
void %{APPNAME}::setupActions()
{
- KStdAction::openNew(this, TQT_SLOT(fileNew()), actionCollection());
- KStdAction::open(this, TQT_SLOT(fileOpen()), actionCollection());
+ KStdAction::openNew(this, TQ_SLOT(fileNew()), actionCollection());
+ KStdAction::open(this, TQ_SLOT(fileOpen()), actionCollection());
- KStdAction::quit(kapp, TQT_SLOT(quit()), actionCollection());
+ KStdAction::quit(tdeApp, TQ_SLOT(quit()), actionCollection());
- m_toolbarAction = KStdAction::showToolbar(this, TQT_SLOT(optionsShowToolbar()), actionCollection());
- m_statusbarAction = KStdAction::showStatusbar(this, TQT_SLOT(optionsShowStatusbar()), actionCollection());
+ m_toolbarAction = KStdAction::showToolbar(this, TQ_SLOT(optionsShowToolbar()), actionCollection());
+ m_statusbarAction = KStdAction::showStatusbar(this, TQ_SLOT(optionsShowStatusbar()), actionCollection());
- KStdAction::keyBindings(this, TQT_SLOT(optionsConfigureKeys()), actionCollection());
- KStdAction::configureToolbars(this, TQT_SLOT(optionsConfigureToolbars()), actionCollection());
+ KStdAction::keyBindings(this, TQ_SLOT(optionsConfigureKeys()), actionCollection());
+ KStdAction::configureToolbars(this, TQ_SLOT(optionsConfigureToolbars()), actionCollection());
}
void %{APPNAME}::saveProperties(TDEConfig* /*config*/)
@@ -159,8 +159,8 @@ void %{APPNAME}::optionsConfigureToolbars()
// use the standard toolbar editor
KEditToolbar dlg(factory());
- connect(&dlg, TQT_SIGNAL(newToolbarConfig()),
- this, TQT_SLOT(applyNewToolbarConfig()));
+ connect(&dlg, TQ_SIGNAL(newToolbarConfig()),
+ this, TQ_SLOT(applyNewToolbarConfig()));
dlg.exec();
}
@@ -185,7 +185,7 @@ void %{APPNAME}::fileOpen()
KURL url =
KFileDialog::getOpenURL( TQString(), TQString(), this );
- if (url.isEmpty() == false)
+ if (!url.isEmpty())
{
// About this function, the style guide (
// http://developer.kde.org/documentation/standards/kde/style/basics/index.html )
diff --git a/languages/cpp/app_templates/kpartapp/app.h b/languages/cpp/app_templates/kpartapp/app.h
index b9101033..480680b7 100644
--- a/languages/cpp/app_templates/kpartapp/app.h
+++ b/languages/cpp/app_templates/kpartapp/app.h
@@ -21,7 +21,7 @@ class TDEToggleAction;
*/
class %{APPNAME} : public KParts::MainWindow
{
- Q_OBJECT
+ TQ_OBJECT
public:
/**
diff --git a/languages/cpp/app_templates/kpartapp/app_part.cpp b/languages/cpp/app_templates/kpartapp/app_part.cpp
index adf210b3..6365ef3b 100644
--- a/languages/cpp/app_templates/kpartapp/app_part.cpp
+++ b/languages/cpp/app_templates/kpartapp/app_part.cpp
@@ -1,7 +1,7 @@
#include "%{APPNAMELC}_part.h"
-#include <kinstance.h>
+#include <tdeinstance.h>
#include <tdeaction.h>
#include <kstdaction.h>
#include <tdefiledialog.h>
@@ -26,9 +26,9 @@
setWidget(m_widget);
// create our actions
- KStdAction::open(this, TQT_SLOT(fileOpen()), actionCollection());
- KStdAction::saveAs(this, TQT_SLOT(fileSaveAs()), actionCollection());
- KStdAction::save(this, TQT_SLOT(save()), actionCollection());
+ KStdAction::open(this, TQ_SLOT(fileOpen()), actionCollection());
+ KStdAction::saveAs(this, TQ_SLOT(fileSaveAs()), actionCollection());
+ KStdAction::save(this, TQ_SLOT(save()), actionCollection());
// set our XML-UI resource file
setXMLFile("%{APPNAMELC}_part.rc");
@@ -49,12 +49,12 @@ void %{APPNAME}Part::setReadWrite(bool rw)
// notify your internal widget of the read-write state
m_widget->setReadOnly(!rw);
if (rw)
- connect(m_widget, TQT_SIGNAL(textChanged()),
- this, TQT_SLOT(setModified()));
+ connect(m_widget, TQ_SIGNAL(textChanged()),
+ this, TQ_SLOT(setModified()));
else
{
- disconnect(m_widget, TQT_SIGNAL(textChanged()),
- this, TQT_SLOT(setModified()));
+ disconnect(m_widget, TQ_SIGNAL(textChanged()),
+ this, TQ_SLOT(setModified()));
}
ReadWritePart::setReadWrite(rw);
@@ -82,7 +82,7 @@ bool %{APPNAME}Part::openFile()
{
// m_file is always local so we can use TQFile on it
TQFile file(m_file);
- if (file.open(IO_ReadOnly) == false)
+ if (!file.open(IO_ReadOnly))
return false;
// our example widget is text-based, so we use TQTextStream instead
@@ -106,12 +106,12 @@ bool %{APPNAME}Part::openFile()
bool %{APPNAME}Part::saveFile()
{
// if we aren't read-write, return immediately
- if (isReadWrite() == false)
+ if (!isReadWrite())
return false;
// m_file is always local, so we use TQFile
TQFile file(m_file);
- if (file.open(IO_WriteOnly) == false)
+ if (!file.open(IO_WriteOnly))
return false;
// use TQTextStream to dump the text to the file
@@ -130,7 +130,7 @@ void %{APPNAME}Part::fileOpen()
// button is clicked
TQString file_name = KFileDialog::getOpenFileName();
- if (file_name.isEmpty() == false)
+ if (!file_name.isEmpty())
openURL(file_name);
}
@@ -138,7 +138,7 @@ void %{APPNAME}Part::fileSaveAs()
{
// this slot is called whenever the File->Save As menu is selected,
TQString file_name = KFileDialog::getSaveFileName();
- if (file_name.isEmpty() == false)
+ if (!file_name.isEmpty())
saveAs(file_name);
}
diff --git a/languages/cpp/app_templates/kpartapp/app_part.h b/languages/cpp/app_templates/kpartapp/app_part.h
index 6ea44663..39e3827b 100644
--- a/languages/cpp/app_templates/kpartapp/app_part.h
+++ b/languages/cpp/app_templates/kpartapp/app_part.h
@@ -20,7 +20,7 @@ class TQMultiLineEdit;
*/
class %{APPNAME}Part : public KParts::ReadWritePart
{
- Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -70,7 +70,7 @@ class TDEAboutData;
class %{APPNAME}PartFactory : public KParts::Factory
{
- Q_OBJECT
+ TQ_OBJECT
public:
%{APPNAME}PartFactory();