summaryrefslogtreecommitdiffstats
path: root/languages/cpp/app_templates/kde4app
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-14 16:45:05 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-14 16:45:05 +0000
commit48d4a26399959121f33d2bc3bfe51c7827b654fc (patch)
tree5ae5e6e00d3ba330b7b8be9bc097154b6bc739e8 /languages/cpp/app_templates/kde4app
parent7e701ace6592d09e1f2c0cf28c7d6d872d78f4f5 (diff)
downloadtdevelop-48d4a26399959121f33d2bc3bfe51c7827b654fc.tar.gz
tdevelop-48d4a26399959121f33d2bc3bfe51c7827b654fc.zip
TQt4 port kdevelop
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1236710 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'languages/cpp/app_templates/kde4app')
-rw-r--r--languages/cpp/app_templates/kde4app/kapp4.cpp10
-rw-r--r--languages/cpp/app_templates/kde4app/kapp4.h1
-rw-r--r--languages/cpp/app_templates/kde4app/kapp4view.cpp2
-rw-r--r--languages/cpp/app_templates/kde4app/kapp4view.h5
-rw-r--r--languages/cpp/app_templates/kde4app/kapp4view_base.ui12
-rw-r--r--languages/cpp/app_templates/kde4app/kde4app-CMakeLists.txt2
-rw-r--r--languages/cpp/app_templates/kde4app/prefs_base.ui22
7 files changed, 28 insertions, 26 deletions
diff --git a/languages/cpp/app_templates/kde4app/kapp4.cpp b/languages/cpp/app_templates/kde4app/kapp4.cpp
index b73c02cb..bb91d42e 100644
--- a/languages/cpp/app_templates/kde4app/kapp4.cpp
+++ b/languages/cpp/app_templates/kde4app/kapp4.cpp
@@ -4,8 +4,8 @@
#include "%{APPNAMELC}view.h"
#include "settings.h"
-#include <QtGui/TQDropEvent>
-#include <QtGui/TQPainter>
+#include <TQtGui/TQDropEvent>
+#include <TQtGui/TQPainter>
#include <kconfigdialog.h>
#include <kstatusbar.h>
@@ -48,13 +48,13 @@
void %{APPNAME}::setupActions()
{
KStandardAction::openNew(this, TQT_SLOT(fileNew()), actionCollection());
- KStandardAction::quit(qApp, TQT_SLOT(quit()), actionCollection());
+ KStandardAction::quit(tqApp, TQT_SLOT(quit()), actionCollection());
KStandardAction::preferences(this, TQT_SLOT(optionsPreferences()), actionCollection());
// custom menu and menu item - the slot is in the class %{APPNAME}View
KAction *custom = new KAction(KIcon("colorize"), i18n("Swi&tch Colors"), this);
- actionCollection()->addAction( QLatin1String("switch_action"), custom );
+ actionCollection()->addAction( TQLatin1String("switch_action"), custom );
connect(custom, TQT_SIGNAL(triggered(bool)), m_view, TQT_SLOT(switchColors()));
}
@@ -83,7 +83,7 @@ void %{APPNAME}::optionsPreferences()
ui_prefs_base.setupUi(generalSettingsDlg);
dialog->addPage(generalSettingsDlg, i18n("General"), "package_setting");
connect(dialog, TQT_SIGNAL(settingsChanged(TQString)), m_view, TQT_SLOT(settingsChanged()));
- dialog->setAttribute( Qt::WA_DeleteOnClose );
+ dialog->setAttribute( TQt::WA_DeleteOnClose );
dialog->show();
}
diff --git a/languages/cpp/app_templates/kde4app/kapp4.h b/languages/cpp/app_templates/kde4app/kapp4.h
index fb059fde..1a15a7c7 100644
--- a/languages/cpp/app_templates/kde4app/kapp4.h
+++ b/languages/cpp/app_templates/kde4app/kapp4.h
@@ -23,6 +23,7 @@ class KUrl;
class %{APPNAME} : public KXmlGuiWindow
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Default Constructor
diff --git a/languages/cpp/app_templates/kde4app/kapp4view.cpp b/languages/cpp/app_templates/kde4app/kapp4view.cpp
index 785a6858..9d9e482a 100644
--- a/languages/cpp/app_templates/kde4app/kapp4view.cpp
+++ b/languages/cpp/app_templates/kde4app/kapp4view.cpp
@@ -3,7 +3,7 @@
#include "settings.h"
#include <klocale.h>
-#include <QtGui/TQLabel>
+#include <TQtGui/TQLabel>
%{APPNAME}View::%{APPNAME}View(TQWidget *)
{
diff --git a/languages/cpp/app_templates/kde4app/kapp4view.h b/languages/cpp/app_templates/kde4app/kapp4view.h
index 40749696..c4ce6517 100644
--- a/languages/cpp/app_templates/kde4app/kapp4view.h
+++ b/languages/cpp/app_templates/kde4app/kapp4view.h
@@ -2,7 +2,7 @@
#ifndef %{APPNAMELC}VIEW_H
#define %{APPNAMELC}VIEW_H
-#include <QtGui/TQWidget>
+#include <TQtGui/TQWidget>
#include "ui_%{APPNAMELC}view_base.h"
@@ -22,11 +22,12 @@ class KUrl;
class %{APPNAME}View : public TQWidget, public Ui::%{APPNAMELC}view_base
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Default constructor
*/
- %{APPNAME}View(TQWidget *parent);
+ %{APPNAME}View(TQWidget *tqparent);
/**
* Destructor
diff --git a/languages/cpp/app_templates/kde4app/kapp4view_base.ui b/languages/cpp/app_templates/kde4app/kapp4view_base.ui
index eb6a254a..92a83f43 100644
--- a/languages/cpp/app_templates/kde4app/kapp4view_base.ui
+++ b/languages/cpp/app_templates/kde4app/kapp4view_base.ui
@@ -1,6 +1,6 @@
<ui version="4.0" >
<class>%{APPNAMELC}view_base</class>
-<widget class="QWidget" name="%{APPNAMELC}view_base" >
+<widget class="TQWidget" name="%{APPNAMELC}view_base" >
<property name="geometry" >
<rect>
<x>0</x>
@@ -15,7 +15,7 @@
<property name="autoFillBackground" >
<bool>true</bool>
</property>
- <layout class="QGridLayout" >
+ <tqlayout class="TQGridLayout" >
<property name="leftMargin" >
<number>11</number>
</property>
@@ -35,7 +35,7 @@
<number>6</number>
</property>
<item row="0" column="0" >
- <widget class="QLabel" name="kcfg_sillyLabel" >
+ <widget class="TQLabel" name="kcfg_sillyLabel" >
<property name="palette" >
<palette>
<active>
@@ -196,7 +196,7 @@
<property name="scaledContents" >
<bool>true</bool>
</property>
- <property name="alignment" >
+ <property name="tqalignment" >
<set>Qt::AlignCenter</set>
</property>
<property name="wordWrap" >
@@ -204,9 +204,9 @@
</property>
</widget>
</item>
- </layout>
+ </tqlayout>
</widget>
- <layoutdefault spacing="6" margin="11" />
+ <tqlayoutdefault spacing="6" margin="11" />
<pixmapfunction>qPixmapFromMimeSource</pixmapfunction>
<resources/>
<connections/>
diff --git a/languages/cpp/app_templates/kde4app/kde4app-CMakeLists.txt b/languages/cpp/app_templates/kde4app/kde4app-CMakeLists.txt
index 2544a271..c29d33da 100644
--- a/languages/cpp/app_templates/kde4app/kde4app-CMakeLists.txt
+++ b/languages/cpp/app_templates/kde4app/kde4app-CMakeLists.txt
@@ -9,7 +9,7 @@ set(%{APPNAMELC}_SRCS
%{APPNAMELC}view.cpp
)
-#kde4_automoc(${%{APPNAMELC}_SRCS})
+#kde4_autotqmoc(${%{APPNAMELC}_SRCS})
kde4_add_ui_files(%{APPNAMELC}_SRCS %{APPNAMELC}view_base.ui prefs_base.ui)
diff --git a/languages/cpp/app_templates/kde4app/prefs_base.ui b/languages/cpp/app_templates/kde4app/prefs_base.ui
index ea400f02..98bf5f19 100644
--- a/languages/cpp/app_templates/kde4app/prefs_base.ui
+++ b/languages/cpp/app_templates/kde4app/prefs_base.ui
@@ -1,6 +1,6 @@
<ui version="4.0" >
<class>prefs_base</class>
- <widget class="QWidget" name="prefs_base" >
+ <widget class="TQWidget" name="prefs_base" >
<property name="geometry" >
<rect>
<x>0</x>
@@ -9,9 +9,9 @@
<height>156</height>
</rect>
</property>
- <layout class="QGridLayout" >
+ <tqlayout class="TQGridLayout" >
<item row="0" column="0" >
- <widget class="QLabel" name="textLabel2_2" >
+ <widget class="TQLabel" name="textLabel2_2" >
<property name="text" >
<string>Background color:</string>
</property>
@@ -37,7 +37,7 @@ p, li { white-space: pre-wrap; }
</widget>
</item>
<item row="2" column="0" >
- <widget class="QLabel" name="textLabel1" >
+ <widget class="TQLabel" name="textLabel1" >
<property name="text" >
<string>Project age:</string>
</property>
@@ -47,7 +47,7 @@ p, li { white-space: pre-wrap; }
</widget>
</item>
<item row="1" column="0" >
- <widget class="QLabel" name="textLabel2" >
+ <widget class="TQLabel" name="textLabel2" >
<property name="text" >
<string>Foreground color:</string>
</property>
@@ -80,7 +80,7 @@ p, li { white-space: pre-wrap; }
<property name="sizeType" >
<enum>QSizePolicy::Expanding</enum>
</property>
- <property name="sizeHint" >
+ <property name="tqsizeHint" >
<size>
<width>41</width>
<height>20</height>
@@ -96,7 +96,7 @@ p, li { white-space: pre-wrap; }
<property name="sizeType" >
<enum>QSizePolicy::Expanding</enum>
</property>
- <property name="sizeHint" >
+ <property name="tqsizeHint" >
<size>
<width>41</width>
<height>20</height>
@@ -105,7 +105,7 @@ p, li { white-space: pre-wrap; }
</spacer>
</item>
<item row="2" column="1" >
- <widget class="QSpinBox" name="kcfg_val_time" >
+ <widget class="TQSpinBox" name="kcfg_val_time" >
<property name="toolTip" >
<string>Set the project age (in days)</string>
</property>
@@ -128,7 +128,7 @@ p, li { white-space: pre-wrap; }
<property name="sizeType" >
<enum>QSizePolicy::Expanding</enum>
</property>
- <property name="sizeHint" >
+ <property name="tqsizeHint" >
<size>
<width>41</width>
<height>20</height>
@@ -136,9 +136,9 @@ p, li { white-space: pre-wrap; }
</property>
</spacer>
</item>
- </layout>
+ </tqlayout>
</widget>
- <layoutdefault spacing="6" margin="11" />
+ <tqlayoutdefault spacing="6" margin="11" />
<pixmapfunction>qPixmapFromMimeSource</pixmapfunction>
<customwidgets>
<customwidget>