From d1a7b536726f040cfa834fb2eedb690d0bf2f1fb Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Sun, 27 Jan 2013 00:52:16 -0600 Subject: Rename a number of libraries and executables to avoid conflicts with KDE4 --- src/Makefile.am | 4 +- src/k9main.cpp | 6 +- src/k9main.h | 4 +- src/k9settings.h | 2 +- src/kconfigdlg.cpp | 151 --------------------------------------------------- src/kconfigdlg.h | 44 --------------- src/tdeconfigdlg.cpp | 151 +++++++++++++++++++++++++++++++++++++++++++++++++++ src/tdeconfigdlg.h | 44 +++++++++++++++ 8 files changed, 203 insertions(+), 203 deletions(-) delete mode 100644 src/kconfigdlg.cpp delete mode 100644 src/kconfigdlg.h create mode 100644 src/tdeconfigdlg.cpp create mode 100644 src/tdeconfigdlg.h (limited to 'src') diff --git a/src/Makefile.am b/src/Makefile.am index e6cf850..d7874f1 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -7,7 +7,7 @@ INCLUDES = -I$(top_srcdir)/dvdread -I$(top_srcdir)/k9Mplayer \ noinst_HEADERS = k9copy.h k9glwidget.h k9langselect.h k9main.h \ k9mencodercmdgen.h k9mp4title.h k9play.h k9playbackoptions.h k9prefauthor.h k9prefdvd.h \ k9prefmencoder.h k9prefmpeg4.h k9prefpreview.h k9redirect.h k9settings.h k9titlefactor.h \ - k9updatefactor.h kconfigdlg.h + k9updatefactor.h tdeconfigdlg.h # let automoc handle all of the meta source files (moc) METASOURCES = AUTO @@ -27,7 +27,7 @@ k9copy_SOURCES = configDlg.ui images.h k9copy.cpp k9copy.png k9glwidget.cpp \ k9langselect.cpp k9main.cpp k9mainw.ui k9mencodercmdgen.cpp k9mp4title.cpp k9play.cpp \ k9playbackoptions.cpp k9prefauthor.cpp k9prefdvd.cpp k9prefmencoder.cpp k9prefmpeg4.cpp \ k9prefpreview.cpp k9redirect.cpp k9settings.cpp k9titlefactor.cpp k9updatefactor.cpp \ - kconfigdlg.cpp kviewmpeg2.cpp kviewmpeg2.h langselectw.ui main.cpp mencoderCmdGen.ui \ + tdeconfigdlg.cpp kviewmpeg2.cpp kviewmpeg2.h langselectw.ui main.cpp mencoderCmdGen.ui \ playbackoptionsw.ui prefAuthor.ui prefDVD.ui prefMPEG4.ui prefMencoder.ui prefpreview.ui \ titlefactor.ui viewmpeg2.ui k9copy_LDFLAGS = $(all_libraries) $(KDE_RPATH) $(LIB_QT) -lDCOP $(LIB_TDECORE) $(LIB_TDEUI) -ltdefx $(LIB_KIO) -ltdetexteditor $(LIB_KPARTS) diff --git a/src/k9main.cpp b/src/k9main.cpp index 1035e34..f10d15c 100644 --- a/src/k9main.cpp +++ b/src/k9main.cpp @@ -53,9 +53,9 @@ #include #include #include -#include -#include -#include +#include +#include +#include #include #include #include diff --git a/src/k9main.h b/src/k9main.h index 0a75343..9c131e6 100644 --- a/src/k9main.h +++ b/src/k9main.h @@ -16,7 +16,7 @@ #include "k9cddrive.h" #include "images.h" #include "k9mainw.h" -#include "kconfigdlg.h" +#include "tdeconfigdlg.h" #include "k9playbackoptions.h" #include #include @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include "k9copy.h" #include diff --git a/src/k9settings.h b/src/k9settings.h index 60ffb45..52d0d55 100644 --- a/src/k9settings.h +++ b/src/k9settings.h @@ -13,7 +13,7 @@ #define K9SETTINGS_H #include "k9common.h" -#include "kconfigdlg.h" +#include "tdeconfigdlg.h" #include "k9prefdvd.h" #include "k9prefmpeg4.h" #include "k9prefmencoder.h" diff --git a/src/kconfigdlg.cpp b/src/kconfigdlg.cpp deleted file mode 100644 index f0a39bb..0000000 --- a/src/kconfigdlg.cpp +++ /dev/null @@ -1,151 +0,0 @@ -/************************************************************************** -* Copyright (C) 2005 by Jean-Michel Petit * -* jm_petit@laposte.net * -* * -* 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 "kconfigdlg.h" -#include "kmessagebox.h" - -#include -#include - -#include -#include -#include "k9config.h" - -kConfigDlg::kConfigDlg(TQWidget *parent) - : configDlg(parent) -{ - TQStringList ldev; - TQStringList llabels; - TQStringList lIO; - tblDevices->setColumnWidth(0,150); - tblDevices->setColumnWidth(1,210); - tblDevices->setColumnWidth(2,40); - tblDevices->setColumnWidth(3,45); - //KSimpleConfig settings("K9Copy"); - k9Config config; - - ldev=config.getDevices(); - llabels=config.getDevicesLabels(); - lIO=config.getDevicesIO(); - int row=0; - for ( TQStringList::Iterator it = ldev.begin(); it != ldev.end(); ++it ) - { - tblDevices->setNumRows(row+1); - tblDevices->setText(row,0,(*it)); - TQStringList::Iterator it2=llabels.at(row); - tblDevices->setText(row,1,(*it2)); - - row++; - - } - for ( int j = 0; j < tblDevices->numRows(); ++j ) - { - TQCheckTableItem *I = new TQCheckTableItem( tblDevices, "" ); - TQCheckTableItem *O = new TQCheckTableItem( tblDevices, "" ) ; - TQStringList::Iterator it=lIO.at(j); - TQString c=(*it); - if((c =="I") || (c =="IO")) I->setChecked(true); - if((c =="O") || (c =="IO")) O->setChecked(true); - tblDevices->setItem( j, 2, I ); - tblDevices->setItem( j, 3, O); - } - - -// buttonCancel->setIconSet(KStdGuiItem::cancel().iconSet()); -// buttonOk->setIconSet(KStdGuiItem::ok().iconSet()); -} - - -kConfigDlg::~kConfigDlg() -{} - - - - -/*! - \fn kConfigDlg::bAddClick() - */ -void kConfigDlg::bAddClick() -{ - tblDevices->setNumRows(tblDevices->numRows()+1); - TQCheckTableItem *I = new TQCheckTableItem( tblDevices, "" ); - TQCheckTableItem *O = new TQCheckTableItem( tblDevices, "" ) ; - tblDevices->setItem( tblDevices->numRows()-1, 2, I ); - tblDevices->setItem( tblDevices->numRows()-1, 3, O); -} - - -/*! - \fn kConfigDlg::bRemoveClick() - */ -void kConfigDlg::bRemoveClick() -{ - tblDevices->removeRow(tblDevices->currentRow()); -} - - -void kConfigDlg::save() -{ - TQStringList ldev; - TQStringList llabels; - TQStringList lIO; - //KSimpleConfig settings("K9Copy"); - k9Config config; - ldev.clear(); - llabels.clear(); - for (int i=0;inumRows();i++) - { - TQString c=tblDevices->text(i,0); - if (!c.isEmpty()) - { - if (TQFile::exists(c)) - { - ldev.append(tblDevices->text(i,0)); - c=tblDevices->text(i,1); - if (c.isEmpty()) c=tblDevices->text(i,0); - llabels.append(c); - TQCheckTableItem *I = (TQCheckTableItem*)tblDevices->item(i,2); - TQCheckTableItem *O = (TQCheckTableItem*)tblDevices->item(i,3); - if (O->isChecked() && I->isChecked()) - { - lIO.append("IO"); - } - else - { - if (O->isChecked()) lIO.append("O"); - if (I->isChecked()) lIO.append("I"); - if ((!O->isChecked()) && (!I->isChecked())) - { - lIO.append("x"); - } - } - } - else - { - KMessageBox::error( this, c + " is not a valid device", "Devices"); - } - } - } - - config.setDevicesLabels(llabels); - config.setDevices(ldev); - config.setDevicesIO(lIO); - config.save(); -} diff --git a/src/kconfigdlg.h b/src/kconfigdlg.h deleted file mode 100644 index 6bf098e..0000000 --- a/src/kconfigdlg.h +++ /dev/null @@ -1,44 +0,0 @@ -/************************************************************************** -* Copyright (C) 2005 by Jean-Michel Petit * -* jm_petit@laposte.net * -* * -* 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. * -***************************************************************************/ -#ifndef KCONFIGDLG_H -#define KCONFIGDLG_H - -#include "k9common.h" -#include -#include -#include -#include - -/** -@author Jean-Michel PETIT -*/ -class kConfigDlg : public configDlg -{ -public: - kConfigDlg(TQWidget *parent); - - ~kConfigDlg(); - void bAddClick(); - void bRemoveClick(); - void save(); - -}; - -#endif diff --git a/src/tdeconfigdlg.cpp b/src/tdeconfigdlg.cpp new file mode 100644 index 0000000..3f001f5 --- /dev/null +++ b/src/tdeconfigdlg.cpp @@ -0,0 +1,151 @@ +/************************************************************************** +* Copyright (C) 2005 by Jean-Michel Petit * +* jm_petit@laposte.net * +* * +* 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 "tdeconfigdlg.h" +#include "kmessagebox.h" + +#include +#include + +#include +#include +#include "k9config.h" + +kConfigDlg::kConfigDlg(TQWidget *parent) + : configDlg(parent) +{ + TQStringList ldev; + TQStringList llabels; + TQStringList lIO; + tblDevices->setColumnWidth(0,150); + tblDevices->setColumnWidth(1,210); + tblDevices->setColumnWidth(2,40); + tblDevices->setColumnWidth(3,45); + //KSimpleConfig settings("K9Copy"); + k9Config config; + + ldev=config.getDevices(); + llabels=config.getDevicesLabels(); + lIO=config.getDevicesIO(); + int row=0; + for ( TQStringList::Iterator it = ldev.begin(); it != ldev.end(); ++it ) + { + tblDevices->setNumRows(row+1); + tblDevices->setText(row,0,(*it)); + TQStringList::Iterator it2=llabels.at(row); + tblDevices->setText(row,1,(*it2)); + + row++; + + } + for ( int j = 0; j < tblDevices->numRows(); ++j ) + { + TQCheckTableItem *I = new TQCheckTableItem( tblDevices, "" ); + TQCheckTableItem *O = new TQCheckTableItem( tblDevices, "" ) ; + TQStringList::Iterator it=lIO.at(j); + TQString c=(*it); + if((c =="I") || (c =="IO")) I->setChecked(true); + if((c =="O") || (c =="IO")) O->setChecked(true); + tblDevices->setItem( j, 2, I ); + tblDevices->setItem( j, 3, O); + } + + +// buttonCancel->setIconSet(KStdGuiItem::cancel().iconSet()); +// buttonOk->setIconSet(KStdGuiItem::ok().iconSet()); +} + + +kConfigDlg::~kConfigDlg() +{} + + + + +/*! + \fn kConfigDlg::bAddClick() + */ +void kConfigDlg::bAddClick() +{ + tblDevices->setNumRows(tblDevices->numRows()+1); + TQCheckTableItem *I = new TQCheckTableItem( tblDevices, "" ); + TQCheckTableItem *O = new TQCheckTableItem( tblDevices, "" ) ; + tblDevices->setItem( tblDevices->numRows()-1, 2, I ); + tblDevices->setItem( tblDevices->numRows()-1, 3, O); +} + + +/*! + \fn kConfigDlg::bRemoveClick() + */ +void kConfigDlg::bRemoveClick() +{ + tblDevices->removeRow(tblDevices->currentRow()); +} + + +void kConfigDlg::save() +{ + TQStringList ldev; + TQStringList llabels; + TQStringList lIO; + //KSimpleConfig settings("K9Copy"); + k9Config config; + ldev.clear(); + llabels.clear(); + for (int i=0;inumRows();i++) + { + TQString c=tblDevices->text(i,0); + if (!c.isEmpty()) + { + if (TQFile::exists(c)) + { + ldev.append(tblDevices->text(i,0)); + c=tblDevices->text(i,1); + if (c.isEmpty()) c=tblDevices->text(i,0); + llabels.append(c); + TQCheckTableItem *I = (TQCheckTableItem*)tblDevices->item(i,2); + TQCheckTableItem *O = (TQCheckTableItem*)tblDevices->item(i,3); + if (O->isChecked() && I->isChecked()) + { + lIO.append("IO"); + } + else + { + if (O->isChecked()) lIO.append("O"); + if (I->isChecked()) lIO.append("I"); + if ((!O->isChecked()) && (!I->isChecked())) + { + lIO.append("x"); + } + } + } + else + { + KMessageBox::error( this, c + " is not a valid device", "Devices"); + } + } + } + + config.setDevicesLabels(llabels); + config.setDevices(ldev); + config.setDevicesIO(lIO); + config.save(); +} diff --git a/src/tdeconfigdlg.h b/src/tdeconfigdlg.h new file mode 100644 index 0000000..6bf098e --- /dev/null +++ b/src/tdeconfigdlg.h @@ -0,0 +1,44 @@ +/************************************************************************** +* Copyright (C) 2005 by Jean-Michel Petit * +* jm_petit@laposte.net * +* * +* 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. * +***************************************************************************/ +#ifndef KCONFIGDLG_H +#define KCONFIGDLG_H + +#include "k9common.h" +#include +#include +#include +#include + +/** +@author Jean-Michel PETIT +*/ +class kConfigDlg : public configDlg +{ +public: + kConfigDlg(TQWidget *parent); + + ~kConfigDlg(); + void bAddClick(); + void bRemoveClick(); + void save(); + +}; + +#endif -- cgit v1.2.1