summaryrefslogtreecommitdiffstats
path: root/languages/cpp/pcsimporter
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2023-07-13 21:45:56 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2023-07-14 10:21:01 +0900
commit5c50dcac16345515a81f7de5766fa240eaa99d31 (patch)
treef90ca08ef922a837ef270d3654a00a879487ff76 /languages/cpp/pcsimporter
parent14334c54280493270f175de52c28170cf14f50a3 (diff)
downloadtdevelop-5c50dcac16345515a81f7de5766fa240eaa99d31.tar.gz
tdevelop-5c50dcac16345515a81f7de5766fa240eaa99d31.zip
Removed Qt4 specific code and template files
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it> (cherry picked from commit 60598ea23e9fec7b4320985aad848c5ffee033c2)
Diffstat (limited to 'languages/cpp/pcsimporter')
-rw-r--r--languages/cpp/pcsimporter/CMakeLists.txt1
-rw-r--r--languages/cpp/pcsimporter/Makefile.am2
-rw-r--r--languages/cpp/pcsimporter/qt4importer/CMakeLists.txt42
-rw-r--r--languages/cpp/pcsimporter/qt4importer/Makefile.am11
-rw-r--r--languages/cpp/pcsimporter/qt4importer/kdevqt4importer.cpp107
-rw-r--r--languages/cpp/pcsimporter/qt4importer/kdevqt4importer.desktop11
-rw-r--r--languages/cpp/pcsimporter/qt4importer/kdevqt4importer.h40
-rw-r--r--languages/cpp/pcsimporter/qt4importer/settingsdialog.cpp112
-rw-r--r--languages/cpp/pcsimporter/qt4importer/settingsdialog.h47
-rw-r--r--languages/cpp/pcsimporter/qt4importer/settingsdialogbase.ui80
10 files changed, 1 insertions, 452 deletions
diff --git a/languages/cpp/pcsimporter/CMakeLists.txt b/languages/cpp/pcsimporter/CMakeLists.txt
index 2f904a5d..f734da91 100644
--- a/languages/cpp/pcsimporter/CMakeLists.txt
+++ b/languages/cpp/pcsimporter/CMakeLists.txt
@@ -12,4 +12,3 @@
add_subdirectory( qtimporter )
add_subdirectory( tdelibsimporter )
add_subdirectory( customimporter )
-add_subdirectory( qt4importer )
diff --git a/languages/cpp/pcsimporter/Makefile.am b/languages/cpp/pcsimporter/Makefile.am
index 31533b36..9a7e1bb4 100644
--- a/languages/cpp/pcsimporter/Makefile.am
+++ b/languages/cpp/pcsimporter/Makefile.am
@@ -1,3 +1,3 @@
INCLUDES =
METASOURCES = AUTO
-SUBDIRS = qtimporter tdelibsimporter customimporter qt4importer
+SUBDIRS = qtimporter tdelibsimporter customimporter
diff --git a/languages/cpp/pcsimporter/qt4importer/CMakeLists.txt b/languages/cpp/pcsimporter/qt4importer/CMakeLists.txt
deleted file mode 100644
index 509a4f16..00000000
--- a/languages/cpp/pcsimporter/qt4importer/CMakeLists.txt
+++ /dev/null
@@ -1,42 +0,0 @@
-#################################################
-#
-# (C) 2010-2011 Serghei Amelian
-# serghei (DOT) amelian (AT) gmail.com
-#
-# Improvements and feedback are welcome
-#
-# This file is released under GPL >= 2
-#
-#################################################
-
-include_directories(
- ${CMAKE_CURRENT_BINARY_DIR}
- ${CMAKE_SOURCE_DIR}/languages/lib/interfaces
- ${CMAKE_SOURCE_DIR}/lib/interfaces
- ${TDE_INCLUDE_DIR}
- ${TQT_INCLUDE_DIRS}
-)
-
-link_directories(
- ${TQT_LIBRARY_DIRS}
-)
-
-
-##### other data ################################
-
-tde_create_translated_desktop(
- SOURCE kdevqt4importer.desktop
- DESTINATION ${SERVICES_INSTALL_DIR}
- PO_DIR tdevelop-desktops
-)
-
-
-##### libkdevqt4importer (module) ###############
-
-tde_add_kpart( libkdevqt4importer AUTOMOC
- SOURCES
- kdevqt4importer.cpp settingsdialogbase.ui
- settingsdialog.cpp
- LINK lang_interfaces-shared tdevelop-shared
- DESTINATION ${PLUGIN_INSTALL_DIR}
-)
diff --git a/languages/cpp/pcsimporter/qt4importer/Makefile.am b/languages/cpp/pcsimporter/qt4importer/Makefile.am
deleted file mode 100644
index 12f12104..00000000
--- a/languages/cpp/pcsimporter/qt4importer/Makefile.am
+++ /dev/null
@@ -1,11 +0,0 @@
-INCLUDES = -I$(top_srcdir)/languages/lib/interfaces \
- -I$(top_srcdir)/lib/interfaces $(all_includes)
-METASOURCES = AUTO
-kde_module_LTLIBRARIES = libkdevqt4importer.la
-
-noinst_HEADERS = kdevqt4importer.h settingsdialog.h
-libkdevqt4importer_la_SOURCES = kdevqt4importer.cpp settingsdialogbase.ui settingsdialog.cpp
-kde_services_DATA = kdevqt4importer.desktop
-libkdevqt4importer_la_LIBADD = $(top_builddir)/lib/libtdevelop.la \
- $(top_builddir)/languages/lib/interfaces/liblang_interfaces.la
-libkdevqt4importer_la_LDFLAGS = -module $(all_libraries) $(KDE_PLUGIN)
diff --git a/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.cpp b/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.cpp
deleted file mode 100644
index 0289c7a4..00000000
--- a/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.cpp
+++ /dev/null
@@ -1,107 +0,0 @@
-/***************************************************************************
- * Copyright (C) 2003 by Roberto Raggi *
- * roberto@kdevelop.org *
- * *
- * This program is free software; you can redistribute it and/or modify *
- * it under the terms of the GNU General Public License as published by *
- * the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
- * *
- ***************************************************************************/
-
-#include "kdevqt4importer.h"
-#include "kdevqt4importer.moc"
-#include "settingsdialog.h"
-
-#include <kgenericfactory.h>
-#include <tdetempfile.h>
-#include <kprocess.h>
-#include <kdebug.h>
-
-#include <tqtextstream.h>
-#include <tqlabel.h>
-#include <tqdir.h>
-
-K_EXPORT_COMPONENT_FACTORY( libkdevqt4importer, KGenericFactory<KDevQt4Importer>( "kdevqt4importer" ) )
-
-KDevQt4Importer::KDevQt4Importer( TQObject * parent, const char * name, const TQStringList& )
- : KDevPCSImporter( parent, name )
-{
- m_qtfile = 0;
-}
-
-KDevQt4Importer::~KDevQt4Importer()
-{
- if (m_qtfile)
- delete m_qtfile;
-
- m_qtfile = 0;
-}
-
-TQStringList KDevQt4Importer::fileList()
-{
- if( !m_settings )
- return TQStringList();
-
- if (m_qtfile)
- delete m_qtfile;
-
- KTempFile ifile;
- TQTextStream &is = *ifile.textStream();
-
- is << "#include <TQtCore/tqobjectdefs.h>\n"
- << "#undef slots\n#undef signals\n#undef slots\n#undef signals"
- << "#define slots slots\n"
- << "#define signals signals\n"
- << "#include <TQtCore/TQtCore>\n"
- << "#include <TQtGui/TQtGui>\n"
- << "#include <TQtNetwork/TQtNetwork>\n"
- << "#include <TQtXml/TQtXml>\n"
- << "#include <TQt3Support/TQt3Support>\n"
- << "#include <TQtSql/TQtSql>\n"
- << "#include <TQtTest/TQtTest>\n"
- << "#include <TQtOpenGL/TQtOpenGL>\n";
-
-
-
- TDEProcess proc;
- proc << "cpp" << "-nostdinc" << "-xc++";
-
- m_qtfile = new KTempFile();
-
- // include paths
- TQStringList paths = includePaths();
- for (TQStringList::Iterator it = paths.begin(); it != paths.end(); ++it)
- proc << "-I" << *it;
-
- ifile.close();
-
- TQString o;
- o += "-o";
- o += m_qtfile->name();
-
- proc << ifile.name() << o;
- proc.start(TDEProcess::Block);
-
- return m_qtfile->name();
-}
-
-TQStringList KDevQt4Importer::includePaths()
-{
- if( !m_settings || !m_qtfile)
- return TQStringList();
-
- TQStringList includePaths;
- includePaths.push_back( m_settings->qtDir() );
- includePaths.push_back( m_settings->qtDir() + "/TQt" );
-
- /// @todo add mkspec
- return includePaths;
-}
-
-TQWidget * KDevQt4Importer::createSettingsPage( TQWidget * parent, const char * name )
-{
- m_settings = new SettingsDialog( parent, name );
- return m_settings;
-}
-
diff --git a/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.desktop b/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.desktop
deleted file mode 100644
index cd7697ee..00000000
--- a/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.desktop
+++ /dev/null
@@ -1,11 +0,0 @@
-[Desktop Entry]
-Name=KDevQt4Importer
-
-Comment=TDevelop Qt4 PCS Importer
-
-Type=Service
-Icon=gear
-X-TDE-ServiceTypes=TDevelop/PCSImporter
-X-TDE-Library=libkdevqt4importer
-X-TDevelop-PCSImporter=
-X-TDevelop-Version=5
diff --git a/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.h b/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.h
deleted file mode 100644
index 3b9563f3..00000000
--- a/languages/cpp/pcsimporter/qt4importer/kdevqt4importer.h
+++ /dev/null
@@ -1,40 +0,0 @@
-/***************************************************************************
- * Copyright (C) 2003 by Roberto Raggi *
- * roberto@kdevelop.org *
- * *
- * This program is free software; you can redistribute it and/or modify *
- * it under the terms of the GNU General Public License as published by *
- * the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
- * *
- ***************************************************************************/
-
-#ifndef KDEVTQTIMPORTER_H
-#define KDEVTQTIMPORTER_H
-
-#include <kdevpcsimporter.h>
-#include <tqguardedptr.h>
-
-class SettingsDialog;
-class KTempFile;
-
-class KDevQt4Importer : public KDevPCSImporter
-{
- Q_OBJECT
-
-public:
- KDevQt4Importer( TQObject* parent=0, const char* name=0, const TQStringList& args=TQStringList() );
- virtual ~KDevQt4Importer();
-
- virtual TQString dbName() const { return TQString::fromLatin1("TQt4"); }
- virtual TQStringList fileList();
- virtual TQStringList includePaths();
-
- virtual TQWidget* createSettingsPage( TQWidget* parent, const char* name=0 );
-
-private:
- TQGuardedPtr<SettingsDialog> m_settings;
- KTempFile *m_qtfile;
-};
-
-#endif
diff --git a/languages/cpp/pcsimporter/qt4importer/settingsdialog.cpp b/languages/cpp/pcsimporter/qt4importer/settingsdialog.cpp
deleted file mode 100644
index 22c5b666..00000000
--- a/languages/cpp/pcsimporter/qt4importer/settingsdialog.cpp
+++ /dev/null
@@ -1,112 +0,0 @@
-/***************************************************************************
- * Copyright (C) 2003 by Roberto Raggi *
- * roberto@kdevelop.org *
- * *
- * Copyright (C) 2006 by Jens Dagerbo *
- * jens.dagerbo@swipnet.se *
- * *
- * This program is free software; you can redistribute it and/or modify *
- * it under the terms of the GNU General Public License as published by *
- * the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
- * *
- ***************************************************************************/
-
-#include <tdelistbox.h>
-#include <kcombobox.h>
-#include <kurlrequester.h>
-#include <kdebug.h>
-#include <klineedit.h>
-#include <tdemessagebox.h>
-#include <tdelocale.h>
-
-#include <tqfile.h>
-#include <tqdir.h>
-#include <tqregexp.h>
-#include <cstdlib>
-
-#include "settingsdialog.h"
-
-TQListBoxItem* TQListBox_selectedItem(TQListBox* cpTQListBox)
-{
- if ( cpTQListBox->selectionMode() != TQListBox::Single )
- return 0;
- if ( cpTQListBox->isSelected( cpTQListBox->currentItem() ) )
- return cpTQListBox->item(cpTQListBox->currentItem());
- return 0;
-}
-
-SettingsDialog::SettingsDialog(TQWidget* parent, const char* name, WFlags fl)
- : SettingsDialogBase(parent,name,fl)
-{
- TQStringList qtdirs;
- qtdirs.push_back( ::getenv("TQTDIR") + TQString("/include") );
- qtdirs.push_back( TQString::fromLocal8Bit(::getenv("HOME")) + "/dev/qt/include" );
- qtdirs.push_back( TQString::fromLocal8Bit(::getenv("HOME")) + "/dev/qt-main/include" );
- qtdirs.push_back( "/usr/qt/4/include" );
-
- for( TQStringList::Iterator it=qtdirs.begin(); it!=qtdirs.end(); ++it )
- {
- TQString qtdir = *it;
- if( !qtdir.isEmpty() && isValidTQtDir(qtdir) )
- if (!qtListBox->findItem(qtdir, ExactMatch))
- qtListBox->insertItem( qtdir );
- }
-
- qtUrl->setMode( KFile::Directory | KFile::ExistingOnly | KFile::LocalOnly );
-
- connect( addUrlButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(addUrlButton_clicked()) );
-}
-
-SettingsDialog::~SettingsDialog()
-{
-}
-
-void SettingsDialog::slotSelectionChanged(TQListBoxItem* item)
-{
- if( !qtListBox->selectedItem() )
- {
- emit enabled( false );
- return;
- }
-
-
- emit enabled( true );
-}
-
-bool SettingsDialog::isValidTQtDir( const TQString & path ) const
-{
- return TQFile::exists( path + "/TQtCore/TQtCore" );
-}
-
-TQString SettingsDialog::qtDir( ) const
-{
- return qtListBox->currentText();
-}
-
-TQString SettingsDialog::configuration( ) const
-{
- return "";
-}
-
-void SettingsDialog::addUrlButton_clicked( )
-{
- kdDebug(9000) << k_funcinfo << endl;
-
- if ( isValidTQtDir( qtUrl->url() ) )
- {
- qtListBox->insertItem( qtUrl->url() );
- if ( TQListBoxItem * item = qtListBox->findItem( qtUrl->url(), ExactMatch ) )
- {
- qtListBox->setSelected( item, true );
- }
- qtUrl->lineEdit()->clear();
- }
- else
- {
- KMessageBox::error( this, i18n("This does not appear to be a valid TQt4 include directory.\nPlease select a different directory."), i18n("Invalid Directory") );
- }
-}
-
-
-#include "settingsdialog.moc"
diff --git a/languages/cpp/pcsimporter/qt4importer/settingsdialog.h b/languages/cpp/pcsimporter/qt4importer/settingsdialog.h
deleted file mode 100644
index 32065973..00000000
--- a/languages/cpp/pcsimporter/qt4importer/settingsdialog.h
+++ /dev/null
@@ -1,47 +0,0 @@
-/***************************************************************************
- * Copyright (C) 2003 by Roberto Raggi *
- * roberto@kdevelop.org *
- * *
- * This program is free software; you can redistribute it and/or modify *
- * it under the terms of the GNU General Public License as published by *
- * the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
- * *
- ***************************************************************************/
-
-#ifndef SETTINGSDIALOG_H
-#define SETTINGSDIALOG_H
-
-#include "settingsdialogbase.h"
-
-class SettingsDialog : public SettingsDialogBase
-{
- Q_OBJECT
-
-
-public:
- SettingsDialog(TQWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
- ~SettingsDialog();
- /*$PUBLIC_FUNCTIONS$*/
-
- bool isValidTQtDir( const TQString& path ) const;
-
- TQString qtDir() const;
- TQString configuration() const;
-
-public slots:
- /*$PUBLIC_SLOTS$*/
- virtual void slotSelectionChanged(TQListBoxItem*);
-
-protected:
- /*$PROTECTED_FUNCTIONS$*/
-
-protected slots:
- /*$PROTECTED_SLOTS$*/
- void addUrlButton_clicked();
-
-};
-
-#endif
-
-
diff --git a/languages/cpp/pcsimporter/qt4importer/settingsdialogbase.ui b/languages/cpp/pcsimporter/qt4importer/settingsdialogbase.ui
deleted file mode 100644
index b0a48d2a..00000000
--- a/languages/cpp/pcsimporter/qt4importer/settingsdialogbase.ui
+++ /dev/null
@@ -1,80 +0,0 @@
-<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
-<class>SettingsDialogBase</class>
-<widget class="TQWidget">
- <property name="name">
- <cstring>SettingsDialogBase</cstring>
- </property>
- <property name="geometry">
- <rect>
- <x>0</x>
- <y>0</y>
- <width>346</width>
- <height>275</height>
- </rect>
- </property>
- <grid>
- <property name="name">
- <cstring>unnamed</cstring>
- </property>
- <widget class="TQLabel" row="0" column="0" rowspan="1" colspan="2">
- <property name="name">
- <cstring>textLabel1_2</cstring>
- </property>
- <property name="text">
- <string>Qt4 include directories:
-Only the selected entry will be used</string>
- </property>
- </widget>
- <widget class="TQPushButton" row="2" column="1">
- <property name="name">
- <cstring>addUrlButton</cstring>
- </property>
- <property name="sizePolicy">
- <sizepolicy>
- <hsizetype>0</hsizetype>
- <vsizetype>0</vsizetype>
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="text">
- <string>&amp;Add</string>
- </property>
- </widget>
- <widget class="KURLRequester" row="2" column="0">
- <property name="name">
- <cstring>qtUrl</cstring>
- </property>
- </widget>
- <widget class="TDEListBox" row="1" column="0" rowspan="1" colspan="2">
- <property name="name">
- <cstring>qtListBox</cstring>
- </property>
- </widget>
- </grid>
-</widget>
-<customwidgets>
-</customwidgets>
-<connections>
- <connection>
- <sender>qtListBox</sender>
- <signal>selectionChanged(TQListBoxItem*)</signal>
- <receiver>SettingsDialogBase</receiver>
- <slot>slotSelectionChanged(TQListBoxItem*)</slot>
- </connection>
-</connections>
-<forwards>
- <forward>class TQListBoxItem;</forward>
-</forwards>
-<Q_SIGNALS>
- <signal>enabled(int)</signal>
-</Q_SIGNALS>
-<Q_SLOTS>
- <slot>slotSelectionChanged(TQListBoxItem*)</slot>
-</Q_SLOTS>
-<layoutdefaults spacing="6" margin="11"/>
-<includes>
- <include location="global" impldecl="in implementation">kurlrequester.h</include>
- <include location="global" impldecl="in implementation">tdelistbox.h</include>
-</includes>
-</UI>