From 3e8f4e9424c0feb3a74600ad6e9426508c792bec Mon Sep 17 00:00:00 2001 From: Ivailo Monev Date: Fri, 7 Jul 2023 19:18:38 +0300 Subject: [PATCH] plasma: remove unused test engine and containment Signed-off-by: Ivailo Monev --- kdewidgets/CMakeLists.txt | 4 - kdewidgets/tests/CMakeLists.txt | 2 - kdewidgets/tests/README | 6 - kdewidgets/tests/sums | 2 - kdewidgets/tests/test.widgets | 251 ------------------ .../CMakeLists.txt | 15 -- .../testcontainmentactionsplugin/config.ui | 26 -- .../plasma-containmentactions-test.desktop | 146 ---------- .../testcontainmentactionsplugin/test.cpp | 110 -------- .../tests/testcontainmentactionsplugin/test.h | 49 ---- plasma/tests/testengine/CMakeLists.txt | 19 -- .../plasma-dataengine-testengine.desktop | 85 ------ plasma/tests/testengine/testengine.cpp | 178 ------------- plasma/tests/testengine/testengine.h | 53 ---- 14 files changed, 946 deletions(-) delete mode 100644 kdewidgets/tests/CMakeLists.txt delete mode 100644 kdewidgets/tests/README delete mode 100644 kdewidgets/tests/sums delete mode 100644 kdewidgets/tests/test.widgets delete mode 100644 plasma/tests/testcontainmentactionsplugin/CMakeLists.txt delete mode 100644 plasma/tests/testcontainmentactionsplugin/config.ui delete mode 100644 plasma/tests/testcontainmentactionsplugin/plasma-containmentactions-test.desktop delete mode 100644 plasma/tests/testcontainmentactionsplugin/test.cpp delete mode 100644 plasma/tests/testcontainmentactionsplugin/test.h delete mode 100644 plasma/tests/testengine/CMakeLists.txt delete mode 100644 plasma/tests/testengine/plasma-dataengine-testengine.desktop delete mode 100644 plasma/tests/testengine/testengine.cpp delete mode 100644 plasma/tests/testengine/testengine.h diff --git a/kdewidgets/CMakeLists.txt b/kdewidgets/CMakeLists.txt index c00c3952..df506632 100644 --- a/kdewidgets/CMakeLists.txt +++ b/kdewidgets/CMakeLists.txt @@ -1,9 +1,5 @@ project(kdewidgets) -if(ENABLE_TESTING) - add_subdirectory(tests) -endif() - add_subdirectory(pics) include_directories( diff --git a/kdewidgets/tests/CMakeLists.txt b/kdewidgets/tests/CMakeLists.txt deleted file mode 100644 index c31368e4..00000000 --- a/kdewidgets/tests/CMakeLists.txt +++ /dev/null @@ -1,2 +0,0 @@ -# TODO test programs - diff --git a/kdewidgets/tests/README b/kdewidgets/tests/README deleted file mode 100644 index 9dd2132f..00000000 --- a/kdewidgets/tests/README +++ /dev/null @@ -1,6 +0,0 @@ -These are the tests for the current makekdewidgets. - -Currently there are two modes generated, and the checksums checked. -These files are correct and build plugins that are functionally -just as TrollTech wants them for designer. If at any time the -code is changed then these md5 sums should be updated. diff --git a/kdewidgets/tests/sums b/kdewidgets/tests/sums deleted file mode 100644 index 8b1f8089..00000000 --- a/kdewidgets/tests/sums +++ /dev/null @@ -1,2 +0,0 @@ -ff629a98965347ed3303a2c70f35af51 testwithpixmaps.cpp -f736575862f21dc175e1778bc159afbf testkde.cpp diff --git a/kdewidgets/tests/test.widgets b/kdewidgets/tests/test.widgets deleted file mode 100644 index 031c78d6..00000000 --- a/kdewidgets/tests/test.widgets +++ /dev/null @@ -1,251 +0,0 @@ -[Global] -PluginName=KDEWidgets -Includes=kcomponentdata.h -Init=new KComponentData("kdewidgets"); - -[KActiveLabel] -ToolTip=Active Label (KDE) -WhatsThis=A label with support for selection and clickable links -Group=Display (KDE) - -[KColorButton] -ToolTip=Color Chooser Button (KDE) -WhatsThis=A button that allows selecting a color -Group=Graphics (KDE) - -[KColorCombo] -ToolTip=Color Combo Box (KDE) -Group=Graphics (KDE) - -[KComboBox] -ToolTip=Combo Box (KDE) -Group=Input (KDE) - -[KCModule] -ToolTip=KControl Center Module (KDE) -IsContainer=true -Group=Container (KDE) - -[KDateWidget] -ToolTip=Date preview (KDE) -Group=Input (KDE) - -[KDatePicker] -ToolTip=A date selection widget (KDE) -WhatsThis=Provides a widget for calendar date input -ConstructorArgs=(parent, QDate::currentDate(), name) -Group=Input (KDE) - -[KDialog] -IncludeFile=kdialog.h -ToolTip=Class for simple Dialogs (KDE) -IsContainer=true -Group=Container (KDE) - -[KDualColorButton] -ToolTip=A widget for selecting two related colors (KDE) -Group=Graphics (KDE) - -[KEditListBox] -ToolTip=Fullfeatured edit box with buttons (KDE) -Group=Views (KDE) - -[KFontCombo] -ToolTip=Font Combo Box (KDE) -WhatsThis=A QCombo Box showing the installed system fonts (with preview) -Group=Input (KDE) - -[KFontChooser] -IncludeFile=kfontdialog.h -IconSet=kfontcombo.png -ToolTip=Font Chooser (KDE) -WhatsThis=A font type, size and style selection widget complete with preview -Group=Input (KDE) - -[KFontRequester] -IncludeFile=kfontrequester.h -ToolTip=Font Requester (KDE) -WhatsThis=A compact font selection and preview widget -Group=Input (KDE) - -[KGradientSelector] -IncludeFile=kselect.h -WhatsThis=A widget that allows the user to select two colors to form a gradient -Group=Graphics (KDE) - -[KHistoryCombo] -IncludeFile=kcombobox.h -ToolTip=A combobox for offering a history and completion (KDE) -WhatsThis=A combobox which implements a history like a unix shell -Group=Input (KDE) - -[KHSSelector] -IncludeFile=kcolordialog.h -ToolTip=Widget for Hue/Saturation selection (KDE) -Group=Graphics (KDE) - -[KLed] -ToolTip=LED Widget (KDE) -WhatsThis=A widget showing a light emitter diode -Group=Display (KDE) - -[KListBox] -ToolTip=Extended List Box (KDE) -WhatsThis=An improved version of the QListBox that follows KDE settings -Group=Views (KDE) - -[K3ListView] -ToolTip=Extended List View (KDE) -WhatsThis=An improved version of the QListView that allows certain KDE extensions -Group=Views (KDE) - -[KLineEdit] -ToolTip=Line Edit (KDE) -Group=Input (KDE) - -[KPasswordEdit] -IncludeFile=kpassworddialog.h -ToolTip=Safe Password LineEdit (KDE) -WhatsThis=A KLineEdit that is safe for prompting the user for passwords -Group=Input (KDE) - -[KProgress] -ToolTip=Progress Bar (KDE) -WhatsThis=An improved progress bar for KDE that uses QFrame and QRangeControl -Group=Display (KDE) - -[KPushButton] -ToolTip=Improved QPushButton (KDE) -WhatsThis=An improved QPushButton to follow KDE settings -Group=Buttons (KDE) - -[KKeyButton] -ToolTip=Keyboard Key Button. (KDE) -WhatsThis=A push button that looks like a keyboard key. -IncludeFile=kkeybutton.h -Group=Buttons (KDE) - -[KRestrictedLine] -ToolTip=Line Edit for restricted input (KDE) -Group=Input (KDE) - -[KIconButton] -IncludeFile=kicondialog.h -ToolTip=Button for selecting an icon (KDE) -Group=Buttons (KDE) - -[K3IconView] -IncludeFile=k3iconview.h -ToolTip=Extended Icon View (KDE) -WhatsThis=An improved version of the QIconView that allows certain KDE extensions -Group=Views (KDE) - -[KIntSpinBox] -IncludeFile=knuminput.h -ToolTip=Enhanced Spinbox for Integer Values (KDE) -Group=Input (KDE) - -[KRuler] -ToolTip=Measuring Ruler Widget (KDE) -WhatsThis=A measuring ruler widget as seen in KWord for page widths and heights -Group=Display (KDE) - -[KSqueezedTextLabel] -ToolTip=A QLabel that squeezes its text (KDE) -WhatsThis=If the text is too long to fit into the label it is divided into remaining left and right parts which are separated by three dots -ConstructorArgs=("KSqueezedTextLabel", parent, name) -Group=Display (KDE) - -[KTextEdit] -ToolTip=Improved QTextEdit (KDE) -WhatsThis=An improved version of the QTextEdit with mail or system browser invocation support -Group=Input (KDE) - -[KUrlLabel] -ToolTip=URL Label (KDE) -ConstructorArgs=("KUrlLabel", QString(), parent, name) -Group=Display (KDE) - -[KUrlComboRequester] -ToolTip=URL Requester (KDE) -WhatsThis=A widget holding a combobox and a pushbutton. A "file open" dialog opened when clicking on the pushbutton -IncludeFile=kurlrequester.h -Group=Input (KDE) - -[KUrlRequester] -ToolTip=URL Requester (KDE) -WhatsThis=A widget holding a lineedit and a pushbutton. A "file open" dialog opened when clicking on the pushbutton -Group=Input (KDE) - -[KIntNumInput] -ToolTip=Integer Input Widget (KDE) -WhatsThis=An input widget for integer numbers, consisting of a spinbox and a slider. -IncludeFile=knuminput.h -Group=Input (KDE) - -[KDoubleNumInput] -ToolTip=Floating Point Number Input Widget (KDE) -WhatsThis=An input widget for floating point numbers, consisting of a spinbox and a slider. -IncludeFile=knuminput.h -Group=Input (KDE) - -[KTimeWidget] -ToolTip=This widget can be used to display or allow user selection of time. (KDE) -IncludeFile=ktimewidget.h -Group=Input (KDE) - -[KDateTimeWidget] -ToolTip=This widget can be used to display or allow user selection of date and time. (KDE) -IncludeFile=kdatetimewidget.h -Group=Input (KDE) - -[KDateTable] -IncludeFile=kdatetbl.h -Group=Input (KDE) -ConstructorArgs=(parent, QDate::currentDate(), name) - -[KLanguageButton] -IncludeFile=klanguagebutton.h -ToolTip=A widget for selecting a language -WhatsThis=A combobox suitable for selecting a language -Group=Input (KDE) - -[KImageFilePreview] -IncludeFile=kimagefilepreview.h -ToolTip=A widget that provides a image preview of a URL -Group=Display (KDE) -ConstructorArgs=(parent) - -[KActionSelector] -IncludeFile=kactionselector.h -ToolTip=A widget for selecting and arranging actions/objects -Group=Views (KDE) - -[KWritePermsIcon] -IncludeFile=kauthicon.h -ToolTip=Auth icon for write permission display. -ConstructorArgs=("", parent, name) -Group=Display (KDE) - -[KRootPermsIcon] -IncludeFile=kauthicon.h -ToolTip=Icon to show whether or not a user has root permissions. -Group=Display (KDE) - -[KColorPatch] -IncludeFile=kcolordialog.h -ToolTip=The KColorPatch widget is a (usually small) widget showing a selected color. -Group=Display (KDE) -ConstructorArgs=(parent) - -[KPaletteTable] -IncludeFile=kcolordialog.h -ToolTip=A color palette in table form. -Group=Display (KDE) -ConstructorArgs=(parent, 210, 16) - -#[KABC::AddressLineEdit] -#IncludeFile=kabc/addresslineedit.h -#ToolTip=A lineedit with LDAP and kabc completion. -#Group=Input (KDE) -#ConstructorArgs=(parent, true, name) diff --git a/plasma/tests/testcontainmentactionsplugin/CMakeLists.txt b/plasma/tests/testcontainmentactionsplugin/CMakeLists.txt deleted file mode 100644 index d3eb5e96..00000000 --- a/plasma/tests/testcontainmentactionsplugin/CMakeLists.txt +++ /dev/null @@ -1,15 +0,0 @@ -project(plasma-containmentactions-test) - -find_package(KDELibs4 REQUIRED) - -include_directories( - ${CMAKE_SOURCE_DIR} - ${CMAKE_BINARY_DIR} - ${KDE4_INCLUDES} -) - -kde4_add_plugin(plasma_containmentactions_test test.cpp) -target_link_libraries(plasma_containmentactions_test KDE4::plasma KDE4::kio) - -install(TARGETS plasma_containmentactions_test DESTINATION ${KDE4_PLUGIN_INSTALL_DIR}) -install(FILES plasma-containmentactions-test.desktop DESTINATION ${KDE4_SERVICES_INSTALL_DIR}) diff --git a/plasma/tests/testcontainmentactionsplugin/config.ui b/plasma/tests/testcontainmentactionsplugin/config.ui deleted file mode 100644 index 038e3476..00000000 --- a/plasma/tests/testcontainmentactionsplugin/config.ui +++ /dev/null @@ -1,26 +0,0 @@ - - Config - - - - 0 - 0 - 355 - 102 - - - - - - - text: - - - - - - - - - - diff --git a/plasma/tests/testcontainmentactionsplugin/plasma-containmentactions-test.desktop b/plasma/tests/testcontainmentactionsplugin/plasma-containmentactions-test.desktop deleted file mode 100644 index e2def34f..00000000 --- a/plasma/tests/testcontainmentactionsplugin/plasma-containmentactions-test.desktop +++ /dev/null @@ -1,146 +0,0 @@ -[Desktop Entry] -Name=Test -Name[ar]=اختبار -Name[bg]=Проба -Name[bs]=Test -Name[ca]=Prova -Name[ca@valencia]=Prova -Name[cs]=Test -Name[da]=Test -Name[de]=Test -Name[el]=Δοκιμή -Name[en_GB]=Test -Name[es]=Prueba -Name[et]=Test -Name[eu]=Proba -Name[fa]=آزمون -Name[fi]=Testi -Name[fr]=Test -Name[ga]=Tástáil -Name[gl]=Proba -Name[gu]=ચકાસણી -Name[he]=בדיקה -Name[hi]=जांच -Name[hr]=Test -Name[hu]=Teszt -Name[hy]=փորձարկում -Name[ia]=Essayo -Name[id]=Tes -Name[is]=Prófun -Name[it]=Prova -Name[ja]=テスト -Name[kk]=Сынақ -Name[km]=សាកល្បង -Name[ko]=테스트 -Name[ku]=Bicaribîne -Name[lt]=Testas -Name[lv]=Tests -Name[mr]=चाचणी -Name[nb]=Test -Name[nds]=Utproberen -Name[nl]=Test -Name[pa]=ਟੈਸਟ -Name[pl]=Test -Name[pt]=Teste -Name[pt_BR]=Teste -Name[ro]=Test -Name[ru]=Проверка -Name[se]=Geahččaleapmi -Name[si]=පරීක්‍ෂණය -Name[sk]=Test -Name[sl]=Preizkus -Name[sq]=Test -Name[sr]=Проба -Name[sr@ijekavian]=Проба -Name[sr@ijekavianlatin]=Proba -Name[sr@latin]=Proba -Name[sv]=Test -Name[tg]=Санҷиш -Name[th]=ทดสอบ -Name[tr]=Deneme -Name[tt]=Тикшерү -Name[ug]=سىنا -Name[uk]=Тест -Name[vi]=Kiểm tra -Name[wa]=Sayî -Name[x-test]=xxTestxx -Name[zh_CN]=测试 -Name[zh_TW]=測試 -Comment=A dummy plugin for testing -Comment[ar]=إضافة وهمية من أجل الاختبار -Comment[bg]=Празна приставка за изпробване -Comment[bs]=Lažni priključak za probe -Comment[ca]=Un connector fals per a provar -Comment[ca@valencia]=Un connector fals per a provar -Comment[cs]=Prázdný zásuvný modul pro testování -Comment[da]=Et attrap-plugin til testformål -Comment[de]=Ein Dummy-Modul zum Testen. -Comment[el]=Ένα "χαζό" πρόσθετο για δοκιμές -Comment[en_GB]=A dummy plugin for testing -Comment[es]=Un complemento de pruebas -Comment[et]=Libaplugin testimiseks -Comment[eu]=Probatarako gezurretazko plugin bat -Comment[fi]=Tyhjä testausliitännäinen -Comment[fr]=Un module factice pour tests -Comment[ga]=Bréagbhreiseán le haghaidh tástála -Comment[gl]=Un complemento para probas -Comment[gu]=ચકાસણી માટે નકલી પ્લગઇન -Comment[he]=תוסף דמה לבדיקה -Comment[hr]=Lažan priključak za testiranje -Comment[hu]=Üres bővítmény teszteléshez -Comment[hy]=Վարժական հարմարանք փորձարկման համար -Comment[ia]=Un plugin vacue pro essayar -Comment[id]=Plugin rekaan untuk pengujian -Comment[is]=Tilraunaíforrit fyrir prófanir -Comment[it]=Una estensione fittizia di prova -Comment[ja]=テスト用のダミープラグイン -Comment[kk]=Сынақ үшін бос плагині -Comment[km]=កម្មវិធី​ជំនួយ​ដំបូង​សម្រាប់​សាកល្បង -Comment[ko]=테스트를 위한 뼈대 플러그인 -Comment[ku]=Pêvekekî hêsan ji bo ceribandinê -Comment[lt]=Netikras priedas testavimui -Comment[lv]=Testēšanai paredzēts spraudnis -Comment[mr]=चाचणीसाठी नकली प्लगइन -Comment[nb]=Et attrapp-programtillegg for testing -Comment[nds]=En Platzholler-Moduul för't Utproberen -Comment[nl]=Een dummy plugin voor testen -Comment[pa]=ਟੈਸਟ ਕਰਨ ਲਈ ਫਰਜ਼ੀ ਪਲੱਗਇਨ -Comment[pl]=Prosta wtyczka testowa -Comment[pt]=Um 'plugin' de exemplo para testes -Comment[pt_BR]=Um plugin fictício para testes -Comment[ro]=Modul fictiv pentru testare -Comment[ru]=Расширение для тестирования -Comment[se]=Geahččalanlassemodula -Comment[sk]=Ukážkový modul pre testovanie -Comment[sl]=Preizkusni vstavek za preizkušanje -Comment[sr]=Лажни прикључак за пробе -Comment[sr@ijekavian]=Лажни прикључак за пробе -Comment[sr@ijekavianlatin]=Lažni priključak za probe -Comment[sr@latin]=Lažni priključak za probe -Comment[sv]=Ett exempelinsticksprogram för test -Comment[tg]=Воситаҳо барои санҷиш -Comment[th]=โปรแกรมเสริมเทียมสำหรับทดสอบ -Comment[tr]=Denemek için sahte bir eklenti -Comment[tt]=Тикшертү өчен ялган өстәмә -Comment[ug]=سىناشقا ئىشلىتىدىغان قىستۇرما -Comment[uk]=Додаток для тестування -Comment[vi]=Một phần bổ sung giả để kiểm thử -Comment[wa]=On fås tchôke-divins po l' asprouvaedje -Comment[x-test]=xxA dummy plugin for testingxx -Comment[zh_CN]=测试用插件 -Comment[zh_TW]=測試用外掛程式 -Type=Service -Icon=preferences-desktop-color -ServiceTypes=Plasma/ContainmentActions - -X-KDE-Library=plasma_containmentactions_test -X-KDE-PluginInfo-Author=Chani -X-KDE-PluginInfo-Email=chani@kde.org -X-KDE-PluginInfo-Name=test -X-KDE-PluginInfo-Version=pre0.1 -X-KDE-PluginInfo-Website=http://plasma.kde.org/ -X-KDE-PluginInfo-Depends= -X-KDE-PluginInfo-License=GPL -X-KDE-PluginInfo-EnabledByDefault=true - -X-Plasma-HasConfigurationInterface=true diff --git a/plasma/tests/testcontainmentactionsplugin/test.cpp b/plasma/tests/testcontainmentactionsplugin/test.cpp deleted file mode 100644 index 7ed3b11f..00000000 --- a/plasma/tests/testcontainmentactionsplugin/test.cpp +++ /dev/null @@ -1,110 +0,0 @@ -/* - * Copyright 2009 by Chani Armitage - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -#include "test.h" - -#include -#include - -#include -#include - -#include - -ContextTest::ContextTest(QObject *parent, const QVariantList &args) - : Plasma::ContainmentActions(parent, args) -{ - setConfigurationRequired(true); -} - -void ContextTest::contextEvent(QEvent *event) -{ - switch (event->type()) { - case QEvent::GraphicsSceneMousePress: { - contextEvent(static_cast(event)); - break; - } - case QEvent::GraphicsSceneWheel: { - wheelEvent(static_cast(event)); - break; - } - default: { - break; - } - } -} - -void ContextTest::contextEvent(QGraphicsSceneMouseEvent *event) -{ - kDebug() << "test!!!!!!!!!!!!!!!!!!!!!!!" << event->pos(); - kDebug() << event->buttons() << event->modifiers(); - - Plasma::Containment *c = containment(); - if (c) { - kDebug() << c->name(); - } else { - kDebug() << "fail"; - return; - } - - KMenu desktopMenu; - desktopMenu.addTitle(m_text); - desktopMenu.addAction(c->action("configure")); - desktopMenu.exec(event->screenPos()); - -} - -void ContextTest::wheelEvent(QGraphicsSceneWheelEvent *event) -{ - kDebug() << "test!!!!!!!!!!!!!11111111!!"; - kDebug() << event->orientation() << event->delta(); - kDebug() << event->buttons() << event->modifiers(); -} - -void ContextTest::init(const KConfigGroup &config) -{ - m_text = config.readEntry("test-text", QString()); - setConfigurationRequired(m_text.isEmpty()); -} - -QWidget* ContextTest::createConfigurationInterface(QWidget* parent) -{ - //m_currentText = m_text; - QWidget *widget = new QWidget(parent); - m_ui.setupUi(widget); - - m_ui.text->setText(m_text); - //FIXME this way or just get it on close? - //connect(m_ui.text, SIGNAL(changed(QColor)), this, SLOT(setColor(QColor))); - //connect(this, SIGNAL(settingsChanged(bool)), parent, SLOT(settingsChanged(bool))); - return widget; -} - -void ContextTest::configurationAccepted() -{ - m_text = m_ui.text->text(); -} - -void ContextTest::save(KConfigGroup &config) -{ - config.writeEntry("test-text", m_text); -} - - -#include "moc_test.cpp" diff --git a/plasma/tests/testcontainmentactionsplugin/test.h b/plasma/tests/testcontainmentactionsplugin/test.h deleted file mode 100644 index 5cc5a6c0..00000000 --- a/plasma/tests/testcontainmentactionsplugin/test.h +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright 2009 by Chani Armitage - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Library General Public License as - * published by the Free Software Foundation; either version 2, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU Library General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -#ifndef CONTEXTTEST_HEADER -#define CONTEXTTEST_HEADER - -#include "ui_config.h" -#include -#include - -class ContextTest : public Plasma::ContainmentActions -{ - Q_OBJECT - public: - ContextTest(QObject* parent, const QVariantList& args); - - void init(const KConfigGroup &config); - void contextEvent(QEvent *event); - void contextEvent(QGraphicsSceneMouseEvent *event); - void wheelEvent(QGraphicsSceneWheelEvent *event); - - QWidget* createConfigurationInterface(QWidget* parent); - void configurationAccepted(); - void save(KConfigGroup &config); - - private: - Ui::Config m_ui; - QString m_text; -}; - -K_EXPORT_PLASMA_CONTAINMENTACTIONS(test, ContextTest) - -#endif diff --git a/plasma/tests/testengine/CMakeLists.txt b/plasma/tests/testengine/CMakeLists.txt deleted file mode 100644 index c45fe7b2..00000000 --- a/plasma/tests/testengine/CMakeLists.txt +++ /dev/null @@ -1,19 +0,0 @@ -project(plasma_testengine_dataengine) - -find_package(KDELibs4 REQUIRED) - -include_directories( - ${CMAKE_SOURCE_DIR} - ${CMAKE_BINARY_DIR} - ${KDE4_INCLUDES} -) - -kde4_add_plugin(plasma_engine_testengine testengine.cpp) - -target_link_libraries(plasma_engine_testengine - KDE4::kio - KDE4::plasma -) - -install(TARGETS plasma_engine_testengine DESTINATION ${KDE4_PLUGIN_INSTALL_DIR}) -install(FILES plasma-dataengine-testengine.desktop DESTINATION ${KDE4_SERVICES_INSTALL_DIR}) diff --git a/plasma/tests/testengine/plasma-dataengine-testengine.desktop b/plasma/tests/testengine/plasma-dataengine-testengine.desktop deleted file mode 100644 index f1098233..00000000 --- a/plasma/tests/testengine/plasma-dataengine-testengine.desktop +++ /dev/null @@ -1,85 +0,0 @@ -[Desktop Entry] -Name=Test Data Engine -Name[ar]=محرك بيانات الاختبار -Name[as]=পৰীক্ষা তথ্যৰ কলঘৰ -Name[ast]=Motor de datos de prueba -Name[be@latin]=Systema spraŭdžvańnia dla źviestak -Name[bg]=Пробно ядро за данни -Name[bn]=টেস্ট ডাটা ইঞ্জিন -Name[bs]=Probni pogon za podatke -Name[ca]=Motor de dades de prova -Name[ca@valencia]=Motor de dades de prova -Name[cs]=Testovací datový nástroj -Name[da]=Test datamotor -Name[de]=Test-Datenmodul -Name[el]=Μηχανή δεδομένων ελέγχου -Name[en_GB]=Test Data Engine -Name[eo]=Testa Datuma motoro -Name[es]=Motor de datos de prueba -Name[et]=Testandmemootor -Name[eu]=Proba datuen motorra -Name[fi]=Testitietomoottori -Name[fr]=Moteur de données de tests -Name[fy]=Test gegevensmotor -Name[ga]=Inneall Sonraí Tástála -Name[gl]=Motor de datos de probas -Name[gu]=ચકાસણી માહિતી એન્જિન -Name[he]=בדיקה למנוע מידע -Name[hi]=जाँच डाटा इंजिन -Name[hne]=जांच डाटा इंजिन -Name[hr]=Provjeri podatkovni mehanizam -Name[hsb]=Test Data Engine -Name[hu]=Az adatkezelő modul tesztje -Name[hy]=Փորձարկման տվյալների գործիք -Name[ia]=Motor del essayo de datos -Name[id]=Mesin Data Tes -Name[is]=Gagnaprófunarvél -Name[it]=Motore dati di prova -Name[ja]=テストデータエンジン -Name[kk]=Сынақ деректер тетігі -Name[km]=សាកល្បង​ម៉ាស៊ីន​ទិន្នន័យ -Name[kn]=ಪರೀಕ್ಷಾ ದತ್ತ ಯಂತ್ರ -Name[ko]=테스트 데이터 엔진 -Name[ku]=Motora Dane Ceribandinê -Name[lt]=Bandomasis duomenų variklis -Name[lv]=Testēšanas datu dzinējs -Name[mai]=जाँचि डाटा इंडन -Name[ml]=പരിശോധനാ ഡാറ്റാ എഞ്ചിന്‍ -Name[mr]=चाचणी डेटा इंजिन -Name[nb]=Testdata-motor -Name[nds]=Test-Datenkarn -Name[nl]=Testgegevensengine -Name[nn]=Testdatamotor -Name[pa]=ਟੈਸਟ ਡਾਟਾ ਇੰਜਣ -Name[pl]=Silnik testów danych -Name[pt]=Motor de Dados de Teste -Name[pt_BR]=Mecanismo de dados de teste -Name[ro]=Motor de date pentru teste -Name[ru]=Тестовый источник данных -Name[se]=Geahččalandáhtamohtor -Name[si]=පරීක්‍ෂණ දත්ත එන්ජිම -Name[sk]=Testovací dátový nástroj -Name[sl]=Preizkusni podatkovni pogon -Name[sq]=Motor i Testimit të të Dhënave -Name[sr]=пробни датомотор података -Name[sr@ijekavian]=пробни датомотор података -Name[sr@ijekavianlatin]=probni datomotor podataka -Name[sr@latin]=probni datomotor podataka -Name[sv]=Testdatagränssnitt -Name[ta]=சோதனை தரவு இயந்திரம் -Name[tg]=Системаи санҷиши маълумот -Name[th]=กลไกทดสอบข้อมูล -Name[tr]=Test Veri Motoru -Name[tt]=Тикшертү өчен мәгълүмат чыганагы -Name[ug]=سىناققا ئىشلىتىدىغان ماتور -Name[uk]=Перевірка рушія даних -Name[vi]=Cơ chế kiểm tra dữ liệu -Name[wa]=Moteur di dnêyes d' asprouvaedje -Name[x-test]=xxTest Data Enginexx -Name[zh_CN]=测试用数据引擎 -Name[zh_TW]=測試資料引擎 -X-KDE-ServiceTypes=Plasma/DataEngine -Type=Service -Icon=unknown -X-KDE-Library=plasma_engine_testengine -X-Plasma-EngineName=testengine diff --git a/plasma/tests/testengine/testengine.cpp b/plasma/tests/testengine/testengine.cpp deleted file mode 100644 index b268e420..00000000 --- a/plasma/tests/testengine/testengine.cpp +++ /dev/null @@ -1,178 +0,0 @@ -/* - * Copyright (C) 2008 Gilles CHAUVIN - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License either version 2, or - * (at your option) any later version as published by the Free Software - * Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - - -#include "testengine.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -Q_DECLARE_METATYPE(TestEngine::MyUserType) - - -TestEngine::TestEngine(QObject *parent, const QVariantList &args) - : Plasma::DataEngine(parent, args) -{ -} // ctor() - - -TestEngine::~TestEngine() -{ -} // dtor() - - -void TestEngine::init() -{ - QString dsn("TestEngine"); - - // QVariant::Invalid - // QVariant::BitArray - setData(dsn, "QBitArray", QVariant(QBitArray(97, false))); - // QVariant::Bitmap - setData(dsn, "QBitmap", QVariant(QBitmap(12, 57))); - // QVariant::Bool - setData(dsn, "bool", QVariant((bool)true)); - // QVariant::Brush - setData(dsn, "QBrush", QVariant(QBrush(Qt::SolidPattern))); - // QVariant::ByteArray - QByteArray byteArray; - for (int i=0; i<256; ++i) { - byteArray.append(i); - } - setData(dsn, "QByteArray1", QVariant(byteArray)); - setData(dsn, "QByteArray2", QVariant(QByteArray("KDE4"))); - // QVariant::Char - setData(dsn, "QChar", QVariant(QChar(0x4B))); - // QVariant::Color - setData(dsn, "QColor", QVariant(QColor("#031337"))); - // QVariant::Cursor - setData(dsn, "QCursor", QVariant(QCursor(Qt::ArrowCursor))); - // QVariant::Date - setData(dsn, "QDate", QVariant(QDate(2008, 1, 11))); - // QVariant::DateTime - setData(dsn, "QDateTime", QVariant(QDateTime(QDate(2008, 1, 11), QTime(12, 34, 56)))); - // QVariant::Double - setData(dsn, "double", QVariant((double)12.34)); - // QVariant::Font - setData(dsn, "QFont", QVariant(QFont())); - // QVariant::Icon - setData(dsn, "QIcon", QVariant(QIcon(QPixmap(12, 34)))); - // QVariant::Image - setData(dsn, "QImage", QVariant(QImage(56, 78, QImage::Format_Mono))); - // QVariant::Int - setData(dsn, "int", QVariant((int)-4321)); - // QVariant::KeySequence (???) - // QVariant::Line - setData(dsn, "QLine", QVariant(QLine(12, 34, 56, 78))); - // QVariant::LineF - setData(dsn, "QLineF", QVariant(QLineF(1.2, 3.4, 5.6, 7.8))); - // QVariant::List - QList list; - list << QString("KDE4") << QBrush() << QPen(); - setData(dsn, "QList", QVariant(list)); - // QVariant::Locale - setData(dsn, "QLocale", QVariant(QLocale("fr_FR"))); - // QVariant::LongLong - setData(dsn, "qlonglong", QVariant((qlonglong)-4321)); - // QVariant::Map - QMap map; - for (int i=0; i<123; ++i) { - QString key = QString("key%1").arg(i); - QString val = QString("value%1").arg(i); - map[key] = val; - } - setData(dsn, "QMap", QVariant(map)); - // QVariant::Matrix - setData(dsn, "QMatrix", QVariant(QMatrix())); - // QVariant::Transform - setData(dsn, "QTransform", QVariant(QTransform())); - // QVariant::Palette - setData(dsn, "QPalette", QVariant(QPalette())); - // QVariant::Pen - setData(dsn, "QPen", QVariant(QPen(Qt::SolidLine))); - // QVariant::Pixmap - setData(dsn, "QPixmap", QVariant(QPixmap(12, 34))); - // QVariant::Point - setData(dsn, "QPoint", QVariant(QPoint(12, 34))); - // QVariant::PointArray (obsoloted in Qt4, see QPolygon) - // QVariant::PointF - setData(dsn, "QPointF", QVariant(QPointF(12.34, 56.78))); - // QVariant::Polygon - setData(dsn, "QPolygon", QVariant(QPolygon(42))); - // QVariant::Rect - setData(dsn, "QRect", QVariant(QRect(12, 34, 56, 78))); - // QVariant::RectF - setData(dsn, "QRectF", QVariant(QRectF(1.2, 3.4, 5.6, 7.8))); - // QVariant::RegExp - setData(dsn, "QRegExp", QVariant(QRegExp("^KDE4$"))); - // QVariant::Region - setData(dsn, "QRegion", QVariant(QRegion(10, 20, 30, 40))); - // QVariant::Size - setData(dsn, "QSize", QVariant(QSize(12, 34))); - // QVariant::SizeF - setData(dsn, "QSizeF", QVariant(QSizeF(12.34, 56.78))); - // QVariant::SizePolicy - setData(dsn, "QSizePolicy", QVariant(QSizePolicy())); - // QVariant::String - setData(dsn, "QString", QVariant(QString("KDE4 ROCKS!"))); - // QVariant::StringList - QStringList stringList; - stringList << "K" << "D" << "E" << "4"; - setData(dsn, "QStringList", QVariant(stringList)); - // QVariant::TextFormat - setData(dsn, "QTextFormat", QVariant(QTextFormat())); - // QVariant::TextLength - setData(dsn, "QTextLength", QVariant(QTextLength())); - // QVariant::Time - setData(dsn, "QTime", QVariant(QTime(12, 34, 56))); - // QVariant::UInt - setData(dsn, "uint", QVariant((uint)4321)); - // QVariant::ULongLong - setData(dsn, "qulonglong", QVariant((qulonglong)4321)); - // QVariant::Url - setData(dsn, "QUrl", QVariant(QUrl("http://user:password@example.com:80/test.php?param1=foo¶m2=bar"))); - // QVariant::UserType - MyUserType userType; - QVariant v; - v.setValue(userType); - setData(dsn, "UserType", v); -} // init() - - -bool TestEngine::sourceRequestEvent(const QString &source) -{ - // Nothing to do... - Q_UNUSED(source) - return true; -} // sourceRequestEvent() - - -#include "moc_testengine.cpp" diff --git a/plasma/tests/testengine/testengine.h b/plasma/tests/testengine/testengine.h deleted file mode 100644 index e937ada4..00000000 --- a/plasma/tests/testengine/testengine.h +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Copyright (C) 2008 Gilles CHAUVIN - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License either version 2, or - * (at your option) any later version as published by the Free Software - * Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details - * - * You should have received a copy of the GNU General Public - * License along with this program; if not, write to the - * Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ - -/* - * A data engine meant to test the Plasma data engine explorer. - */ - -#ifndef __TESTDATAENGINE_H__ -#define __TESTDATAENGINE_H__ - - -#include "plasma/dataengine.h" - - -class TestEngine : public Plasma::DataEngine -{ - Q_OBJECT - -public: - struct MyUserType { - int a; - QString b; - }; - - TestEngine(QObject *parent, const QVariantList &args); - ~TestEngine(); - -protected: - void init(); - bool sourceRequestEvent(const QString &source); -}; - - -K_EXPORT_PLASMA_DATAENGINE(testengine, TestEngine) - - -#endif // __TESTDATAENGINE_H__