diff options
Diffstat (limited to 'kapptemplate/kpartapp')
-rw-r--r-- | kapptemplate/kpartapp/app-Makefile.am | 2 | ||||
-rw-r--r-- | kapptemplate/kpartapp/app.cpp | 2 | ||||
-rw-r--r-- | kapptemplate/kpartapp/app.h | 1 | ||||
-rw-r--r-- | kapptemplate/kpartapp/app_part-desktop | 2 | ||||
-rw-r--r-- | kapptemplate/kpartapp/app_part.cpp | 14 | ||||
-rw-r--r-- | kapptemplate/kpartapp/app_part.h | 5 |
6 files changed, 14 insertions, 12 deletions
diff --git a/kapptemplate/kpartapp/app-Makefile.am b/kapptemplate/kpartapp/app-Makefile.am index 3aa0495f..fc096f65 100644 --- a/kapptemplate/kpartapp/app-Makefile.am +++ b/kapptemplate/kpartapp/app-Makefile.am @@ -10,7 +10,7 @@ INCLUDES = \$(all_includes) # these are the headers for your project noinst_HEADERS = ${APP_NAME_LC}.h ${APP_NAME_LC}_part.h -# let automoc handle all of the meta source files (moc) +# let autotqmoc handle all of the meta source files (tqmoc) METASOURCES = AUTO messages: rc.cpp diff --git a/kapptemplate/kpartapp/app.cpp b/kapptemplate/kpartapp/app.cpp index 626aa8bd..c5d21f06 100644 --- a/kapptemplate/kpartapp/app.cpp +++ b/kapptemplate/kpartapp/app.cpp @@ -152,7 +152,7 @@ void ${APP_NAME}::fileOpen() // the Open shortcut is pressed (usually CTRL+O) or the Open toolbar // button is clicked KURL url = - KFileDialog::getOpenURL( TQString::null, TQString::null, this ); + KFileDialog::getOpenURL( TQString(), TQString(), this ); if (url.isEmpty() == false) { diff --git a/kapptemplate/kpartapp/app.h b/kapptemplate/kpartapp/app.h index 41daea60..b9862c3b 100644 --- a/kapptemplate/kpartapp/app.h +++ b/kapptemplate/kpartapp/app.h @@ -21,6 +21,7 @@ cat << EOF > $LOCATION_ROOT/$APP_NAME_LC/${APP_NAME_LC}.h class ${APP_NAME} : public KParts::MainWindow { Q_OBJECT + TQ_OBJECT public: /** * Default Constructor diff --git a/kapptemplate/kpartapp/app_part-desktop b/kapptemplate/kpartapp/app_part-desktop index 6ba3bf54..b32923f6 100644 --- a/kapptemplate/kpartapp/app_part-desktop +++ b/kapptemplate/kpartapp/app_part-desktop @@ -3,7 +3,7 @@ cat << EOF > $LOCATION_ROOT/${APP_NAME_LC}/${APP_NAME_LC}_part.desktop [Desktop Entry] Encoding=UTF-8 Name=${APP_NAME}Part -MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;text/x-chdr;text/x-csrc;text/x-java;text/x-moc;text/x-pascal;text/x-tcl;text/x-tex;application/x-shellscript;text/x-c;text/x-c++; +MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;text/x-chdr;text/x-csrc;text/x-java;text/x-tqmoc;text/x-pascal;text/x-tcl;text/x-tex;application/x-shellscript;text/x-c;text/x-c++; ServiceTypes=KParts/ReadOnlyPart,KParts/ReadWritePart X-KDE-Library=lib${APP_NAME_LC}part Type=Service diff --git a/kapptemplate/kpartapp/app_part.cpp b/kapptemplate/kpartapp/app_part.cpp index d8880577..25bf0886 100644 --- a/kapptemplate/kpartapp/app_part.cpp +++ b/kapptemplate/kpartapp/app_part.cpp @@ -17,16 +17,16 @@ cat << EOF > $LOCATION_ROOT/${APP_NAME_LC}/${APP_NAME_LC}_part.cpp typedef KParts::GenericFactory<${APP_NAME}Part> ${APP_NAME}PartFactory; K_EXPORT_COMPONENT_FACTORY( lib${APP_NAME_LC}part, ${APP_NAME}PartFactory ) -${APP_NAME}Part::${APP_NAME}Part( TQWidget *parentWidget, const char *widgetName, - TQObject *parent, const char *name, +${APP_NAME}Part::${APP_NAME}Part( TQWidget *tqparentWidget, const char *widgetName, + TQObject *tqparent, const char *name, const TQStringList & /*args*/ ) - : KParts::ReadWritePart(parent, name) + : KParts::ReadWritePart(tqparent, name) { // we need an instance setInstance( ${APP_NAME}PartFactory::instance() ); // this should be your custom internal widget - m_widget = new TQMultiLineEdit( parentWidget, widgetName ); + m_widget = new TQMultiLineEdit( tqparentWidget, widgetName ); // notify the part that this is our internal widget setWidget(m_widget); @@ -79,7 +79,7 @@ void ${APP_NAME}Part::setModified(bool modified) else save->setEnabled(false); - // in any event, we want our parent to do it's thing + // in any event, we want our tqparent to do it's thing ReadWritePart::setModified(modified); } @@ -101,7 +101,7 @@ bool ${APP_NAME}Part::openFile() return false; // our example widget is text-based, so we use TQTextStream instead - // of a raw QDataStream + // of a raw TQDataStream TQTextStream stream(&file); TQString str; while (!stream.eof()) @@ -124,7 +124,7 @@ bool ${APP_NAME}Part::saveFile() if (isReadWrite() == false) return false; - // m_file is always local, so we use QFile + // m_file is always local, so we use TQFile TQFile file(m_file); if (file.open(IO_WriteOnly) == false) return false; diff --git a/kapptemplate/kpartapp/app_part.h b/kapptemplate/kpartapp/app_part.h index 75eedc4f..908adaa3 100644 --- a/kapptemplate/kpartapp/app_part.h +++ b/kapptemplate/kpartapp/app_part.h @@ -22,12 +22,13 @@ class KAboutData; class ${APP_NAME}Part : public KParts::ReadWritePart { Q_OBJECT + TQ_OBJECT public: /** * Default constructor */ - ${APP_NAME}Part(TQWidget *parentWidget, const char *widgetName, - TQObject *parent, const char *name, const TQStringList &args); + ${APP_NAME}Part(TQWidget *tqparentWidget, const char *widgetName, + TQObject *tqparent, const char *name, const TQStringList &args); /** * Destructor |