diff --git a/TODO b/TODO index 35a7aeb..7ba66cf 100644 --- a/TODO +++ b/TODO @@ -6,9 +6,6 @@ Plans and ideas for 1.1: * Check if no of sectors fits in an unsigned 32 bit int for msdos partition tables. -* The KPart works but has problems: The context menus don't show up, the status - bar is missing, maybe more. - * save msdos mbr? * let the user specify extern command locations and options in the settings; diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index dab4730..bccc9af 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -62,32 +62,5 @@ install(FILES partitionmanager.desktop DESTINATION ${XDG_APPS_INSTALL_DIR}) ############################################ -option(PARTMAN_KPART "Build a kpart for KDE Partition Manager" OFF) - -if(PARTMAN_KPART) - file(GLOB partitionmanagerpart_SRCS kpart/partitionmanagerpart.cpp) - - kde4_add_plugin(partitionmanagerpart ${partitionmanagerpart_SRCS}) - - target_link_libraries(partitionmanagerpart - ${KDE4_KPARTS_LIBS} - ${KDE4_KDECORE_LIBS} - partitionmanagerprivate - ) - - install(TARGETS partitionmanagerpart DESTINATION ${PLUGIN_INSTALL_DIR}) - install(FILES kpart/partitionmanagerpart.desktop DESTINATION ${SERVICES_INSTALL_DIR}) - install(FILES kpart/partitionmanagerpart.rc DESTINATION ${DATA_INSTALL_DIR}/partitionmanagerpart) - - option(PARTMAN_KPART_TEST "Build a kpart test application for KDE Partition Manager" OFF) - - if(PARTMAN_KPART_TEST) - add_subdirectory(kpart/test) - endif(PARTMAN_KPART_TEST) - -endif(PARTMAN_KPART) - -############################################ - add_subdirectory(plugins) diff --git a/src/kpart/partitionmanagerpart.cpp b/src/kpart/partitionmanagerpart.cpp deleted file mode 100644 index 082a7bb..0000000 --- a/src/kpart/partitionmanagerpart.cpp +++ /dev/null @@ -1,49 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2008 by Volker Lanz * - * * - * 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. * - * * - * 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 "kpart/partitionmanagerpart.h" - -#include "gui/mainwindow.h" - -#include "util/helpers.h" - -#include - -K_PLUGIN_FACTORY(PartitionManagerPartFactory, registerPlugin("PartitionManagerPart");) -K_EXPORT_PLUGIN(PartitionManagerPartFactory("partitionmanagerpart", "partitionmanager")) - -PartitionManagerPart::PartitionManagerPart(QWidget*, QObject* parent, const QVariantList&) : - KParts::ReadOnlyPart(parent) -{ - setComponentData(PartitionManagerPartFactory::componentData(), false); - - // workaround for https://bugs.launchpad.net/kdesudo/+bug/272427 - unblockSigChild(); - - registerMetaTypes(); - - setWidget(new MainWindow(NULL, actionCollection())); - setXMLFile("partitionmanagerpart.rc"); -} - -KAboutData* PartitionManagerPart::createAboutData() -{ - return createPartitionManagerAboutData(); -} - diff --git a/src/kpart/partitionmanagerpart.desktop b/src/kpart/partitionmanagerpart.desktop deleted file mode 100644 index 9080951..0000000 --- a/src/kpart/partitionmanagerpart.desktop +++ /dev/null @@ -1,48 +0,0 @@ -[Desktop Entry] -Type=Service -Name=KDE Partition Manager -Name[bg]=Управление на дялове за KDE -Name[ca]=Gestor de particions del KDE -Name[ca@valencia]=Gestor de particions del KDE -Name[cs]=Správce diskových oddílů pro KDE -Name[da]=KDE Partitionshåndtering -Name[de]=KDE-Partitionsmanager -Name[el]=Διαχειριστής κατατμήσεων του KDE -Name[en_GB]=KDE Partition Manager -Name[es]=Gestor de particiones de KDE -Name[et]=KDE partitsioonide haldur -Name[fr]=Gestionnaire de partitions de KDE -Name[ga]=Bainisteoir Deighiltí KDE -Name[gl]=Xestor de particións de KDE -Name[hu]=KDE Partíció Menedzser -Name[it]=Gestore delle partizioni di KDE -Name[ja]=KDE パーティションマネージャ -Name[km]=កម្មវិធី​គ្រប់គ្រង​ការ​ចែកភាគ​ថាស​របស់ KDE -Name[lt]=KDE skaidinių tvarkyklė -Name[lv]=KDE partīciju pārvaldnieks -Name[ms]=Pengurus Partisyen KDE -Name[nb]=KDE partisjonshåndtering -Name[nds]=KDE-Partitschonenpleger -Name[nl]=KDE Partitiebeheer -Name[nn]=KDE-partisjonshandtering -Name[pa]=ਕੇਡੀਈ ਪਾਰਟੀਸ਼ਨ ਮੈਨੇਜਰ -Name[pt]=Gestor de Partições do KDE -Name[pt_BR]=Gerenciador de partições do KDE -Name[ro]=Gestionarul de partiții KDE -Name[ru]=Диспетчер разделов для KDE -Name[sk]=KDE Správca partícií -Name[sr]=КДЕ‑ов менаџер партиција -Name[sr@ijekavian]=КДЕ‑ов менаџер партиција -Name[sr@ijekavianlatin]=KDE‑ov menadžer particija -Name[sr@latin]=KDE‑ov menadžer particija -Name[sv]=KDE:s partitionshanterare -Name[th]=เครื่องมือจัดการพาร์ทิชันของ KDE -Name[tr]=KDE Partition Manager -Name[uk]=Керування розділами диска KDE -Name[x-test]=xxKDE Partition Managerxx -Name[zh_CN]=KDE 分区管理器 -Name[zh_TW]=KDE 磁碟分割區管理員 -Icon= - -X-KDE-ServiceTypes=KParts/ReadOnlyPart -X-KDE-Library=partitionmanagerpart diff --git a/src/kpart/partitionmanagerpart.h b/src/kpart/partitionmanagerpart.h deleted file mode 100644 index e97b93c..0000000 --- a/src/kpart/partitionmanagerpart.h +++ /dev/null @@ -1,42 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2008 by Volker Lanz * - * * - * 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. * - * * - * 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. * - ***************************************************************************/ - -#if !defined(PARTITIONMANAGERPART__H) - -#define PARTITIONMANAGERPART__H - -#include - -class KAboutData; - -class PartitionManagerPart : public KParts::ReadOnlyPart -{ - Q_OBJECT - - public: - PartitionManagerPart(QWidget* parentWidget, QObject* parent, const QVariantList& args); - - public: - static KAboutData* createAboutData(); - - protected: - virtual bool openFile() { return false; } -}; - -#endif diff --git a/src/kpart/partitionmanagerpart.rc b/src/kpart/partitionmanagerpart.rc deleted file mode 100644 index 31dcfda..0000000 --- a/src/kpart/partitionmanagerpart.rc +++ /dev/null @@ -1,73 +0,0 @@ - - - - - Edit Toolbar - - - - - - - Partition Toolbar - - - - - - - - - - - Device Toolbar - - - - - - - Edit - - - - - - View - - - - - - - - - - Device - - - - - Partition - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/kpart/test/CMakeLists.txt b/src/kpart/test/CMakeLists.txt deleted file mode 100644 index ae7f360..0000000 --- a/src/kpart/test/CMakeLists.txt +++ /dev/null @@ -1,34 +0,0 @@ -# Copyright (C) 2008 by Volker Lanz -# -# 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. -# -# 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 - -find_package(KDE4 REQUIRED) - -include_directories(${KDE4_INCLUDES} .) - -set(kparttest_SRCS - main.cpp - kparttest.cpp -) - -add_subdirectory(po) - -kde4_add_executable(kparttest ${kparttest_SRCS}) - -target_link_libraries(kparttest ${KDE4_KDEUI_LIBS} ${KDE4_KPARTS_LIBS}) - -install(TARGETS kparttest ${INSTALL_TARGETS_DEFAULT_ARGS}) -install(FILES kparttestui.rc DESTINATION ${DATA_INSTALL_DIR}/kparttest) diff --git a/src/kpart/test/kparttest.cpp b/src/kpart/test/kparttest.cpp deleted file mode 100644 index 951ef7d..0000000 --- a/src/kpart/test/kparttest.cpp +++ /dev/null @@ -1,57 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2008 by Volker Lanz * - * * - * 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. * - * * - * 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 "kparttest.h" - -#include -#include -#include -#include -#include -#include -#include - -#include - -KPartTest::KPartTest() : - KParts::MainWindow(), - m_Part(NULL) -{ - setupActions(); - - KPluginFactory* factory = KPluginLoader("partitionmanagerpart").factory(); - m_Part = factory ? factory->create("PartitionManagerPart", this) : NULL; - - if (m_Part == NULL) - { - KMessageBox::error(this, "Could not load Partition Manager's KPart"); - qApp->quit(); - return; - } - - setCentralWidget(m_Part->widget()); - - setupGUI(ToolBar | Keys | StatusBar | Save); - createGUI(m_Part); -} - -void KPartTest::setupActions() -{ - KStandardAction::quit(qApp, SLOT(closeAllWindows()), actionCollection()); -} diff --git a/src/kpart/test/kparttest.h b/src/kpart/test/kparttest.h deleted file mode 100644 index 920d26e..0000000 --- a/src/kpart/test/kparttest.h +++ /dev/null @@ -1,40 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2008 by Volker Lanz * - * * - * 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. * - * * - * 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 * - ***************************************************************************/ - -#if !defined(KPARTTEST__H) - -#define KPARTTEST__H - -#include - -class KPartTest : public KParts::MainWindow -{ - Q_OBJECT - - public: - KPartTest(); - - private: - void setupActions(); - - private: - KParts::ReadOnlyPart* m_Part; -}; - -#endif diff --git a/src/kpart/test/kparttestui.rc b/src/kpart/test/kparttestui.rc deleted file mode 100644 index 4961653..0000000 --- a/src/kpart/test/kparttestui.rc +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/src/kpart/test/main.cpp b/src/kpart/test/main.cpp deleted file mode 100644 index 7f479f6..0000000 --- a/src/kpart/test/main.cpp +++ /dev/null @@ -1,45 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2008 by Volker Lanz * - * * - * 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. * - * * - * 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 "kparttest.h" - -#include -#include -#include - -int main(int argc, char* argv[]) -{ - KAboutData aboutData( - "kparttest", - NULL, - ki18n("KDE Partition Manager KPart"), "0.1", - ki18n("A test application for KDE Partition Manager's KPart."), - KAboutData::License_GPL, - ki18n("Copyright (c) 2008 Volker Lanz") - ); - - KCmdLineArgs::init(argc, argv, &aboutData); - - KApplication app; - - KPartTest* widget = new KPartTest(); - widget->show(); - - return app.exec(); -} diff --git a/src/kpart/test/po/CMakeLists.txt b/src/kpart/test/po/CMakeLists.txt deleted file mode 100644 index 63b5f28..0000000 --- a/src/kpart/test/po/CMakeLists.txt +++ /dev/null @@ -1,21 +0,0 @@ -# Copyright (C) 2008 by Volker Lanz -# -# 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. -# -# 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 - -FILE(GLOB PO_FILES *.po) - -ADD_TRANSLATIONS(kparttest ${PO_FILES}) - diff --git a/src/kpart/test/po/de.po b/src/kpart/test/po/de.po deleted file mode 100644 index ebc2d37..0000000 --- a/src/kpart/test/po/de.po +++ /dev/null @@ -1,40 +0,0 @@ -# Copyright (C) 2009 -# This file is distributed under the same license as the kparttest package. -# -# Volker Lanz , 2009. -msgid "" -msgstr "" -"Project-Id-Version: kparttest_de\n" -"Report-Msgid-Bugs-To: http://sourceforge.net/tracker/?group_id=50231&atid=459007\n" -"POT-Creation-Date: 2009-04-23 09:37+0200\n" -"PO-Revision-Date: 2009-04-23 09:38+0200\n" -"Last-Translator: Volker Lanz \n" -"Language-Team: German \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Lokalize 0.3\n" -"Plural-Forms: nplurals=2; plural=n != 1;\n" - -#: main.cpp:31 -msgid "KDE Partition Manager KPart" -msgstr "" - -#: main.cpp:32 -msgid "A test application for KDE Partition Manager's KPart." -msgstr "Eine Testanwendung für den KPart vom KDE Partitionsmanager." - -#: main.cpp:34 -msgid "Copyright (c) 2008 Volker Lanz" -msgstr "" - -#: rc.cpp:1 -msgctxt "NAME OF TRANSLATORS" -msgid "Your names" -msgstr "Volker Lanz" - -#: rc.cpp:2 -msgctxt "EMAIL OF TRANSLATORS" -msgid "Your emails" -msgstr "vl@fidra.de" - diff --git a/src/kpart/test/po/kparttest.pot b/src/kpart/test/po/kparttest.pot deleted file mode 100644 index 8124483..0000000 --- a/src/kpart/test/po/kparttest.pot +++ /dev/null @@ -1,40 +0,0 @@ -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# -#, fuzzy -msgid "" -msgstr "" -"Project-Id-Version: PACKAGE VERSION\n" -"Report-Msgid-Bugs-To: http://sourceforge.net/tracker/?" -"group_id=50231&atid=459007\n" -"POT-Creation-Date: 2009-04-23 09:37+0200\n" -"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" -"Last-Translator: FULL NAME \n" -"Language-Team: LANGUAGE \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=CHARSET\n" -"Content-Transfer-Encoding: 8bit\n" - -#: main.cpp:31 -msgid "KDE Partition Manager KPart" -msgstr "" - -#: main.cpp:32 -msgid "A test application for KDE Partition Manager's KPart." -msgstr "" - -#: main.cpp:34 -msgid "Copyright (c) 2008 Volker Lanz" -msgstr "" - -#: rc.cpp:1 -msgctxt "NAME OF TRANSLATORS" -msgid "Your names" -msgstr "" - -#: rc.cpp:2 -msgctxt "EMAIL OF TRANSLATORS" -msgid "Your emails" -msgstr "" diff --git a/src/kpart/test/po/messages.sh b/src/kpart/test/po/messages.sh deleted file mode 100755 index f44169c..0000000 --- a/src/kpart/test/po/messages.sh +++ /dev/null @@ -1,50 +0,0 @@ -#!/bin/sh - -BASEDIR=".." # root of translatable sources -PROJECT="kparttest" # project name -BUGADDR="http://sourceforge.net/tracker/?group_id=50231&atid=459007" # MSGID-Bugs -WDIR=`pwd` # working dir -EXTRACTRC="/usr/lib/kde4/bin/extractrc" # path to KDE4 extractrc (the KDE3 version silently fails) - -echo "Preparing rc files" -cd ${BASEDIR} - -# we use simple sorting to make sure the lines do not jump around too much from system to system -find . -name '*.rc' -o -name '*.ui' -o -name '*.kcfg' | sort > ${WDIR}/rcfiles.list - -xargs --arg-file=${WDIR}/rcfiles.list ${EXTRACTRC} > ${WDIR}/rc.cpp -# additional string for KAboutData -echo 'i18nc("NAME OF TRANSLATORS","Your names");' >> ${WDIR}/rc.cpp -echo 'i18nc("EMAIL OF TRANSLATORS","Your emails");' >> ${WDIR}/rc.cpp -cd ${WDIR} -echo "Done preparing rc files" - - -echo "Extracting messages" -cd ${BASEDIR} -# see above on sorting -find . -name '*.cpp' -o -name '*.h' -o -name '*.c' | sort > ${WDIR}/infiles.list -echo "rc.cpp" >> ${WDIR}/infiles.list -cd ${WDIR} -xgettext --from-code=UTF-8 -C -kde -ci18n -ki18n:1 -ki18nc:1c,2 -ki18np:1,2 -ki18ncp:1c,2,3 -ktr2i18n:1 \ --kI18N_NOOP:1 -kI18N_NOOP2:1c,2 -kaliasLocale -kki18n:1 -kki18nc:1c,2 -kki18np:1,2 -kki18ncp:1c,2,3 \ ---msgid-bugs-address="${BUGADDR}" \ ---files-from=infiles.list -D ${BASEDIR} -D ${WDIR} -o ${PROJECT}.pot || { echo "error while calling xgettext. aborting."; exit 1; } -echo "Done extracting messages" - -echo "Merging translations" -catalogs=`find . -name '*.po'` -for cat in $catalogs; do - echo $cat - msgmerge -o $cat.new $cat ${PROJECT}.pot - mv $cat.new $cat -done -echo "Done merging translations" - -echo "Cleaning up" -cd ${WDIR} -rm rcfiles.list -rm infiles.list -rm rc.cpp -echo "Done" -