summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugin/smb4k_konqplugin.cpp86
-rw-r--r--plugin/smb4k_konqplugin.h32
-rw-r--r--smb4k/browser/smb4knetworkbrowser.cpp34
-rw-r--r--smb4k/browser/smb4knetworkbrowser.h19
-rw-r--r--smb4k/browser/smb4knetworkbrowser_part.cpp264
-rw-r--r--smb4k/browser/smb4knetworkbrowser_part.h50
-rw-r--r--smb4k/browser/smb4knetworkbrowseritem.cpp36
-rw-r--r--smb4k/browser/smb4knetworkbrowseritem.h24
-rw-r--r--smb4k/browser/smb4knetworkbrowsertooltip.cpp152
-rw-r--r--smb4k/browser/smb4knetworkbrowsertooltip.h23
-rw-r--r--smb4k/configdlg/smb4kauthoptions.cpp70
-rw-r--r--smb4k/configdlg/smb4kauthoptions.h11
-rw-r--r--smb4k/configdlg/smb4kconfigdialog.cpp250
-rw-r--r--smb4k/configdlg/smb4kconfigdialog.h16
-rw-r--r--smb4k/configdlg/smb4knetworkoptions.cpp40
-rw-r--r--smb4k/configdlg/smb4knetworkoptions.h11
-rw-r--r--smb4k/configdlg/smb4krsyncoptions.cpp248
-rw-r--r--smb4k/configdlg/smb4krsyncoptions.h11
-rw-r--r--smb4k/configdlg/smb4ksambaoptions.cpp406
-rw-r--r--smb4k/configdlg/smb4ksambaoptions.h17
-rw-r--r--smb4k/configdlg/smb4kshareoptions.cpp42
-rw-r--r--smb4k/configdlg/smb4kshareoptions.h11
-rw-r--r--smb4k/configdlg/smb4ksuperuseroptions.cpp44
-rw-r--r--smb4k/configdlg/smb4ksuperuseroptions.h11
-rw-r--r--smb4k/configdlg/smb4kuserinterfaceoptions.cpp130
-rw-r--r--smb4k/configdlg/smb4kuserinterfaceoptions.h9
-rw-r--r--smb4k/core/smb4k.kcfg6
-rw-r--r--smb4k/core/smb4kauthinfo.cpp8
-rw-r--r--smb4k/core/smb4kauthinfo.h46
-rw-r--r--smb4k/core/smb4kbookmark.cpp24
-rw-r--r--smb4k/core/smb4kbookmark.h56
-rw-r--r--smb4k/core/smb4kbookmarkhandler.cpp96
-rw-r--r--smb4k/core/smb4kbookmarkhandler.h27
-rw-r--r--smb4k/core/smb4kcore.cpp74
-rw-r--r--smb4k/core/smb4kcore.h17
-rw-r--r--smb4k/core/smb4kerror.cpp66
-rw-r--r--smb4k/core/smb4kerror.h12
-rw-r--r--smb4k/core/smb4kfileio.cpp318
-rw-r--r--smb4k/core/smb4kfileio.h27
-rw-r--r--smb4k/core/smb4kglobal.cpp10
-rw-r--r--smb4k/core/smb4kglobal.h14
-rw-r--r--smb4k/core/smb4kglobal_p.cpp14
-rw-r--r--smb4k/core/smb4kglobal_p.h14
-rw-r--r--smb4k/core/smb4khomesshareshandler.cpp100
-rw-r--r--smb4k/core/smb4khomesshareshandler.h25
-rw-r--r--smb4k/core/smb4kmounter.cpp422
-rw-r--r--smb4k/core/smb4kmounter.h47
-rw-r--r--smb4k/core/smb4kmounter_p.cpp42
-rw-r--r--smb4k/core/smb4kmounter_p.h58
-rw-r--r--smb4k/core/smb4knetworkitems.cpp50
-rw-r--r--smb4k/core/smb4knetworkitems.h110
-rw-r--r--smb4k/core/smb4kpasswordhandler.cpp242
-rw-r--r--smb4k/core/smb4kpasswordhandler.h29
-rw-r--r--smb4k/core/smb4kpreviewer.cpp84
-rw-r--r--smb4k/core/smb4kpreviewer.h23
-rw-r--r--smb4k/core/smb4kpreviewitem.cpp16
-rw-r--r--smb4k/core/smb4kpreviewitem.h50
-rw-r--r--smb4k/core/smb4kprint.cpp88
-rw-r--r--smb4k/core/smb4kprint.h15
-rw-r--r--smb4k/core/smb4kprintinfo.cpp8
-rw-r--r--smb4k/core/smb4kprintinfo.h34
-rw-r--r--smb4k/core/smb4ksambaoptionshandler.cpp392
-rw-r--r--smb4k/core/smb4ksambaoptionshandler.h41
-rw-r--r--smb4k/core/smb4ksambaoptionsinfo.cpp28
-rw-r--r--smb4k/core/smb4ksambaoptionsinfo.h36
-rw-r--r--smb4k/core/smb4kscanner.cpp362
-rw-r--r--smb4k/core/smb4kscanner.h87
-rw-r--r--smb4k/core/smb4kscanner_p.cpp24
-rw-r--r--smb4k/core/smb4kscanner_p.h28
-rw-r--r--smb4k/core/smb4ksettings.cpp870
-rw-r--r--smb4k/core/smb4kshare.cpp34
-rw-r--r--smb4k/core/smb4kshare.h32
-rw-r--r--smb4k/core/smb4ksynchronizationinfo.cpp8
-rw-r--r--smb4k/core/smb4ksynchronizationinfo.h18
-rw-r--r--smb4k/core/smb4ksynchronizer.cpp78
-rw-r--r--smb4k/core/smb4ksynchronizer.h21
-rw-r--r--smb4k/dialogs/smb4kbookmarkeditor.cpp62
-rw-r--r--smb4k/dialogs/smb4kbookmarkeditor.h9
-rw-r--r--smb4k/dialogs/smb4kcustomoptionsdialog.cpp198
-rw-r--r--smb4k/dialogs/smb4kcustomoptionsdialog.h27
-rw-r--r--smb4k/dialogs/smb4kmountdialog.cpp74
-rw-r--r--smb4k/dialogs/smb4kmountdialog.h11
-rw-r--r--smb4k/dialogs/smb4kpreviewdialog.cpp84
-rw-r--r--smb4k/dialogs/smb4kpreviewdialog.h17
-rw-r--r--smb4k/dialogs/smb4kprintdialog.cpp74
-rw-r--r--smb4k/dialogs/smb4kprintdialog.h13
-rw-r--r--smb4k/dialogs/smb4ksynchronizationdialog.cpp108
-rw-r--r--smb4k/dialogs/smb4ksynchronizationdialog.h5
-rw-r--r--smb4k/iconview/smb4ksharesiconview.cpp36
-rw-r--r--smb4k/iconview/smb4ksharesiconview.h35
-rw-r--r--smb4k/iconview/smb4ksharesiconview_part.cpp76
-rw-r--r--smb4k/iconview/smb4ksharesiconview_part.h24
-rw-r--r--smb4k/iconview/smb4ksharesiconviewitem.cpp24
-rw-r--r--smb4k/iconview/smb4ksharesiconviewitem.h24
-rw-r--r--smb4k/iconview/smb4ksharesiconviewtooltip.cpp142
-rw-r--r--smb4k/iconview/smb4ksharesiconviewtooltip.h41
-rw-r--r--smb4k/listview/smb4kshareslistview.cpp44
-rw-r--r--smb4k/listview/smb4kshareslistview.h31
-rw-r--r--smb4k/listview/smb4kshareslistview_part.cpp112
-rw-r--r--smb4k/listview/smb4kshareslistview_part.h24
-rw-r--r--smb4k/listview/smb4kshareslistviewitem.cpp92
-rw-r--r--smb4k/listview/smb4kshareslistviewitem.h24
-rw-r--r--smb4k/listview/smb4kshareslistviewtooltip.cpp142
-rw-r--r--smb4k/listview/smb4kshareslistviewtooltip.h41
-rw-r--r--smb4k/main.cpp26
-rw-r--r--smb4k/searchdlg/smb4ksearchdialog.cpp56
-rw-r--r--smb4k/searchdlg/smb4ksearchdialog.h23
-rw-r--r--smb4k/searchdlg/smb4ksearchdialog_part.cpp46
-rw-r--r--smb4k/searchdlg/smb4ksearchdialog_part.h24
-rw-r--r--smb4k/searchdlg/smb4ksearchdialogitem.cpp14
-rw-r--r--smb4k/searchdlg/smb4ksearchdialogitem.h10
-rw-r--r--smb4k/smb4k.cpp142
-rw-r--r--smb4k/smb4k.h9
-rw-r--r--smb4k/smb4ksystemtray.cpp216
-rw-r--r--smb4k/smb4ksystemtray.h5
-rw-r--r--utilities/smb4k_kill.cpp2
-rw-r--r--utilities/smb4k_mount.cpp2
-rw-r--r--utilities/smb4k_mv.cpp2
-rw-r--r--utilities/smb4k_umount.cpp2
119 files changed, 4298 insertions, 4253 deletions
diff --git a/plugin/smb4k_konqplugin.cpp b/plugin/smb4k_konqplugin.cpp
index 3cab7fa..e66ba97 100644
--- a/plugin/smb4k_konqplugin.cpp
+++ b/plugin/smb4k_konqplugin.cpp
@@ -1,6 +1,6 @@
/***************************************************************************
* Copyright (C) 2004 by Massimo Callegari *
- * massimocallegari@yahoo.it *
+ * massitqmocallegari@yahoo.it *
* *
* 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 *
@@ -18,21 +18,21 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
***************************************************************************/
-// Qt includes
-#include <qapplication.h>
-#include <qlabel.h>
-#include <qtooltip.h>
-#include <qstring.h>
-#include <qwidget.h>
-#include <qlayout.h>
-#include <qpainter.h>
-#include <qheader.h>
-#include <qvaluelist.h>
-#include <qpixmap.h>
-#include <qtoolbutton.h>
-#include <qtoolbar.h>
-#include <qdir.h>
-#include <qpushbutton.h>
+// TQt includes
+#include <tqapplication.h>
+#include <tqlabel.h>
+#include <tqtooltip.h>
+#include <tqstring.h>
+#include <tqwidget.h>
+#include <tqlayout.h>
+#include <tqpainter.h>
+#include <tqheader.h>
+#include <tqvaluelist.h>
+#include <tqpixmap.h>
+#include <tqtoolbutton.h>
+#include <tqtoolbar.h>
+#include <tqdir.h>
+#include <tqpushbutton.h>
// KDE includes
#include <klibloader.h>
@@ -53,23 +53,23 @@
#include "../smb4k/core/smb4kcore.h"
#include "../smb4k/core/smb4kdefs.h"
-smb4kWidget::smb4kWidget( QWidget * parent, const char * name, WFlags f )
- : QVBox(parent, name, f)
+smb4kWidget::smb4kWidget( TQWidget * tqparent, const char * name, WFlags f )
+ : TQVBox(tqparent, name, f)
{
// Nothing exciting to do !
}
-KonqSidebar_Smb4K::KonqSidebar_Smb4K(KInstance *inst,QObject *parent,QWidget *widgetParent, QString &desktopName, const char* name):
- KonqSidebarPlugin(inst,parent,widgetParent,desktopName,name)
+KonqSidebar_Smb4K::KonqSidebar_Smb4K(KInstance *inst,TQObject *tqparent,TQWidget *widgetParent, TQString &desktopName, const char* name):
+ KonqSidebarPlugin(inst,tqparent,widgetParent,desktopName,name)
{
widget = new smb4kWidget( widgetParent );
KToolBar *topBar = new KToolBar( widget, "Topbar" );
topBar->setIconSize(16);
- topBar->insertButton( "reload", 0, SIGNAL( clicked() ), this, SLOT( slotRescan() ) , TRUE, i18n( "Scan Network" ) );
- topBar->insertButton( "find", 1, SIGNAL( clicked() ), this, SLOT( slotSearch() ) , TRUE, i18n( "Search" ) );
- topBar->insertButton( "configure", 2, SIGNAL( clicked() ), this, SLOT( slotSmb4KOptionsDlg() ) , TRUE, i18n( "Configure" ) );
+ topBar->insertButton( "reload", 0, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotRescan() ) , TRUE, i18n( "Scan Network" ) );
+ topBar->insertButton( "tqfind", 1, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotSearch() ) , TRUE, i18n( "Search" ) );
+ topBar->insertButton( "configure", 2, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotSmb4KOptionsDlg() ) , TRUE, i18n( "Configure" ) );
//
// Browser widget:
@@ -78,7 +78,7 @@ KonqSidebar_Smb4K::KonqSidebar_Smb4K(KInstance *inst,QObject *parent,QWidget *wi
if ( browser_factory )
{
- m_browser_part = static_cast<KParts::Part *>( browser_factory->create( widget, "BrowserPart", "KParts::Part", QStringList( "konqplugin=\"true\"" ) ) );
+ m_browser_part = static_cast<KParts::Part *>( browser_factory->create( TQT_TQOBJECT(widget), "BrowserPart", "KParts::Part", TQStringList( "konqplugin=\"true\"" ) ) );
// Do nothing here. The network scan (and the mounting of recently used
// shares) will be done by Smb4KCore::init() below.
@@ -90,8 +90,8 @@ KonqSidebar_Smb4K::KonqSidebar_Smb4K(KInstance *inst,QObject *parent,QWidget *wi
return;
}
- connect( Smb4KCore::mounter(), SIGNAL( mountedShare( const QString &) ), this, SLOT( slotMountedShare( const QString & ) ) );
- connect( Smb4KCore::mounter(), SIGNAL( aboutToUnmount( const QString& ) ), this, SLOT( slotPrepareUnmount( const QString& ) ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( mountedShare( const TQString &) ), this, TQT_SLOT( slotMountedShare( const TQString & ) ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( aboutToUnmount( const TQString& ) ), this, TQT_SLOT( slotPrepareUnmount( const TQString& ) ) );
// Scan the network and remount recently used shares:
Smb4KCore::self()->init();
@@ -106,7 +106,7 @@ KonqSidebar_Smb4K::~KonqSidebar_Smb4K()
extern "C"
{
- void* create_konqsidebar_smb4k(KInstance *instance,QObject *par,QWidget *widp,QString &desktopname,const char *name)
+ void* create_konqsidebar_smb4k(KInstance *instance,TQObject *par,TQWidget *widp,TQString &desktopname,const char *name)
{
KGlobal::locale()->insertCatalogue("smb4k");
return new KonqSidebar_Smb4K(instance,par,widp,desktopname,name);
@@ -115,7 +115,7 @@ extern "C"
extern "C"
{
- bool add_konqsidebar_smb4k(QString* fn, QString* /*param*/, QMap<QString,QString> *map)
+ bool add_konqsidebar_smb4k(TQString* fn, TQString* /*param*/, TQMap<TQString,TQString> *map)
{
map->insert("Type","Link");
map->insert("Icon","smb4k");
@@ -136,7 +136,7 @@ void KonqSidebar_Smb4K::handleURL(const KURL &url)
void KonqSidebar_Smb4K::slotRescan()
{
// Send a custom rescan event to the browser part.
- QApplication::postEvent( m_browser_part, new QCustomEvent( EVENT_SCAN_NETWORK ) );
+ TQApplication::postEvent( m_browser_part, new TQCustomEvent( EVENT_SCAN_NETWORK ) );
}
void KonqSidebar_Smb4K::slotSearch()
@@ -149,22 +149,22 @@ void KonqSidebar_Smb4K::slotSearch()
KDialogBase *searchDialog = new KDialogBase( KDialogBase::Plain, i18n( "Search Dialog" ), KDialogBase::Close,
KDialogBase::NoDefault, widget, "sd", true, true );
- QFrame *frame = searchDialog->plainPage();
+ TQFrame *frame = searchDialog->plainPage();
- m_search_part = static_cast<KParts::Part *>( search_factory->create( frame, "SearchDialogPart", "KParts::Part" ) );
+ m_search_part = static_cast<KParts::Part *>( search_factory->create( TQT_TQOBJECT(frame), "SearchDialogPart", "KParts::Part" ) );
if ( m_search_part )
{
- QGridLayout *layout = new QGridLayout( frame );
- layout->setSpacing( 10 );
- layout->setMargin( 0 );
- layout->addWidget ( m_search_part->widget(), 0, 0, 0 );
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
+ tqlayout->setSpacing( 10 );
+ tqlayout->setMargin( 0 );
+ tqlayout->addWidget ( m_search_part->widget(), 0, 0, 0 );
searchDialog->resize(400,300);
// We do not want the dialog to be closed if the user presses return.
// Instead we want that a search is started:
searchDialog->actionButton( KDialogBase::Close )->setAutoDefault( false );
- //connect( m_search_dialog, SIGNAL( searchResult( Smb4KHostItem * ) ), this, SLOT( slotInsertItem( Smb4KHostItem * ) ) );
+ //connect( m_search_dialog, TQT_SIGNAL( searchResult( Smb4KHostItem * ) ), this, TQT_SLOT( slotInsertItem( Smb4KHostItem * ) ) );
searchDialog->show();
}
@@ -188,11 +188,11 @@ void KonqSidebar_Smb4K::slotSmb4KOptionsDlg()
if ( config_factory )
{
- KConfigDialog *dlg = static_cast<KConfigDialog *>( config_factory->create( widget, "ConfigDialog", "KConfigDialog" ) );
+ KConfigDialog *dlg = static_cast<KConfigDialog *>( TQT_TQWIDGET(config_factory->create( TQT_TQOBJECT(widget), "ConfigDialog", "KConfigDialog" )) );
if ( dlg )
{
- connect( dlg, SIGNAL( settingsChanged() ), this, SLOT( slotSettingsChanged() ) );
+ connect( dlg, TQT_SIGNAL( settingsChanged() ), this, TQT_SLOT( slotSettingsChanged() ) );
dlg->show();
}
@@ -208,19 +208,19 @@ void KonqSidebar_Smb4K::slotSmb4KOptionsDlg()
void KonqSidebar_Smb4K::slotSettingsChanged()
{
- QApplication::postEvent( m_browser_part, new QCustomEvent( EVENT_LOAD_SETTINGS ) );
+ TQApplication::postEvent( m_browser_part, new TQCustomEvent( EVENT_LOAD_SETTINGS ) );
}
-void KonqSidebar_Smb4K::slotMountedShare( const QString &mountedShare )
+void KonqSidebar_Smb4K::slotMountedShare( const TQString &mountedShare )
{
emit openURLRequest( KURL(mountedShare) );
}
-void KonqSidebar_Smb4K::slotPrepareUnmount( const QString &mountpoint )
+void KonqSidebar_Smb4K::slotPrepareUnmount( const TQString &mountpoint )
{
- if ( QString::compare( currentKonquerorURL, mountpoint ) == 0 )
+ if ( TQString::compare( currentKonquerorURL, mountpoint ) == 0 )
{
- emit openURLRequest( KURL( QDir::home().canonicalPath() ) );
+ emit openURLRequest( KURL( TQDir::home().canonicalPath() ) );
}
else
{
diff --git a/plugin/smb4k_konqplugin.h b/plugin/smb4k_konqplugin.h
index 7f57324..fbefb26 100644
--- a/plugin/smb4k_konqplugin.h
+++ b/plugin/smb4k_konqplugin.h
@@ -26,10 +26,10 @@
#endif
#include <konqsidebarplugin.h>
-#include <qstring.h>
-#include <qwidget.h>
-#include <qvbox.h>
-#include <qwidgetstack.h>
+#include <tqstring.h>
+#include <tqwidget.h>
+#include <tqvbox.h>
+#include <tqwidgetstack.h>
#include <kpopupmenu.h>
#include <ktoolbar.h>
#include <khtml_part.h>
@@ -40,11 +40,12 @@
#include <kparts/factory.h>
-class smb4kWidget : public QVBox
+class smb4kWidget : public TQVBox
{
Q_OBJECT
+ TQ_OBJECT
public:
- smb4kWidget( QWidget * parent = 0, const char * name = 0, WFlags f = 0 );
+ smb4kWidget( TQWidget * tqparent = 0, const char * name = 0, WFlags f = 0 );
private:
@@ -53,25 +54,26 @@ private:
class KonqSidebar_Smb4K : public KonqSidebarPlugin
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Construct a @ref KonqSidebarPlugin.
*
* @param inst The sidebar's kinstance class.
- * @param parent The sidebar internal button info class responsible for this plugin.
+ * @param tqparent The sidebar internal button info class responsible for this plugin.
* @param widgetParent The container which will contain the plugins widget.
* @param desktopName The filename of the configuration file.
- * @param name A Qt object name for your plugin.
+ * @param name A TQt object name for your plugin.
**/
- KonqSidebar_Smb4K(KInstance *inst,QObject *parent,QWidget *widgetParent, QString &desktopName, const char* name=0);
+ KonqSidebar_Smb4K(KInstance *inst,TQObject *tqparent,TQWidget *widgetParent, TQString &desktopName, const char* name=0);
/** destructor */
~KonqSidebar_Smb4K();
KHTMLPart* m_part;
- virtual QWidget *getWidget(){ return (QWidget*)widget;}
- virtual void *provides(const QString &) {return 0;}
- void emitStatusBarText (const QString &) {;}
+ virtual TQWidget *getWidget(){ return (TQWidget*)widget;}
+ virtual void *provides(const TQString &) {return 0;}
+ void emitStatusBarText (const TQString &) {;}
private:
/**
@@ -90,7 +92,7 @@ protected:
*/
smb4kWidget *widget;
- QString currentKonquerorURL;
+ TQString currentKonquerorURL;
virtual void handleURL(const KURL &url);
@@ -117,7 +119,7 @@ protected slots:
/**
* Called from mounter when a share is mounted
*/
- void slotMountedShare( const QString & );
+ void slotMountedShare( const TQString & );
/**
* Called from the mounter just before a share is unmounted. This slot
* changes the URL to the user's home so that we can unmount the share
@@ -126,7 +128,7 @@ protected slots:
* @param mountpoint The mount point of the share that's going to
* be unmounted.
*/
- void slotPrepareUnmount( const QString &mounpoint );
+ void slotPrepareUnmount( const TQString &mounpoint );
signals:
// see <konqsidebarplugin.h>
void openURLRequest(const KURL &url,
diff --git a/smb4k/browser/smb4knetworkbrowser.cpp b/smb4k/browser/smb4knetworkbrowser.cpp
index 67c7b87..91562e0 100644
--- a/smb4k/browser/smb4knetworkbrowser.cpp
+++ b/smb4k/browser/smb4knetworkbrowser.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qheader.h>
-#include <qtimer.h>
+// TQt includes
+#include <tqheader.h>
+#include <tqtimer.h>
// KDE includes
#include <klocale.h>
@@ -37,8 +37,8 @@
#include "../core/smb4ksettings.h"
-Smb4KNetworkBrowser::Smb4KNetworkBrowser( QWidget *parent, const char *name )
-: KListView( parent, name )
+Smb4KNetworkBrowser::Smb4KNetworkBrowser( TQWidget *tqparent, const char *name )
+: KListView( tqparent, name )
{
setRootIsDecorated( true );
setAllColumnsShowFocus( false );
@@ -53,14 +53,14 @@ Smb4KNetworkBrowser::Smb4KNetworkBrowser( QWidget *parent, const char *name )
addColumn( i18n( "Comment" ), -1 );
// Add some connections:
- connect( this, SIGNAL( expanded( QListViewItem * ) ),
- this, SLOT( slotItemExpandedCollapsed( QListViewItem * ) ) );
+ connect( this, TQT_SIGNAL( expanded( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemExpandedCollapsed( TQListViewItem * ) ) );
- connect( this, SIGNAL( collapsed( QListViewItem * ) ),
- this, SLOT( slotItemExpandedCollapsed( QListViewItem * ) ) );
+ connect( this, TQT_SIGNAL( collapsed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemExpandedCollapsed( TQListViewItem * ) ) );
- connect( this, SIGNAL( executed( QListViewItem * ) ),
- this, SLOT( slotItemExecuted( QListViewItem * ) ) );
+ connect( this, TQT_SIGNAL( executed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemExecuted( TQListViewItem * ) ) );
}
@@ -81,7 +81,7 @@ void Smb4KNetworkBrowser::blockToolTips( bool block )
}
-void Smb4KNetworkBrowser::contentsMouseMoveEvent( QMouseEvent *e )
+void Smb4KNetworkBrowser::contentsMouseMoveEvent( TQMouseEvent *e )
{
// Store the *global* position of the mouse:
m_pos = e->globalPos();
@@ -114,7 +114,7 @@ void Smb4KNetworkBrowser::contentsMouseMoveEvent( QMouseEvent *e )
{
m_tooltip = new Smb4KNetworkBrowserToolTip( item );
- QTimer::singleShot( 2000, this, SLOT( slotShowToolTip() ) );
+ TQTimer::singleShot( 2000, this, TQT_SLOT( slotShowToolTip() ) );
}
else
{
@@ -133,7 +133,7 @@ void Smb4KNetworkBrowser::contentsMouseMoveEvent( QMouseEvent *e )
{
m_tooltip = new Smb4KNetworkBrowserToolTip( item );
- QTimer::singleShot( 2000, this, SLOT( slotShowToolTip() ) );
+ TQTimer::singleShot( 2000, this, TQT_SLOT( slotShowToolTip() ) );
}
else
{
@@ -161,10 +161,10 @@ void Smb4KNetworkBrowser::contentsMouseMoveEvent( QMouseEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
-void Smb4KNetworkBrowser::slotItemExpandedCollapsed( QListViewItem *item )
+void Smb4KNetworkBrowser::slotItemExpandedCollapsed( TQListViewItem *item )
{
// Explicitly select the item, because this won't be
// done if the user clicked on the root decoration.
@@ -173,7 +173,7 @@ void Smb4KNetworkBrowser::slotItemExpandedCollapsed( QListViewItem *item )
}
-void Smb4KNetworkBrowser::slotItemExecuted( QListViewItem *item )
+void Smb4KNetworkBrowser::slotItemExecuted( TQListViewItem *item )
{
if ( m_tooltip )
{
diff --git a/smb4k/browser/smb4knetworkbrowser.h b/smb4k/browser/smb4knetworkbrowser.h
index ade9e64..9c7ebda 100644
--- a/smb4k/browser/smb4knetworkbrowser.h
+++ b/smb4k/browser/smb4knetworkbrowser.h
@@ -40,16 +40,17 @@ class Smb4KNetworkBrowserToolTip;
class Smb4KNetworkBrowser : public KListView
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The widget name
*/
- Smb4KNetworkBrowser( QWidget *parent = 0, const char *name = 0 );
+ Smb4KNetworkBrowser( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -67,7 +68,7 @@ class Smb4KNetworkBrowser : public KListView
*
* @returns the position of the mouse.
*/
- const QPoint &mousePosition() { return m_pos; }
+ const TQPoint &mousePosition() { return m_pos; }
/**
* Returns a pointer to the current tool tip or NULL, if there
@@ -103,22 +104,22 @@ class Smb4KNetworkBrowser : public KListView
protected:
/**
- * Reimplemented from QListView. This slot keeps track of the
+ * Reimplemented from TQListView. This slot keeps track of the
* mouse position and handles the tool tips.
*
* @param e The mouse event
*/
- void contentsMouseMoveEvent( QMouseEvent *e );
+ void contentsMouseMoveEvent( TQMouseEvent *e );
protected slots:
/**
- * This slot is called whenever a QListViewItem is expanded or
+ * This slot is called whenever a TQListViewItem is expanded or
* collapsed. At the moment it is only used to select the item.
*
* @param item The list view item that has been
* expanded/collapsed.
*/
- void slotItemExpandedCollapsed( QListViewItem *item );
+ void slotItemExpandedCollapsed( TQListViewItem *item );
/**
* This slot is called when the user executed an item. It is used
@@ -126,7 +127,7 @@ class Smb4KNetworkBrowser : public KListView
*
* @param item The item that has been executed.
*/
- void slotItemExecuted( QListViewItem *item );
+ void slotItemExecuted( TQListViewItem *item );
/**
* This slot shows the tool tip.
@@ -137,7 +138,7 @@ class Smb4KNetworkBrowser : public KListView
/**
* The global position of the mouse with respect to the widget.
*/
- QPoint m_pos;
+ TQPoint m_pos;
/**
* The tool tip for the network browser
diff --git a/smb4k/browser/smb4knetworkbrowser_part.cpp b/smb4k/browser/smb4knetworkbrowser_part.cpp
index 2773872..f116d55 100644
--- a/smb4k/browser/smb4knetworkbrowser_part.cpp
+++ b/smb4k/browser/smb4knetworkbrowser_part.cpp
@@ -24,8 +24,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qheader.h>
+// TQt includes
+#include <tqheader.h>
// KDE includes
#include <kaboutdata.h>
@@ -61,9 +61,9 @@ KInstance *Smb4KNetworkBrowserPartFactory::m_instance = 0L;
KAboutData *Smb4KNetworkBrowserPartFactory::m_about = 0L;
-Smb4KNetworkBrowserPart::Smb4KNetworkBrowserPart( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name, Mode mode )
-: KParts::Part( parent, name ), m_mode( mode )
+Smb4KNetworkBrowserPart::Smb4KNetworkBrowserPart( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name, Mode mode )
+: KParts::Part( tqparent, name ), m_mode( mode )
{
// First of all we need an instance:
setInstance( Smb4KNetworkBrowserPartFactory::instance() );
@@ -72,7 +72,7 @@ Smb4KNetworkBrowserPart::Smb4KNetworkBrowserPart( QWidget *parentWidget, const c
setXMLFile( "smb4knetworkbrowser_part.rc" );
// Set the widget of this part:
- m_widget = new Smb4KNetworkBrowser( parentWidget, widgetName );
+ m_widget = new Smb4KNetworkBrowser( tqparentWidget, widgetName );
setWidget( m_widget );
// Set up the actions.
@@ -84,50 +84,50 @@ Smb4KNetworkBrowserPart::Smb4KNetworkBrowserPart( QWidget *parentWidget, const c
loadSettings();
// Add some connections:
- connect( m_widget, SIGNAL( contextMenuRequested( QListViewItem *, const QPoint & , int ) ),
- this, SLOT( slotContextMenuRequested( QListViewItem *, const QPoint &, int ) ) );
+ connect( m_widget, TQT_SIGNAL( contextMenuRequested( TQListViewItem *, const TQPoint & , int ) ),
+ this, TQT_SLOT( slotContextMenuRequested( TQListViewItem *, const TQPoint &, int ) ) );
- connect( m_widget, SIGNAL( selectionChanged( QListViewItem * ) ),
- this, SLOT( slotSelectionChanged( QListViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( selectionChanged( TQListViewItem * ) ),
+ this, TQT_SLOT( slotSelectionChanged( TQListViewItem * ) ) );
- connect( m_widget, SIGNAL( pressed( QListViewItem * ) ),
- this, SLOT( slotPressed( QListViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( pressed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotPressed( TQListViewItem * ) ) );
- connect( m_widget, SIGNAL( expanded( QListViewItem * ) ),
- this, SLOT( slotItemExpanded( QListViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( expanded( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemExpanded( TQListViewItem * ) ) );
- connect( m_widget, SIGNAL( collapsed( QListViewItem * ) ),
- this, SLOT( slotItemCollapsed( QListViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( collapsed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemCollapsed( TQListViewItem * ) ) );
- connect( m_widget, SIGNAL( executed( QListViewItem * ) ),
- this, SLOT( slotItemExecuted( QListViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( executed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemExecuted( TQListViewItem * ) ) );
- connect( m_widget, SIGNAL( aboutToShowToolTip( Smb4KNetworkBrowserItem * ) ),
- this, SLOT( slotAboutToShowToolTip( Smb4KNetworkBrowserItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( aboutToShowToolTip( Smb4KNetworkBrowserItem * ) ),
+ this, TQT_SLOT( slotAboutToShowToolTip( Smb4KNetworkBrowserItem * ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( workgroups( const QValueList<Smb4KWorkgroupItem *> & ) ),
- this, SLOT( slotWorkgroups( const QValueList<Smb4KWorkgroupItem *> & ) ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( workgroups( const TQValueList<Smb4KWorkgroupItem *> & ) ),
+ this, TQT_SLOT( slotWorkgroups( const TQValueList<Smb4KWorkgroupItem *> & ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( members( const QString &, const QValueList<Smb4KHostItem *> & ) ),
- this, SLOT( slotWorkgroupMembers( const QString &, const QValueList<Smb4KHostItem *> & ) ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( members( const TQString &, const TQValueList<Smb4KHostItem *> & ) ),
+ this, TQT_SLOT( slotWorkgroupMembers( const TQString &, const TQValueList<Smb4KHostItem *> & ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( shares( const QString &, const QValueList<Smb4KShareItem *> & ) ),
- this, SLOT( slotShares( const QString &, const QValueList<Smb4KShareItem *> & ) ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( shares( const TQString &, const TQValueList<Smb4KShareItem *> & ) ),
+ this, TQT_SLOT( slotShares( const TQString &, const TQValueList<Smb4KShareItem *> & ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( ipAddress( Smb4KHostItem * ) ),
- this, SLOT( slotAddIPAddress( Smb4KHostItem * ) ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( ipAddress( Smb4KHostItem * ) ),
+ this, TQT_SLOT( slotAddIPAddress( Smb4KHostItem * ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( info( Smb4KHostItem * ) ),
- this, SLOT( slotAddInformation( Smb4KHostItem * ) ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( info( Smb4KHostItem * ) ),
+ this, TQT_SLOT( slotAddInformation( Smb4KHostItem * ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( hostAdded( Smb4KHostItem * ) ),
- this, SLOT( slotInsertHost( Smb4KHostItem * ) ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( hostAdded( Smb4KHostItem * ) ),
+ this, TQT_SLOT( slotInsertHost( Smb4KHostItem * ) ) );
- connect( Smb4KCore::mounter(), SIGNAL( updated() ),
- this, SLOT( slotMarkMountedShares() ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( updated() ),
+ this, TQT_SLOT( slotMarkMountedShares() ) );
- connect( Smb4KCore::self(), SIGNAL( runStateChanged() ),
- this, SLOT( slotRunStateChanged() ) );
+ connect( Smb4KCore::self(), TQT_SIGNAL( runStateChanged() ),
+ this, TQT_SLOT( slotRunStateChanged() ) );
}
@@ -139,35 +139,35 @@ Smb4KNetworkBrowserPart::~Smb4KNetworkBrowserPart()
void Smb4KNetworkBrowserPart::setupActions()
{
KAction *rescan = new KAction( i18n( "Scan Netwo&rk" ), "reload", KShortcut( CTRL+Key_R ),
- this, SLOT( slotRescan() ),
+ this, TQT_SLOT( slotRescan() ),
actionCollection(), "rescan_action" );
KAction *abort = new KAction( i18n( "&Abort" ) , "stop", KShortcut( CTRL+Key_A ),
- this, SLOT( slotAbort() ),
+ this, TQT_SLOT( slotAbort() ),
actionCollection(), "abort_action" );
KActionSeparator *sep1 = new KActionSeparator( actionCollection(),
"separator_1" );
KAction *manual_mount = new KAction( i18n( "M&ount Manually" ), "connect_creating", KShortcut( CTRL+Key_O ),
- this, SLOT( slotMountManually() ),
+ this, TQT_SLOT( slotMountManually() ),
actionCollection(), "mount_manually_action" );
KActionSeparator *sep2 = new KActionSeparator( actionCollection(),
"separator_2" );
KAction *auth = new KAction( i18n( "Au&thentication" ), "identity", KShortcut( CTRL+Key_T ),
- this, SLOT( slotAuthentication() ),
+ this, TQT_SLOT( slotAuthentication() ),
actionCollection(), "askpass_action" );
KAction *custom = new KAction( i18n( "&Custom Options" ), "samba", KShortcut( CTRL+Key_C ),
- this, SLOT( slotCustomOptions() ),
+ this, TQT_SLOT( slotCustomOptions() ),
actionCollection(), "custom_action" );
KAction *bookmark = new KAction( i18n( "Add &Bookmark" ), "bookmark_add", KShortcut( CTRL+Key_B ),
- this, SLOT( slotBookmark() ),
+ this, TQT_SLOT( slotBookmark() ),
actionCollection(), "bookmark_action" );
KAction *preview = new KAction( i18n( "Pre&view" ), "view_icon", KShortcut( CTRL+Key_V ),
- this, SLOT( slotPreview() ),
+ this, TQT_SLOT( slotPreview() ),
actionCollection(), "preview_action" );
KAction *print = new KAction( i18n( "&Print File" ), "printer1", KShortcut( CTRL+Key_P ),
- this, SLOT( slotPrint() ),
+ this, TQT_SLOT( slotPrint() ),
actionCollection(), "print_action" );
KAction *mount = new KAction( i18n( "&Mount" ), "hdd_mount", KShortcut( CTRL+Key_M ),
- this, SLOT( slotMount() ),
+ this, TQT_SLOT( slotMount() ),
actionCollection(), "mount_action" );
// Enable/disable the actions:
@@ -201,7 +201,7 @@ void Smb4KNetworkBrowserPart::setupActions()
if ( m_mode == KonqPlugin )
{
KAction *unmount = new KAction( i18n( "&Unmount" ), "hdd_unmount", KShortcut( CTRL+Key_U ),
- this, SLOT( slotUnmount() ),
+ this, TQT_SLOT( slotUnmount() ),
actionCollection(), "konq_umount_action" );
unmount->setEnabled( false );
@@ -215,39 +215,39 @@ void Smb4KNetworkBrowserPart::loadSettings()
if ( Smb4KSettings::showIPAddress() )
{
m_widget->setColumnWidth( Smb4KNetworkBrowser::IP, 10 );
- m_widget->setColumnWidthMode( Smb4KNetworkBrowser::IP, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KNetworkBrowser::IP, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KNetworkBrowser::IP );
}
else
{
m_widget->setColumnWidth( Smb4KNetworkBrowser::IP, 0 );
- m_widget->setColumnWidthMode( Smb4KNetworkBrowser::IP, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KNetworkBrowser::IP, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KNetworkBrowser::IP );
}
if ( Smb4KSettings::showType() )
{
m_widget->setColumnWidth( Smb4KNetworkBrowser::Type, 10 );
- m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Type, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Type, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KNetworkBrowser::Type );
}
else
{
m_widget->setColumnWidth( Smb4KNetworkBrowser::Type, 0 );
- m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Type, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Type, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KNetworkBrowser::Type );
}
if ( Smb4KSettings::showComment() )
{
m_widget->setColumnWidth( Smb4KNetworkBrowser::Comment, 10 );
- m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Comment, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Comment, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KNetworkBrowser::Comment );
}
else
{
m_widget->setColumnWidth( Smb4KNetworkBrowser::Comment, 0 );
- m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Comment, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KNetworkBrowser::Comment, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KNetworkBrowser::Comment );
}
@@ -264,7 +264,7 @@ void Smb4KNetworkBrowserPart::loadSettings()
}
-void Smb4KNetworkBrowserPart::customEvent( QCustomEvent *e )
+void Smb4KNetworkBrowserPart::customEvent( TQCustomEvent *e )
{
switch ( e->type() )
{
@@ -306,10 +306,10 @@ void Smb4KNetworkBrowserPart::customEvent( QCustomEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS (Smb4KNetworkBrowserPart)
+// TQT_SLOT IMPLEMENTATIONS (Smb4KNetworkBrowserPart)
/////////////////////////////////////////////////////////////////////////////
-void Smb4KNetworkBrowserPart::slotContextMenuRequested( QListViewItem *item, const QPoint &pos,
+void Smb4KNetworkBrowserPart::slotContextMenuRequested( TQListViewItem *item, const TQPoint &pos,
int /* column */ )
{
m_widget->blockToolTips( true );
@@ -329,7 +329,7 @@ void Smb4KNetworkBrowserPart::slotContextMenuRequested( QListViewItem *item, con
}
-void Smb4KNetworkBrowserPart::slotSelectionChanged( QListViewItem *item )
+void Smb4KNetworkBrowserPart::slotSelectionChanged( TQListViewItem *item )
{
Smb4KNetworkBrowserItem *browser_item = static_cast<Smb4KNetworkBrowserItem *>( item );
@@ -519,7 +519,7 @@ void Smb4KNetworkBrowserPart::slotSelectionChanged( QListViewItem *item )
}
-void Smb4KNetworkBrowserPart::slotPressed( QListViewItem *item )
+void Smb4KNetworkBrowserPart::slotPressed( TQListViewItem *item )
{
Smb4KNetworkBrowserItem *browser_item = static_cast<Smb4KNetworkBrowserItem *>( item );
@@ -584,7 +584,7 @@ void Smb4KNetworkBrowserPart::slotPressed( QListViewItem *item )
}
-void Smb4KNetworkBrowserPart::slotItemExpanded( QListViewItem *item )
+void Smb4KNetworkBrowserPart::slotItemExpanded( TQListViewItem *item )
{
Smb4KNetworkBrowserItem *browser_item = static_cast<Smb4KNetworkBrowserItem *>( item );
@@ -615,11 +615,11 @@ void Smb4KNetworkBrowserPart::slotItemExpanded( QListViewItem *item )
}
-void Smb4KNetworkBrowserPart::slotItemCollapsed( QListViewItem *item )
+void Smb4KNetworkBrowserPart::slotItemCollapsed( TQListViewItem *item )
{
Smb4KNetworkBrowserItem *browser_item = static_cast<Smb4KNetworkBrowserItem *>( item );
- // Remove all children if we have a host item, because we
+ // Remove all tqchildren if we have a host item, because we
// do not want shares already displayed before the user provided
// the login data.
if ( browser_item && browser_item->type() == Smb4KNetworkBrowserItem::Host )
@@ -636,7 +636,7 @@ void Smb4KNetworkBrowserPart::slotItemCollapsed( QListViewItem *item )
}
-void Smb4KNetworkBrowserPart::slotItemExecuted( QListViewItem *item )
+void Smb4KNetworkBrowserPart::slotItemExecuted( TQListViewItem *item )
{
Smb4KNetworkBrowserItem *browser_item = static_cast<Smb4KNetworkBrowserItem *>( item );
@@ -698,7 +698,7 @@ void Smb4KNetworkBrowserPart::slotAboutToShowToolTip( Smb4KNetworkBrowserItem *b
}
-void Smb4KNetworkBrowserPart::slotWorkgroups( const QValueList<Smb4KWorkgroupItem *> &list )
+void Smb4KNetworkBrowserPart::slotWorkgroups( const TQValueList<Smb4KWorkgroupItem *> &list )
{
if ( !list.isEmpty() )
{
@@ -707,7 +707,7 @@ void Smb4KNetworkBrowserPart::slotWorkgroups( const QValueList<Smb4KWorkgroupIte
if ( m_widget->childCount() > 0 )
{
- QListViewItemIterator it( m_widget );
+ TQListViewItemIterator it( m_widget );
while ( it.current() )
{
@@ -716,13 +716,13 @@ void Smb4KNetworkBrowserPart::slotWorkgroups( const QValueList<Smb4KWorkgroupIte
// We only want to check workgroup items:
if ( item->type() == Smb4KNetworkBrowserItem::Workgroup )
{
- QValueList<Smb4KWorkgroupItem *>::ConstIterator i;
+ TQValueList<Smb4KWorkgroupItem *>::ConstIterator i;
for ( i = list.begin(); i != list.end(); ++i )
{
- if ( QString::compare( item->workgroupItem()->name(), (*i)->name() ) == 0 )
+ if ( TQString::compare( item->workgroupItem()->name(), (*i)->name() ) == 0 )
{
- QString old_master = item->workgroupItem()->master();
+ TQString old_master = item->workgroupItem()->master();
// Found the workgroup item in the new list. Update it and stop here.
item->update( *i );
@@ -730,11 +730,11 @@ void Smb4KNetworkBrowserPart::slotWorkgroups( const QValueList<Smb4KWorkgroupIte
// We update the master as well, if it changed and the workgroup item is open.
// In the case the item is closed, Smb4KScanner::getWorkgroupMembers() will be
// called by setOpen() and an update will be done by slotWorkgroupMembers().
- if ( QString::compare( old_master, (*i)->master() ) != 0 && item->isOpen() )
+ if ( TQString::compare( old_master, (*i)->master() ) != 0 && item->isOpen() )
{
// Get the list view items:
- Smb4KNetworkBrowserItem *oldMasterItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( old_master, Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) );
- Smb4KNetworkBrowserItem *newMasterItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( (*i)->master(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) );
+ Smb4KNetworkBrowserItem *oldMasterItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( old_master, Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) );
+ Smb4KNetworkBrowserItem *newMasterItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( (*i)->master(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) );
// Get the host item of the new master from the scanner. The old master
// has been removed from the internal host list, so we cannot search for
@@ -778,7 +778,7 @@ void Smb4KNetworkBrowserPart::slotWorkgroups( const QValueList<Smb4KWorkgroupIte
{
// Is the list entry in the list view? If not, add it to the list
// view. (If it is, it will be found and updated by the code above.)
- if ( m_widget->findItem( (*i)->name(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) == 0 )
+ if ( m_widget->tqfindItem( (*i)->name(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) == 0 )
{
Smb4KNetworkBrowserItem *workgroup = new Smb4KNetworkBrowserItem( m_widget, *i );
workgroup->setExpandable( true );
@@ -802,7 +802,7 @@ void Smb4KNetworkBrowserPart::slotWorkgroups( const QValueList<Smb4KWorkgroupIte
else
{
// Put the items in the empty list view:
- for ( QValueList<Smb4KWorkgroupItem *>::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KWorkgroupItem *>::ConstIterator it = list.begin(); it != list.end(); ++it )
{
Smb4KNetworkBrowserItem *workgroup = new Smb4KNetworkBrowserItem( m_widget, *it );
workgroup->setExpandable( true );
@@ -827,14 +827,14 @@ void Smb4KNetworkBrowserPart::slotWorkgroups( const QValueList<Smb4KWorkgroupIte
}
-void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const QString &workgroup, const QValueList<Smb4KHostItem *> &list )
+void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const TQString &workgroup, const TQValueList<Smb4KHostItem *> &list )
{
// Get the workgroup item:
Smb4KNetworkBrowserItem *workgroupItem = NULL;
if ( !workgroup.isEmpty() )
{
- workgroupItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( workgroup, Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
+ workgroupItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( workgroup, Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
}
else
{
@@ -850,7 +850,7 @@ void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const QString &workgroup, co
if ( workgroupItem->childCount() > 0 )
{
// Traverse though the hosts:
- QListViewItemIterator it( m_widget );
+ TQListViewItemIterator it( m_widget );
while ( it.current() )
{
@@ -859,13 +859,13 @@ void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const QString &workgroup, co
// We will only take action if we have a host item that belongs
// to the workgroup 'workgroup':
if ( item->type() == Smb4KNetworkBrowserItem::Host &&
- QString::compare( item->hostItem()->workgroup(), workgroupItem->workgroupItem()->name() ) == 0 )
+ TQString::compare( item->hostItem()->workgroup(), workgroupItem->workgroupItem()->name() ) == 0 )
{
- QValueList<Smb4KHostItem *>::ConstIterator i;
+ TQValueList<Smb4KHostItem *>::ConstIterator i;
for ( i = list.begin(); i != list.end(); ++i )
{
- if ( QString::compare( item->hostItem()->name(), (*i)->name() ) == 0 )
+ if ( TQString::compare( item->hostItem()->name(), (*i)->name() ) == 0 )
{
// The host is already in the workgroup. Update it:
item->update( *i );
@@ -879,8 +879,8 @@ void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const QString &workgroup, co
// Also: In case the whole list of known hosts is emitted by the
// scanner, we need omit all entries that do not belong to this
// workgroup.
- if ( QString::compare( (*i)->workgroup(), workgroupItem->workgroupItem()->name() ) == 0 &&
- m_widget->findItem( (*i)->name(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) == 0 )
+ if ( TQString::compare( (*i)->workgroup(), workgroupItem->workgroupItem()->name() ) == 0 &&
+ m_widget->tqfindItem( (*i)->name(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) == 0 )
{
Smb4KNetworkBrowserItem *hostItem = new Smb4KNetworkBrowserItem( workgroupItem, *i );
hostItem->setExpandable( true );
@@ -903,12 +903,12 @@ void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const QString &workgroup, co
}
else
{
- // Add the children to the childless host item:
- for ( QValueList<Smb4KHostItem *>::ConstIterator it = list.begin(); it != list.end(); ++it )
+ // Add the tqchildren to the childless host item:
+ for ( TQValueList<Smb4KHostItem *>::ConstIterator it = list.begin(); it != list.end(); ++it )
{
// In case the whole list of known hosts is emitted by the scanner,
// we need omit all entries that do not belong to this workgroup.
- if ( QString::compare( (*it)->workgroup(), workgroupItem->workgroupItem()->name() ) == 0 )
+ if ( TQString::compare( (*it)->workgroup(), workgroupItem->workgroupItem()->name() ) == 0 )
{
Smb4KNetworkBrowserItem *hostItem = new Smb4KNetworkBrowserItem( workgroupItem, *it );
hostItem->setExpandable( true );
@@ -928,7 +928,7 @@ void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const QString &workgroup, co
m_widget->setOpen( workgroupItem, false );
// Delete all host items in this workgroup:
- QListViewItem *child = workgroupItem->firstChild();
+ TQListViewItem *child = workgroupItem->firstChild();
while ( child )
{
@@ -953,14 +953,14 @@ void Smb4KNetworkBrowserPart::slotWorkgroupMembers( const QString &workgroup, co
}
-void Smb4KNetworkBrowserPart::slotShares( const QString &host, const QValueList<Smb4KShareItem *> &list )
+void Smb4KNetworkBrowserPart::slotShares( const TQString &host, const TQValueList<Smb4KShareItem *> &list )
{
// Get the host item:
Smb4KNetworkBrowserItem *hostItem = NULL;
if ( !host.isEmpty() )
{
- hostItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( host, Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
+ hostItem = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( host, Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
}
else
{
@@ -979,7 +979,7 @@ void Smb4KNetworkBrowserPart::slotShares( const QString &host, const QValueList<
if ( hostItem->childCount() > 0 )
{
- QListViewItemIterator it( m_widget );
+ TQListViewItemIterator it( m_widget );
while( it.current() )
{
@@ -987,13 +987,13 @@ void Smb4KNetworkBrowserPart::slotShares( const QString &host, const QValueList<
// We only take action, if the shares belong to hostItem:
if ( item->type() == Smb4KNetworkBrowserItem::Share &&
- QString::compare( item->shareItem()->host(), hostItem->hostItem()->name() ) == 0 )
+ TQString::compare( item->shareItem()->host(), hostItem->hostItem()->name() ) == 0 )
{
- QValueList<Smb4KShareItem *>::ConstIterator i;
+ TQValueList<Smb4KShareItem *>::ConstIterator i;
for ( i = list.begin(); i != list.end(); ++i )
{
- if ( QString::compare( item->shareItem()->name(), (*i)->name() ) == 0 )
+ if ( TQString::compare( item->shareItem()->name(), (*i)->name() ) == 0 )
{
// Found the share. Now process it:
if ( !item->shareItem()->isHidden() )
@@ -1079,7 +1079,7 @@ void Smb4KNetworkBrowserPart::slotShares( const QString &host, const QValueList<
{
// Does the host carry the list entry? If not, add it to it.
// (If it is, it will be found and updated by the code above.)
- if ( m_widget->findItem( (*i)->name(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) == 0 )
+ if ( m_widget->tqfindItem( (*i)->name(), Smb4KNetworkBrowser::Network, CaseSensitive|ExactMatch ) == 0 )
{
// Respect the settings the user chose to use:
if ( !(*i)->isHidden() )
@@ -1151,8 +1151,8 @@ void Smb4KNetworkBrowserPart::slotShares( const QString &host, const QValueList<
}
else
{
- // Add the children to the childless host item:
- for ( QValueList<Smb4KShareItem *>::ConstIterator it = list.begin(); it != list.end(); ++it )
+ // Add the tqchildren to the childless host item:
+ for ( TQValueList<Smb4KShareItem *>::ConstIterator it = list.begin(); it != list.end(); ++it )
{
// Respect the settings the user chose to use:
if ( !(*it)->isHidden() )
@@ -1213,7 +1213,7 @@ void Smb4KNetworkBrowserPart::slotShares( const QString &host, const QValueList<
// Delete all shares of this host:
m_widget->setOpen( hostItem, false );
- QListViewItem *child = hostItem->firstChild();
+ TQListViewItem *child = hostItem->firstChild();
while ( child )
{
@@ -1244,9 +1244,9 @@ void Smb4KNetworkBrowserPart::slotAddIPAddress( Smb4KHostItem *item )
{
// Get the workgroup item the server is a child of and update
// it.
- Smb4KNetworkBrowserItem *workgroup_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( item->workgroup(), Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
+ Smb4KNetworkBrowserItem *workgroup_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( item->workgroup(), Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
- if ( workgroup_item && QString::compare( workgroup_item->workgroupItem()->name(), item->workgroup() ) == 0 )
+ if ( workgroup_item && TQString::compare( workgroup_item->workgroupItem()->name(), item->workgroup() ) == 0 )
{
Smb4KWorkgroupItem *workgroup = Smb4KCore::scanner()->getWorkgroup( item->workgroup() );
@@ -1262,9 +1262,9 @@ void Smb4KNetworkBrowserPart::slotAddIPAddress( Smb4KHostItem *item )
}
}
- Smb4KNetworkBrowserItem *host_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( item->name(), Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
+ Smb4KNetworkBrowserItem *host_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( item->name(), Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
- if ( host_item && host_item->parent() && QString::compare( host_item->hostItem()->workgroup(), item->workgroup() ) == 0 )
+ if ( host_item && host_item->tqparent() && TQString::compare( host_item->hostItem()->workgroup(), item->workgroup() ) == 0 )
{
host_item->update( item );
@@ -1287,12 +1287,12 @@ void Smb4KNetworkBrowserPart::slotAddInformation( Smb4KHostItem *item )
{
if ( item )
{
- Smb4KNetworkBrowserItem *browser_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( item->name(), Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
+ Smb4KNetworkBrowserItem *browser_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( item->name(), Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
if ( browser_item )
{
// First update the browser item, if appropriate:
- if ( QString::compare( browser_item->hostItem()->workgroup(), item->workgroup() ) == 0 )
+ if ( TQString::compare( browser_item->hostItem()->workgroup(), item->workgroup() ) == 0 )
{
browser_item->update( item );
}
@@ -1320,7 +1320,7 @@ void Smb4KNetworkBrowserPart::slotInsertHost( Smb4KHostItem *item )
if ( item )
{
// Look up the workgroup:
- workgroup_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->findItem( item->workgroup(),
+ workgroup_item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->tqfindItem( item->workgroup(),
Smb4KNetworkBrowser::Network, ExactMatch|CaseSensitive ) );
}
else
@@ -1331,12 +1331,12 @@ void Smb4KNetworkBrowserPart::slotInsertHost( Smb4KHostItem *item )
if ( workgroup_item )
{
// Check if the host item is already there. We traverse
- // workgroup's children for that:
+ // workgroup's tqchildren for that:
Smb4KNetworkBrowserItem *host_item = static_cast<Smb4KNetworkBrowserItem *>( workgroup_item->firstChild() );
while ( host_item )
{
- if ( QString::compare( host_item->text( Smb4KNetworkBrowser::Network ).upper(),
+ if ( TQString::compare( host_item->text( Smb4KNetworkBrowser::Network ).upper(),
item->name().upper() ) == 0 )
{
break;
@@ -1346,8 +1346,8 @@ void Smb4KNetworkBrowserPart::slotInsertHost( Smb4KHostItem *item )
}
- if ( !host_item || (host_item && host_item->parent() &&
- QString::compare( host_item->hostItem()->workgroup(), item->workgroup() ) != 0) )
+ if ( !host_item || (host_item && host_item->tqparent() &&
+ TQString::compare( host_item->hostItem()->workgroup(), item->workgroup() ) != 0) )
{
// The host is not there. Insert it.
// NOTE: The following procedure will not produce a leak.
@@ -1391,7 +1391,7 @@ void Smb4KNetworkBrowserPart::slotRescan()
bool viewport_has_mouse;
// We transform the global mouse position to a local position:
- QPoint pos = m_widget->mapFromGlobal( m_widget->mousePosition() );
+ TQPoint pos = m_widget->mapFromGlobal( m_widget->mousePosition() );
if ( pos.x() <= 0 || m_widget->viewport()->width() <= pos.x() ||
pos.y() <= 0 || m_widget->viewport()->height() <= pos.y() )
@@ -1438,7 +1438,7 @@ void Smb4KNetworkBrowserPart::slotRescan()
}
case Smb4KNetworkBrowserItem::Share:
{
- Smb4KHostItem *item = static_cast<Smb4KNetworkBrowserItem *>( browser_item->parent() )->hostItem();
+ Smb4KHostItem *item = static_cast<Smb4KNetworkBrowserItem *>( browser_item->tqparent() )->hostItem();
Smb4KCore::scanner()->getShares( item->workgroup(), item->name(), item->ip() );
break;
@@ -1477,7 +1477,7 @@ void Smb4KNetworkBrowserPart::slotAbort()
void Smb4KNetworkBrowserPart::slotMountManually()
{
- Smb4KMountDialog *dlg = static_cast<Smb4KMountDialog *>( m_widget->child( "MountDialog", "Smb4KMountDialog", true ) );
+ Smb4KMountDialog *dlg = static_cast<Smb4KMountDialog *>( TQT_TQWIDGET(m_widget->child( "MountDialog", "Smb4KMountDialog", true )) );
if ( !dlg )
{
@@ -1504,7 +1504,7 @@ void Smb4KNetworkBrowserPart::slotAuthentication()
{
passwordHandler()->askpass( item->hostItem()->workgroup(),
item->hostItem()->name(),
- QString::null,
+ TQString(),
Smb4KPasswordHandler::NewData,
m_widget,
"AuthenticationDialog" );
@@ -1534,7 +1534,7 @@ void Smb4KNetworkBrowserPart::slotAuthentication()
void Smb4KNetworkBrowserPart::slotCustomOptions()
{
Smb4KCustomOptionsDialog *dlg = static_cast<Smb4KCustomOptionsDialog *>(
- m_widget->child( "CustomOptionsDialog", "Smb4KCustomOptionsDialog", true ) );
+ TQT_TQWIDGET(m_widget->child( "CustomOptionsDialog", "Smb4KCustomOptionsDialog", true )) );
Smb4KNetworkBrowserItem *item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->currentItem() );
if ( !dlg && item )
@@ -1580,11 +1580,11 @@ void Smb4KNetworkBrowserPart::slotBookmark()
if ( item && item->type() == Smb4KNetworkBrowserItem::Share )
{
- Smb4KNetworkBrowserItem *parent_item = static_cast<Smb4KNetworkBrowserItem *>( item->parent() );
+ Smb4KNetworkBrowserItem *tqparent_item = static_cast<Smb4KNetworkBrowserItem *>( item->tqparent() );
// Add a bookmark. The alternative label can be set in the bookmark editor,
// so we won't do anything about it here.
- Smb4KCore::bookmarkHandler()->addBookmark( new Smb4KBookmark( item->shareItem(), parent_item->hostItem()->ip() ) );
+ Smb4KCore::bookmarkHandler()->addBookmark( new Smb4KBookmark( item->shareItem(), tqparent_item->hostItem()->ip() ) );
}
}
@@ -1618,7 +1618,7 @@ void Smb4KNetworkBrowserPart::slotPreview()
void Smb4KNetworkBrowserPart::slotPrint()
{
- Smb4KPrintDialog *dlg = static_cast<Smb4KPrintDialog *>( m_widget->child( "PrintDialog", "Smb4KPrintDialog", true ) );
+ Smb4KPrintDialog *dlg = static_cast<Smb4KPrintDialog *>( TQT_TQWIDGET(m_widget->child( "PrintDialog", "Smb4KPrintDialog", true )) );
Smb4KNetworkBrowserItem *item = static_cast<Smb4KNetworkBrowserItem *>( m_widget->currentItem() );
if ( !dlg && item )
@@ -1655,12 +1655,12 @@ void Smb4KNetworkBrowserPart::slotMount()
if ( browser_item && browser_item->type() == Smb4KNetworkBrowserItem::Share )
{
- // If the item is a share item, get its parent and start mounting it:
- Smb4KNetworkBrowserItem *parent_browser_item = static_cast<Smb4KNetworkBrowserItem *>( browser_item->parent() );
+ // If the item is a share item, get its tqparent and start mounting it:
+ Smb4KNetworkBrowserItem *tqparent_browser_item = static_cast<Smb4KNetworkBrowserItem *>( browser_item->tqparent() );
Smb4KCore::mounter()->mountShare( browser_item->shareItem()->workgroup(),
browser_item->shareItem()->host(),
- parent_browser_item->hostItem()->ip() /* There is no better way ATM */,
+ tqparent_browser_item->hostItem()->ip() /* There is no better way ATM */,
browser_item->shareItem()->name() );
}
}
@@ -1676,13 +1676,13 @@ void Smb4KNetworkBrowserPart::slotUnmount()
if ( browser_item && browser_item->type() == Smb4KNetworkBrowserItem::Share &&
browser_item->isMounted() )
{
- QString share_name = QString( "//%1/%2" ).arg( browser_item->shareItem()->host(),
+ TQString share_name = TQString( "//%1/%2" ).tqarg( browser_item->shareItem()->host(),
browser_item->shareItem()->name() );
- QValueList<Smb4KShare> list = Smb4KCore::mounter()->findShareByName( share_name );
+ TQValueList<Smb4KShare> list = Smb4KCore::mounter()->findShareByName( share_name );
Smb4KShare *share = NULL;
- for ( QValueList<Smb4KShare>::Iterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KShare>::Iterator it = list.begin(); it != list.end(); ++it )
{
if ( !(*it).isForeign() )
{
@@ -1718,8 +1718,8 @@ void Smb4KNetworkBrowserPart::slotUnmount()
void Smb4KNetworkBrowserPart::slotMarkMountedShares()
{
- QListViewItemIterator it( m_widget );
- QListViewItem *item;
+ TQListViewItemIterator it( m_widget );
+ TQListViewItem *item;
while ((item = it.current()) != 0 )
{
@@ -1729,7 +1729,7 @@ void Smb4KNetworkBrowserPart::slotMarkMountedShares()
{
Smb4KShareItem *share_item = static_cast<Smb4KNetworkBrowserItem *>( item )->shareItem();
- QValueList<Smb4KShare> list = Smb4KCore::mounter()->findShareByName( QString( "//%1/%2" ).arg( share_item->host(), share_item->name() ) );
+ TQValueList<Smb4KShare> list = Smb4KCore::mounter()->findShareByName( TQString( "//%1/%2" ).tqarg( share_item->host(), share_item->name() ) );
if ( list.isEmpty() )
{
@@ -1759,7 +1759,7 @@ void Smb4KNetworkBrowserPart::slotMarkMountedShares()
}
else
{
- for ( QValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( !(*it).isForeign() || Smb4KSettings::showAllShares() )
{
@@ -1866,32 +1866,32 @@ Smb4KNetworkBrowserPartFactory::~Smb4KNetworkBrowserPartFactory()
}
-KParts::Part *Smb4KNetworkBrowserPartFactory::createPartObject( QWidget *parentWidget, const char *widgetName,
-QObject *parent, const char *name, const char *, const QStringList &args )
+KParts::Part *Smb4KNetworkBrowserPartFactory::createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+TQObject *tqparent, const char *name, const char *, const TQStringList &args )
{
Smb4KNetworkBrowserPart *obj = NULL;
- for ( QStringList::ConstIterator it = args.begin(); it != args.end(); ++it )
+ for ( TQStringList::ConstIterator it = args.begin(); it != args.end(); ++it )
{
- QString arg = (*it).section( "=", 0, 0 ).stripWhiteSpace();
- QString value = (*it).section( "=", 1, -1 ).stripWhiteSpace();
+ TQString arg = (*it).section( "=", 0, 0 ).stripWhiteSpace();
+ TQString value = (*it).section( "=", 1, -1 ).stripWhiteSpace();
- if ( QString::compare( arg, "konqplugin" ) == 0 )
+ if ( TQString::compare( arg, "konqplugin" ) == 0 )
{
- if ( QString::compare( value, "\"true\"" ) == 0 )
+ if ( TQString::compare( value, "\"true\"" ) == 0 )
{
- obj = new Smb4KNetworkBrowserPart( parentWidget, widgetName, parent, name, Smb4KNetworkBrowserPart::KonqPlugin );
+ obj = new Smb4KNetworkBrowserPart( tqparentWidget, widgetName, tqparent, name, Smb4KNetworkBrowserPart::KonqPlugin );
}
else
{
- obj = new Smb4KNetworkBrowserPart( parentWidget, widgetName, parent, name, Smb4KNetworkBrowserPart::Normal );
+ obj = new Smb4KNetworkBrowserPart( tqparentWidget, widgetName, tqparent, name, Smb4KNetworkBrowserPart::Normal );
}
}
}
if ( !obj )
{
- obj = new Smb4KNetworkBrowserPart( parentWidget, widgetName, parent, name, Smb4KNetworkBrowserPart::Normal );
+ obj = new Smb4KNetworkBrowserPart( tqparentWidget, widgetName, tqparent, name, Smb4KNetworkBrowserPart::Normal );
}
return obj ;
diff --git a/smb4k/browser/smb4knetworkbrowser_part.h b/smb4k/browser/smb4knetworkbrowser_part.h
index a3351dc..627b0eb 100644
--- a/smb4k/browser/smb4knetworkbrowser_part.h
+++ b/smb4k/browser/smb4knetworkbrowser_part.h
@@ -36,9 +36,9 @@
#include <kparts/part.h>
#include <kparts/factory.h>
-// Qt includes
-#include <qptrlist.h>
-#include <qlistview.h>
+// TQt includes
+#include <tqptrlist.h>
+#include <tqlistview.h>
// forward declarations
class Smb4KNetworkBrowser;
@@ -56,6 +56,7 @@ class Smb4KShareItem;
class Smb4KNetworkBrowserPart : public KParts::Part
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -66,19 +67,19 @@ class Smb4KNetworkBrowserPart : public KParts::Part
/**
* The constructor.
*
- * @param parentWidget The parent widget
+ * @param tqparentWidget The tqparent widget
*
* @param widgetName The name the widget should have
*
- * @param parent The parent object
+ * @param tqparent The tqparent object
*
* @param name The name this object should have
*
* @param mode Determines in which mode the KPart should be started
*/
- Smb4KNetworkBrowserPart( QWidget *parentWidget = 0,
+ Smb4KNetworkBrowserPart( TQWidget *tqparentWidget = 0,
const char *widgetName = 0,
- QObject *parent = 0,
+ TQObject *tqparent = 0,
const char *name = 0,
Mode mode = Normal );
@@ -91,7 +92,7 @@ class Smb4KNetworkBrowserPart : public KParts::Part
/**
* Reimplemented from KParts::Part.
*/
- void customEvent( QCustomEvent *e );
+ void customEvent( TQCustomEvent *e );
protected slots:
/**
@@ -105,7 +106,7 @@ class Smb4KNetworkBrowserPart : public KParts::Part
*
* @param col The column where the user clicked.
*/
- void slotContextMenuRequested( QListViewItem *item, const QPoint &pos, int col );
+ void slotContextMenuRequested( TQListViewItem *item, const TQPoint &pos, int col );
/**
* Is called when the selection changed. This slot takes care of the
@@ -114,7 +115,7 @@ class Smb4KNetworkBrowserPart : public KParts::Part
*
* @param item The selection list view item.
*/
- void slotSelectionChanged( QListViewItem *item );
+ void slotSelectionChanged( TQListViewItem *item );
/**
* Is called when the user pressed a mouse button somewhere in the widget.
@@ -124,7 +125,7 @@ class Smb4KNetworkBrowserPart : public KParts::Part
*
* @param item The selection list view item.
*/
- void slotPressed( QListViewItem *item );
+ void slotPressed( TQListViewItem *item );
/**
* This slot is called when an item of the browser's list view has been opened.
@@ -132,14 +133,14 @@ class Smb4KNetworkBrowserPart : public KParts::Part
*
* @param item The list view item that has been opened.
*/
- void slotItemExpanded( QListViewItem *item );
+ void slotItemExpanded( TQListViewItem *item );
/**
* This slot is called when an item of the browser's list view has been closed.
*
* @param item The list view item that has been closed.
*/
- void slotItemCollapsed( QListViewItem *item );
+ void slotItemCollapsed( TQListViewItem *item );
/**
* This slot is invoked when the user executed an item. It is used to mount
@@ -147,7 +148,7 @@ class Smb4KNetworkBrowserPart : public KParts::Part
*
* @param item The list view item that has been executed.
*/
- void slotItemExecuted( QListViewItem *item );
+ void slotItemExecuted( TQListViewItem *item );
/**
* This slot is called when the user moved the mouse over an @p item in the
@@ -168,30 +169,30 @@ class Smb4KNetworkBrowserPart : public KParts::Part
*
* @param list A list of Smb4KWorkgroupItem objects
*/
- void slotWorkgroups( const QValueList<Smb4KWorkgroupItem *> &list );
+ void slotWorkgroups( const TQValueList<Smb4KWorkgroupItem *> &list );
/**
* This slot receives the list of workgroup/domain members that were found
* by the scanner. It takes this @p list and inserts it into the list view.
- * The parent of the items is the workgroup/domain item with the name
+ * The tqparent of the items is the workgroup/domain item with the name
* @p workgroup. Obsolete items will be deleted from the network browser.
*
* @param workgroup The workgroup where the hosts belong
*
* @param list A list of Smb4KHostItem objects
*/
- void slotWorkgroupMembers( const QString &workgroup, const QValueList<Smb4KHostItem *> &list );
+ void slotWorkgroupMembers( const TQString &workgroup, const TQValueList<Smb4KHostItem *> &list );
/**
* This slot receives the list of shared resources a host provides. It takes
- * this @p list and inserts its items as children of @p host into the list
+ * this @p list and inserts its items as tqchildren of @p host into the list
* view. Obsolete items will be deleted from the network browser.
*
* @param host The host where the shares belong
*
* @param list The list of shares that belong to @p host
*/
- void slotShares( const QString &host, const QValueList<Smb4KShareItem *> &list );
+ void slotShares( const TQString &host, const TQValueList<Smb4KShareItem *> &list );
/**
* This slot takes a Smb4KHostItem object @p item, reads the IP address entry
@@ -322,6 +323,7 @@ class KAboutData;
class Smb4KNetworkBrowserPartFactory : public KParts::Factory
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -338,11 +340,11 @@ class Smb4KNetworkBrowserPartFactory : public KParts::Factory
* Reimplemented from KParts::Factory. This function is used to
* create a part object.
*
- * @param parentWidget The parent of the part's widget.
+ * @param tqparentWidget The tqparent of the part's widget.
*
* @param widgetName The name of the part's widget.
*
- * @param parent The parent of the part.
+ * @param tqparent The tqparent of the part.
*
* @param name The name of the part.
*
@@ -353,9 +355,9 @@ class Smb4KNetworkBrowserPartFactory : public KParts::Factory
* the following pairs:
* konqplugin="true"|"false".
*/
- virtual KParts::Part *createPartObject( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
- const char *classname, const QStringList &args = QStringList() );
+ virtual KParts::Part *createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name,
+ const char *classname, const TQStringList &args = TQStringList() );
/**
* The instance
diff --git a/smb4k/browser/smb4knetworkbrowseritem.cpp b/smb4k/browser/smb4knetworkbrowseritem.cpp
index c3f2ebe..f72a414 100644
--- a/smb4k/browser/smb4knetworkbrowseritem.cpp
+++ b/smb4k/browser/smb4knetworkbrowseritem.cpp
@@ -23,8 +23,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qpainter.h>
+// TQt includes
+#include <tqpainter.h>
// KDE includes
#include <kiconloader.h>
@@ -33,24 +33,24 @@
// application specific includes
#include "smb4knetworkbrowseritem.h"
-Smb4KNetworkBrowserItem::Smb4KNetworkBrowserItem( QListView *parent, Smb4KWorkgroupItem *item )
-: KListViewItem( parent, item->name() ), m_type( Workgroup ), m_workgroup( *item ),
+Smb4KNetworkBrowserItem::Smb4KNetworkBrowserItem( TQListView *tqparent, Smb4KWorkgroupItem *item )
+: KListViewItem( tqparent, item->name() ), m_type( Workgroup ), m_workgroup( *item ),
m_mounted( false )
{
setIcon();
}
-Smb4KNetworkBrowserItem::Smb4KNetworkBrowserItem( QListViewItem *parent, Smb4KHostItem *item )
-: KListViewItem( parent, item->name(), QString::null, item->ip(), item->comment() ),
+Smb4KNetworkBrowserItem::Smb4KNetworkBrowserItem( TQListViewItem *tqparent, Smb4KHostItem *item )
+: KListViewItem( tqparent, item->name(), TQString(), item->ip(), item->comment() ),
m_type( Host ), m_host( *item ), m_mounted( false )
{
setIcon();
}
-Smb4KNetworkBrowserItem::Smb4KNetworkBrowserItem( QListViewItem *parent, Smb4KShareItem *item )
-: KListViewItem( parent, item->name(), item->plainType(), QString::null, item->comment() ),
+Smb4KNetworkBrowserItem::Smb4KNetworkBrowserItem( TQListViewItem *tqparent, Smb4KShareItem *item )
+: KListViewItem( tqparent, item->name(), item->plainType(), TQString(), item->comment() ),
m_type( Share ), m_share( *item ), m_mounted( false )
{
setIcon();
@@ -142,12 +142,12 @@ void Smb4KNetworkBrowserItem::update( Smb4KHostItem *item )
{
m_host = *item;
- if ( !m_host.ip().isEmpty() && QString::compare( text( IP ).stripWhiteSpace(), m_host.ip() ) != 0 )
+ if ( !m_host.ip().isEmpty() && TQString::compare( text( IP ).stripWhiteSpace(), m_host.ip() ) != 0 )
{
setText( IP, m_host.ip() );
}
- if ( QString::compare( text( Comment ).stripWhiteSpace(), m_host.comment() ) != 0 )
+ if ( TQString::compare( text( Comment ).stripWhiteSpace(), m_host.comment() ) != 0 )
{
setText( Comment, m_host.comment() );
}
@@ -158,7 +158,7 @@ void Smb4KNetworkBrowserItem::update( Smb4KShareItem *item )
{
m_share = *item;
- if ( !m_share.comment().isEmpty() && QString::compare( text( Comment ).stripWhiteSpace(), m_share.comment() ) != 0 )
+ if ( !m_share.comment().isEmpty() && TQString::compare( text( Comment ).stripWhiteSpace(), m_share.comment() ) != 0 )
{
setText( Comment, m_share.comment() );
}
@@ -180,7 +180,7 @@ bool Smb4KNetworkBrowserItem::isPrinter()
void Smb4KNetworkBrowserItem::setMounted( bool mounted )
{
- if ( m_type == Share && QString::compare( m_share.plainType(), "Disk" ) == 0 )
+ if ( m_type == Share && TQString::compare( m_share.plainType(), "Disk" ) == 0 )
{
m_mounted = mounted;
@@ -199,10 +199,10 @@ bool Smb4KNetworkBrowserItem::isMounted()
}
-void Smb4KNetworkBrowserItem::paintCell( QPainter *p, const QColorGroup &cg, int column, int width, int align )
+void Smb4KNetworkBrowserItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column, int width, int align )
{
- QFont f( p->font() );
- QColorGroup colorgrp( cg );
+ TQFont f( p->font() );
+ TQColorGroup colorgrp( cg );
if ( m_type == Share && m_mounted )
{
@@ -215,14 +215,14 @@ void Smb4KNetworkBrowserItem::paintCell( QPainter *p, const QColorGroup &cg, int
if ( m_type == Host && m_host.isMaster() )
{
- colorgrp.setColor( QColorGroup::Text, Qt::darkBlue );
+ colorgrp.setColor( TQColorGroup::Text, TQt::darkBlue );
}
else
{
- colorgrp.setColor( QColorGroup::Text, cg.text() );
+ colorgrp.setColor( TQColorGroup::Text, cg.text() );
}
p->setFont( f );
- QListViewItem::paintCell( p, colorgrp, column, width, align );
+ TQListViewItem::paintCell( p, colorgrp, column, width, align );
}
diff --git a/smb4k/browser/smb4knetworkbrowseritem.h b/smb4k/browser/smb4knetworkbrowseritem.h
index 141ae04..73fecf2 100644
--- a/smb4k/browser/smb4knetworkbrowseritem.h
+++ b/smb4k/browser/smb4knetworkbrowseritem.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qpixmap.h>
+// TQt includes
+#include <tqpixmap.h>
// KDE includes
#include <klistview.h>
@@ -46,30 +46,30 @@ class Smb4KNetworkBrowserItem : public KListViewItem
/**
* The constructor for toplevel (workgroup) items.
*
- * @param parent The parent list view.
+ * @param tqparent The tqparent list view.
*
* @param item The Smb4KWorkgroupItem that carries all the data
* needed to set up a "workgroup item".
*/
- Smb4KNetworkBrowserItem( QListView *parent, Smb4KWorkgroupItem *item );
+ Smb4KNetworkBrowserItem( TQListView *tqparent, Smb4KWorkgroupItem *item );
/**
* The constructor for the host items.
*
- * @param parent The parent list view item.
+ * @param tqparent The tqparent list view item.
*
* @param item The Smb4KHostItem that carries all the data.
*/
- Smb4KNetworkBrowserItem( QListViewItem *parent, Smb4KHostItem *item );
+ Smb4KNetworkBrowserItem( TQListViewItem *tqparent, Smb4KHostItem *item );
/**
* The constructor for the share items.
*
- * @param parent The parent list view item.
+ * @param tqparent The tqparent list view item.
*
* @param item The Smb4KShareItem that carries all the data.
*/
- Smb4KNetworkBrowserItem( QListViewItem *parent, Smb4KShareItem *item );
+ Smb4KNetworkBrowserItem( TQListViewItem *tqparent, Smb4KShareItem *item );
/**
* The destructor.
@@ -168,13 +168,13 @@ class Smb4KNetworkBrowserItem : public KListViewItem
*
* @returns a pixmap
*/
- const QPixmap &desktopIcon() { return m_desktop_icon; }
+ const TQPixmap &desktopIcon() { return m_desktop_icon; }
protected:
/**
- * Reimplemented from QListViewItem.
+ * Reimplemented from TQListViewItem.
*/
- void paintCell( QPainter *p, const QColorGroup &cg, int column, int width, int align );
+ void paintCell( TQPainter *p, const TQColorGroup &cg, int column, int width, int align );
private:
/**
@@ -216,7 +216,7 @@ class Smb4KNetworkBrowserItem : public KListViewItem
/**
* The icon in "DesktopIcon" format
*/
- QPixmap m_desktop_icon;
+ TQPixmap m_desktop_icon;
};
#endif
diff --git a/smb4k/browser/smb4knetworkbrowsertooltip.cpp b/smb4k/browser/smb4knetworkbrowsertooltip.cpp
index 451344f..0c111ea 100644
--- a/smb4k/browser/smb4knetworkbrowsertooltip.cpp
+++ b/smb4k/browser/smb4knetworkbrowsertooltip.cpp
@@ -23,11 +23,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qtooltip.h>
-#include <qdesktopwidget.h>
-#include <qapplication.h>
-#include <qtimer.h>
+// TQt includes
+#include <tqtooltip.h>
+#include <tqdesktopwidget.h>
+#include <tqapplication.h>
+#include <tqtimer.h>
// KDE includes
#include <klocale.h>
@@ -37,16 +37,16 @@
#include "smb4knetworkbrowseritem.h"
Smb4KNetworkBrowserToolTip::Smb4KNetworkBrowserToolTip( Smb4KNetworkBrowserItem *item )
-: QLabel( 0, "NetworkBrowserToolTip", WStyle_StaysOnTop | WStyle_Customize | WStyle_NoBorder | WStyle_Tool | WX11BypassWM | WDestructiveClose ), m_item( item )
+: TQLabel( 0, "NetworkBrowserToolTip", WStyle_StaysOnTop | WStyle_Customize | WStyle_NoBorder | WStyle_Tool | WX11BypassWM | WDestructiveClose ), m_item( item )
{
- setPalette( QToolTip::palette() );
+ setPalette( TQToolTip::palette() );
setLineWidth( 1 );
setMidLineWidth( 1 );
setFrameShape( Box );
setFrameShadow( Plain );
setMouseTracking( true );
- m_layout = new QGridLayout( this );
+ m_layout = new TQGridLayout( this );
m_layout->setMargin( 10 );
m_layout->setSpacing( 3 );
@@ -60,7 +60,7 @@ Smb4KNetworkBrowserToolTip::~Smb4KNetworkBrowserToolTip()
}
-void Smb4KNetworkBrowserToolTip::showTip( const QPoint &pos )
+void Smb4KNetworkBrowserToolTip::showTip( const TQPoint &pos )
{
if ( !m_item || isShown() )
{
@@ -71,9 +71,9 @@ void Smb4KNetworkBrowserToolTip::showTip( const QPoint &pos )
adjustSize();
- QPoint p( pos );
+ TQPoint p( pos );
- QDesktopWidget *d = QApplication::desktop();
+ TQDesktopWidget *d = TQApplication::desktop();
if ( p.x() + width() > d->width() )
{
@@ -96,7 +96,7 @@ void Smb4KNetworkBrowserToolTip::showTip( const QPoint &pos )
setGeometry( p.x(), p.y(), width(), height() );
polish();
show();
- QTimer::singleShot( 10000, this, SLOT( slotHideToolTip() ) );
+ TQTimer::singleShot( 10000, this, TQT_SLOT( slotHideToolTip() ) );
}
@@ -106,16 +106,16 @@ void Smb4KNetworkBrowserToolTip::setupTip()
{
case Smb4KNetworkBrowserItem::Workgroup:
{
- QLabel *workgroup_label = new QLabel( i18n( "Workgroup:" ), this );
- QLabel *workgroup = new QLabel( m_item->workgroupItem()->name() , this );
+ TQLabel *workgroup_label = new TQLabel( i18n( "Workgroup:" ), this );
+ TQLabel *workgroup = new TQLabel( m_item->workgroupItem()->name() , this );
- QString master_label_entry = m_item->workgroupItem()->hasPseudoMaster() ? i18n( "Pseudo master browser:" ) : i18n( "Master browser:" );
- QLabel *master_label = new QLabel( master_label_entry, this );
+ TQString master_label_entry = m_item->workgroupItem()->hasPseudoMaster() ? i18n( "Pseudo master browser:" ) : i18n( "Master browser:" );
+ TQLabel *master_label = new TQLabel( master_label_entry, this );
- QString master_entry = m_item->workgroupItem()->masterIP().isEmpty() ?
+ TQString master_entry = m_item->workgroupItem()->masterIP().isEmpty() ?
(m_item->workgroupItem()->master().isEmpty() ? i18n( "Unknown" ) : m_item->workgroupItem()->master()) :
m_item->workgroupItem()->master() + " ("+m_item->workgroupItem()->masterIP()+")";
- QLabel *master = new QLabel( master_entry, this, "MasterBrowser" );
+ TQLabel *master = new TQLabel( master_entry, this, "MasterBrowser" );
m_layout->addWidget( workgroup_label, 0, 1, 0 );
m_layout->addWidget( workgroup, 0, 2, 0 );
@@ -126,37 +126,37 @@ void Smb4KNetworkBrowserToolTip::setupTip()
}
case Smb4KNetworkBrowserItem::Host:
{
- QLabel *host_label = new QLabel( i18n( "Host:" ), this );
- QLabel *host = new QLabel( m_item->hostItem()->name(), this );
+ TQLabel *host_label = new TQLabel( i18n( "Host:" ), this );
+ TQLabel *host = new TQLabel( m_item->hostItem()->name(), this );
- QLabel *comment_label = new QLabel( i18n( "Comment:" ), this );
- QLabel *comment = new QLabel( m_item->hostItem()->comment(), this );
+ TQLabel *comment_label = new TQLabel( i18n( "Comment:" ), this );
+ TQLabel *comment = new TQLabel( m_item->hostItem()->comment(), this );
- QLabel *ip_label = new QLabel( i18n( "IP address:" ), this );
- QString ip_entry = m_item->hostItem()->ip().isEmpty() ? i18n( "Unknown" ) : m_item->hostItem()->ip();
- QLabel *ip_address = new QLabel( ip_entry, this, "IPAddress" );
+ TQLabel *ip_label = new TQLabel( i18n( "IP address:" ), this );
+ TQString ip_entry = m_item->hostItem()->ip().isEmpty() ? i18n( "Unknown" ) : m_item->hostItem()->ip();
+ TQLabel *ip_address = new TQLabel( ip_entry, this, "IPAddress" );
- QLabel *os_label = new QLabel( i18n( "Operating system:" ), this );
- QLabel *operating_system = new QLabel( m_item->hostItem()->osString().isEmpty() ? i18n( "Unknown" ) :
+ TQLabel *os_label = new TQLabel( i18n( "Operating system:" ), this );
+ TQLabel *operating_system = new TQLabel( m_item->hostItem()->osString().isEmpty() ? i18n( "Unknown" ) :
m_item->hostItem()->osString(), this, "OSString" );
- QLabel *server_label = new QLabel( i18n( "Server string:" ), this );
- QLabel *server_string = new QLabel( m_item->hostItem()->serverString().isEmpty() ? i18n( "Unknown" ) :
+ TQLabel *server_label = new TQLabel( i18n( "Server string:" ), this );
+ TQLabel *server_string = new TQLabel( m_item->hostItem()->serverString().isEmpty() ? i18n( "Unknown" ) :
m_item->hostItem()->serverString(), this, "ServerString" );
- QFrame *line = new QFrame( this );
+ TQFrame *line = new TQFrame( this );
line->setLineWidth( 1 );
line->setMidLineWidth( 0 );
line->setFixedWidth( 100 );
- line->setFrameShape( QFrame::HLine );
- line->setFrameShadow( QFrame::Plain );
+ line->setFrameShape( TQFrame::HLine );
+ line->setFrameShadow( TQFrame::Plain );
- QLabel *workgroup_label = new QLabel( i18n( "Workgroup:" ), this );
- QLabel *workgroup = new QLabel( m_item->hostItem()->workgroup(), this );
+ TQLabel *workgroup_label = new TQLabel( i18n( "Workgroup:" ), this );
+ TQLabel *workgroup = new TQLabel( m_item->hostItem()->workgroup(), this );
- Smb4KWorkgroupItem *workgroup_item = static_cast<Smb4KNetworkBrowserItem *>( m_item->parent() )->workgroupItem();
- QLabel *master_label = new QLabel( i18n( "Master browser:" ), this );
- QLabel *master_yes_no = new QLabel( (workgroup_item && !workgroup_item->master().isEmpty()) ?
+ Smb4KWorkgroupItem *workgroup_item = static_cast<Smb4KNetworkBrowserItem *>( m_item->tqparent() )->workgroupItem();
+ TQLabel *master_label = new TQLabel( i18n( "Master browser:" ), this );
+ TQLabel *master_yes_no = new TQLabel( (workgroup_item && !workgroup_item->master().isEmpty()) ?
workgroup_item->master() : i18n( "Unknown" ), this );
m_layout->addWidget( host_label, 0, 1, 0 );
@@ -169,7 +169,7 @@ void Smb4KNetworkBrowserToolTip::setupTip()
m_layout->addWidget( operating_system, 3, 2, 0 );
m_layout->addWidget( server_label, 4, 1, 0 );
m_layout->addWidget( server_string, 4, 2, 0 );
- m_layout->addMultiCellWidget( line, 5, 5, 1, 2, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( line, 5, 5, 1, 2, TQt::AlignCenter );
m_layout->addWidget( workgroup_label, 6, 1, 0 );
m_layout->addWidget( workgroup, 6, 2, 0 );
m_layout->addWidget( master_label, 7, 1, 0 );
@@ -179,37 +179,37 @@ void Smb4KNetworkBrowserToolTip::setupTip()
}
case Smb4KNetworkBrowserItem::Share:
{
- QLabel *share_label = new QLabel( i18n( "Share:" ), this );
- QLabel *share = new QLabel( m_item->shareItem()->name(), this );
+ TQLabel *share_label = new TQLabel( i18n( "Share:" ), this );
+ TQLabel *share = new TQLabel( m_item->shareItem()->name(), this );
- QLabel *comment_label = new QLabel( i18n( "Comment:" ), this );
- QLabel *comment = new QLabel( m_item->shareItem()->comment(), this );
+ TQLabel *comment_label = new TQLabel( i18n( "Comment:" ), this );
+ TQLabel *comment = new TQLabel( m_item->shareItem()->comment(), this );
- QLabel *type_label = new QLabel( i18n( "Type:" ), this );
- QLabel *type = new QLabel( m_item->shareItem()->translatedType(), this );
+ TQLabel *type_label = new TQLabel( i18n( "Type:" ), this );
+ TQLabel *type = new TQLabel( m_item->shareItem()->translatedType(), this );
- QLabel *mounted_label = NULL;
- QLabel *mounted = NULL;
+ TQLabel *mounted_label = NULL;
+ TQLabel *mounted = NULL;
if ( !m_item->isPrinter() )
{
- mounted_label = new QLabel( i18n( "Mounted:" ), this );
- mounted = new QLabel( m_item->isMounted() ? i18n( "Yes" ) : i18n( "No" ), this );
+ mounted_label = new TQLabel( i18n( "Mounted:" ), this );
+ mounted = new TQLabel( m_item->isMounted() ? i18n( "Yes" ) : i18n( "No" ), this );
}
- QFrame *line = new QFrame( this );
+ TQFrame *line = new TQFrame( this );
line->setLineWidth( 1 );
line->setMidLineWidth( 0 );
line->setFixedWidth( 100 );
- line->setFrameShape( QFrame::HLine );
- line->setFrameShadow( QFrame::Plain );
+ line->setFrameShape( TQFrame::HLine );
+ line->setFrameShadow( TQFrame::Plain );
- QLabel *host_label = new QLabel( i18n( "Host:" ), this );
- QLabel *host = new QLabel( m_item->shareItem()->host(), this );
+ TQLabel *host_label = new TQLabel( i18n( "Host:" ), this );
+ TQLabel *host = new TQLabel( m_item->shareItem()->host(), this );
- Smb4KHostItem *host_item = static_cast<Smb4KNetworkBrowserItem *>( m_item->parent() )->hostItem();
- QLabel *ip_label = new QLabel( i18n( "IP address:" ), this );
- QLabel *ip_address = new QLabel( (host_item && !host_item->ip().isEmpty()) ?
+ Smb4KHostItem *host_item = static_cast<Smb4KNetworkBrowserItem *>( m_item->tqparent() )->hostItem();
+ TQLabel *ip_label = new TQLabel( i18n( "IP address:" ), this );
+ TQLabel *ip_address = new TQLabel( (host_item && !host_item->ip().isEmpty()) ?
host_item->ip() : i18n( "Unknown" ), this, "IPAddress" );
m_layout->addWidget( share_label, 0, 1, 0 );
@@ -223,7 +223,7 @@ void Smb4KNetworkBrowserToolTip::setupTip()
{
m_layout->addWidget( mounted_label, 3, 1, 0 );
m_layout->addWidget( mounted, 3, 2, 0 );
- m_layout->addMultiCellWidget( line, 4, 4, 1, 2, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( line, 4, 4, 1, 2, TQt::AlignCenter );
m_layout->addWidget( host_label, 5, 1, 0 );
m_layout->addWidget( host, 5, 2, 0 );
m_layout->addWidget( ip_label, 6, 1, 0 );
@@ -231,7 +231,7 @@ void Smb4KNetworkBrowserToolTip::setupTip()
}
else
{
- m_layout->addMultiCellWidget( line, 3, 3, 1, 2, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( line, 3, 3, 1, 2, TQt::AlignCenter );
m_layout->addWidget( host_label, 4, 1, 0 );
m_layout->addWidget( host, 4, 2, 0 );
m_layout->addWidget( ip_label, 5, 1, 0 );
@@ -246,10 +246,10 @@ void Smb4KNetworkBrowserToolTip::setupTip()
}
}
- QLabel *pix_label = new QLabel( this );
+ TQLabel *pix_label = new TQLabel( this );
pix_label->setPixmap( m_item->desktopIcon() );
- m_layout->addMultiCellWidget( pix_label, 0, m_layout->numRows(), 0, 0, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( pix_label, 0, m_layout->numRows(), 0, 0, TQt::AlignCenter );
}
@@ -267,11 +267,11 @@ void Smb4KNetworkBrowserToolTip::update()
{
case Smb4KNetworkBrowserItem::Workgroup:
{
- QLabel *master_label = static_cast<QLabel *>( child( "MasterBrowser", "QLabel", true ) );
+ TQLabel *master_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "MasterBrowser", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( master_label )
{
- QString master_string = m_item->workgroupItem()->masterIP().isEmpty() ?
+ TQString master_string = m_item->workgroupItem()->masterIP().isEmpty() ?
m_item->workgroupItem()->master() :
m_item->workgroupItem()->master() + " ("+m_item->workgroupItem()->masterIP()+")";
@@ -282,13 +282,13 @@ void Smb4KNetworkBrowserToolTip::update()
}
case Smb4KNetworkBrowserItem::Host:
{
- QLabel *os_label = static_cast<QLabel *>( child( "OSString", "QLabel", true ) );
- QLabel *server_label = static_cast<QLabel *>( child( "ServerString", "QLabel", true ) );
- QLabel *ip_label = static_cast<QLabel *>( child( "IPAddress", "QLabel", true ) );
+ TQLabel *os_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "OSString", TQLABEL_OBJECT_NAME_STRING, true )) );
+ TQLabel *server_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "ServerString", TQLABEL_OBJECT_NAME_STRING, true )) );
+ TQLabel *ip_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "IPAddress", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( os_label )
{
- QString os_string = m_item->hostItem()->osString().isEmpty() ?
+ TQString os_string = m_item->hostItem()->osString().isEmpty() ?
i18n( "Unknown" ) :
m_item->hostItem()->osString();
@@ -297,7 +297,7 @@ void Smb4KNetworkBrowserToolTip::update()
if ( server_label )
{
- QString server_string = m_item->hostItem()->serverString().isEmpty() ?
+ TQString server_string = m_item->hostItem()->serverString().isEmpty() ?
i18n( "Unknown" ) :
m_item->hostItem()->serverString();
@@ -306,7 +306,7 @@ void Smb4KNetworkBrowserToolTip::update()
if ( ip_label )
{
- QString ip_string = m_item->hostItem()->ip().isEmpty() ?
+ TQString ip_string = m_item->hostItem()->ip().isEmpty() ?
i18n( "Unknown" ) :
m_item->hostItem()->ip();
@@ -317,12 +317,12 @@ void Smb4KNetworkBrowserToolTip::update()
}
case Smb4KNetworkBrowserItem::Share:
{
- QLabel *ip_label = static_cast<QLabel *>( child( "IPAddress", "QLabel", true ) );
+ TQLabel *ip_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "IPAddress", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( ip_label )
{
- Smb4KHostItem *host = static_cast<Smb4KNetworkBrowserItem *>( m_item->parent() )->hostItem();
- QString ip_string;
+ Smb4KHostItem *host = static_cast<Smb4KNetworkBrowserItem *>( m_item->tqparent() )->hostItem();
+ TQString ip_string;
if ( host )
{
@@ -348,22 +348,22 @@ void Smb4KNetworkBrowserToolTip::update()
}
-void Smb4KNetworkBrowserToolTip::mousePressEvent( QMouseEvent *e )
+void Smb4KNetworkBrowserToolTip::mousePressEvent( TQMouseEvent *e )
{
hide();
- QLabel::mousePressEvent( e );
+ TQLabel::mousePressEvent( e );
}
-void Smb4KNetworkBrowserToolTip::leaveEvent( QEvent *e )
+void Smb4KNetworkBrowserToolTip::leaveEvent( TQEvent *e )
{
hide();
- QLabel::leaveEvent( e );
+ TQLabel::leaveEvent( e );
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KNetworkBrowserToolTip::slotHideToolTip()
diff --git a/smb4k/browser/smb4knetworkbrowsertooltip.h b/smb4k/browser/smb4knetworkbrowsertooltip.h
index 993f64c..a389991 100644
--- a/smb4k/browser/smb4knetworkbrowsertooltip.h
+++ b/smb4k/browser/smb4knetworkbrowsertooltip.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qlabel.h>
-#include <qlayout.h>
+// TQt includes
+#include <tqlabel.h>
+#include <tqlayout.h>
// Forward declarations:
class Smb4KNetworkBrowserItem;
@@ -45,9 +45,10 @@ class Smb4KNetworkBrowserItem;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KNetworkBrowserToolTip : public QLabel
+class Smb4KNetworkBrowserToolTip : public TQLabel
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -68,7 +69,7 @@ class Smb4KNetworkBrowserToolTip : public QLabel
* exactly at position @p pos but with a displacement of 5 pixels in x-
* and y-direction.
*/
- void showTip( const QPoint &pos );
+ void showTip( const TQPoint &pos );
/**
* If you need to update the tool tip while it is shown, this is the function
@@ -87,14 +88,14 @@ class Smb4KNetworkBrowserToolTip : public QLabel
protected:
/**
- * Reimplemented from QLabel.
+ * Reimplemented from TQLabel.
*/
- void mousePressEvent( QMouseEvent *e );
+ void mousePressEvent( TQMouseEvent *e );
/**
- * Reimplemented from QLabel.
+ * Reimplemented from TQLabel.
*/
- void leaveEvent( QEvent *e );
+ void leaveEvent( TQEvent *e );
protected slots:
/**
@@ -109,9 +110,9 @@ class Smb4KNetworkBrowserToolTip : public QLabel
Smb4KNetworkBrowserItem *m_item;
/**
- * The layout for the tool tip
+ * The tqlayout for the tool tip
*/
- QGridLayout *m_layout;
+ TQGridLayout *m_layout;
/**
* Set up the tool tip
diff --git a/smb4k/configdlg/smb4kauthoptions.cpp b/smb4k/configdlg/smb4kauthoptions.cpp
index 1cafc91..6dcbd9d 100644
--- a/smb4k/configdlg/smb4kauthoptions.cpp
+++ b/smb4k/configdlg/smb4kauthoptions.cpp
@@ -24,13 +24,13 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qcheckbox.h>
-#include <qlayout.h>
-#include <qgroupbox.h>
-#include <qbuttongroup.h>
-#include <qlabel.h>
-#include <qwhatsthis.h>
+// TQt includes
+#include <tqcheckbox.h>
+#include <tqlayout.h>
+#include <tqgroupbox.h>
+#include <tqbuttongroup.h>
+#include <tqlabel.h>
+#include <tqwhatsthis.h>
// KDE includes
#include <klocale.h>
@@ -39,58 +39,58 @@
// application specific includes
#include "smb4kauthoptions.h"
-Smb4KAuthOptions::Smb4KAuthOptions( QWidget *parent, const char *name )
-: QWidget( parent, name )
+Smb4KAuthOptions::Smb4KAuthOptions( TQWidget *tqparent, const char *name )
+: TQWidget( tqparent, name )
{
//
// Default Authentication
//
- QGridLayout *grid = new QGridLayout( this );
+ TQGridLayout *grid = new TQGridLayout( this );
grid->setSpacing( 10 );
- QButtonGroup *password_group = new QButtonGroup( 1, QButtonGroup::Horizontal,
+ TQButtonGroup *password_group = new TQButtonGroup( 1, Qt::Horizontal,
i18n( "Password Storage" ), this );
- QCheckBox *use_wallet = new QCheckBox( i18n( "Save the authentication data in a wallet" ),
+ TQCheckBox *use_wallet = new TQCheckBox( i18n( "Save the authentication data in a wallet" ),
password_group, "kcfg_UseWallet" );
- (void) new QCheckBox( i18n( "If no wallet is used, remember authentication data during run time" ),
+ (void) new TQCheckBox( i18n( "If no wallet is used, remember authentication data during run time" ),
password_group, "kcfg_RememberPasswords" );
- QGroupBox *login_box = new QGroupBox( 1, Qt::Horizontal, i18n( "Default Login" ),
+ TQGroupBox *login_box = new TQGroupBox( 1, Qt::Horizontal, i18n( "Default Login" ),
this, "DefaultLoginBox" );
// login_box->setInsideMargin( 10 );
- QCheckBox *default_auth = new QCheckBox( i18n( "Use default login" ),
+ TQCheckBox *default_auth = new TQCheckBox( i18n( "Use default login" ),
login_box, "kcfg_UseDefaultLogin" );
- QWidget *auth_widget = new QWidget( login_box, "DefaultAuthWidget" );
- QGridLayout *auth_grid = new QGridLayout( auth_widget );
+ TQWidget *auth_widget = new TQWidget( login_box, "DefaultAuthWidget" );
+ TQGridLayout *auth_grid = new TQGridLayout( auth_widget );
auth_grid->setSpacing( 5 );
- QLabel *login = new QLabel( i18n( "User:" ), auth_widget );
+ TQLabel *login = new TQLabel( i18n( "User:" ), auth_widget );
KLineEdit *default_login = new KLineEdit( auth_widget, "DefaultUserName" );
default_login->setMinimumWidth( 150 );
- QWhatsThis::add( default_login, i18n( "This login name is used by default to authenticate to a remote server." ) );
- QLabel *password = new QLabel( i18n( "Password:" ), auth_widget );
+ TQWhatsThis::add( default_login, i18n( "This login name is used by default to authenticate to a remote server." ) );
+ TQLabel *password = new TQLabel( i18n( "Password:" ), auth_widget );
KLineEdit *default_password = new KLineEdit( auth_widget, "DefaultPassword" );
default_password->setEchoMode( KLineEdit::Password );
default_password->setMinimumWidth( 150 );
- QWhatsThis::add( default_password, i18n( "This password is used by default to authenticate to a remote server. It may be empty." ) );
+ TQWhatsThis::add( default_password, i18n( "This password is used by default to authenticate to a remote server. It may be empty." ) );
auth_grid->addWidget( login, 0, 0 );
auth_grid->addWidget( default_login, 0, 1 );
auth_grid->addWidget( password, 1, 0 );
auth_grid->addWidget( default_password, 1, 1 );
- QSpacerItem *spacer2 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer2 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
grid->addWidget( password_group, 0, 0, 0 );
grid->addWidget( login_box, 1, 0, 0 );
grid->addItem( spacer2, 2, 0 );
- connect( use_wallet, SIGNAL( stateChanged( int ) ),
- this, SLOT( slotKWalletButtonState( int ) ) );
- connect( default_auth, SIGNAL( stateChanged( int ) ),
- this, SLOT( slotDefaultAuthButtonState( int ) ) );
+ connect( use_wallet, TQT_SIGNAL( stateChanged( int ) ),
+ this, TQT_SLOT( slotKWalletButtonState( int ) ) );
+ connect( default_auth, TQT_SIGNAL( stateChanged( int ) ),
+ this, TQT_SLOT( slotDefaultAuthButtonState( int ) ) );
slotKWalletButtonState( use_wallet->state() );
slotDefaultAuthButtonState( default_auth->state() );
@@ -102,31 +102,31 @@ Smb4KAuthOptions::~Smb4KAuthOptions()
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KAuthOptions::slotKWalletButtonState( int state )
{
- if ( state == QCheckBox::On )
+ if ( state == TQCheckBox::On )
{
- static_cast<QCheckBox *>( child( "DefaultLoginBox", "QGroupBox", true ) )->setEnabled( true );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "DefaultLoginBox", TQGROUPBOX_OBJECT_NAME_STRING, true )) )->setEnabled( true );
}
- else if ( state == QCheckBox::Off )
+ else if ( state == TQCheckBox::Off )
{
- static_cast<QCheckBox *>( child( "DefaultLoginBox", "QGroupBox", true ) )->setEnabled( false );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "DefaultLoginBox", TQGROUPBOX_OBJECT_NAME_STRING, true )) )->setEnabled( false );
}
}
void Smb4KAuthOptions::slotDefaultAuthButtonState( int state )
{
- if ( state == QCheckBox::On )
+ if ( state == TQCheckBox::On )
{
- static_cast<QCheckBox *>( child( "DefaultAuthWidget", "QWidget", true ) )->setEnabled( true );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "DefaultAuthWidget", TQWIDGET_OBJECT_NAME_STRING, true )) )->setEnabled( true );
}
- else if ( state == QCheckBox::Off )
+ else if ( state == TQCheckBox::Off )
{
- static_cast<QCheckBox *>( child( "DefaultAuthWidget", "QWidget", true ) )->setEnabled( false );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "DefaultAuthWidget", TQWIDGET_OBJECT_NAME_STRING, true )) )->setEnabled( false );
}
}
diff --git a/smb4k/configdlg/smb4kauthoptions.h b/smb4k/configdlg/smb4kauthoptions.h
index 5428ede..119f077 100644
--- a/smb4k/configdlg/smb4kauthoptions.h
+++ b/smb4k/configdlg/smb4kauthoptions.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qwidget.h>
+// TQt includes
+#include <tqwidget.h>
/**
@@ -43,19 +43,20 @@
*/
-class Smb4KAuthOptions : public QWidget
+class Smb4KAuthOptions : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this widget
*/
- Smb4KAuthOptions( QWidget *parent = 0, const char *name = 0 );
+ Smb4KAuthOptions( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
diff --git a/smb4k/configdlg/smb4kconfigdialog.cpp b/smb4k/configdlg/smb4kconfigdialog.cpp
index 449aec3..5e28afc 100644
--- a/smb4k/configdlg/smb4kconfigdialog.cpp
+++ b/smb4k/configdlg/smb4kconfigdialog.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qradiobutton.h>
-#include <qcheckbox.h>
+// TQt includes
+#include <tqradiobutton.h>
+#include <tqcheckbox.h>
// KDE includes
#include <klistview.h>
@@ -74,14 +74,14 @@ bool always_use_su = false;
bool close_dialog = false;
-Smb4KConfigDialog::Smb4KConfigDialog( Smb4KSettings *settings, QWidget *parent, const char *name )
-: KConfigDialog( parent, name, settings )
+Smb4KConfigDialog::Smb4KConfigDialog( Smb4KSettings *settings, TQWidget *tqparent, const char *name )
+: KConfigDialog( tqparent, name, settings )
{
// FIXME: I guess, normally we would not need to close destructively,
// but at the moment there are issues with the KURLRequester in file
// mode. To work around those, we are closing the dialog destructively.
// Maybe we can remove this if we moved to KDE4.
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
// Add the pages:
Smb4KUserInterfaceOptions *interface_options = new Smb4KUserInterfaceOptions( this, "UserInterfaceOptions" );
@@ -108,7 +108,7 @@ Smb4KConfigDialog::Smb4KConfigDialog( Smb4KSettings *settings, QWidget *parent,
// done by the core. We only need to disable widgets here.
if ( Smb4KSettings::sudo().isEmpty() )
{
- QRadioButton *sudo = static_cast<QRadioButton *>( super_user_options->child( "SudoButton", "QRadioButton", true ) );
+ TQRadioButton *sudo = static_cast<TQRadioButton *>( TQT_TQWIDGET(super_user_options->child( "SudoButton", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
if ( sudo )
{
@@ -117,7 +117,7 @@ Smb4KConfigDialog::Smb4KConfigDialog( Smb4KSettings *settings, QWidget *parent,
}
else if ( Smb4KSettings::super().isEmpty() )
{
- QRadioButton *super = static_cast<QRadioButton *>( super_user_options->child( "SuperButton", "QRadioButton", true ) );
+ TQRadioButton *super = static_cast<TQRadioButton *>( TQT_TQWIDGET(super_user_options->child( "SuperButton", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
if ( super )
{
@@ -174,17 +174,17 @@ Smb4KConfigDialog::Smb4KConfigDialog( Smb4KSettings *settings, QWidget *parent,
setInitialSize( configDialogSize( *(Smb4KSettings::self()->config()), "ConfigDialog" ) );
// Connections
- connect( samba_options, SIGNAL( customSettingsChanged() ),
- this, SLOT( slotCustomSambaSettingsChanged() ) );
+ connect( samba_options, TQT_SIGNAL( customSettingsChanged() ),
+ this, TQT_SLOT( slotCustomSambaSettingsChanged() ) );
- connect( super_user_options, SIGNAL( removeEntries() ),
- this, SLOT( slotRemoveSuperUserEntries() ) );
+ connect( super_user_options, TQT_SIGNAL( removeEntries() ),
+ this, TQT_SLOT( slotRemoveSuperUserEntries() ) );
- connect( Smb4KCore::fileIO(), SIGNAL( failed() ),
- this, SLOT( slotReceivedFileIOFailed() ) );
+ connect( Smb4KCore::fileIO(), TQT_SIGNAL( failed() ),
+ this, TQT_SLOT( slotReceivedFileIOFailed() ) );
- connect( Smb4KCore::fileIO(), SIGNAL( finished() ),
- this, SLOT( slotReceivedFileIOFinished() ) );
+ connect( Smb4KCore::fileIO(), TQT_SIGNAL( finished() ),
+ this, TQT_SLOT( slotReceivedFileIOFinished() ) );
}
@@ -196,7 +196,7 @@ Smb4KConfigDialog::~Smb4KConfigDialog()
void Smb4KConfigDialog::loadCustomSambaOptions()
{
// Get the list view:
- KListView *custom_list = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *custom_list = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( !custom_list )
{
@@ -207,7 +207,7 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
custom_list->clear();
// Now get the default values:
- QString default_filesystem, protocol_hint, default_uid, default_gid;
+ TQString default_filesystem, protocol_hint, default_uid, default_gid;
bool write_access = true;
switch( Smb4KSettings::filesystem() )
@@ -237,7 +237,7 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
{
// In this case the user leaves it to the net
// command to determine the right protocol.
- protocol_hint = QString::null;
+ protocol_hint = TQString();
break;
}
@@ -261,7 +261,7 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
}
default:
{
- protocol_hint = QString::null;
+ protocol_hint = TQString();
break;
}
@@ -287,9 +287,9 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
}
}
- const QValueList<Smb4KSambaOptionsInfo *> &list = optionsHandler()->customOptionsList();
+ const TQValueList<Smb4KSambaOptionsInfo *> &list = optionsHandler()->customOptionsList();
- for ( QValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = list.begin();
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = list.begin();
it != list.end(); ++it )
{
// If the only modification is that the share is to be remounted,
@@ -298,14 +298,14 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
(*it)->remount() &&
(*it)->port() == Smb4KSettings::remotePort() &&
#ifndef __FreeBSD__
- QString::compare( (*it)->filesystem(), default_filesystem ) == 0 &&
+ TQString::compare( (*it)->filesystem(), default_filesystem ) == 0 &&
(*it)->writeAccess() == write_access &&
(*it)->kerberos() == Smb4KSettings::useKerberos() /* FreeBSD does not know Kerberos for mounting */ &&
#endif
- ((QString::compare( default_filesystem, "cifs" ) == 0 && (*it)->uid().toInt() == (int)getuid()) ||
- (!(*it)->uid().isEmpty() && QString::compare( (*it)->uid(), Smb4KSettings::userID() ) == 0)) &&
- ((QString::compare( default_filesystem, "cifs" ) == 0 && (*it)->gid().toInt() == (int)getgid()) ||
- (!(*it)->gid().isEmpty() && QString::compare( (*it)->gid(), Smb4KSettings::groupID() ) == 0)) )
+ ((TQString::compare( default_filesystem, "cifs" ) == 0 && (*it)->uid().toInt() == (int)getuid()) ||
+ (!(*it)->uid().isEmpty() && TQString::compare( (*it)->uid(), Smb4KSettings::userID() ) == 0)) &&
+ ((TQString::compare( default_filesystem, "cifs" ) == 0 && (*it)->gid().toInt() == (int)getgid()) ||
+ (!(*it)->gid().isEmpty() && TQString::compare( (*it)->gid(), Smb4KSettings::groupID() ) == 0)) )
{
continue;
}
@@ -316,15 +316,15 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
item->setText( Smb4KSambaOptions::ItemName, (*it)->itemName() );
item->setText( Smb4KSambaOptions::Port, ((*it)->port() != -1 ?
- QString( "%1" ).arg( (*it)->port() ) :
- QString( "%1" ).arg( Smb4KSettings::remotePort() )) );
+ TQString( "%1" ).tqarg( (*it)->port() ) :
+ TQString( "%1" ).tqarg( Smb4KSettings::remotePort() )) );
switch ( (*it)->type() )
{
case Smb4KSambaOptionsInfo::Host:
{
item->setText( Smb4KSambaOptions::Protocol, !(*it)->protocol().isEmpty() ?
- (QString::compare( (*it)->protocol(), "auto" ) == 0 ? i18n( "auto" ) : (*it)->protocol().upper()) :
+ (TQString::compare( (*it)->protocol(), "auto" ) == 0 ? i18n( "auto" ) : (*it)->protocol().upper()) :
(protocol_hint.isEmpty() ? i18n( "auto" ) : protocol_hint.upper()) );
item->setText( Smb4KSambaOptions::Kerberos, (*it)->kerberos() ?
@@ -380,7 +380,7 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
}
}
- Smb4KSambaOptions *samba_options = static_cast<Smb4KSambaOptions *>( child( "SambaOptions", "Smb4KSambaOptions", true ) );
+ Smb4KSambaOptions *samba_options = static_cast<Smb4KSambaOptions *>( TQT_TQWIDGET(child( "SambaOptions", "Smb4KSambaOptions", true )) );
if ( samba_options )
{
@@ -392,7 +392,7 @@ void Smb4KConfigDialog::loadCustomSambaOptions()
void Smb4KConfigDialog::saveCustomSambaOptions()
{
// Get the list view:
- KListView *custom_list = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *custom_list = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( !custom_list )
{
@@ -403,11 +403,11 @@ void Smb4KConfigDialog::saveCustomSambaOptions()
{
// First remove all items that have been deleted in the
// configuration dialog:
- QValueList<Smb4KSambaOptionsInfo *> list = optionsHandler()->customOptionsList();
+ TQValueList<Smb4KSambaOptionsInfo *> list = optionsHandler()->customOptionsList();
- for ( QValueList<Smb4KSambaOptionsInfo *>::Iterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::Iterator it = list.begin(); it != list.end(); ++it )
{
- if ( !custom_list->findItem( (*it)->itemName(), Smb4KSambaOptions::ItemName ) )
+ if ( !custom_list->tqfindItem( (*it)->itemName(), Smb4KSambaOptions::ItemName ) )
{
optionsHandler()->removeItem( (*it)->itemName(), false );
@@ -420,11 +420,11 @@ void Smb4KConfigDialog::saveCustomSambaOptions()
}
// Now updated the remaining items:
- QListViewItemIterator it( custom_list );
+ TQListViewItemIterator it( custom_list );
while ( it.current() )
{
- QListViewItem *item = it.current();
+ TQListViewItem *item = it.current();
Smb4KSambaOptionsInfo *info = optionsHandler()->findItem( item->text( Smb4KSambaOptions::ItemName ) );
@@ -434,11 +434,11 @@ void Smb4KConfigDialog::saveCustomSambaOptions()
{
case Smb4KSambaOptionsInfo::Host:
{
- info->setProtocol( (QString::compare( item->text( Smb4KSambaOptions::Protocol ), "-" ) != 0 ?
+ info->setProtocol( (TQString::compare( item->text( Smb4KSambaOptions::Protocol ), "-" ) != 0 ?
item->text( Smb4KSambaOptions::Protocol ).lower() :
- QString::null) );
+ TQString()) );
- info->setKerberos( (QString::compare( item->text( Smb4KSambaOptions::Kerberos ), i18n( "yes" ) ) == 0) );
+ info->setKerberos( (TQString::compare( item->text( Smb4KSambaOptions::Kerberos ), i18n( "yes" ) ) == 0) );
info->setPort( item->text( Smb4KSambaOptions::Port ).toInt() );
@@ -448,24 +448,24 @@ void Smb4KConfigDialog::saveCustomSambaOptions()
{
#ifndef __FreeBSD__
// FreeBSD does not know Kerberos for mounting
- info->setKerberos( (QString::compare( item->text( Smb4KSambaOptions::Kerberos ), i18n( "yes" ) ) == 0) );
+ info->setKerberos( (TQString::compare( item->text( Smb4KSambaOptions::Kerberos ), i18n( "yes" ) ) == 0) );
- info->setFilesystem( (QString::compare( item->text( Smb4KSambaOptions::FileSystem ), "-" ) != 0 ?
+ info->setFilesystem( (TQString::compare( item->text( Smb4KSambaOptions::FileSystem ), "-" ) != 0 ?
item->text( Smb4KSambaOptions::FileSystem ).lower() :
- QString::null) );
+ TQString()) );
- info->setWriteAccess( (QString::compare( item->text( Smb4KSambaOptions::WriteAccess ),
+ info->setWriteAccess( (TQString::compare( item->text( Smb4KSambaOptions::WriteAccess ),
i18n( "read-write" ) ) == 0) );
#endif
- info->setUID( (QString::compare( item->text( Smb4KSambaOptions::UID ), i18n( "default" ) ) != 0 &&
- QString::compare( item->text( Smb4KSambaOptions::UID ), "-" ) != 0) ?
+ info->setUID( (TQString::compare( item->text( Smb4KSambaOptions::UID ), i18n( "default" ) ) != 0 &&
+ TQString::compare( item->text( Smb4KSambaOptions::UID ), "-" ) != 0) ?
item->text( Smb4KSambaOptions::UID ) :
- QString::null );
+ TQString() );
- info->setGID( (QString::compare( item->text( Smb4KSambaOptions::GID ), i18n( "default" ) ) != 0 &&
- QString::compare( item->text( Smb4KSambaOptions::GID ), "-" ) != 0) ?
+ info->setGID( (TQString::compare( item->text( Smb4KSambaOptions::GID ), i18n( "default" ) ) != 0 &&
+ TQString::compare( item->text( Smb4KSambaOptions::GID ), "-" ) != 0) ?
item->text( Smb4KSambaOptions::GID ) :
- QString::null );
+ TQString() );
info->setPort( item->text( Smb4KSambaOptions::Port ).toInt() );
@@ -488,9 +488,9 @@ void Smb4KConfigDialog::saveCustomSambaOptions()
else
{
// Remove all items, if the list view is empty:
- QValueList<Smb4KSambaOptionsInfo *> list = optionsHandler()->customOptionsList();
+ TQValueList<Smb4KSambaOptionsInfo *> list = optionsHandler()->customOptionsList();
- for ( QValueList<Smb4KSambaOptionsInfo *>::Iterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::Iterator it = list.begin(); it != list.end(); ++it )
{
if ( !(*it)->remount() )
{
@@ -513,18 +513,18 @@ void Smb4KConfigDialog::loadAuthenticationData()
{
// Load the default login info and put it into the configuration
// page:
- Smb4KAuthInfo auth( QString::null, QString::null, QString::null );
+ Smb4KAuthInfo auth( TQString::null, TQString::null, TQString::null );
(void) passwordHandler()->readDefaultAuth( &auth );
- KLineEdit *default_user = static_cast<KLineEdit *>( child( "DefaultUserName", "KLineEdit", true ) );
+ KLineEdit *default_user = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "DefaultUserName", "KLineEdit", true )) );
if ( default_user )
{
default_user->setText( auth.user() );
}
- KLineEdit *default_pass = static_cast<KLineEdit *>( child( "DefaultPassword", "KLineEdit", true ) );
+ KLineEdit *default_pass = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "DefaultPassword", "KLineEdit", true )) );
if ( default_pass )
{
@@ -541,16 +541,16 @@ void Smb4KConfigDialog::saveAuthenticationData()
// entries:
if ( passwordHandler()->walletIsOpen() )
{
- Smb4KAuthInfo auth( QString::null, QString::null, QString::null );
+ Smb4KAuthInfo auth( TQString::null, TQString::null, TQString::null );
- KLineEdit *default_user = static_cast<KLineEdit *>( child( "DefaultUserName", "KLineEdit", true ) );
+ KLineEdit *default_user = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "DefaultUserName", "KLineEdit", true )) );
if ( default_user )
{
auth.setUser( default_user->text() );
}
- KLineEdit *default_pass = static_cast<KLineEdit *>( child( "DefaultPassword", "KLineEdit", true ) );
+ KLineEdit *default_pass = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "DefaultPassword", "KLineEdit", true )) );
if ( default_pass )
{
@@ -568,12 +568,12 @@ void Smb4KConfigDialog::saveAuthenticationData()
bool Smb4KConfigDialog::writeSuperUserEntries()
{
- QRadioButton *sudo = static_cast<QRadioButton *>( child( "SudoButton", "QRadioButton", true ) );
- QRadioButton *super = static_cast<QRadioButton *>( child( "SuperButton", "QRadioButton", true ) );
+ TQRadioButton *sudo = static_cast<TQRadioButton *>( TQT_TQWIDGET(child( "SudoButton", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
+ TQRadioButton *super = static_cast<TQRadioButton *>( TQT_TQWIDGET(child( "SuperButton", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
#ifdef __linux__
- QCheckBox *force = static_cast<QCheckBox *>( child( "kcfg_UseForceUnmount", "QCheckBox", true ) );
+ TQCheckBox *force = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseForceUnmount", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
#endif
- QCheckBox *full_use = static_cast<QCheckBox *>( child( "kcfg_AlwaysUseSuperUser", "QCheckBox", true ) );
+ TQCheckBox *full_use = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_AlwaysUseSuperUser", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
// Check if we need to write anything at all:
Smb4KFileIO::Operation op = Smb4KFileIO::NoOperation;
@@ -640,12 +640,12 @@ bool Smb4KConfigDialog::writeSuperUserEntries()
void Smb4KConfigDialog::removeSuperUserEntries()
{
- QRadioButton *sudo = static_cast<QRadioButton *>( child( "SudoButton", "QRadioButton", true ) );
- QRadioButton *super = static_cast<QRadioButton *>( child( "SuperButton", "QRadioButton", true ) );
+ TQRadioButton *sudo = static_cast<TQRadioButton *>( TQT_TQWIDGET(child( "SudoButton", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
+ TQRadioButton *super = static_cast<TQRadioButton *>( TQT_TQWIDGET(child( "SuperButton", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
#ifdef __linux__
- QCheckBox *force = static_cast<QCheckBox *>( child( "kcfg_UseForceUnmount", "QCheckBox", true ) );
+ TQCheckBox *force = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseForceUnmount", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
#endif
- QCheckBox *full_use = static_cast<QCheckBox *>( child( "kcfg_AlwaysUseSuperUser", "QCheckBox", true ) );
+ TQCheckBox *full_use = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_AlwaysUseSuperUser", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
#ifdef __linux__
if ( sudo && super && force && full_use )
@@ -689,13 +689,13 @@ void Smb4KConfigDialog::removeSuperUserEntries()
bool Smb4KConfigDialog::checkSettings()
{
bool ok = true;
- QString issues = QString::null;
+ TQString issues = TQString();
int index = 0;
// If the user chose "Query custom master browser" in the
// "Network" tab, there must be a master browser present:
- QRadioButton *query_custom_master = static_cast<QRadioButton *>( child( "CustomMasterBrowserLabel", "QRadioButton", true ) );
- KLineEdit *custom_master_input = static_cast<KLineEdit *>( child( "kcfg_CustomMasterBrowser", "KLineEdit", true ) );
+ TQRadioButton *query_custom_master = static_cast<TQRadioButton *>( TQT_TQWIDGET(child( "CustomMasterBrowserLabel", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
+ KLineEdit *custom_master_input = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_CustomMasterBrowser", "KLineEdit", true )) );
if ( query_custom_master && custom_master_input &&
query_custom_master->isChecked() &&
@@ -709,8 +709,8 @@ bool Smb4KConfigDialog::checkSettings()
// If the user chose "Scan broadcast areas" in the
// "Network" tab, there must broadcast areas present:
- QRadioButton *scan_bcast_areas = static_cast<QRadioButton *>( child( "BroadcastAreasLabel", "QRadioButton", true ) );
- KLineEdit *bcast_areas_input = static_cast<KLineEdit *>( child( "kcfg_BroadcastAreas", "KLineEdit", true ) );
+ TQRadioButton *scan_bcast_areas = static_cast<TQRadioButton *>( TQT_TQWIDGET(child( "BroadcastAreasLabel", TQRADIOBUTTON_OBJECT_NAME_STRING, true )) );
+ KLineEdit *bcast_areas_input = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_BroadcastAreas", "KLineEdit", true )) );
if ( scan_bcast_areas && bcast_areas_input &&
scan_bcast_areas->isChecked() &&
@@ -723,7 +723,7 @@ bool Smb4KConfigDialog::checkSettings()
}
// The mount prefix must not be empty:
- KURLRequester *mount_prefix = static_cast<KURLRequester *>( child( "kcfg_MountPrefix", "KURLRequester", true ) );
+ KURLRequester *mount_prefix = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "kcfg_MountPrefix", "KURLRequester", true )) );
if ( mount_prefix && mount_prefix->url().stripWhiteSpace().isEmpty() )
{
@@ -735,8 +735,8 @@ bool Smb4KConfigDialog::checkSettings()
// If the user wants to use a default login, the user
// name must not be empty.
- QCheckBox *use_default_login = static_cast<QCheckBox *>( child( "kcfg_UseDefaultLogin", "QCheckBox", true ) );
- KLineEdit *default_user_name = static_cast<KLineEdit *>( child( "kcfg_DefaultUserName", "KLineEdit", true ) );
+ TQCheckBox *use_default_login = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseDefaultLogin", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KLineEdit *default_user_name = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_DefaultUserName", "KLineEdit", true )) );
if ( use_default_login && default_user_name &&
use_default_login->isChecked() &&
@@ -748,30 +748,30 @@ bool Smb4KConfigDialog::checkSettings()
issues.append( "* "+i18n( "[Authentication] The default user name has not been entered.\n" ) );
}
- // The file mask must not be empty.
- KLineEdit *file_mask = static_cast<KLineEdit *>( child( "kcfg_FileMask", "KLineEdit", true ) );
+ // The file tqmask must not be empty.
+ KLineEdit *file_tqmask = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_FileMask", "KLineEdit", true )) );
- if ( file_mask && file_mask->text().stripWhiteSpace().isEmpty() )
+ if ( file_tqmask && file_tqmask->text().stripWhiteSpace().isEmpty() )
{
ok = false;
index++;
- issues.append( "* "+i18n( "[Samba] The file mask is empty.\n" ) );
+ issues.append( "* "+i18n( "[Samba] The file tqmask is empty.\n" ) );
}
- // The directory mask must not be empty.
- KLineEdit *directory_mask = static_cast<KLineEdit *>( child( "kcfg_DirectoryMask", "KLineEdit", true ) );
+ // The directory tqmask must not be empty.
+ KLineEdit *directory_tqmask = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_DirectoryMask", "KLineEdit", true )) );
- if ( directory_mask && directory_mask->text().stripWhiteSpace().isEmpty() )
+ if ( directory_tqmask && directory_tqmask->text().stripWhiteSpace().isEmpty() )
{
ok = false;
index++;
- issues.append( "* "+i18n( "[Samba] The directory mask is empty.\n" ) );
+ issues.append( "* "+i18n( "[Samba] The directory tqmask is empty.\n" ) );
}
// The UID must not be empty.
- KLineEdit *user_id = static_cast<KLineEdit *>( child( "kcfg_UserID", "KLineEdit", true ) );
+ KLineEdit *user_id = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_UserID", "KLineEdit", true )) );
if ( user_id && user_id->text().stripWhiteSpace().isEmpty() )
{
@@ -782,7 +782,7 @@ bool Smb4KConfigDialog::checkSettings()
}
// The GID must not be empty.
- KLineEdit *group_id = static_cast<KLineEdit *>( child( "kcfg_GroupID", "KLineEdit", true ) );
+ KLineEdit *group_id = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_GroupID", "KLineEdit", true )) );
if ( group_id && group_id->text().stripWhiteSpace().isEmpty() )
{
@@ -793,7 +793,7 @@ bool Smb4KConfigDialog::checkSettings()
}
// The rsync prefix must not be empty.
- KURLRequester *rsync_prefix = static_cast<KURLRequester *>( child( "kcfg_RsyncPrefix", "KURLRequester", true ) );
+ KURLRequester *rsync_prefix = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "kcfg_RsyncPrefix", "KURLRequester", true )) );
if ( rsync_prefix && rsync_prefix->url().stripWhiteSpace().isEmpty() )
{
@@ -804,8 +804,8 @@ bool Smb4KConfigDialog::checkSettings()
}
// The path where to store partial files must not be empty.
- QCheckBox *use_partical_directory = static_cast<QCheckBox *>( child( "kcfg_UsePartialDirectory", "QCheckBox", true ) );
- KURLRequester *partial_directory = static_cast<KURLRequester *>( child( "kcfg_PartialDirectory", "KURLRequester", true ) );
+ TQCheckBox *use_partical_directory = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UsePartialDirectory", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KURLRequester *partial_directory = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "kcfg_PartialDirectory", "KURLRequester", true )) );
if ( use_partical_directory && use_partical_directory->isChecked() &&
partial_directory && partial_directory->url().stripWhiteSpace().isEmpty() )
@@ -817,8 +817,8 @@ bool Smb4KConfigDialog::checkSettings()
}
// The the exclude patterns must not be empty.
- QCheckBox *use_exclude_pattern = static_cast<QCheckBox *>( child( "kcfg_UseExcludePattern", "QCheckBox", true ) );
- KLineEdit *exclude_pattern = static_cast<KLineEdit *>( child( "kcfg_ExcludePattern", "KLineEdit", true ) );
+ TQCheckBox *use_exclude_pattern = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseExcludePattern", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KLineEdit *exclude_pattern = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_ExcludePattern", "KLineEdit", true )) );
if ( use_exclude_pattern && use_exclude_pattern->isChecked() &&
exclude_pattern && exclude_pattern->text().stripWhiteSpace().isEmpty() )
@@ -830,8 +830,8 @@ bool Smb4KConfigDialog::checkSettings()
}
// The the path of the exclude file must not be empty.
- QCheckBox *use_exclude_file = static_cast<QCheckBox *>( child( "kcfg_UseExcludeFrom", "QCheckBox", true ) );
- KURLRequester *exclude_file = static_cast<KURLRequester *>( child( "kcfg_ExcludeFrom", "KURLRequester", true ) );
+ TQCheckBox *use_exclude_file = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseExcludeFrom", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KURLRequester *exclude_file = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "kcfg_ExcludeFrom", "KURLRequester", true )) );
if ( use_exclude_file && use_exclude_file->isChecked() &&
exclude_file && exclude_file->url().stripWhiteSpace().isEmpty() )
@@ -843,8 +843,8 @@ bool Smb4KConfigDialog::checkSettings()
}
// The the include patterns must not be empty.
- QCheckBox *use_include_pattern = static_cast<QCheckBox *>( child( "kcfg_UseIncludePattern", "QCheckBox", true ) );
- KLineEdit *include_pattern = static_cast<KLineEdit *>( child( "kcfg_IncludePattern", "KLineEdit", true ) );
+ TQCheckBox *use_include_pattern = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseIncludePattern", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KLineEdit *include_pattern = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_IncludePattern", "KLineEdit", true )) );
if ( use_include_pattern && use_include_pattern->isChecked() &&
include_pattern && include_pattern->text().stripWhiteSpace().isEmpty() )
@@ -856,8 +856,8 @@ bool Smb4KConfigDialog::checkSettings()
}
// The the path of the exclude file must not be empty.
- QCheckBox *use_include_file = static_cast<QCheckBox *>( child( "kcfg_UseIncludeFrom", "QCheckBox", true ) );
- KURLRequester *include_file = static_cast<KURLRequester *>( child( "kcfg_IncludeFrom", "KURLRequester", true ) );
+ TQCheckBox *use_include_file = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseIncludeFrom", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KURLRequester *include_file = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "kcfg_IncludeFrom", "KURLRequester", true )) );
if ( use_include_file && use_include_file->isChecked() &&
include_file && include_file->url().stripWhiteSpace().isEmpty() )
@@ -870,13 +870,13 @@ bool Smb4KConfigDialog::checkSettings()
// If you make backups, check that the suffix and that the
// backup directory is not empty.
- QCheckBox *make_backups = static_cast<QCheckBox *>( child( "kcfg_MakeBackups", "QCheckBox", true ) );
+ TQCheckBox *make_backups = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_MakeBackups", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
if ( make_backups && make_backups->isChecked() )
{
// The backup suffix must not be empty.
- QCheckBox *use_backup_suffix = static_cast<QCheckBox *>( child( "kcfg_UseBackupSuffix", "QCheckBox", true ) );
- KLineEdit *backup_suffix = static_cast<KLineEdit *>( child( "kcfg_BackupSuffix", "KLineEdit", true ) );
+ TQCheckBox *use_backup_suffix = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseBackupSuffix", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KLineEdit *backup_suffix = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_BackupSuffix", "KLineEdit", true )) );
if ( use_backup_suffix && use_backup_suffix->isChecked() &&
backup_suffix && backup_suffix->text().stripWhiteSpace().isEmpty() )
@@ -888,8 +888,8 @@ bool Smb4KConfigDialog::checkSettings()
}
// The the path for backups must not be empty.
- QCheckBox *use_backup_dir = static_cast<QCheckBox *>( child( "kcfg_UseBackupDirectory", "QCheckBox", true ) );
- KURLRequester *backup_dir = static_cast<KURLRequester *>( child( "kcfg_BackupDirectory", "KURLRequester", true ) );
+ TQCheckBox *use_backup_dir = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseBackupDirectory", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
+ KURLRequester *backup_dir = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "kcfg_BackupDirectory", "KURLRequester", true )) );
if ( use_backup_dir && use_backup_dir->isChecked() &&
backup_dir && backup_dir->url().stripWhiteSpace().isEmpty() )
@@ -905,11 +905,11 @@ bool Smb4KConfigDialog::checkSettings()
{
if ( index == 1 )
{
- KMessageBox::error( this, i18n( "The configuration could not be written, because one setting is incomplete:\n%1Please correct this issue." ).arg( issues ) );
+ KMessageBox::error( this, i18n( "The configuration could not be written, because one setting is incomplete:\n%1Please correct this issue." ).tqarg( issues ) );
}
else
{
- KMessageBox::error( this, i18n( "The configuration could not be written, because %1 settings are incomplete:\n%1Please correct these issues." ).arg( index ).arg( issues ) );
+ KMessageBox::error( this, i18n( "The configuration could not be written, because %1 settings are incomplete:\n%1Please correct these issues." ).tqarg( index ).tqarg( issues ) );
}
}
@@ -917,7 +917,7 @@ bool Smb4KConfigDialog::checkSettings()
}
-void Smb4KConfigDialog::showEvent( QShowEvent *e )
+void Smb4KConfigDialog::showEvent( TQShowEvent *e )
{
// Spontaneous show events come from outside the application.
// We do not want to react on them.
@@ -930,7 +930,7 @@ void Smb4KConfigDialog::showEvent( QShowEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KConfigDialog::slotApply()
@@ -996,7 +996,7 @@ void Smb4KConfigDialog::slotOk()
void Smb4KConfigDialog::slotCancel()
{
// Reset the custom Samba options tab:
- Smb4KSambaOptions *samba_options = static_cast<Smb4KSambaOptions *>( child( "SambaOptions", "Smb4KSambaOptions", true ) );
+ Smb4KSambaOptions *samba_options = static_cast<Smb4KSambaOptions *>( TQT_TQWIDGET(child( "SambaOptions", "Smb4KSambaOptions", true )) );
if ( samba_options )
{
@@ -1010,7 +1010,7 @@ void Smb4KConfigDialog::slotCancel()
void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
{
// Get the list view and all other input widgets:
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( !view )
{
@@ -1018,17 +1018,17 @@ void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
}
// Get the list of custom options:
- QValueList<Smb4KSambaOptionsInfo *> list = optionsHandler()->customOptionsList();
+ TQValueList<Smb4KSambaOptionsInfo *> list = optionsHandler()->customOptionsList();
bool changed = false;
// Loop through the list view items to see what changed and if
// we need to enable the 'Apply' button:
- for ( QValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = list.begin();
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = list.begin();
it != list.end(); ++it )
{
// Find the item in the list view:
- QListViewItem *item = view->findItem( (*it)->itemName(), Smb4KSambaOptions::ItemName );
+ TQListViewItem *item = view->tqfindItem( (*it)->itemName(), Smb4KSambaOptions::ItemName );
if ( item )
{
@@ -1036,8 +1036,8 @@ void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
{
// Check if the protocol changed.
if ( ((*it)->protocol().isEmpty() &&
- QString::compare( item->text( Smb4KSambaOptions::Protocol ).lower(), i18n( "auto" ) ) != 0) ||
- QString::compare( (*it)->protocol(), item->text( Smb4KSambaOptions::Protocol ).lower() ) != 0 )
+ TQString::compare( item->text( Smb4KSambaOptions::Protocol ).lower(), i18n( "auto" ) ) != 0) ||
+ TQString::compare( (*it)->protocol(), item->text( Smb4KSambaOptions::Protocol ).lower() ) != 0 )
{
changed = true;
@@ -1048,7 +1048,7 @@ void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
{
#ifndef __FreeBSD__
// Check if the file system changed.
- if ( QString::compare( (*it)->filesystem(), item->text( Smb4KSambaOptions::FileSystem ).lower() ) != 0 )
+ if ( TQString::compare( (*it)->filesystem(), item->text( Smb4KSambaOptions::FileSystem ).lower() ) != 0 )
{
changed = true;
@@ -1056,11 +1056,11 @@ void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
}
// Check if the write access changed.
- QString write_access = (*it)->writeAccess() ?
+ TQString write_access = (*it)->writeAccess() ?
i18n( "read-write" ) :
i18n( "read-only" );
- if ( QString::compare( write_access, item->text( Smb4KSambaOptions::WriteAccess ) ) != 0 )
+ if ( TQString::compare( write_access, item->text( Smb4KSambaOptions::WriteAccess ) ) != 0 )
{
changed = true;
@@ -1069,8 +1069,8 @@ void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
#endif
// Check if the UID changed.
if ( ((*it)->uid().isEmpty() &&
- QString::compare( i18n( "default" ), item->text( Smb4KSambaOptions::UID ) ) != 0) ||
- QString::compare( (*it)->uid(), item->text( Smb4KSambaOptions::UID ) ) != 0 )
+ TQString::compare( i18n( "default" ), item->text( Smb4KSambaOptions::UID ) ) != 0) ||
+ TQString::compare( (*it)->uid(), item->text( Smb4KSambaOptions::UID ) ) != 0 )
{
changed = true;
@@ -1079,8 +1079,8 @@ void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
// Check if the GID changed.
if ( ((*it)->gid().isEmpty() &&
- QString::compare( i18n( "default" ), item->text( Smb4KSambaOptions::GID ) ) != 0) ||
- QString::compare( (*it)->gid(), item->text( Smb4KSambaOptions::GID ) ) != 0 )
+ TQString::compare( i18n( "default" ), item->text( Smb4KSambaOptions::GID ) ) != 0) ||
+ TQString::compare( (*it)->gid(), item->text( Smb4KSambaOptions::GID ) ) != 0 )
{
changed = true;
@@ -1094,11 +1094,11 @@ void Smb4KConfigDialog::slotCustomSambaSettingsChanged()
}
// Check if the Kerberos entry changed.
- QString kerberos = (*it)->kerberos() ?
+ TQString kerberos = (*it)->kerberos() ?
i18n( "yes" ) :
i18n( "no" );
- if ( QString::compare( kerberos, item->text( Smb4KSambaOptions::Kerberos ) ) != 0 )
+ if ( TQString::compare( kerberos, item->text( Smb4KSambaOptions::Kerberos ) ) != 0 )
{
changed = true;
@@ -1136,9 +1136,9 @@ void Smb4KConfigDialog::slotRemoveSuperUserEntries()
void Smb4KConfigDialog::slotReceivedFileIOFailed()
{
#ifdef __linux__
- QCheckBox *force = static_cast<QCheckBox *>( child( "kcfg_UseForceUnmount", "QCheckBox", true ) );
+ TQCheckBox *force = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseForceUnmount", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
#endif
- QCheckBox *full_use = static_cast<QCheckBox *>( child( "kcfg_AlwaysUseSuperUser", "QCheckBox", true ) );
+ TQCheckBox *full_use = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_AlwaysUseSuperUser", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
#ifdef __linux__
if ( force && full_use )
@@ -1198,10 +1198,10 @@ KInstance *Smb4KConfigDialogFactory::instance()
}
-QObject *Smb4KConfigDialogFactory::createObject( QObject *parent, const char *name, const char *,
-const QStringList & )
+TQObject *Smb4KConfigDialogFactory::createObject( TQObject *tqparent, const char *name, const char *,
+const TQStringList & )
{
- return static_cast<QObject *>( new Smb4KConfigDialog( Smb4KSettings::self(), static_cast<QWidget *>( parent ), name ) );
+ return TQT_TQOBJECT( new Smb4KConfigDialog( Smb4KSettings::self(), TQT_TQWIDGET( tqparent ), name ) );
}
diff --git a/smb4k/configdlg/smb4kconfigdialog.h b/smb4k/configdlg/smb4kconfigdialog.h
index 8e6f9f8..4681df2 100644
--- a/smb4k/configdlg/smb4kconfigdialog.h
+++ b/smb4k/configdlg/smb4kconfigdialog.h
@@ -48,6 +48,7 @@ class Smb4KSettings;
class Smb4KConfigDialog : public KConfigDialog
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -56,11 +57,11 @@ class Smb4KConfigDialog : public KConfigDialog
* @param settings The Smb4KSettings object that needs to be passed
* so that the settings can be managed.
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this dialog
*/
- Smb4KConfigDialog( Smb4KSettings *settings, QWidget *parent = 0, const char *name = 0 );
+ Smb4KConfigDialog( Smb4KSettings *settings, TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -69,12 +70,12 @@ class Smb4KConfigDialog : public KConfigDialog
protected:
/**
- * Reimplemented from QWidget to do last things before the
+ * Reimplemented from TQWidget to do last things before the
* configuration dialog is shown.
*
* @param e The show event object
*/
- void showEvent( QShowEvent *e );
+ void showEvent( TQShowEvent *e );
protected slots:
/**
@@ -171,6 +172,7 @@ class KAboutData;
class Smb4KConfigDialogFactory : KLibFactory
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -189,9 +191,9 @@ class Smb4KConfigDialogFactory : KLibFactory
static KInstance *instance();
protected:
- QObject *createObject( QObject *parent = 0, const char *name = 0,
- const char *classname = "QObject",
- const QStringList &args = QStringList() );
+ TQObject *createObject( TQObject *tqparent = 0, const char *name = 0,
+ const char *classname = TQOBJECT_OBJECT_NAME_STRING,
+ const TQStringList &args = TQStringList() );
private:
/**
diff --git a/smb4k/configdlg/smb4knetworkoptions.cpp b/smb4k/configdlg/smb4knetworkoptions.cpp
index 4c2244b..23b7f22 100644
--- a/smb4k/configdlg/smb4knetworkoptions.cpp
+++ b/smb4k/configdlg/smb4knetworkoptions.cpp
@@ -24,11 +24,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qbuttongroup.h>
-#include <qlayout.h>
-#include <qradiobutton.h>
-#include <qlabel.h>
+// TQt includes
+#include <tqbuttongroup.h>
+#include <tqlayout.h>
+#include <tqradiobutton.h>
+#include <tqlabel.h>
// KDE includes
#include <klocale.h>
@@ -39,30 +39,30 @@
#include "smb4knetworkoptions.h"
#include "../core/smb4ksettings.h"
-Smb4KNetworkOptions::Smb4KNetworkOptions( QWidget *parent, const char *name ) : QWidget( parent, name )
+Smb4KNetworkOptions::Smb4KNetworkOptions( TQWidget *tqparent, const char *name ) : TQWidget( tqparent, name )
{
- QGridLayout *grid = new QGridLayout( this );
+ TQGridLayout *grid = new TQGridLayout( this );
grid->setSpacing( 10 );
//
// The browse list group box.
//
- QButtonGroup *browse_box = new QButtonGroup( 1, Qt::Horizontal, i18n( "Browse List" ),
+ TQButtonGroup *browse_box = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Browse List" ),
this, "kcfg_BrowseList" );
- browse_box->insert( new QRadioButton( i18n( "Scan the network neighborhood for available workgroups and domains" ),
+ browse_box->insert( new TQRadioButton( i18n( "Scan the network neighborhood for available workgroups and domains" ),
browse_box ), Smb4KSettings::EnumBrowseList::LookupDomains );
- browse_box->insert( new QRadioButton( i18n( "Query the current workgroup master browser" ),
+ browse_box->insert( new TQRadioButton( i18n( "Query the current workgroup master browser" ),
browse_box), Smb4KSettings::EnumBrowseList::QueryCurrentMaster );
- QWidget *buttonWidget = new QWidget( browse_box );
- QGridLayout *buttonLayout = new QGridLayout( buttonWidget );
+ TQWidget *buttonWidget = new TQWidget( browse_box );
+ TQGridLayout *buttonLayout = new TQGridLayout( buttonWidget );
buttonLayout->setSpacing( 5 );
- QRadioButton *use_host = new QRadioButton( i18n( "Query this master browser:" ),
+ TQRadioButton *use_host = new TQRadioButton( i18n( "Query this master browser:" ),
buttonWidget, "CustomMasterBrowserLabel" );
KLineEdit *host_name = new KLineEdit( buttonWidget, "kcfg_CustomMasterBrowser" );
- QRadioButton *use_scan = new QRadioButton( i18n( "Scan broadcast areas:" ),
+ TQRadioButton *use_scan = new TQRadioButton( i18n( "Scan broadcast areas:" ),
buttonWidget, "BroadcastAreasLabel" );
KLineEdit *broadcast_addresses = new KLineEdit( buttonWidget, "kcfg_BroadcastAreas" );
@@ -77,21 +77,21 @@ Smb4KNetworkOptions::Smb4KNetworkOptions( QWidget *parent, const char *name ) :
//
// The search group box
//
- QButtonGroup *search_box = new QButtonGroup( 1, Qt::Horizontal, i18n( "Network Search" ),
+ TQButtonGroup *search_box = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Network Search" ),
this, "kcfg_SearchMethod" );
search_box->setInsideSpacing( 5 );
- QLabel *description = new QLabel( search_box );
+ TQLabel *description = new TQLabel( search_box );
description->setText( i18n( "Smb4K uses \"nmblookup\" by default to search for remote hosts. This method is very reliable but fails sometimes if your network neighborhood is configured uncommonly. In this case you should try to use \"smbclient\"." ) );
- description->setTextFormat( Qt::RichText );
+ description->setTextFormat( TQt::RichText );
- search_box->insert( new QRadioButton( i18n( "Use nmblookup (recommended)" ),
+ search_box->insert( new TQRadioButton( i18n( "Use nmblookup (recommended)" ),
search_box ), Smb4KSettings::EnumSearchMethod::Nmblookup );
- search_box->insert( new QRadioButton( i18n( "Use smbclient" ),
+ search_box->insert( new TQRadioButton( i18n( "Use smbclient" ),
search_box ), Smb4KSettings::EnumSearchMethod::Smbclient );
- QSpacerItem *spacer4 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer4 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
grid->addWidget( browse_box, 0, 0, 0 );
grid->addWidget( search_box, 1, 0, 0 );
diff --git a/smb4k/configdlg/smb4knetworkoptions.h b/smb4k/configdlg/smb4knetworkoptions.h
index b3b47f3..a23e64f 100644
--- a/smb4k/configdlg/smb4knetworkoptions.h
+++ b/smb4k/configdlg/smb4knetworkoptions.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qwidget.h>
+// TQt includes
+#include <tqwidget.h>
/**
* This is the configuration tab for the network settings
@@ -41,19 +41,20 @@
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KNetworkOptions : public QWidget
+class Smb4KNetworkOptions : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The widget's name
*/
- Smb4KNetworkOptions( QWidget *parent = 0, const char *name = 0 );
+ Smb4KNetworkOptions( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
diff --git a/smb4k/configdlg/smb4krsyncoptions.cpp b/smb4k/configdlg/smb4krsyncoptions.cpp
index 301ee30..e7ca576 100644
--- a/smb4k/configdlg/smb4krsyncoptions.cpp
+++ b/smb4k/configdlg/smb4krsyncoptions.cpp
@@ -23,12 +23,12 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qbuttongroup.h>
-#include <qcheckbox.h>
-#include <qlabel.h>
-#include <qradiobutton.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqbuttongroup.h>
+#include <tqcheckbox.h>
+#include <tqlabel.h>
+#include <tqradiobutton.h>
// KDE includes
#include <klocale.h>
@@ -41,60 +41,60 @@
// application specific includes
#include "smb4krsyncoptions.h"
-Smb4KRsyncOptions::Smb4KRsyncOptions( QWidget *parent, const char *name ) : QTabWidget( parent, name )
+Smb4KRsyncOptions::Smb4KRsyncOptions( TQWidget *tqparent, const char *name ) : TQTabWidget( tqparent, name )
{
setMargin( 10 );
//
// The Copying tab
//
- QWidget *copying_tab = new QWidget( this, "RsyncCopying" );
- QGridLayout *copying_layout = new QGridLayout( copying_tab );
+ TQWidget *copying_tab = new TQWidget( this, "RsyncCopying" );
+ TQGridLayout *copying_layout = new TQGridLayout( copying_tab );
copying_layout->setSpacing( 10 );
- QGroupBox *directory_box = new QGroupBox( 2, QGroupBox::Horizontal, i18n( "Default Destination" ),
+ TQGroupBox *directory_box = new TQGroupBox( 2, Qt::Horizontal, i18n( "Default Destination" ),
copying_tab, "RsyncDestinationBox" );
directory_box->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "Rsync prefix:" ), directory_box, "RsyncPrefixLabel" );
+ (void) new TQLabel( i18n( "Rsync prefix:" ), directory_box, "RsyncPrefixLabel" );
KURLRequester *prefix = new KURLRequester( directory_box, "kcfg_RsyncPrefix" );
prefix->setMode( KFile::Directory | KFile::LocalOnly );
- QButtonGroup *general_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "General" ),
+ TQButtonGroup *general_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "General" ),
copying_tab, "RsyncModeBox" );
general_box->setInsideSpacing( 5 );
- QCheckBox *archive_mode = new QCheckBox( i18n( "Archive mode" ), general_box, "kcfg_ArchiveMode" );
- QCheckBox *recursive = new QCheckBox( i18n( "Recurse into directories" ), general_box, "kcfg_RecurseIntoDirectories" );
- (void) new QCheckBox( i18n( "Skip files that are newer in target directory" ), general_box, "kcfg_UpdateTarget" );
- (void) new QCheckBox( i18n( "Update destination files in place" ), general_box, "kcfg_UpdateInPlace" );
- (void) new QCheckBox( i18n( "Use relative path names" ), general_box, "kcfg_RelativePathNames" );
- (void) new QCheckBox( i18n( "Don't send implied directories" ), general_box, "kcfg_NoImpliedDirectories" );
- (void) new QCheckBox( i18n( "Transfer directories without recursing" ), general_box, "kcfg_TransferDirectories" );
- (void) new QCheckBox( i18n( "Compress data during transfer" ), general_box, "kcfg_CompressData" );
+ TQCheckBox *archive_mode = new TQCheckBox( i18n( "Archive mode" ), general_box, "kcfg_ArchiveMode" );
+ TQCheckBox *recursive = new TQCheckBox( i18n( "Recurse into directories" ), general_box, "kcfg_RecurseIntoDirectories" );
+ (void) new TQCheckBox( i18n( "Skip files that are newer in target directory" ), general_box, "kcfg_UpdateTarget" );
+ (void) new TQCheckBox( i18n( "Update destination files in place" ), general_box, "kcfg_UpdateInPlace" );
+ (void) new TQCheckBox( i18n( "Use relative path names" ), general_box, "kcfg_RelativePathNames" );
+ (void) new TQCheckBox( i18n( "Don't send implied directories" ), general_box, "kcfg_NoImpliedDirectories" );
+ (void) new TQCheckBox( i18n( "Transfer directories without recursing" ), general_box, "kcfg_TransferDirectories" );
+ (void) new TQCheckBox( i18n( "Compress data during transfer" ), general_box, "kcfg_CompressData" );
- QButtonGroup *links_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "Links" ), copying_tab, "RsyncModeBox" );
+ TQButtonGroup *links_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "Links" ), copying_tab, "RsyncModeBox" );
links_box->setInsideSpacing( 5 );
- QCheckBox *links = new QCheckBox( i18n( "Preserve symlinks" ), links_box, "kcfg_PreserveSymlinks" );
- (void) new QCheckBox( i18n( "Transform symlinks" ), links_box, "kcfg_TransformSymlinks" );
- (void) new QCheckBox( i18n( "Only transform unsafe symlinks" ), links_box, "kcfg_TransformUnsafeSymlinks" );
- (void) new QCheckBox( i18n( "Ignore unsafe symlinks" ), links_box, "kcfg_IgnoreUnsafeSymlinks" );
- (void) new QCheckBox( i18n( "Preserve hard links" ), links_box, "kcfg_PreserveHardLinks" );
- (void) new QCheckBox( i18n( "Keep directory symlinks" ), links_box, "kcfg_KeepDirectorySymlinks" );
+ TQCheckBox *links = new TQCheckBox( i18n( "Preserve symlinks" ), links_box, "kcfg_PreserveSymlinks" );
+ (void) new TQCheckBox( i18n( "Transform symlinks" ), links_box, "kcfg_TransformSymlinks" );
+ (void) new TQCheckBox( i18n( "Only transform unsafe symlinks" ), links_box, "kcfg_TransformUnsafeSymlinks" );
+ (void) new TQCheckBox( i18n( "Ignore unsafe symlinks" ), links_box, "kcfg_IgnoreUnsafeSymlinks" );
+ (void) new TQCheckBox( i18n( "Preserve hard links" ), links_box, "kcfg_PreserveHardLinks" );
+ (void) new TQCheckBox( i18n( "Keep directory symlinks" ), links_box, "kcfg_KeepDirectorySymlinks" );
- QButtonGroup *perm_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "File Permissions, etc." ),
+ TQButtonGroup *perm_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "File Permissions, etc." ),
copying_tab, "RsyncPreservationBox" );
perm_box->setInsideSpacing( 5 );
- QCheckBox *perms = new QCheckBox( i18n( "Preserve permissions" ), perm_box, "kcfg_PreservePermissions" );
- QCheckBox *group = new QCheckBox( i18n( "Preserve group" ), perm_box, "kcfg_PreserveGroup" );
- QCheckBox *owner = new QCheckBox( i18n( "Preserve owner" ), perm_box, "kcfg_PreserveOwner" );
- QCheckBox *devices = new QCheckBox( i18n( "Preserve device and special files" ), perm_box, "kcfg_PreserveDevicesAndSpecials" );
- QCheckBox *times = new QCheckBox( i18n( "Preserve times" ), perm_box, "kcfg_PreserveTimes" );
- (void) new QCheckBox( i18n( "Omit directories when preserving times" ), perm_box, "kcfg_OmitDirectoryTimes" );
+ TQCheckBox *perms = new TQCheckBox( i18n( "Preserve permissions" ), perm_box, "kcfg_PreservePermissions" );
+ TQCheckBox *group = new TQCheckBox( i18n( "Preserve group" ), perm_box, "kcfg_PreserveGroup" );
+ TQCheckBox *owner = new TQCheckBox( i18n( "Preserve owner" ), perm_box, "kcfg_PreserveOwner" );
+ TQCheckBox *devices = new TQCheckBox( i18n( "Preserve device and special files" ), perm_box, "kcfg_PreserveDevicesAndSpecials" );
+ TQCheckBox *times = new TQCheckBox( i18n( "Preserve times" ), perm_box, "kcfg_PreserveTimes" );
+ (void) new TQCheckBox( i18n( "Omit directories when preserving times" ), perm_box, "kcfg_OmitDirectoryTimes" );
- QSpacerItem *spacer1 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer1 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
copying_layout->addWidget( directory_box, 0, 0, 0 );
copying_layout->addWidget( general_box, 1, 0, 0 );
@@ -108,45 +108,45 @@ Smb4KRsyncOptions::Smb4KRsyncOptions( QWidget *parent, const char *name ) : QTab
//
// The File Deletion & Transfer tab
//
- QWidget *deltrans_tab = new QWidget( this, "RsyncFileDeletion" );
- QGridLayout *deltrans_layout = new QGridLayout( deltrans_tab );
+ TQWidget *deltrans_tab = new TQWidget( this, "RsyncFileDeletion" );
+ TQGridLayout *deltrans_layout = new TQGridLayout( deltrans_tab );
deltrans_layout->setSpacing( 10 );
- QButtonGroup *delete_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "File Deletion" ), deltrans_tab, "RsyncDeleteBox" );
+ TQButtonGroup *delete_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "File Deletion" ), deltrans_tab, "RsyncDeleteBox" );
delete_box->setInsideSpacing( 5 );
- (void) new QCheckBox( i18n( "Remove synchronized source files" ), delete_box, "kcfg_RemoveSourceFiles" );
- (void) new QCheckBox( i18n( "Delete extraneous files" ), delete_box, "kcfg_DeleteExtraneous" );
- (void) new QCheckBox( i18n( "Delete files before transfer" ), delete_box, "kcfg_DeleteBefore" );
- (void) new QCheckBox( i18n( "Delete files after transfer" ), delete_box, "kcfg_DeleteAfter" );
- (void) new QCheckBox( i18n( "Delete files during transfer" ), delete_box, "kcfg_DeleteDuring" );
- (void) new QCheckBox( i18n( "Also delete excluded files" ), delete_box, "kcfg_DeleteExcluded" );
- (void) new QCheckBox( i18n( "Delete even if I/O errors occur" ), delete_box, "kcfg_IgnoreErrors" );
- (void) new QCheckBox( i18n( "Force deletion of non-void directories" ), delete_box, "kcfg_ForceDirectoryDeletion" );
+ (void) new TQCheckBox( i18n( "Remove synchronized source files" ), delete_box, "kcfg_RemoveSourceFiles" );
+ (void) new TQCheckBox( i18n( "Delete extraneous files" ), delete_box, "kcfg_DeleteExtraneous" );
+ (void) new TQCheckBox( i18n( "Delete files before transfer" ), delete_box, "kcfg_DeleteBefore" );
+ (void) new TQCheckBox( i18n( "Delete files after transfer" ), delete_box, "kcfg_DeleteAfter" );
+ (void) new TQCheckBox( i18n( "Delete files during transfer" ), delete_box, "kcfg_DeleteDuring" );
+ (void) new TQCheckBox( i18n( "Also delete excluded files" ), delete_box, "kcfg_DeleteExcluded" );
+ (void) new TQCheckBox( i18n( "Delete even if I/O errors occur" ), delete_box, "kcfg_IgnoreErrors" );
+ (void) new TQCheckBox( i18n( "Force deletion of non-void directories" ), delete_box, "kcfg_ForceDirectoryDeletion" );
- QButtonGroup *delete_restrictions_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "Restrictions" ), deltrans_tab, "RsyncDeleteRestrictionsBox" );
+ TQButtonGroup *delete_restrictions_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "Restrictions" ), deltrans_tab, "RsyncDeleteRestrictionsBox" );
delete_restrictions_box->setInsideSpacing( 5 );
- (void) new QCheckBox( i18n( "Don't delete more than this many files:" ), delete_restrictions_box, "kcfg_UseMaximumDelete" );
+ (void) new TQCheckBox( i18n( "Don't delete more than this many files:" ), delete_restrictions_box, "kcfg_UseMaximumDelete" );
(void) new KIntNumInput( delete_restrictions_box, "kcfg_MaximumDeleteValue" );
- QButtonGroup *transfer_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "File Transfer" ),
+ TQButtonGroup *transfer_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "File Transfer" ),
deltrans_tab, "RsyncFileTransferBox" );
transfer_box->setInsideSpacing( 5 );
- (void) new QCheckBox( i18n( "Don't transfer any file smaller than:" ), transfer_box, "kcfg_UseMinimalTransferSize" );
+ (void) new TQCheckBox( i18n( "Don't transfer any file smaller than:" ), transfer_box, "kcfg_UseMinimalTransferSize" );
KIntNumInput *min_size = new KIntNumInput( transfer_box, "kcfg_MinimalTransferSize" );
min_size->setSuffix( " kB" );
- (void) new QCheckBox( i18n( "Don't transfer any file larger than:" ), transfer_box, "kcfg_UseMaximalTransferSize" );
+ (void) new TQCheckBox( i18n( "Don't transfer any file larger than:" ), transfer_box, "kcfg_UseMaximalTransferSize" );
KIntNumInput *max_size = new KIntNumInput( transfer_box, "kcfg_MaximalTransferSize" );
max_size->setSuffix( " kB" );
- (void) new QCheckBox( i18n( "Keep partially transferred files" ), transfer_box, "kcfg_KeepPartial" );
+ (void) new TQCheckBox( i18n( "Keep partially transferred files" ), transfer_box, "kcfg_KeepPartial" );
transfer_box->addSpace( 0 );
- (void) new QCheckBox( i18n( "Put a partially transferred file into:" ), transfer_box, "kcfg_UsePartialDirectory" );
+ (void) new TQCheckBox( i18n( "Put a partially transferred file into:" ), transfer_box, "kcfg_UsePartialDirectory" );
KURLRequester *partial_dir = new KURLRequester( transfer_box, "kcfg_PartialDirectory" );
partial_dir->setMode( KFile::Directory | KFile::LocalOnly );
- QSpacerItem *spacer2 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer2 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
deltrans_layout->addWidget( delete_box, 0, 0, 0 );
deltrans_layout->addWidget( delete_restrictions_box, 1, 0, 0 );
@@ -159,38 +159,38 @@ Smb4KRsyncOptions::Smb4KRsyncOptions( QWidget *parent, const char *name ) : QTab
//
// The Filter tab
//
- QWidget *filter_tab = new QWidget( this, "RsyncFiltering" );
- QGridLayout *filter_layout = new QGridLayout( filter_tab );
+ TQWidget *filter_tab = new TQWidget( this, "RsyncFiltering" );
+ TQGridLayout *filter_layout = new TQGridLayout( filter_tab );
filter_layout->setSpacing( 10 );
- QButtonGroup *general_filter_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "General" ),
+ TQButtonGroup *general_filter_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "General" ),
filter_tab, "RsyncGeneralFilterBox" );
general_filter_box->setInsideSpacing( 5 );
- (void) new QCheckBox( i18n( "Auto-ignore files in the same way CVS does" ), general_filter_box, "kcfg_UseCVSExclude" );
+ (void) new TQCheckBox( i18n( "Auto-ignore files in the same way CVS does" ), general_filter_box, "kcfg_UseCVSExclude" );
general_filter_box->addSpace( 0 );
- (void) new QCheckBox( i18n( "Exclude files matching this pattern:" ), general_filter_box, "kcfg_UseExcludePattern" );
+ (void) new TQCheckBox( i18n( "Exclude files matching this pattern:" ), general_filter_box, "kcfg_UseExcludePattern" );
(void) new KLineEdit( general_filter_box, "kcfg_ExcludePattern" );
- (void) new QCheckBox( i18n( "Read exclude patterns from:" ), general_filter_box, "kcfg_UseExcludeFrom" );
+ (void) new TQCheckBox( i18n( "Read exclude patterns from:" ), general_filter_box, "kcfg_UseExcludeFrom" );
KURLRequester *exclude_from = new KURLRequester( general_filter_box, "kcfg_ExcludeFrom" );
exclude_from->setMode( KFile::File | KFile::LocalOnly );
- (void) new QCheckBox( i18n( "Don't exclude files matching this pattern:" ), general_filter_box, "kcfg_UseIncludePattern" );
+ (void) new TQCheckBox( i18n( "Don't exclude files matching this pattern:" ), general_filter_box, "kcfg_UseIncludePattern" );
(void) new KLineEdit( general_filter_box, "kcfg_IncludePattern" );
- (void) new QCheckBox( i18n( "Read include patterns from:" ), general_filter_box, "kcfg_UseIncludeFrom" );
+ (void) new TQCheckBox( i18n( "Read include patterns from:" ), general_filter_box, "kcfg_UseIncludeFrom" );
KURLRequester *include_from = new KURLRequester( general_filter_box, "kcfg_IncludeFrom" );
include_from->setMode( KFile::File | KFile::LocalOnly );
- QButtonGroup *filter_rules_box = new QButtonGroup( 1, QGroupBox::Horizontal, i18n( "Filter Rules" ),
+ TQButtonGroup *filter_rules_box = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Filter Rules" ),
filter_tab, "RsyncFilterRulesBox" );
filter_rules_box->setInsideSpacing( 5 );
- QLabel *filter_rules_label = new QLabel( i18n( "The rules defined below will be added to the \"rsync\" command as they are. Thus, you have to start with the --filter=... argument." ), filter_rules_box );
- filter_rules_label->setTextFormat( Qt::RichText );
+ TQLabel *filter_rules_label = new TQLabel( i18n( "The rules defined below will be added to the \"rsync\" command as they are. Thus, you have to start with the --filter=... argument." ), filter_rules_box );
+ filter_rules_label->setTextFormat( TQt::RichText );
(void) new KLineEdit( filter_rules_box, "kcfg_CustomFilteringRules" );
- (void) new QLabel( i18n( "Special filter rules:" ), filter_rules_box );
- QCheckBox *f_filter = new QCheckBox( i18n( "Use --filter='dir-merge /.rsync-filter' filter rule" ), filter_rules_box, "kcfg_UseFFilterRule" );
- QCheckBox *ff_filter = new QCheckBox( i18n( "Use --filter='exclude .rsync-filter' filter rule" ), filter_rules_box, "kcfg_UseFFFilterRule" );
+ (void) new TQLabel( i18n( "Special filter rules:" ), filter_rules_box );
+ TQCheckBox *f_filter = new TQCheckBox( i18n( "Use --filter='dir-merge /.rsync-filter' filter rule" ), filter_rules_box, "kcfg_UseFFilterRule" );
+ TQCheckBox *ff_filter = new TQCheckBox( i18n( "Use --filter='exclude .rsync-filter' filter rule" ), filter_rules_box, "kcfg_UseFFFilterRule" );
- QSpacerItem *spacer3 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer3 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
filter_layout->addWidget( general_filter_box, 0, 0, 0 );
filter_layout->addWidget( filter_rules_box, 1, 0, 0 );
@@ -202,43 +202,43 @@ Smb4KRsyncOptions::Smb4KRsyncOptions( QWidget *parent, const char *name ) : QTab
//
// The Advanced tab
//
- QWidget *advanced_tab = new QWidget( this, "RsyncAdvanced" );
- QGridLayout *advanced_layout = new QGridLayout( advanced_tab );
+ TQWidget *advanced_tab = new TQWidget( this, "RsyncAdvanced" );
+ TQGridLayout *advanced_layout = new TQGridLayout( advanced_tab );
advanced_layout->setSpacing( 10 );
- QButtonGroup *misc_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "General" ),
+ TQButtonGroup *misc_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "General" ),
advanced_tab, "RsyncAdvancedMiscBox" );
misc_box->setInsideSpacing( 5 );
- (void) new QCheckBox( i18n( "Handle sparse files efficiently" ), misc_box, "kcfg_EfficientSparseFileHandling" );
- (void) new QCheckBox( i18n( "Copy files whole (no rsync algorithm)" ), misc_box, "kcfg_CopyFilesWhole" );
- (void) new QCheckBox( i18n( "Don't cross file system boundaries" ), misc_box, "kcfg_OneFileSystem" );
- (void) new QCheckBox( i18n( "Only update files that already exist" ), misc_box, "kcfg_UpdateExisting" );
- (void) new QCheckBox( i18n( "Ignore files that already exist" ), misc_box, "kcfg_IgnoreExisting" );
- (void) new QCheckBox( i18n( "Delay updates until the end of transfer" ), misc_box, "kcfg_DelayUpdates" );
+ (void) new TQCheckBox( i18n( "Handle sparse files efficiently" ), misc_box, "kcfg_EfficientSparseFileHandling" );
+ (void) new TQCheckBox( i18n( "Copy files whole (no rsync algorithm)" ), misc_box, "kcfg_CopyFilesWhole" );
+ (void) new TQCheckBox( i18n( "Don't cross file system boundaries" ), misc_box, "kcfg_OneFileSystem" );
+ (void) new TQCheckBox( i18n( "Only update files that already exist" ), misc_box, "kcfg_UpdateExisting" );
+ (void) new TQCheckBox( i18n( "Ignore files that already exist" ), misc_box, "kcfg_IgnoreExisting" );
+ (void) new TQCheckBox( i18n( "Delay updates until the end of transfer" ), misc_box, "kcfg_DelayUpdates" );
- QButtonGroup *backup_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "Backup" ), advanced_tab, "RsyncBackupBox" );
+ TQButtonGroup *backup_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "Backup" ), advanced_tab, "RsyncBackupBox" );
backup_box->setInsideSpacing( 5 );
- QCheckBox *backup = new QCheckBox( i18n( "Make backups" ), backup_box, "kcfg_MakeBackups" );
+ TQCheckBox *backup = new TQCheckBox( i18n( "Make backups" ), backup_box, "kcfg_MakeBackups" );
backup_box->addSpace( 0 );
- (void) new QCheckBox( i18n( "Backup suffix:" ), backup_box, "kcfg_UseBackupSuffix" );
+ (void) new TQCheckBox( i18n( "Backup suffix:" ), backup_box, "kcfg_UseBackupSuffix" );
(void) new KLineEdit( backup_box, "kcfg_BackupSuffix" );
- (void) new QCheckBox( i18n( "Backup directory:" ), backup_box, "kcfg_UseBackupDirectory" );
+ (void) new TQCheckBox( i18n( "Backup directory:" ), backup_box, "kcfg_UseBackupDirectory" );
KURLRequester *backup_dir = new KURLRequester( backup_box, "kcfg_BackupDirectory" );
backup_dir->setMode( KFile::Directory | KFile::LocalOnly );
- QButtonGroup *checksum_box = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "Checksums" ), advanced_tab, "RsyncChecksumsBox" );
+ TQButtonGroup *checksum_box = new TQButtonGroup( 2, Qt::Horizontal, i18n( "Checksums" ), advanced_tab, "RsyncChecksumsBox" );
checksum_box->setInsideSpacing( 5 );
- (void) new QCheckBox( i18n( "Force fixed checksum block size:" ), checksum_box, "kcfg_UseBlockSize" );
+ (void) new TQCheckBox( i18n( "Force fixed checksum block size:" ), checksum_box, "kcfg_UseBlockSize" );
(void) new KIntNumInput( checksum_box, "kcfg_BlockSize" );
- (void) new QCheckBox( i18n( "Set block/file checksum seed:" ), checksum_box, "kcfg_UseChecksumSeed" );
+ (void) new TQCheckBox( i18n( "Set block/file checksum seed:" ), checksum_box, "kcfg_UseChecksumSeed" );
(void) new KIntNumInput( checksum_box, "kcfg_ChecksumSeed" );
- (void) new QCheckBox( i18n( "Skip files based on checksum" ), checksum_box, "kcfg_UseChecksum" );
+ (void) new TQCheckBox( i18n( "Skip files based on checksum" ), checksum_box, "kcfg_UseChecksum" );
checksum_box->addSpace( 0 );
- QSpacerItem *spacer4 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer4 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
advanced_layout->addWidget( misc_box, 0, 0, 0 );
advanced_layout->addWidget( backup_box, 1, 0, 0 );
@@ -247,38 +247,38 @@ Smb4KRsyncOptions::Smb4KRsyncOptions( QWidget *parent, const char *name ) : QTab
addTab( advanced_tab, i18n( "Advanced" ) );
- connect( archive_mode, SIGNAL( toggled( bool ) ),
- this, SLOT( slotArchiveToggled( bool ) ) );
+ connect( archive_mode, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotArchiveToggled( bool ) ) );
- connect( recursive, SIGNAL( toggled( bool ) ),
- this, SLOT( slotUncheckArchive( bool ) ) );
+ connect( recursive, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotUncheckArchive( bool ) ) );
- connect( links, SIGNAL( toggled( bool ) ),
- this, SLOT( slotUncheckArchive( bool ) ) );
+ connect( links, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotUncheckArchive( bool ) ) );
- connect( perms, SIGNAL( toggled( bool ) ),
- this, SLOT( slotUncheckArchive( bool ) ) );
+ connect( perms, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotUncheckArchive( bool ) ) );
- connect( times, SIGNAL( toggled( bool ) ),
- this, SLOT( slotUncheckArchive( bool ) ) );
+ connect( times, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotUncheckArchive( bool ) ) );
- connect( group, SIGNAL( toggled( bool ) ),
- this, SLOT( slotUncheckArchive( bool ) ) );
+ connect( group, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotUncheckArchive( bool ) ) );
- connect( owner, SIGNAL( toggled( bool ) ),
- this, SLOT( slotUncheckArchive( bool ) ) );
+ connect( owner, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotUncheckArchive( bool ) ) );
- connect( devices, SIGNAL( toggled( bool ) ),
- this, SLOT( slotUncheckArchive( bool ) ) );
+ connect( devices, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotUncheckArchive( bool ) ) );
- connect( backup, SIGNAL( toggled( bool ) ),
- this, SLOT( slotBackupToggled( bool ) ) );
+ connect( backup, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotBackupToggled( bool ) ) );
- connect( f_filter, SIGNAL( toggled( bool ) ),
- this, SLOT( slotFShortcutToggled( bool ) ) );
+ connect( f_filter, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotFShortcutToggled( bool ) ) );
- connect( ff_filter, SIGNAL( toggled( bool ) ),
- this, SLOT( slotFFShortcutToggled( bool ) ) );
+ connect( ff_filter, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotFFShortcutToggled( bool ) ) );
slotArchiveToggled( true );
slotBackupToggled( false );
@@ -291,20 +291,20 @@ Smb4KRsyncOptions::~Smb4KRsyncOptions()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KRsyncOptions::slotArchiveToggled( bool on )
{
if ( on )
{
- static_cast<QCheckBox *>( child( "kcfg_RecurseIntoDirectories", "QCheckBox", true ) )->setChecked( on );
- static_cast<QCheckBox *>( child( "kcfg_PreserveSymlinks", "QCheckBox", true ) )->setChecked( on );
- static_cast<QCheckBox *>( child( "kcfg_PreservePermissions", "QCheckBox", true ) )->setChecked( on );
- static_cast<QCheckBox *>( child( "kcfg_PreserveTimes", "QCheckBox", true ) )->setChecked( on );
- static_cast<QCheckBox *>( child( "kcfg_PreserveGroup", "QCheckBox", true ) )->setChecked( on );
- static_cast<QCheckBox *>( child( "kcfg_PreserveOwner", "QCheckBox", true ) )->setChecked( on );
- static_cast<QCheckBox *>( child( "kcfg_PreserveDevicesAndSpecials", "QCheckBox", true ) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_RecurseIntoDirectories", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_PreserveSymlinks", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_PreservePermissions", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_PreserveTimes", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_PreserveGroup", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_PreserveOwner", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_PreserveDevicesAndSpecials", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
}
}
@@ -313,23 +313,23 @@ void Smb4KRsyncOptions::slotUncheckArchive( bool on )
{
if ( !on )
{
- static_cast<QCheckBox *>( child( "kcfg_ArchiveMode", "QCheckBox", true ) )->setChecked( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_ArchiveMode", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setChecked( on );
}
}
void Smb4KRsyncOptions::slotBackupToggled( bool on )
{
- static_cast<QCheckBox *>( child( "kcfg_UseBackupDirectory", "QCheckBox", true ) )->setEnabled( on );
- static_cast<KURLRequester *>( child( "kcfg_BackupDirectory", "KURLRequester", true ) )->setEnabled( on );
- static_cast<QCheckBox *>( child( "kcfg_UseBackupSuffix", "QCheckBox", true ) )->setEnabled( on );
- static_cast<KLineEdit *>( child( "kcfg_BackupSuffix", "KLineEdit", true ) )->setEnabled( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseBackupDirectory", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setEnabled( on );
+ static_cast<KURLRequester *>( TQT_TQWIDGET(child( "kcfg_BackupDirectory", "KURLRequester", true )) )->setEnabled( on );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseBackupSuffix", TQCHECKBOX_OBJECT_NAME_STRING, true )) )->setEnabled( on );
+ static_cast<KLineEdit *>( TQT_TQWIDGET(child( "kcfg_BackupSuffix", "KLineEdit", true )) )->setEnabled( on );
}
void Smb4KRsyncOptions::slotFShortcutToggled( bool on )
{
- QCheckBox *ff_filter = static_cast<QCheckBox *>( child( "kcfg_UseFFFilterRule", "QCheckBox", true ) );
+ TQCheckBox *ff_filter = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseFFFilterRule", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
if ( on && ff_filter->isChecked() )
{
@@ -340,7 +340,7 @@ void Smb4KRsyncOptions::slotFShortcutToggled( bool on )
void Smb4KRsyncOptions::slotFFShortcutToggled( bool on )
{
- QCheckBox *f_filter = static_cast<QCheckBox *>( child( "kcfg_UseFFilterRule", "QCheckBox", true ) );
+ TQCheckBox *f_filter = static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_UseFFilterRule", TQCHECKBOX_OBJECT_NAME_STRING, true )) );
if ( on && f_filter->isChecked() )
{
diff --git a/smb4k/configdlg/smb4krsyncoptions.h b/smb4k/configdlg/smb4krsyncoptions.h
index 3559182..9e6aba8 100644
--- a/smb4k/configdlg/smb4krsyncoptions.h
+++ b/smb4k/configdlg/smb4krsyncoptions.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qtabwidget.h>
+// TQt includes
+#include <tqtabwidget.h>
/**
@@ -41,19 +41,20 @@
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KRsyncOptions : public QTabWidget
+class Smb4KRsyncOptions : public TQTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this widget
*/
- Smb4KRsyncOptions( QWidget *parent = 0, const char *name = 0 );
+ Smb4KRsyncOptions( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
diff --git a/smb4k/configdlg/smb4ksambaoptions.cpp b/smb4k/configdlg/smb4ksambaoptions.cpp
index ab57b25..6628a60 100644
--- a/smb4k/configdlg/smb4ksambaoptions.cpp
+++ b/smb4k/configdlg/smb4ksambaoptions.cpp
@@ -24,14 +24,14 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qgroupbox.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qbuttongroup.h>
-#include <qradiobutton.h>
-#include <qmap.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqgroupbox.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqbuttongroup.h>
+#include <tqradiobutton.h>
+#include <tqmap.h>
// KDE includes
#include <klocale.h>
@@ -54,44 +54,44 @@
using namespace Smb4KGlobal;
-Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
-: QTabWidget( parent, name )
+Smb4KSambaOptions::Smb4KSambaOptions( TQWidget *tqparent, const char *name )
+: TQTabWidget( tqparent, name )
{
setMargin( 10 );
//
// General options
//
- QWidget *general_tab = new QWidget( this, "GeneralSambaOptions" );
- QGridLayout *general_layout = new QGridLayout( general_tab );
+ TQWidget *general_tab = new TQWidget( this, "GeneralSambaOptions" );
+ TQGridLayout *general_layout = new TQGridLayout( general_tab );
general_layout->setSpacing( 10 );
- QGroupBox *general_options = new QGroupBox( 2, Qt::Horizontal,
+ TQGroupBox *general_options = new TQGroupBox( 2, Qt::Horizontal,
i18n( "General Options" ), general_tab );
general_options->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "NetBIOS name:"), general_options );
+ (void) new TQLabel( i18n( "NetBIOS name:"), general_options );
(void) new KLineEdit( general_options, "kcfg_NetBIOSName" );
- (void) new QLabel( i18n( "Domain:" ), general_options );
+ (void) new TQLabel( i18n( "Domain:" ), general_options );
(void) new KLineEdit( general_options, "kcfg_DomainName" );
- (void) new QLabel( i18n( "Socket options:" ), general_options );
+ (void) new TQLabel( i18n( "Socket options:" ), general_options );
(void) new KLineEdit( general_options, "kcfg_SocketOptions" );
- (void) new QLabel( i18n( "NetBIOS scope:" ), general_options );
+ (void) new TQLabel( i18n( "NetBIOS scope:" ), general_options );
(void) new KLineEdit( general_options, "kcfg_NetBIOSScope" );
- (void) new QLabel( i18n( "Remote SMB port:" ), general_options );
+ (void) new TQLabel( i18n( "Remote SMB port:" ), general_options );
(void) new KIntNumInput( general_options, "kcfg_RemotePort" );
- QGroupBox *authentication = new QGroupBox( 1, Qt::Horizontal,
+ TQGroupBox *authentication = new TQGroupBox( 1, Qt::Horizontal,
i18n( "Authentication" ), general_tab );
- (void) new QCheckBox( i18n( "Try to authenticate with Kerberos" ), authentication, "kcfg_UseKerberos" );
- (void) new QCheckBox( i18n( "Authenticate as machine account" ), authentication, "kcfg_MachineAccount" );
+ (void) new TQCheckBox( i18n( "Try to authenticate with Kerberos" ), authentication, "kcfg_UseKerberos" );
+ (void) new TQCheckBox( i18n( "Authenticate as machine account" ), authentication, "kcfg_MachineAccount" );
- QSpacerItem *spacer1 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer1 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
general_layout->addWidget( general_options, 0, 0, 0 );
general_layout->addWidget( authentication, 1, 0, 0 );
@@ -102,11 +102,11 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
//
// Options for the mount commands
//
- QWidget *mount_tab = new QWidget( this, "MountOptions" );
- QGridLayout *mount_layout = new QGridLayout( mount_tab );
+ TQWidget *mount_tab = new TQWidget( this, "MountOptions" );
+ TQGridLayout *mount_layout = new TQGridLayout( mount_tab );
mount_layout->setSpacing( 10 );
- QGroupBox *filesystem_box = new QGroupBox( 1, Qt::Horizontal,
+ TQGroupBox *filesystem_box = new TQGroupBox( 1, Qt::Horizontal,
i18n( "File System" ), mount_tab );
#ifndef __FreeBSD__
@@ -114,29 +114,29 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
filesystem->insertItem( "CIFS", Smb4KSettings::EnumFilesystem::CIFS );
filesystem->insertItem( "SMBFS", Smb4KSettings::EnumFilesystem::SMBFS );
#else
- (void) new QLabel( "SMBFS", filesystem_box );
+ (void) new TQLabel( "SMBFS", filesystem_box );
#endif
- QLabel *note = new QLabel( i18n( "NOTE: You might need to enable support for either \"super\" or \"sudo\" in the Super User page." ), filesystem_box );
- note->setTextFormat( Qt::RichText );
+ TQLabel *note = new TQLabel( i18n( "NOTE: You might need to enable support for either \"super\" or \"sudo\" in the Super User page." ), filesystem_box );
+ note->setTextFormat( TQt::RichText );
- QGroupBox *user_group_box = new QGroupBox( 2, Qt::Horizontal,
+ TQGroupBox *user_group_box = new TQGroupBox( 2, Qt::Horizontal,
i18n( "User and Group" ), mount_tab );
user_group_box->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "User ID:" ), user_group_box );
+ (void) new TQLabel( i18n( "User ID:" ), user_group_box );
KLineEdit *user_id = new KLineEdit( user_group_box, "kcfg_UserID" );
- user_id->setAlignment( Qt::AlignRight );
+ user_id->tqsetAlignment( TQt::AlignRight );
- (void) new QLabel( i18n( "Group ID:" ), user_group_box );
+ (void) new TQLabel( i18n( "Group ID:" ), user_group_box );
KLineEdit *group_id = new KLineEdit( user_group_box, "kcfg_GroupID" );
- group_id->setAlignment( Qt::AlignRight );
+ group_id->tqsetAlignment( TQt::AlignRight );
- QGroupBox *charset_box = new QGroupBox( 2, Qt::Horizontal,
+ TQGroupBox *charset_box = new TQGroupBox( 2, Qt::Horizontal,
i18n( "Charset and Codepage" ), mount_tab );
charset_box->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "Client charset:" ), charset_box );
+ (void) new TQLabel( i18n( "Client charset:" ), charset_box );
KComboBox *charset = new KComboBox( charset_box, "kcfg_ClientCharset" );
charset->insertItem( i18n( "default" ), Smb4KSettings::EnumClientCharset::default_charset );
charset->insertItem( "iso8859-1", Smb4KSettings::EnumClientCharset::iso8859_1 );
@@ -162,7 +162,7 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
charset->insertItem( "euc-kr", Smb4KSettings::EnumClientCharset::euc_kr );
charset->insertItem( "tis-620", Smb4KSettings::EnumClientCharset::tis_620 );
- (void) new QLabel( i18n( "Server codepage:" ), charset_box, "CodepageLabel" );
+ (void) new TQLabel( i18n( "Server codepage:" ), charset_box, "CodepageLabel" );
KComboBox *codepage = new KComboBox( charset_box, "kcfg_ServerCodepage" );
codepage->insertItem( i18n( "default" ), Smb4KSettings::EnumServerCodepage::default_codepage );
codepage->insertItem( "cp437", Smb4KSettings::EnumServerCodepage::cp437 );
@@ -196,73 +196,73 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
codepage->insertItem( "cp1256", Smb4KSettings::EnumServerCodepage::cp1256 );
codepage->insertItem( "cp1257", Smb4KSettings::EnumServerCodepage::cp1257 );
codepage->insertItem( "cp1258", Smb4KSettings::EnumServerCodepage::cp1258 );
- codepage->insertItem( "unicode", Smb4KSettings::EnumServerCodepage::unicode );
+ codepage->insertItem( "tqunicode", Smb4KSettings::EnumServerCodepage::unicode );
- QGroupBox *perms_box = new QGroupBox( 2, Qt::Horizontal,
+ TQGroupBox *perms_box = new TQGroupBox( 2, Qt::Horizontal,
i18n( "Permissions" ), mount_tab );
perms_box->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "File mask:" ), perms_box );
- KLineEdit *fmask = new KLineEdit( perms_box, "kcfg_FileMask" );
- fmask->setAlignment( Qt::AlignRight );
+ (void) new TQLabel( i18n( "File tqmask:" ), perms_box );
+ KLineEdit *ftqmask = new KLineEdit( perms_box, "kcfg_FileMask" );
+ ftqmask->tqsetAlignment( TQt::AlignRight );
- (void) new QLabel( i18n( "Directory mask:" ), perms_box );
- KLineEdit *dmask = new KLineEdit( perms_box, "kcfg_DirectoryMask" );
- dmask->setAlignment( Qt::AlignRight );
+ (void) new TQLabel( i18n( "Directory tqmask:" ), perms_box );
+ KLineEdit *dtqmask = new KLineEdit( perms_box, "kcfg_DirectoryMask" );
+ dtqmask->tqsetAlignment( TQt::AlignRight );
- (void) new QLabel( i18n( "Write access:" ), perms_box );
+ (void) new TQLabel( i18n( "Write access:" ), perms_box );
KComboBox *read_mode = new KComboBox( perms_box, "kcfg_WriteAccess" );
read_mode->insertItem( i18n( "read-write" ), Smb4KSettings::EnumWriteAccess::ReadWrite );
read_mode->insertItem( i18n( "read-only" ), Smb4KSettings::EnumWriteAccess::ReadOnly );
#ifndef __FreeBSD__
- QGroupBox *advanced_cifs = new QGroupBox( 1, Qt::Horizontal,
+ TQGroupBox *advanced_cifs = new TQGroupBox( 1, Qt::Horizontal,
i18n( "Advanced CIFS Options" ), mount_tab, "AdvancedCIFSOptions" );
advanced_cifs->setInsideSpacing( 5 );
- QWidget *c_advanced_widget = new QWidget( advanced_cifs );
- QGridLayout *c_advanced_layout = new QGridLayout( c_advanced_widget );
+ TQWidget *c_advanced_widget = new TQWidget( advanced_cifs );
+ TQGridLayout *c_advanced_layout = new TQGridLayout( c_advanced_widget );
c_advanced_layout->setSpacing( 5 );
c_advanced_layout->setMargin( 0 );
- c_advanced_layout->addWidget( new QCheckBox( i18n( "Do permission checks" ),
+ c_advanced_layout->addWidget( new TQCheckBox( i18n( "Do permission checks" ),
c_advanced_widget, "kcfg_PermissionChecks" ), 0, 0, 0 );
- c_advanced_layout->addWidget( new QCheckBox( i18n( "Attempt to set UID and GID" ),
+ c_advanced_layout->addWidget( new TQCheckBox( i18n( "Attempt to set UID and GID" ),
c_advanced_widget, "kcfg_ClientControlsIDs" ), 0, 1, 0 );
- c_advanced_layout->addWidget( new QCheckBox( i18n( "Use server inode numbers" ),
+ c_advanced_layout->addWidget( new TQCheckBox( i18n( "Use server inode numbers" ),
c_advanced_widget, "kcfg_ServerInodeNumbers" ), 1, 0, 0 );
- c_advanced_layout->addWidget( new QCheckBox( i18n( "Do not cache inode data" ),
+ c_advanced_layout->addWidget( new TQCheckBox( i18n( "Do not cache inode data" ),
c_advanced_widget, "kcfg_InodeDataCaching" ), 1, 1, 0 );
- c_advanced_layout->addWidget( new QCheckBox( i18n( "Translate reserved characters" ),
+ c_advanced_layout->addWidget( new TQCheckBox( i18n( "Translate reserved characters" ),
c_advanced_widget, "kcfg_TranslateReservedChars" ), 2, 0, 0 );
- c_advanced_layout->addWidget( new QCheckBox( i18n( "Do not use locking" ),
+ c_advanced_layout->addWidget( new TQCheckBox( i18n( "Do not use locking" ),
c_advanced_widget, "kcfg_NoLocking" ), 2, 1, 0 );
- QWidget *c_extra_widget = new QWidget( advanced_cifs );
- QGridLayout *c_extra_layout = new QGridLayout( c_extra_widget );
+ TQWidget *c_extra_widget = new TQWidget( advanced_cifs );
+ TQGridLayout *c_extra_layout = new TQGridLayout( c_extra_widget );
c_extra_layout->setSpacing( 5 );
c_extra_layout->setMargin( 0 );
- c_extra_layout->addWidget( new QLabel( i18n( "Additional options:" ), c_extra_widget ), 0, 0, 0 );
+ c_extra_layout->addWidget( new TQLabel( i18n( "Additional options:" ), c_extra_widget ), 0, 0, 0 );
c_extra_layout->addWidget( new KLineEdit( c_extra_widget, "kcfg_CustomCIFSOptions" ), 0, 1, 0 );
- QGroupBox *advanced_smbfs = new QGroupBox( 1, Qt::Horizontal,
+ TQGroupBox *advanced_smbfs = new TQGroupBox( 1, Qt::Horizontal,
i18n( "Advanced SMBFS Options" ), mount_tab, "AdvancedSMBFSOptions" );
advanced_smbfs->setInsideSpacing( 5 );
- (void) new QCheckBox( i18n( "Use Unicode when communicating with the server" ), advanced_smbfs, "kcfg_UnicodeSupport" );
- (void) new QCheckBox( i18n( "Use large file support" ), advanced_smbfs, "kcfg_LargeFileSystemSupport" );
+ (void) new TQCheckBox( i18n( "Use Unicode when communicating with the server" ), advanced_smbfs, "kcfg_UnicodeSupport" );
+ (void) new TQCheckBox( i18n( "Use large file support" ), advanced_smbfs, "kcfg_LargeFileSystemSupport" );
- QWidget *s_advanced_widget = new QWidget( advanced_smbfs );
- QGridLayout *s_advanced_layout = new QGridLayout( s_advanced_widget );
+ TQWidget *s_advanced_widget = new TQWidget( advanced_smbfs );
+ TQGridLayout *s_advanced_layout = new TQGridLayout( s_advanced_widget );
s_advanced_layout->setSpacing( 5 );
s_advanced_layout->setMargin( 0 );
- s_advanced_layout->addWidget( new QLabel( i18n( "Caching time of directory listings:" ), s_advanced_widget ), 0, 0, 0 );
+ s_advanced_layout->addWidget( new TQLabel( i18n( "Caching time of directory listings:" ), s_advanced_widget ), 0, 0, 0 );
KIntNumInput *ttl = new KIntNumInput( s_advanced_widget, "kcfg_CachingTime" );
ttl->setSuffix( " ms" );
s_advanced_layout->addWidget( ttl, 0, 1, 0 );
#endif
- QSpacerItem *spacer2 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer2 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
mount_layout->addMultiCellWidget( filesystem_box, 0, 0, 0, 1, 0 );
mount_layout->addMultiCellWidget( perms_box, 0, 0, 2, 3, 0 );
@@ -281,23 +281,23 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
//
// Options for the 'net' command
//
- QWidget *net_tab = new QWidget( this, "NetOptions" );
- QGridLayout *net_layout = new QGridLayout( net_tab );
+ TQWidget *net_tab = new TQWidget( this, "NetOptions" );
+ TQGridLayout *net_layout = new TQGridLayout( net_tab );
net_layout->setSpacing( 10 );
- QButtonGroup *protocol_hint = new QButtonGroup( 1, Qt::Horizontal,
+ TQButtonGroup *protocol_hint = new TQButtonGroup( 1, Qt::Horizontal,
i18n( "Protocol Hint" ), net_tab, "kcfg_ProtocolHint" );
- protocol_hint->insert( new QRadioButton( i18n( "Automatic detection" ), protocol_hint ),
+ protocol_hint->insert( new TQRadioButton( i18n( "Automatic detection" ), protocol_hint ),
Smb4KSettings::EnumProtocolHint::Automatic );
- protocol_hint->insert( new QRadioButton( i18n( "RPC: Modern operating systems" ), protocol_hint ),
+ protocol_hint->insert( new TQRadioButton( i18n( "RPC: Modern operating systems" ), protocol_hint ),
Smb4KSettings::EnumProtocolHint::RPC );
- protocol_hint->insert( new QRadioButton( i18n( "RAP: Older operating systems" ), protocol_hint ),
+ protocol_hint->insert( new TQRadioButton( i18n( "RAP: Older operating systems" ), protocol_hint ),
Smb4KSettings::EnumProtocolHint::RAP );
- protocol_hint->insert( new QRadioButton( i18n( "ADS: Active Directory environment (LDAP/Kerberos)" ), protocol_hint ),
+ protocol_hint->insert( new TQRadioButton( i18n( "ADS: Active Directory environment (LDAP/Kerberos)" ), protocol_hint ),
Smb4KSettings::EnumProtocolHint::ADS );
- QSpacerItem *spacer3 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer3 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
net_layout->addWidget( protocol_hint, 0, 0, 0 );
net_layout->addItem( spacer3, 1, 0 );
@@ -307,29 +307,29 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
//
// Options for the 'smbclient' command
//
- QWidget *smbclient_tab = new QWidget( this, "SmbclientOptions" );
- QGridLayout *smbclient_layout = new QGridLayout( smbclient_tab );
+ TQWidget *smbclient_tab = new TQWidget( this, "SmbclientOptions" );
+ TQGridLayout *smbclient_layout = new TQGridLayout( smbclient_tab );
smbclient_layout->setSpacing( 10 );
- QGroupBox *smbclient_misc = new QGroupBox( 2, Qt::Horizontal, i18n( "Miscellaneous" ),
+ TQGroupBox *smbclient_misc = new TQGroupBox( 2, Qt::Horizontal, i18n( "Miscellaneous" ),
smbclient_tab, "SmbclientMiscellaneous" );
smbclient_misc->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "Name resolve order:" ), smbclient_misc );
+ (void) new TQLabel( i18n( "Name resolve order:" ), smbclient_misc );
(void) new KLineEdit( smbclient_misc, "kcfg_NameResolveOrder" );
- (void) new QLabel( i18n( "Buffer size:" ), smbclient_misc );
+ (void) new TQLabel( i18n( "Buffer size:" ), smbclient_misc );
KIntNumInput *buffer_size = new KIntNumInput( smbclient_misc, "kcfg_BufferSize" );
buffer_size->setSuffix( i18n( " Bytes" ) );
- (void) new QLabel( i18n( "Signing state:" ), smbclient_misc );
+ (void) new TQLabel( i18n( "Signing state:" ), smbclient_misc );
KComboBox *signing_state = new KComboBox( smbclient_misc, "kcfg_SigningState" );
signing_state->insertItem( i18n( "none" ), Smb4KSettings::EnumSigningState::None );
signing_state->insertItem( i18n( "on" ), Smb4KSettings::EnumSigningState::On );
signing_state->insertItem( i18n( "off" ), Smb4KSettings::EnumSigningState::Off );
signing_state->insertItem( i18n( "required" ), Smb4KSettings::EnumSigningState::Required );
- QSpacerItem *spacer4 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer4 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
smbclient_layout->addWidget( smbclient_misc, 0, 0, 0 );
smbclient_layout->addItem( spacer4, 1, 0 );
@@ -339,24 +339,24 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
//
// Options for the 'nmblookup' command
//
- QWidget *nmblookup_tab = new QWidget( this, "NmblookupOptions" );
- QGridLayout *nmblookup_layout = new QGridLayout( nmblookup_tab );
+ TQWidget *nmblookup_tab = new TQWidget( this, "NmblookupOptions" );
+ TQGridLayout *nmblookup_layout = new TQGridLayout( nmblookup_tab );
nmblookup_layout->setSpacing( 10 );
- QGroupBox *nmblookup_misc = new QGroupBox( 1, Qt::Horizontal,
+ TQGroupBox *nmblookup_misc = new TQGroupBox( 1, Qt::Horizontal,
i18n( "Miscellaneous" ), nmblookup_tab );
nmblookup_misc->setInsideSpacing( 5 );
- QWidget *broadcast_widget = new QWidget( nmblookup_misc );
- QGridLayout *broadcast_layout = new QGridLayout( broadcast_widget );
+ TQWidget *broadcast_widget = new TQWidget( nmblookup_misc );
+ TQGridLayout *broadcast_layout = new TQGridLayout( broadcast_widget );
broadcast_layout->setSpacing( 5 );
broadcast_layout->setMargin( 0 );
- broadcast_layout->addWidget( new QLabel( i18n( "Broadcast address:" ), broadcast_widget ), 0, 0, 0 );
+ broadcast_layout->addWidget( new TQLabel( i18n( "Broadcast address:" ), broadcast_widget ), 0, 0, 0 );
broadcast_layout->addWidget( new KLineEdit( broadcast_widget, "kcfg_BroadcastAddress" ), 0, 1, 0 );
- (void) new QCheckBox( i18n( "Try and bind to UDP port 137 to send and receive UDP datagrams" ), nmblookup_misc, "kcfg_UsePort137" );
+ (void) new TQCheckBox( i18n( "Try and bind to UDP port 137 to send and receive UDP datagrams" ), nmblookup_misc, "kcfg_UsePort137" );
- QSpacerItem *spacer5 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer5 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
nmblookup_layout->addWidget( nmblookup_misc, 0, 0, 0 );
nmblookup_layout->addItem( spacer5, 1, 0 );
@@ -367,8 +367,8 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
//
// Custom options
//
- QWidget *custom_tab = new QWidget( this, "CustomOptions" );
- QGridLayout *custom_layout = new QGridLayout( custom_tab );
+ TQWidget *custom_tab = new TQWidget( this, "CustomOptions" );
+ TQGridLayout *custom_layout = new TQGridLayout( custom_tab );
custom_layout->setSpacing( 10 );
@@ -376,7 +376,7 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
KListView *custom_options = new KListView( custom_tab, "CustomOptionsList" );
// custom_options->setAllColumnsShowFocus( true );
- custom_options->setSelectionMode( QListView::Single );
+ custom_options->setSelectionMode( TQListView::Single );
custom_options->setVScrollBarMode( KListView::Auto );
custom_options->addColumn( i18n( "Item" ), -1 );
custom_options->addColumn( i18n( "Protocol" ), -1 );
@@ -389,11 +389,11 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
custom_options->addColumn( i18n( "GID" ), -1 );
custom_options->addColumn( i18n( "Port" ), -1 );
- QWidget *custom_input = new QWidget( custom_tab, "CustomInputWidget" );
- QGridLayout *custom_input_layout = new QGridLayout( custom_input );
+ TQWidget *custom_input = new TQWidget( custom_tab, "CustomInputWidget" );
+ TQGridLayout *custom_input_layout = new TQGridLayout( custom_input );
custom_input_layout->setSpacing( 5 );
- QLabel *custom_proto_label = new QLabel( i18n( "Protocol:" ), custom_input, "CustomProtocolLabel" );
+ TQLabel *custom_proto_label = new TQLabel( i18n( "Protocol:" ), custom_input, "CustomProtocolLabel" );
KComboBox *custom_protocol = new KComboBox( custom_input, "CustomProtocol" );
custom_protocol->insertItem( "-", -1 );
@@ -404,14 +404,14 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
#ifndef __FreeBSD__
- QLabel *custom_fs_label = new QLabel( i18n( "File system:" ), custom_input, "CustomFileSystemLabel" );
+ TQLabel *custom_fs_label = new TQLabel( i18n( "File system:" ), custom_input, "CustomFileSystemLabel" );
KComboBox *custom_fs = new KComboBox( custom_input, "CustomFileSystem" );
custom_fs->insertItem( "-", -1 );
custom_fs->insertItem( "CIFS", -1 );
custom_fs->insertItem( "SMBFS", -1 );
- QLabel *custom_rw_label = new QLabel( i18n( "Write access:" ), custom_input, "CustomWriteAccessLabel" );
+ TQLabel *custom_rw_label = new TQLabel( i18n( "Write access:" ), custom_input, "CustomWriteAccessLabel" );
KComboBox *custom_rw = new KComboBox( custom_input, "CustomWriteAccess" );
custom_rw->insertItem( "-", -1 );
@@ -420,37 +420,37 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
#endif
- QLabel *custom_krb_label = new QLabel( i18n( "Kerberos:" ), custom_input, "CustomKerberosLabel" );
+ TQLabel *custom_krb_label = new TQLabel( i18n( "Kerberos:" ), custom_input, "CustomKerberosLabel" );
KComboBox *custom_krb = new KComboBox( custom_input, "CustomKerberos" );
custom_krb->insertItem( "-", -1 );
custom_krb->insertItem( i18n( "no" ), -1 );
custom_krb->insertItem( i18n( "yes" ), -1 );
- QLabel *custom_uid_label = new QLabel( i18n( "User ID:" ), custom_input, "CustomUIDLabel" );
+ TQLabel *custom_uid_label = new TQLabel( i18n( "User ID:" ), custom_input, "CustomUIDLabel" );
KLineEdit *custom_uid = new KLineEdit( custom_input, "CustomUID" );
custom_uid->setText( "-" );
- QLabel *custom_gid_label = new QLabel( i18n( "Group ID:" ), custom_input, "CustomGIDLabel" );
+ TQLabel *custom_gid_label = new TQLabel( i18n( "Group ID:" ), custom_input, "CustomGIDLabel" );
KLineEdit *custom_gid = new KLineEdit( custom_input, "CustomGID" );
custom_gid->setText( "-" );
- QLabel *custom_port_label = new QLabel( i18n( "Port:" ), custom_input, "CustomPortLabel" );
+ TQLabel *custom_port_label = new TQLabel( i18n( "Port:" ), custom_input, "CustomPortLabel" );
KIntNumInput *custom_port = new KIntNumInput( Smb4KSettings::remotePort(), custom_input, 10, "CustomPort" );
custom_port->setMinValue( 0 );
custom_port->setMaxValue( 65535 );
- QWidget *custom_rm = new QWidget( custom_input );
- QGridLayout *custom_rm_layout = new QGridLayout( custom_rm );
+ TQWidget *custom_rm = new TQWidget( custom_input );
+ TQGridLayout *custom_rm_layout = new TQGridLayout( custom_rm );
custom_rm_layout->setSpacing( 5 );
KPushButton *remove_custom = new KPushButton( KGuiItem( i18n( "Remove" ), "remove" ), custom_rm, "CustomRemoveItem" );
KPushButton *rm_all_custom = new KPushButton( KGuiItem( i18n( "Remove All" ), "editdelete" ), custom_rm, "CustomRemoveAllItems" );
- QSpacerItem *spacer6 = new QSpacerItem( 0, 0, QSizePolicy::Expanding, QSizePolicy::Preferred );
+ TQSpacerItem *spacer6 = new TQSpacerItem( 0, 0, TQSizePolicy::Expanding, TQSizePolicy::Preferred );
custom_rm_layout->addItem( spacer6, 0, 0 );
custom_rm_layout->addWidget( remove_custom, 0, 1, 0 );
@@ -484,7 +484,7 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
custom_input_layout->addMultiCellWidget( custom_rm, 2, 2, 2, 3, 0 );
#endif
- QSpacerItem *spacer7 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Minimum );
+ TQSpacerItem *spacer7 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Minimum );
custom_layout->addWidget( custom_options, 0, 0, 0 );
custom_layout->addWidget( custom_input, 1, 0, 0 );
@@ -496,41 +496,41 @@ Smb4KSambaOptions::Smb4KSambaOptions( QWidget *parent, const char *name )
// Connections
//
#ifndef __FreeBSD__
- connect( filesystem, SIGNAL( activated( int ) ),
- this, SLOT( slotSambaFileSystem( int ) ) );
+ connect( filesystem, TQT_SIGNAL( activated( int ) ),
+ this, TQT_SLOT( slotSambaFileSystem( int ) ) );
#endif
- connect( remove_custom, SIGNAL( clicked() ),
- this, SLOT( slotRemoveCustomOption() ) );
+ connect( remove_custom, TQT_SIGNAL( clicked() ),
+ this, TQT_SLOT( slotRemoveCustomOption() ) );
- connect( rm_all_custom, SIGNAL( clicked() ),
- this, SLOT( slotRemoveAllCustomOptions() ) );
+ connect( rm_all_custom, TQT_SIGNAL( clicked() ),
+ this, TQT_SLOT( slotRemoveAllCustomOptions() ) );
- connect( custom_options, SIGNAL( clicked( QListViewItem * ) ),
- this, SLOT( slotCustomItemClicked( QListViewItem * ) ) );
+ connect( custom_options, TQT_SIGNAL( clicked( TQListViewItem * ) ),
+ this, TQT_SLOT( slotCustomItemClicked( TQListViewItem * ) ) );
- connect( custom_protocol, SIGNAL( activated( int ) ),
- this, SLOT( slotCustomProtocolChanged( int ) ) );
+ connect( custom_protocol, TQT_SIGNAL( activated( int ) ),
+ this, TQT_SLOT( slotCustomProtocolChanged( int ) ) );
#ifndef __FreeBSD__
- connect( custom_fs, SIGNAL( activated( int ) ),
- this, SLOT( slotCustomFileSystemChanged( int ) ) );
+ connect( custom_fs, TQT_SIGNAL( activated( int ) ),
+ this, TQT_SLOT( slotCustomFileSystemChanged( int ) ) );
- connect( custom_rw, SIGNAL( activated( int ) ),
- this, SLOT( slotCustomWriteAccessChanged( int ) ) );
+ connect( custom_rw, TQT_SIGNAL( activated( int ) ),
+ this, TQT_SLOT( slotCustomWriteAccessChanged( int ) ) );
#endif
- connect( custom_krb, SIGNAL( activated( int ) ),
- this, SLOT( slotCustomKerberosChanged( int ) ) );
+ connect( custom_krb, TQT_SIGNAL( activated( int ) ),
+ this, TQT_SLOT( slotCustomKerberosChanged( int ) ) );
- connect( custom_uid, SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotCustomUIDChanged( const QString & ) ) );
+ connect( custom_uid, TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotCustomUIDChanged( const TQString & ) ) );
- connect( custom_gid, SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotCustomGIDChanged( const QString & ) ) );
+ connect( custom_gid, TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotCustomGIDChanged( const TQString & ) ) );
- connect( custom_port, SIGNAL( valueChanged( int ) ),
- this, SLOT( slotCustomPortChanged( int ) ) );
+ connect( custom_port, TQT_SIGNAL( valueChanged( int ) ),
+ this, TQT_SLOT( slotCustomPortChanged( int ) ) );
//
// Do last things before we are ready to go
@@ -554,7 +554,7 @@ void Smb4KSambaOptions::resetCustomTab()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
#ifndef __FreeBSD__
@@ -564,28 +564,28 @@ void Smb4KSambaOptions::slotSambaFileSystem( int item_index )
{
case Smb4KSettings::EnumFilesystem::CIFS:
{
- QGroupBox *adv_cifs = static_cast<QGroupBox *>( child( "AdvancedCIFSOptions", "QGroupBox", true ) );
+ TQGroupBox *adv_cifs = static_cast<TQGroupBox *>( TQT_TQWIDGET(child( "AdvancedCIFSOptions", TQGROUPBOX_OBJECT_NAME_STRING, true )) );
if ( adv_cifs )
{
adv_cifs->setEnabled( true );
}
- QGroupBox *adv_smbfs = static_cast<QGroupBox *>( child( "AdvancedSMBFSOptions", "QGroupBox", true ) );
+ TQGroupBox *adv_smbfs = static_cast<TQGroupBox *>( TQT_TQWIDGET(child( "AdvancedSMBFSOptions", TQGROUPBOX_OBJECT_NAME_STRING, true )) );
if ( adv_smbfs )
{
adv_smbfs->setEnabled( false );
}
- QLabel *codepage = static_cast<QLabel *>( child( "CodepageLabel", "QLabel", true ) );
+ TQLabel *codepage = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CodepageLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( codepage )
{
codepage->setEnabled( false );
}
- KComboBox *srv_codepage = static_cast<KComboBox *>( child( "kcfg_ServerCodepage", "KComboBox", true ) );
+ KComboBox *srv_codepage = static_cast<KComboBox *>( TQT_TQWIDGET(child( "kcfg_ServerCodepage", "KComboBox", true )) );
if ( srv_codepage )
{
@@ -596,28 +596,28 @@ void Smb4KSambaOptions::slotSambaFileSystem( int item_index )
}
case Smb4KSettings::EnumFilesystem::SMBFS:
{
- QGroupBox *adv_cifs = static_cast<QGroupBox *>( child( "AdvancedCIFSOptions", "QGroupBox", true ) );
+ TQGroupBox *adv_cifs = static_cast<TQGroupBox *>( TQT_TQWIDGET(child( "AdvancedCIFSOptions", TQGROUPBOX_OBJECT_NAME_STRING, true )) );
if ( adv_cifs )
{
adv_cifs->setEnabled( false );
}
- QGroupBox *adv_smbfs = static_cast<QGroupBox *>( child( "AdvancedSMBFSOptions", "QGroupBox", true ) );
+ TQGroupBox *adv_smbfs = static_cast<TQGroupBox *>( TQT_TQWIDGET(child( "AdvancedSMBFSOptions", TQGROUPBOX_OBJECT_NAME_STRING, true )) );
if ( adv_smbfs )
{
adv_smbfs->setEnabled( true );
}
- QLabel *codepage = static_cast<QLabel *>( child( "CodepageLabel", "QLabel", true ) );
+ TQLabel *codepage = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CodepageLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( codepage )
{
codepage->setEnabled( true );
}
- KComboBox *srv_codepage = static_cast<KComboBox *>( child( "kcfg_ServerCodepage", "KComboBox", true ) );
+ KComboBox *srv_codepage = static_cast<KComboBox *>( TQT_TQWIDGET(child( "kcfg_ServerCodepage", "KComboBox", true )) );
if ( srv_codepage )
{
@@ -638,12 +638,12 @@ void Smb4KSambaOptions::slotSambaFileSystem( int )
}
-void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
+void Smb4KSambaOptions::slotCustomItemClicked( TQListViewItem *item )
{
if ( item )
{
// Enable the input widget:
- QWidget *input = static_cast<QGroupBox *>( child( "CustomInputWidget", "QGroupBox", true ) );
+ TQWidget *input = static_cast<TQGroupBox *>( TQT_TQWIDGET(child( "CustomInputWidget", TQGROUPBOX_OBJECT_NAME_STRING, true )) );
if ( input )
{
@@ -651,11 +651,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
// Enable/disable the labels, combo boxes, buttons, etc:
- QLabel *protocol_label = static_cast<QLabel *>( child( "CustomProtocolLabel", "QLabel", true ) );
+ TQLabel *protocol_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomProtocolLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( protocol_label )
{
- if ( QString::compare( item->text( Protocol ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( Protocol ).stripWhiteSpace(), "-" ) == 0 )
{
protocol_label->setEnabled( false );
}
@@ -665,11 +665,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
}
- KComboBox *protocol = static_cast<KComboBox *>( child( "CustomProtocol", "KComboBox", true ) );
+ KComboBox *protocol = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomProtocol", "KComboBox", true )) );
if ( protocol )
{
- if ( QString::compare( item->text( Protocol ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( Protocol ).stripWhiteSpace(), "-" ) == 0 )
{
protocol->setEnabled( false );
}
@@ -683,11 +683,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
#ifndef __FreeBSD__
- QLabel *fs_label = static_cast<QLabel *>( child( "CustomFileSystemLabel", "QLabel", true ) );
+ TQLabel *fs_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomFileSystemLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( fs_label )
{
- if ( QString::compare( item->text( FileSystem ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( FileSystem ).stripWhiteSpace(), "-" ) == 0 )
{
fs_label->setEnabled( false );
}
@@ -697,11 +697,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
}
- KComboBox *filesystem = static_cast<KComboBox *>( child( "CustomFileSystem", "KComboBox", true ) );
+ KComboBox *filesystem = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomFileSystem", "KComboBox", true )) );
if ( filesystem )
{
- if ( QString::compare( item->text( FileSystem ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( FileSystem ).stripWhiteSpace(), "-" ) == 0 )
{
filesystem->setEnabled( false );
}
@@ -713,11 +713,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
filesystem->setCurrentText( item->text( FileSystem ) );
}
- QLabel *write_access_label = static_cast<QLabel *>( child( "CustomWriteAccessLabel", "QLabel", true ) );
+ TQLabel *write_access_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomWriteAccessLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( write_access_label )
{
- if ( QString::compare( item->text( WriteAccess ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( WriteAccess ).stripWhiteSpace(), "-" ) == 0 )
{
write_access_label->setEnabled( false );
}
@@ -727,11 +727,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
}
- KComboBox *write_access = static_cast<KComboBox *>( child( "CustomWriteAccess", "KComboBox", true ) );
+ KComboBox *write_access = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomWriteAccess", "KComboBox", true )) );
if ( write_access )
{
- if ( QString::compare( item->text( WriteAccess ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( WriteAccess ).stripWhiteSpace(), "-" ) == 0 )
{
write_access->setEnabled( false );
}
@@ -745,11 +745,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
#endif
- QLabel *krb_label = static_cast<QLabel *>( child( "CustomKerberosLabel", "QLabel", true ) );
+ TQLabel *krb_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomKerberosLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( krb_label )
{
- if ( QString::compare( item->text( Kerberos ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( Kerberos ).stripWhiteSpace(), "-" ) == 0 )
{
krb_label->setEnabled( false );
}
@@ -759,11 +759,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
}
- KComboBox *kerberos = static_cast<KComboBox *>( child( "CustomKerberos", "KComboBox", true ) );
+ KComboBox *kerberos = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomKerberos", "KComboBox", true )) );
if ( kerberos )
{
- if ( QString::compare( item->text( Kerberos ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( Kerberos ).stripWhiteSpace(), "-" ) == 0 )
{
kerberos->setEnabled( false );
}
@@ -775,11 +775,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
kerberos->setCurrentText( item->text( Kerberos ) );
}
- QLabel *uid_label = static_cast<QLabel *>( child( "CustomUIDLabel", "QLabel", true ) );
+ TQLabel *uid_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomUIDLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( uid_label )
{
- if ( QString::compare( item->text( UID ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( UID ).stripWhiteSpace(), "-" ) == 0 )
{
uid_label->setEnabled( false );
}
@@ -789,11 +789,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
}
- KLineEdit *uid = static_cast<KLineEdit *>( child( "CustomUID", "KLineEdit", true ) );
+ KLineEdit *uid = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "CustomUID", "KLineEdit", true )) );
if ( uid )
{
- if ( QString::compare( item->text( UID ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( UID ).stripWhiteSpace(), "-" ) == 0 )
{
uid->setEnabled( false );
}
@@ -805,11 +805,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
uid->setText( item->text( UID ) );
}
- QLabel *gid_label = static_cast<QLabel *>( child( "CustomGIDLabel", "QLabel", true ) );
+ TQLabel *gid_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomGIDLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( gid_label )
{
- if ( QString::compare( item->text( GID ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( GID ).stripWhiteSpace(), "-" ) == 0 )
{
gid_label->setEnabled( false );
}
@@ -819,11 +819,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
}
- KLineEdit *gid = static_cast<KLineEdit *>( child( "CustomGID", "KLineEdit", true ) );
+ KLineEdit *gid = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "CustomGID", "KLineEdit", true )) );
if ( gid )
{
- if ( QString::compare( item->text( GID ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( GID ).stripWhiteSpace(), "-" ) == 0 )
{
gid->setEnabled( false );
}
@@ -835,11 +835,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
gid->setText( item->text( GID ) );
}
- QLabel *port_label = static_cast<QLabel *>( child( "CustomPortLabel", "QLabel", true ) );
+ TQLabel *port_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomPortLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( port_label )
{
- if ( QString::compare( item->text( Port ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( Port ).stripWhiteSpace(), "-" ) == 0 )
{
port_label->setEnabled( false );
}
@@ -849,11 +849,11 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
}
}
- KIntNumInput *port = static_cast<KIntNumInput *>( child( "CustomPort", "KIntNumInput", true ) );
+ KIntNumInput *port = static_cast<KIntNumInput *>( TQT_TQWIDGET(child( "CustomPort", "KIntNumInput", true )) );
if ( port )
{
- if ( QString::compare( item->text( Port ).stripWhiteSpace(), "-" ) == 0 )
+ if ( TQString::compare( item->text( Port ).stripWhiteSpace(), "-" ) == 0 )
{
port->setEnabled( false );
}
@@ -865,14 +865,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
port->setValue( item->text( Port ).toInt() );
}
- KPushButton *remove = static_cast<KPushButton *>( child( "CustomRemoveItem", "KPushButton", true ) );
+ KPushButton *remove = static_cast<KPushButton *>( TQT_TQWIDGET(child( "CustomRemoveItem", "KPushButton", true )) );
if ( remove )
{
remove->setEnabled( true );
}
- KPushButton *remove_all = static_cast<KPushButton *>( child( "CustomRemoveAllItems", "KPushButton", true ) );
+ KPushButton *remove_all = static_cast<KPushButton *>( TQT_TQWIDGET(child( "CustomRemoveAllItems", "KPushButton", true )) );
if ( remove_all )
{
@@ -882,18 +882,18 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
else
{
// Get the list view:
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( view )
{
- QLabel *protocol_label = static_cast<QLabel *>( child( "CustomProtocolLabel", "QLabel", true ) );
+ TQLabel *protocol_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomProtocolLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( protocol_label )
{
protocol_label->setEnabled( false );
}
- KComboBox *protocol = static_cast<KComboBox *>( child( "CustomProtocol", "KComboBox", true ) );
+ KComboBox *protocol = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomProtocol", "KComboBox", true )) );
if ( protocol )
{
@@ -903,14 +903,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
#ifndef __FreeBSD__
- QLabel *fs_label = static_cast<QLabel *>( child( "CustomFileSystemLabel", "QLabel", true ) );
+ TQLabel *fs_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomFileSystemLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( fs_label )
{
fs_label->setEnabled( false );
}
- KComboBox *filesystem = static_cast<KComboBox *>( child( "CustomFileSystem", "KComboBox", true ) );
+ KComboBox *filesystem = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomFileSystem", "KComboBox", true )) );
if ( filesystem )
{
@@ -918,14 +918,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
filesystem->setEnabled( false );
}
- QLabel *write_access_label = static_cast<QLabel *>( child( "CustomWriteAccessLabel", "QLabel", true ) );
+ TQLabel *write_access_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomWriteAccessLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( write_access_label )
{
write_access_label->setEnabled( false );
}
- KComboBox *write_access = static_cast<KComboBox *>( child( "CustomWriteAccess", "KComboBox", true ) );
+ KComboBox *write_access = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomWriteAccess", "KComboBox", true )) );
if ( write_access )
{
@@ -935,14 +935,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
#endif
- QLabel *krb_label = static_cast<QLabel *>( child( "CustomKerberosLabel", "QLabel", true ) );
+ TQLabel *krb_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomKerberosLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( krb_label )
{
krb_label->setEnabled( false );
}
- KComboBox *kerberos = static_cast<KComboBox *>( child( "CustomKerberos", "KComboBox", true ) );
+ KComboBox *kerberos = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomKerberos", "KComboBox", true )) );
if ( kerberos )
{
@@ -950,14 +950,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
kerberos->setEnabled( false );
}
- QLabel *uid_label = static_cast<QLabel *>( child( "CustomUIDLabel", "QLabel", true ) );
+ TQLabel *uid_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomUIDLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( uid_label )
{
uid_label->setEnabled( false );
}
- KLineEdit *uid = static_cast<KLineEdit *>( child( "CustomUID", "KLineEdit", true ) );
+ KLineEdit *uid = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "CustomUID", "KLineEdit", true )) );
if ( uid )
{
@@ -965,14 +965,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
uid->setEnabled( false );
}
- QLabel *gid_label = static_cast<QLabel *>( child( "CustomGIDLabel", "QLabel", true ) );
+ TQLabel *gid_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomGIDLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( gid_label )
{
gid_label->setEnabled( false );
}
- KLineEdit *gid = static_cast<KLineEdit *>( child( "CustomGID", "KLineEdit", true ) );
+ KLineEdit *gid = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "CustomGID", "KLineEdit", true )) );
if ( gid )
{
@@ -980,14 +980,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
gid->setEnabled( false );
}
- QLabel *port_label = static_cast<QLabel *>( child( "CustomPortLabel", "QLabel", true ) );
+ TQLabel *port_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "CustomPortLabel", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( port_label )
{
port_label->setEnabled( false );
}
- KIntNumInput *port = static_cast<KIntNumInput *>( child( "CustomPort", "KIntNumInput", true ) );
+ KIntNumInput *port = static_cast<KIntNumInput *>( TQT_TQWIDGET(child( "CustomPort", "KIntNumInput", true )) );
if ( port )
{
@@ -995,14 +995,14 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
port->setEnabled( false );
}
- KPushButton *remove = static_cast<KPushButton *>( child( "CustomRemoveItem", "KPushButton", true ) );
+ KPushButton *remove = static_cast<KPushButton *>( TQT_TQWIDGET(child( "CustomRemoveItem", "KPushButton", true )) );
if ( remove )
{
remove->setEnabled( false );
}
- KPushButton *remove_all = static_cast<KPushButton *>( child( "CustomRemoveAllItems", "KPushButton", true ) );
+ KPushButton *remove_all = static_cast<KPushButton *>( TQT_TQWIDGET(child( "CustomRemoveAllItems", "KPushButton", true )) );
if ( remove_all )
{
@@ -1015,12 +1015,12 @@ void Smb4KSambaOptions::slotCustomItemClicked( QListViewItem *item )
void Smb4KSambaOptions::slotCustomProtocolChanged( int index )
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
- KComboBox *custom_protocol = static_cast<KComboBox *>( child( "CustomProtocol", "KComboBox", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
+ KComboBox *custom_protocol = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomProtocol", "KComboBox", true )) );
if ( view && view->selectedItem() && custom_protocol )
{
- if ( QString::compare( "-", custom_protocol->text( index ) ) != 0 )
+ if ( TQString::compare( "-", custom_protocol->text( index ) ) != 0 )
{
// Set the new value:
view->selectedItem()->setText( Protocol, custom_protocol->text( index ) );
@@ -1043,12 +1043,12 @@ void Smb4KSambaOptions::slotCustomProtocolChanged( int index )
#ifndef __FreeBSD__
void Smb4KSambaOptions::slotCustomFileSystemChanged( int index )
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
- KComboBox *custom_filesystem = static_cast<KComboBox *>( child( "CustomFileSystem", "KComboBox", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
+ KComboBox *custom_filesystem = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomFileSystem", "KComboBox", true )) );
if ( view && view->selectedItem() && custom_filesystem )
{
- if ( QString::compare( "-", custom_filesystem->text( index ) ) != 0 )
+ if ( TQString::compare( "-", custom_filesystem->text( index ) ) != 0 )
{
// Set the new value:
view->selectedItem()->setText( FileSystem, custom_filesystem->text( index ) );
@@ -1075,12 +1075,12 @@ void Smb4KSambaOptions::slotCustomFileSystemChanged( int )
#ifndef __FreeBSD__
void Smb4KSambaOptions::slotCustomWriteAccessChanged( int index )
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
- KComboBox *custom_rw = static_cast<KComboBox *>( child( "CustomWriteAccess", "KComboBox", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
+ KComboBox *custom_rw = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomWriteAccess", "KComboBox", true )) );
if ( view && view->selectedItem() && custom_rw )
{
- if ( QString::compare( "-", custom_rw->text( index ) ) != 0 )
+ if ( TQString::compare( "-", custom_rw->text( index ) ) != 0 )
{
// Set the new value:
view->selectedItem()->setText( WriteAccess, custom_rw->text( index ) );
@@ -1109,12 +1109,12 @@ void Smb4KSambaOptions::slotCustomKerberosChanged( int index )
// FIXME: Do we need to adjust something here with respect to
// FreeBSD? It does not know Kerberos for mounting!
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
- KComboBox *custom_kerberos = static_cast<KComboBox *>( child( "CustomWriteAccess", "KComboBox", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
+ KComboBox *custom_kerberos = static_cast<KComboBox *>( TQT_TQWIDGET(child( "CustomWriteAccess", "KComboBox", true )) );
if ( view && view->selectedItem() && custom_kerberos )
{
- if ( QString::compare( "-", custom_kerberos->text( index ) ) != 0 )
+ if ( TQString::compare( "-", custom_kerberos->text( index ) ) != 0 )
{
// Set the new value:
view->selectedItem()->setText( Kerberos, custom_kerberos->text( index ) );
@@ -1134,9 +1134,9 @@ void Smb4KSambaOptions::slotCustomKerberosChanged( int index )
}
-void Smb4KSambaOptions::slotCustomUIDChanged( const QString &uid )
+void Smb4KSambaOptions::slotCustomUIDChanged( const TQString &uid )
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( view && view->selectedItem() )
{
@@ -1152,9 +1152,9 @@ void Smb4KSambaOptions::slotCustomUIDChanged( const QString &uid )
}
-void Smb4KSambaOptions::slotCustomGIDChanged( const QString &gid )
+void Smb4KSambaOptions::slotCustomGIDChanged( const TQString &gid )
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( view && view->selectedItem() )
{
@@ -1172,11 +1172,11 @@ void Smb4KSambaOptions::slotCustomGIDChanged( const QString &gid )
void Smb4KSambaOptions::slotCustomPortChanged( int port )
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( view && view->selectedItem() )
{
- view->selectedItem()->setText( Port, QString( "%1" ).arg( port ) );
+ view->selectedItem()->setText( Port, TQString( "%1" ).tqarg( port ) );
emit customSettingsChanged();
}
@@ -1189,7 +1189,7 @@ void Smb4KSambaOptions::slotCustomPortChanged( int port )
void Smb4KSambaOptions::slotRemoveCustomOption()
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( view && view->selectedItem() )
{
@@ -1208,7 +1208,7 @@ void Smb4KSambaOptions::slotRemoveCustomOption()
void Smb4KSambaOptions::slotRemoveAllCustomOptions()
{
- KListView *view = static_cast<KListView *>( child( "CustomOptionsList", "KListView", true ) );
+ KListView *view = static_cast<KListView *>( TQT_TQWIDGET(child( "CustomOptionsList", "KListView", true )) );
if ( view )
{
diff --git a/smb4k/configdlg/smb4ksambaoptions.h b/smb4k/configdlg/smb4ksambaoptions.h
index 9a994b0..911f82c 100644
--- a/smb4k/configdlg/smb4ksambaoptions.h
+++ b/smb4k/configdlg/smb4ksambaoptions.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qtabwidget.h>
+// TQt includes
+#include <tqtabwidget.h>
/**
@@ -44,19 +44,20 @@
*/
-class Smb4KSambaOptions : public QTabWidget
+class Smb4KSambaOptions : public TQTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name This widget's name
*/
- Smb4KSambaOptions( QWidget *parent = 0, const char *name = 0 );
+ Smb4KSambaOptions( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -103,7 +104,7 @@ class Smb4KSambaOptions : public QTabWidget
*
* @param item The item that has been clicked/highlighted.
*/
- void slotCustomItemClicked( QListViewItem *item );
+ void slotCustomItemClicked( TQListViewItem *item );
/**
* Commit the new custom protocol to the list view item.
@@ -138,14 +139,14 @@ class Smb4KSambaOptions : public QTabWidget
*
* @param uid The new UID in text form
*/
- void slotCustomUIDChanged( const QString &uid );
+ void slotCustomUIDChanged( const TQString &uid );
/**
* This slot is invoked if the value for the custom GID setting changed.
*
* @param gid The new GID in text form
*/
- void slotCustomGIDChanged( const QString &gid );
+ void slotCustomGIDChanged( const TQString &gid );
/**
* Commit the new custom port number to the list view item.
diff --git a/smb4k/configdlg/smb4kshareoptions.cpp b/smb4k/configdlg/smb4kshareoptions.cpp
index aebd505..040ff88 100644
--- a/smb4k/configdlg/smb4kshareoptions.cpp
+++ b/smb4k/configdlg/smb4kshareoptions.cpp
@@ -24,12 +24,12 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qgroupbox.h>
-#include <qbuttongroup.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqgroupbox.h>
+#include <tqbuttongroup.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
// KDE includes
#include <klocale.h>
@@ -45,44 +45,44 @@
#include "smb4kshareoptions.h"
-Smb4KShareOptions::Smb4KShareOptions( QWidget *parent, const char *name ) : QWidget( parent, name )
+Smb4KShareOptions::Smb4KShareOptions( TQWidget *tqparent, const char *name ) : TQWidget( tqparent, name )
{
- QGridLayout *grid = new QGridLayout( this );
+ TQGridLayout *grid = new TQGridLayout( this );
grid->setSpacing( 10 );
- QGroupBox *dir_box = new QGroupBox( 1, Qt::Horizontal, i18n( "Directories" ), this );
+ TQGroupBox *dir_box = new TQGroupBox( 1, Qt::Horizontal, i18n( "Directories" ), this );
- QWidget *prefix_container = new QWidget( dir_box );
- QGridLayout *prefix_layout = new QGridLayout( prefix_container );
+ TQWidget *prefix_container = new TQWidget( dir_box );
+ TQGridLayout *prefix_layout = new TQGridLayout( prefix_container );
prefix_layout->setSpacing( 10 );
- QLabel *prefix = new QLabel( i18n( "Mount prefix:" ), prefix_container );
- KURLRequester *mount_prefix = new KURLRequester( QString::null, prefix_container,
+ TQLabel *prefix = new TQLabel( i18n( "Mount prefix:" ), prefix_container );
+ KURLRequester *mount_prefix = new KURLRequester( TQString(), prefix_container,
"kcfg_MountPrefix" );
mount_prefix->setMode( KFile::Directory );
prefix_layout->addWidget( prefix, 0, 0, 0 );
prefix_layout->addWidget( mount_prefix, 0, 1, 0 );
- (void) new QCheckBox( i18n( "Force generated subdirectories to be lower case" ),
+ (void) new TQCheckBox( i18n( "Force generated subdirectories to be lower case" ),
dir_box, "kcfg_ForceLowerCaseSubdirs" );
- QButtonGroup *mount_box = new QButtonGroup( 1, QButtonGroup::Horizontal, i18n( "Mounting and Unmounting" ), this );
- (void) new QCheckBox( i18n( "Unmount all shares of user %1 on exit" ).arg( getpwuid( getuid() )->pw_name ),
+ TQButtonGroup *mount_box = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Mounting and Unmounting" ), this );
+ (void) new TQCheckBox( i18n( "Unmount all shares of user %1 on exit" ).tqarg( getpwuid( getuid() )->pw_name ),
mount_box, "kcfg_UnmountSharesOnExit" );
- (void) new QCheckBox( i18n( "Remount recently used shares on program start" ),
+ (void) new TQCheckBox( i18n( "Remount recently used shares on program start" ),
mount_box, "kcfg_RemountShares" );
- (void) new QCheckBox( i18n( "Allow the unmounting of shares that are owned by other users" ),
+ (void) new TQCheckBox( i18n( "Allow the unmounting of shares that are owned by other users" ),
mount_box, "kcfg_UnmountForeignShares" );
- QGroupBox *checks_box = new QGroupBox( 2, QGroupBox::Horizontal, i18n( "Checks" ), this );
+ TQGroupBox *checks_box = new TQGroupBox( 2, Qt::Horizontal, i18n( "Checks" ), this );
- (void) new QLabel( i18n( "Interval between checks:" ), checks_box );
+ (void) new TQLabel( i18n( "Interval between checks:" ), checks_box );
KIntNumInput *check_interval = new KIntNumInput( 2500, checks_box, 10,
"kcfg_CheckInterval" );
check_interval->setSuffix( " ms" );
check_interval->setRange( 500, 300000, 1, false );
- QSpacerItem *spacer2 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer2 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
grid->addWidget( dir_box, 0, 0, 0 );
grid->addWidget( mount_box, 1, 0, 0 );
diff --git a/smb4k/configdlg/smb4kshareoptions.h b/smb4k/configdlg/smb4kshareoptions.h
index cf45aa7..8c115f2 100644
--- a/smb4k/configdlg/smb4kshareoptions.h
+++ b/smb4k/configdlg/smb4kshareoptions.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qwidget.h>
+// TQt includes
+#include <tqwidget.h>
/**
* This is the configuration tab for the settings that are
@@ -41,19 +41,20 @@
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KShareOptions : public QWidget
+class Smb4KShareOptions : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent of this widget
+ * @param tqparent The tqparent of this widget
*
* @param name The name of this widget
*/
- Smb4KShareOptions( QWidget *parent = 0, const char *name = 0 );
+ Smb4KShareOptions( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
*/
diff --git a/smb4k/configdlg/smb4ksuperuseroptions.cpp b/smb4k/configdlg/smb4ksuperuseroptions.cpp
index d23b624..a9dce42 100644
--- a/smb4k/configdlg/smb4ksuperuseroptions.cpp
+++ b/smb4k/configdlg/smb4ksuperuseroptions.cpp
@@ -24,13 +24,13 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qgroupbox.h>
-#include <qbuttongroup.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qradiobutton.h>
-#include <qcheckbox.h>
+// TQt includes
+#include <tqgroupbox.h>
+#include <tqbuttongroup.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqradiobutton.h>
+#include <tqcheckbox.h>
// KDE includes
#include <klocale.h>
@@ -42,34 +42,34 @@
#include "../core/smb4ksettings.h"
-Smb4KSuperUserOptions::Smb4KSuperUserOptions( QWidget *parent, const char *name )
-: QWidget( parent, name )
+Smb4KSuperUserOptions::Smb4KSuperUserOptions( TQWidget *tqparent, const char *name )
+: TQWidget( tqparent, name )
{
- QGridLayout *grid = new QGridLayout( this );
+ TQGridLayout *grid = new TQGridLayout( this );
grid->setSpacing( 10 );
- QButtonGroup *suid_progs = new QButtonGroup( 1, QButtonGroup::Horizontal,
+ TQButtonGroup *suid_progs = new TQButtonGroup( 1, Qt::Horizontal,
i18n( "Programs" ), this, "kcfg_SuperUserProgram" );
suid_progs->setInsideSpacing( 5 );
- new QLabel( i18n( "Use the following program to gain super user privileges:" ), suid_progs );
- suid_progs->insert( new QRadioButton( "sudo", suid_progs, "SudoButton" ), Smb4KSettings::EnumSuperUserProgram::Sudo );
- suid_progs->insert( new QRadioButton( "super", suid_progs, "SuperButton" ), Smb4KSettings::EnumSuperUserProgram::Super );
+ new TQLabel( i18n( "Use the following program to gain super user privileges:" ), suid_progs );
+ suid_progs->insert( new TQRadioButton( "sudo", suid_progs, "SudoButton" ), Smb4KSettings::EnumSuperUserProgram::Sudo );
+ suid_progs->insert( new TQRadioButton( "super", suid_progs, "SuperButton" ), Smb4KSettings::EnumSuperUserProgram::Super );
- QButtonGroup *suid_actions = new QButtonGroup( 1, QButtonGroup::Horizontal, i18n( "Actions" ), this, "SUIDActions" );
+ TQButtonGroup *suid_actions = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Actions" ), this, "SUIDActions" );
suid_actions->setInsideSpacing( 5 );
#ifdef __linux__
- (void) new QCheckBox( i18n( "Use super user privileges to force the unmounting of (inaccessible) shares" ), suid_actions, "kcfg_UseForceUnmount" );
+ (void) new TQCheckBox( i18n( "Use super user privileges to force the unmounting of (inaccessible) shares" ), suid_actions, "kcfg_UseForceUnmount" );
#endif
- (void) new QCheckBox( i18n( "Use super user privileges to mount and unmount shares" ), suid_actions, "kcfg_AlwaysUseSuperUser" );
+ (void) new TQCheckBox( i18n( "Use super user privileges to mount and unmount shares" ), suid_actions, "kcfg_AlwaysUseSuperUser" );
- QSpacerItem *spacer1 = new QSpacerItem( 0, 0, QSizePolicy::Expanding, QSizePolicy::Preferred );
+ TQSpacerItem *spacer1 = new TQSpacerItem( 0, 0, TQSizePolicy::Expanding, TQSizePolicy::Preferred );
KGuiItem remove_item = KGuiItem( i18n( "Remove Entries" ), "editdelete",
i18n( "Remove entries from the configuration file" ),
i18n( "Depending on your choice under \"Programs\", all entries that were written by Smb4K will be removed either from /etc/super.tab or /etc/sudoers. Additionally, all your choices under \"Actions\" will be cleared." ) );
KPushButton *remove = new KPushButton( remove_item, this, "RemoveButton" );
- QSpacerItem *spacer2 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer2 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
grid->addMultiCellWidget( suid_progs, 0, 0, 0, 3, 0 );
grid->addMultiCellWidget( suid_actions, 1, 1, 0, 3, 0 );
@@ -77,8 +77,8 @@ Smb4KSuperUserOptions::Smb4KSuperUserOptions( QWidget *parent, const char *name
grid->addWidget( remove, 2, 3, 0 );
grid->addMultiCell( spacer2, 3, 3, 0, 3, 0 );
- connect( remove, SIGNAL( clicked() ),
- this, SLOT( slotRemoveClicked() ) );
+ connect( remove, TQT_SIGNAL( clicked() ),
+ this, TQT_SLOT( slotRemoveClicked() ) );
}
@@ -88,7 +88,7 @@ Smb4KSuperUserOptions::~Smb4KSuperUserOptions()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KSuperUserOptions::slotRemoveClicked()
diff --git a/smb4k/configdlg/smb4ksuperuseroptions.h b/smb4k/configdlg/smb4ksuperuseroptions.h
index 86c705e..9fcffbf 100644
--- a/smb4k/configdlg/smb4ksuperuseroptions.h
+++ b/smb4k/configdlg/smb4ksuperuseroptions.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qwidget.h>
+// TQt includes
+#include <tqwidget.h>
/**
* This is the configuration tab where the user can determine
@@ -42,19 +42,20 @@
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KSuperUserOptions : public QWidget
+class Smb4KSuperUserOptions : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this widget
*/
- Smb4KSuperUserOptions( QWidget *parent = 0, const char *name = 0 );
+ Smb4KSuperUserOptions( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
*/
diff --git a/smb4k/configdlg/smb4kuserinterfaceoptions.cpp b/smb4k/configdlg/smb4kuserinterfaceoptions.cpp
index c4310fe..2fd83a7 100644
--- a/smb4k/configdlg/smb4kuserinterfaceoptions.cpp
+++ b/smb4k/configdlg/smb4kuserinterfaceoptions.cpp
@@ -24,11 +24,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qbuttongroup.h>
-#include <qcheckbox.h>
-#include <qradiobutton.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqbuttongroup.h>
+#include <tqcheckbox.h>
+#include <tqradiobutton.h>
// KDE includes
#include <klocale.h>
@@ -37,36 +37,36 @@
#include "smb4kuserinterfaceoptions.h"
#include "../core/smb4ksettings.h"
-Smb4KUserInterfaceOptions::Smb4KUserInterfaceOptions( QWidget *parent, const char *name )
-: QTabWidget( parent, name )
+Smb4KUserInterfaceOptions::Smb4KUserInterfaceOptions( TQWidget *tqparent, const char *name )
+: TQTabWidget( tqparent, name )
{
setMargin( 10 );
//
// Configuration for the main window:
//
- QWidget *main_wd_widget = new QWidget( this );
- QGridLayout *main_wd_layout = new QGridLayout( main_wd_widget );
+ TQWidget *main_wd_widget = new TQWidget( this );
+ TQGridLayout *main_wd_layout = new TQGridLayout( main_wd_widget );
main_wd_layout->setSpacing( 10 );
- QButtonGroup *shares_view = new QButtonGroup( 1, Qt::Horizontal, i18n( "Shares View" ),
+ TQButtonGroup *shares_view = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Shares View" ),
main_wd_widget, "kcfg_SharesView" );
- shares_view->insert( new QRadioButton( i18n( "Show mounted shares in an icon view" ), shares_view ), Smb4KSettings::EnumSharesView::IconView );
+ shares_view->insert( new TQRadioButton( i18n( "Show mounted shares in an icon view" ), shares_view ), Smb4KSettings::EnumSharesView::IconView );
- shares_view->insert( new QRadioButton( i18n( "Show mounted shares in a list view" ), shares_view ), Smb4KSettings::EnumSharesView::ListView );
+ shares_view->insert( new TQRadioButton( i18n( "Show mounted shares in a list view" ), shares_view ), Smb4KSettings::EnumSharesView::ListView );
- QButtonGroup *bookmarks_grp = new QButtonGroup( 1, Qt::Horizontal, i18n( "Bookmarks" ),
+ TQButtonGroup *bookmarks_grp = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Bookmarks" ),
main_wd_widget, "BookmarksBox" );
- (void) new QCheckBox( i18n( "Show custom bookmark label if available" ), bookmarks_grp, "kcfg_ShowCustomBookmarkLabel" );
+ (void) new TQCheckBox( i18n( "Show custom bookmark label if available" ), bookmarks_grp, "kcfg_ShowCustomBookmarkLabel" );
- QButtonGroup *tray_group = new QButtonGroup( 1, Qt::Horizontal, i18n( "System Tray" ),
+ TQButtonGroup *tray_group = new TQButtonGroup( 1, Qt::Horizontal, i18n( "System Tray" ),
main_wd_widget, "SystemTrayBox" );
- (void) new QCheckBox( i18n( "Embed application into the system tray" ), tray_group, "kcfg_EmbedIntoSystemTray" );
+ (void) new TQCheckBox( i18n( "Embed application into the system tray" ), tray_group, "kcfg_EmbedIntoSystemTray" );
- QSpacerItem *spacer1 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer1 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
main_wd_layout->addWidget( shares_view, 0, 0, 0 );
main_wd_layout->addWidget( bookmarks_grp, 1, 0, 0 );
@@ -76,28 +76,28 @@ Smb4KUserInterfaceOptions::Smb4KUserInterfaceOptions( QWidget *parent, const cha
//
// Configuration for the network browser:
//
- QWidget *browser_widget = new QWidget( this );
- QGridLayout *browser_layout = new QGridLayout( browser_widget );
+ TQWidget *browser_widget = new TQWidget( this );
+ TQGridLayout *browser_layout = new TQGridLayout( browser_widget );
browser_layout->setSpacing( 10 );
- QButtonGroup *remoteGroup = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "Remote Shares" ),
+ TQButtonGroup *remoteGroup = new TQButtonGroup( 2, Qt::Horizontal, i18n( "Remote Shares" ),
browser_widget, "BrowserRemoteSharesBox" );
- (void) new QCheckBox( i18n( "Show printer shares" ), remoteGroup, "kcfg_ShowPrinterShares" );
- QCheckBox *hidden = new QCheckBox( i18n( "Show hidden shares" ), remoteGroup, "kcfg_ShowHiddenShares" );
- (void) new QCheckBox( i18n( "Show IPC$ shares" ), remoteGroup, "kcfg_ShowHiddenIPCShares" );
- (void) new QCheckBox( i18n( "Show ADMIN$ shares" ), remoteGroup, "kcfg_ShowHiddenADMINShares" );
+ (void) new TQCheckBox( i18n( "Show printer shares" ), remoteGroup, "kcfg_ShowPrinterShares" );
+ TQCheckBox *hidden = new TQCheckBox( i18n( "Show hidden shares" ), remoteGroup, "kcfg_ShowHiddenShares" );
+ (void) new TQCheckBox( i18n( "Show IPC$ shares" ), remoteGroup, "kcfg_ShowHiddenIPCShares" );
+ (void) new TQCheckBox( i18n( "Show ADMIN$ shares" ), remoteGroup, "kcfg_ShowHiddenADMINShares" );
- QButtonGroup *columnsGroup = new QButtonGroup( 2, QButtonGroup::Horizontal, i18n( "Columns" ),
+ TQButtonGroup *columnsGroup = new TQButtonGroup( 2, Qt::Horizontal, i18n( "Columns" ),
browser_widget, "BrowserColumnsBox" );
- (void) new QCheckBox( i18n( "Show type" ), columnsGroup, "kcfg_ShowType" );
- (void) new QCheckBox( i18n( "Show IP address" ), columnsGroup, "kcfg_ShowIPAddress" );
- (void) new QCheckBox( i18n( "Show comment" ), columnsGroup, "kcfg_ShowComment" );
+ (void) new TQCheckBox( i18n( "Show type" ), columnsGroup, "kcfg_ShowType" );
+ (void) new TQCheckBox( i18n( "Show IP address" ), columnsGroup, "kcfg_ShowIPAddress" );
+ (void) new TQCheckBox( i18n( "Show comment" ), columnsGroup, "kcfg_ShowComment" );
- QButtonGroup *netTooltipsGroup = new QButtonGroup( 1, QButtonGroup::Horizontal, i18n( "Tooltips" ),
+ TQButtonGroup *netTooltipsGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Tooltips" ),
browser_widget, "BrowserTooltipsBox" );
- (void) new QCheckBox( i18n( "Show tooltip with information about a network item" ), netTooltipsGroup, "kcfg_ShowNetworkItemToolTip" );
+ (void) new TQCheckBox( i18n( "Show tooltip with information about a network item" ), netTooltipsGroup, "kcfg_ShowNetworkItemToolTip" );
- QSpacerItem *spacer2 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer2 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
browser_layout->addWidget( remoteGroup, 0, 0, 0 );
browser_layout->addWidget( columnsGroup, 1, 0, 0 );
@@ -107,40 +107,40 @@ Smb4KUserInterfaceOptions::Smb4KUserInterfaceOptions( QWidget *parent, const cha
//
// Configuration for the shares view
//
- QWidget *shares_widget = new QWidget( this );
- QGridLayout *shares_layout = new QGridLayout( shares_widget );
+ TQWidget *shares_widget = new TQWidget( this );
+ TQGridLayout *shares_layout = new TQGridLayout( shares_widget );
shares_layout->setSpacing( 10 );
- QButtonGroup *shares_group = new QButtonGroup( 1, Qt::Horizontal, i18n( "Mounted Shares" ),
+ TQButtonGroup *shares_group = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Mounted Shares" ),
shares_widget, "SharesIconGroupBox" );
- (void) new QCheckBox( i18n( "Show mount point instead of share name" ), shares_group, "kcfg_ShowMountPoint" );
- (void) new QCheckBox( i18n( "Show all shares that are mounted on the system" ), shares_group, "kcfg_ShowAllShares" );
+ (void) new TQCheckBox( i18n( "Show mount point instead of share name" ), shares_group, "kcfg_ShowMountPoint" );
+ (void) new TQCheckBox( i18n( "Show all shares that are mounted on the system" ), shares_group, "kcfg_ShowAllShares" );
- QButtonGroup *dnd_group = new QButtonGroup( 1, Qt::Horizontal, i18n( "Drag and Drop" ),
+ TQButtonGroup *dnd_group = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Drag and Drop" ),
shares_widget, "DragnDropBox" );
- (void) new QCheckBox( i18n( "Allow dropping of files and directories onto shares" ), dnd_group, "kcfg_EnableDropSupport" );
- (void) new QCheckBox( i18n( "Allow dragging of shares" ), dnd_group, "kcfg_EnableDragSupport" );
+ (void) new TQCheckBox( i18n( "Allow dropping of files and directories onto shares" ), dnd_group, "kcfg_EnableDropSupport" );
+ (void) new TQCheckBox( i18n( "Allow dragging of shares" ), dnd_group, "kcfg_EnableDragSupport" );
- QButtonGroup *sharesTooltipGroup = new QButtonGroup( 1, Qt::Horizontal, i18n( "Tooltips" ),
+ TQButtonGroup *sharesTooltipGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Tooltips" ),
shares_widget, "SharesTooltipsBox" );
- (void) new QCheckBox( i18n( "Show tooltip with information about a share" ), sharesTooltipGroup, "kcfg_ShowShareToolTip" );
+ (void) new TQCheckBox( i18n( "Show tooltip with information about a share" ), sharesTooltipGroup, "kcfg_ShowShareToolTip" );
- QButtonGroup *list_view_group = new QButtonGroup( 2, Qt::Horizontal, i18n( "List View" ),
+ TQButtonGroup *list_view_group = new TQButtonGroup( 2, Qt::Horizontal, i18n( "List View" ),
shares_widget, "SharesListViewBox" );
#ifndef __FreeBSD__
- (void) new QCheckBox( i18n( "Show owner and group (SMBFS only)" ), list_view_group, "kcfg_ShowOwner" );
- (void) new QCheckBox( i18n( "Show login (CIFS only)" ), list_view_group, "kcfg_ShowLogin" );
+ (void) new TQCheckBox( i18n( "Show owner and group (SMBFS only)" ), list_view_group, "kcfg_ShowOwner" );
+ (void) new TQCheckBox( i18n( "Show login (CIFS only)" ), list_view_group, "kcfg_ShowLogin" );
#else
- (void) new QCheckBox( i18n( "Show owner and group" ), list_view_group, "kcfg_ShowOwner" );
+ (void) new TQCheckBox( i18n( "Show owner and group" ), list_view_group, "kcfg_ShowOwner" );
#endif
- (void) new QCheckBox( i18n( "Show file system" ), list_view_group, "kcfg_ShowFileSystem" );
- (void) new QCheckBox( i18n( "Show free disk space" ), list_view_group, "kcfg_ShowFreeDiskSpace" );
- (void) new QCheckBox( i18n( "Show used disk space" ), list_view_group, "kcfg_ShowUsedDiskSpace" );
- (void) new QCheckBox( i18n( "Show total disk space" ), list_view_group, "kcfg_ShowTotalDiskSpace" );
- (void) new QCheckBox( i18n( "Show disk usage" ), list_view_group, "kcfg_ShowDiskUsage" );
+ (void) new TQCheckBox( i18n( "Show file system" ), list_view_group, "kcfg_ShowFileSystem" );
+ (void) new TQCheckBox( i18n( "Show free disk space" ), list_view_group, "kcfg_ShowFreeDiskSpace" );
+ (void) new TQCheckBox( i18n( "Show used disk space" ), list_view_group, "kcfg_ShowUsedDiskSpace" );
+ (void) new TQCheckBox( i18n( "Show total disk space" ), list_view_group, "kcfg_ShowTotalDiskSpace" );
+ (void) new TQCheckBox( i18n( "Show disk usage" ), list_view_group, "kcfg_ShowDiskUsage" );
- QSpacerItem *spacer3 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer3 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
shares_layout->addWidget( shares_group, 0, 0, 0 );
shares_layout->addWidget( dnd_group, 1, 0, 0 );
@@ -151,14 +151,14 @@ Smb4KUserInterfaceOptions::Smb4KUserInterfaceOptions( QWidget *parent, const cha
//
// Configuration for the preview dialog
//
- QWidget *preview_widget = new QWidget( this );
- QGridLayout *preview_layout = new QGridLayout( preview_widget );
+ TQWidget *preview_widget = new TQWidget( this );
+ TQGridLayout *preview_layout = new TQGridLayout( preview_widget );
preview_layout->setSpacing( 10 );
- QButtonGroup *previewFilesGroup = new QButtonGroup( 1, QButtonGroup::Horizontal, i18n( "Hidden Files and Directories" ), preview_widget, "HiddenFilesBox" );
- (void) new QCheckBox( i18n( "Preview hidden files and directories" ), previewFilesGroup, "kcfg_PreviewHiddenItems" );
+ TQButtonGroup *previewFilesGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Hidden Files and Directories" ), preview_widget, "HiddenFilesBox" );
+ (void) new TQCheckBox( i18n( "Preview hidden files and directories" ), previewFilesGroup, "kcfg_PreviewHiddenItems" );
- QSpacerItem *spacer4 = new QSpacerItem( 0, 0, QSizePolicy::Preferred, QSizePolicy::Expanding );
+ TQSpacerItem *spacer4 = new TQSpacerItem( 0, 0, TQSizePolicy::Preferred, TQSizePolicy::Expanding );
preview_layout->addWidget( previewFilesGroup, 0, 0, 0 );
preview_layout->addItem( spacer4, 1, 0 );
@@ -172,8 +172,8 @@ Smb4KUserInterfaceOptions::Smb4KUserInterfaceOptions( QWidget *parent, const cha
addTab( preview_widget, i18n( "Preview Dialog" ) );
// Add connections:
- connect( hidden, SIGNAL( stateChanged( int ) ),
- this, SLOT( slotShowHiddenShares( int ) ) );
+ connect( hidden, TQT_SIGNAL( stateChanged( int ) ),
+ this, TQT_SLOT( slotShowHiddenShares( int ) ) );
// Do last adjustments:
slotShowHiddenShares( hidden->state() );
@@ -186,21 +186,21 @@ Smb4KUserInterfaceOptions::~Smb4KUserInterfaceOptions()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KUserInterfaceOptions::slotShowHiddenShares( int state )
{
- if ( state == QCheckBox::On )
+ if ( state == TQCheckBox::On )
{
- static_cast<QCheckBox *>( child( "kcfg_ShowHiddenIPCShares", "QCheckBox" ) )->setEnabled( true );
- static_cast<QCheckBox *>( child( "kcfg_ShowHiddenADMINShares", "QCheckBox" ) )->setEnabled( true );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_ShowHiddenIPCShares", TQCHECKBOX_OBJECT_NAME_STRING )) )->setEnabled( true );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_ShowHiddenADMINShares", TQCHECKBOX_OBJECT_NAME_STRING )) )->setEnabled( true );
}
- else if ( state == QCheckBox::Off )
+ else if ( state == TQCheckBox::Off )
{
- static_cast<QCheckBox *>( child( "kcfg_ShowHiddenIPCShares", "QCheckBox" ) )->setEnabled( false );
- static_cast<QCheckBox *>( child( "kcfg_ShowHiddenADMINShares", "QCheckBox" ) )->setEnabled( false );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_ShowHiddenIPCShares", TQCHECKBOX_OBJECT_NAME_STRING )) )->setEnabled( false );
+ static_cast<TQCheckBox *>( TQT_TQWIDGET(child( "kcfg_ShowHiddenADMINShares", TQCHECKBOX_OBJECT_NAME_STRING )) )->setEnabled( false );
}
}
diff --git a/smb4k/configdlg/smb4kuserinterfaceoptions.h b/smb4k/configdlg/smb4kuserinterfaceoptions.h
index 6fb7e64..88414a7 100644
--- a/smb4k/configdlg/smb4kuserinterfaceoptions.h
+++ b/smb4k/configdlg/smb4kuserinterfaceoptions.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qtabwidget.h>
+// TQt includes
+#include <tqtabwidget.h>
/**
@@ -41,15 +41,16 @@
* @author Alexander Reinholdt <dustpuppy@mail.berlios.de>
*/
-class Smb4KUserInterfaceOptions : public QTabWidget
+class Smb4KUserInterfaceOptions : public TQTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*/
- Smb4KUserInterfaceOptions( QWidget *parent = 0, const char *name = 0 );
+ Smb4KUserInterfaceOptions( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
diff --git a/smb4k/core/smb4k.kcfg b/smb4k/core/smb4k.kcfg
index 45a2ead..ceea0b6 100644
--- a/smb4k/core/smb4k.kcfg
+++ b/smb4k/core/smb4k.kcfg
@@ -3,7 +3,7 @@
<kcfg>
<include>unistd.h</include>
<include>sys/types.h</include>
- <include>qstring.h</include>
+ <include>tqstring.h</include>
<kcfgfile name="smb4krc" />
<!-- Programs -->
@@ -504,12 +504,12 @@
<entry name="UserID" type="String">
<label>The user ID that is to be used for mounting</label>
<whatsthis>Here you can enter the user ID (a number) that the files and directories of the mounted share will have. If you are using the CIFS file system and the remote server supports the CIFS Unix Extentions, this setting will be ignored.</whatsthis>
- <default code="true">QString( "%1" ).arg( (int)getuid() )</default>
+ <default code="true">TQString( "%1" ).arg( (int)getuid() )</default>
</entry>
<entry name="GroupID" type="String">
<label>The group ID that is to be used for mounting</label>
<whatsthis>Here you can enter the group ID (a number) that the files and directories of the mounted share will have. If you are using the CIFS file system and the remote server supports the CIFS Unix Extentions, this setting will be ignored.</whatsthis>
- <default code="true">QString( "%1" ).arg( (int)getgid() )</default>
+ <default code="true">TQString( "%1" ).arg( (int)getgid() )</default>
</entry>
<entry name="FileMask" type="String">
<label>The file mask for a share</label>
diff --git a/smb4k/core/smb4kauthinfo.cpp b/smb4k/core/smb4kauthinfo.cpp
index d47eeb0..521e941 100644
--- a/smb4k/core/smb4kauthinfo.cpp
+++ b/smb4k/core/smb4kauthinfo.cpp
@@ -28,7 +28,7 @@
#include "smb4kauthinfo.h"
-Smb4KAuthInfo::Smb4KAuthInfo( const QString &wg, const QString &h, const QString &s, const QString &u, const QString &p ) : m_workgroup(wg), m_host(h), m_share(s), m_user(u.local8Bit()), m_password(p.local8Bit())
+Smb4KAuthInfo::Smb4KAuthInfo( const TQString &wg, const TQString &h, const TQString &s, const TQString &u, const TQString &p ) : m_workgroup(wg), m_host(h), m_share(s), m_user(u.local8Bit()), m_password(p.local8Bit())
{
}
@@ -43,19 +43,19 @@ Smb4KAuthInfo::~Smb4KAuthInfo()
}
-void Smb4KAuthInfo::setUser( const QString &user )
+void Smb4KAuthInfo::setUser( const TQString &user )
{
m_user = user.local8Bit();
}
-void Smb4KAuthInfo::setPassword( const QString &passwd )
+void Smb4KAuthInfo::setPassword( const TQString &passwd )
{
m_password = passwd.local8Bit();
}
-void Smb4KAuthInfo::setShare( const QString &share )
+void Smb4KAuthInfo::setShare( const TQString &share )
{
m_share = share;
}
diff --git a/smb4k/core/smb4kauthinfo.h b/smb4k/core/smb4kauthinfo.h
index 9c4798e..dd0f05c 100644
--- a/smb4k/core/smb4kauthinfo.h
+++ b/smb4k/core/smb4kauthinfo.h
@@ -27,9 +27,9 @@
#ifndef SMB4KAUTHINFO_H
#define SMB4KAUTHINFO_H
-// Qt includes
-#include <qstring.h>
-#include <qcstring.h>
+// TQt includes
+#include <tqstring.h>
+#include <tqcstring.h>
/**
* This class provides a container for the authentication data.
@@ -50,15 +50,15 @@ class Smb4KAuthInfo
*
* @param share The share's name
*
- * @param user The username that's used for authentication. Default is QString::null.
+ * @param user The username that's used for authentication. Default is TQString().
*
- * @param password The password that's used for authentication. Default is QString::null.
+ * @param password The password that's used for authentication. Default is TQString().
*/
- Smb4KAuthInfo( const QString &workgroup,
- const QString &host,
- const QString &share,
- const QString &user = QString::null,
- const QString &password = QString::null );
+ Smb4KAuthInfo( const TQString &workgroup,
+ const TQString &host,
+ const TQString &share,
+ const TQString &user = TQString(),
+ const TQString &password = TQString() );
/**
* The empty constructor.
*/
@@ -79,69 +79,69 @@ class Smb4KAuthInfo
* @returns The workgroup of the server/share for which this
* authentication data is for.
*/
- const QString &workgroup() const { return m_workgroup; }
+ const TQString &workgroup() const { return m_workgroup; }
/**
* Returns the name of the server (host).
*
* @returns The server name
*/
- const QString &host() const { return m_host; }
+ const TQString &host() const { return m_host; }
/**
* Returns the name of the share.
*
* @returns The share name
*/
- const QString &share() const { return m_share; }
+ const TQString &share() const { return m_share; }
/**
* Returns the user's name.
*
* @returns The user name
*/
- const QCString &user() const { return m_user; }
+ const TQCString &user() const { return m_user; }
/**
* Returns the (unescaped) password.
*/
- const QCString &password() const { return m_password; }
+ const TQCString &password() const { return m_password; }
/**
* Sets the user name.
*
* @param user The user name for the server/share
*/
- void setUser( const QString &user );
+ void setUser( const TQString &user );
/**
* Sets the password.
*
* @param passwd The password for the server/share
*/
- void setPassword( const QString &passwd );
+ void setPassword( const TQString &passwd );
/**
* Sets the share name.
*
* @param share The name of the share
*/
- void setShare( const QString &share );
+ void setShare( const TQString &share );
private:
/**
* The workgroup object.
*/
- QString m_workgroup;
+ TQString m_workgroup;
/**
* The host object.
*/
- QString m_host;
+ TQString m_host;
/**
* The share object.
*/
- QString m_share;
+ TQString m_share;
/**
* The user name for this share.
*/
- QCString m_user;
+ TQCString m_user;
/**
* The password object for this share.
*/
- QCString m_password;
+ TQCString m_password;
};
diff --git a/smb4k/core/smb4kbookmark.cpp b/smb4k/core/smb4kbookmark.cpp
index 20b3a90..2edae5f 100644
--- a/smb4k/core/smb4kbookmark.cpp
+++ b/smb4k/core/smb4kbookmark.cpp
@@ -33,22 +33,22 @@
#include "smb4knetworkitems.h"
-Smb4KBookmark::Smb4KBookmark( const QString &host, const QString &share, const QString &workgroup, const QString &ip, const QString &type, const QString &label )
+Smb4KBookmark::Smb4KBookmark( const TQString &host, const TQString &share, const TQString &workgroup, const TQString &ip, const TQString &type, const TQString &label )
: m_host( host ), m_share( share ), m_workgroup( workgroup ), m_type( type ), m_label( label )
{
//FIXME should throw an exception if one of the param is empty
- m_ip = ipIsValid( ip ) ? ip : QString::null;
- m_bookmark = QString( "//%1/%2" ).arg( m_host, m_share );
+ m_ip = ipIsValid( ip ) ? ip : TQString();
+ m_bookmark = TQString( "//%1/%2" ).tqarg( m_host, m_share );
}
-Smb4KBookmark::Smb4KBookmark( Smb4KShareItem *item, const QString &ip, const QString &label )
+Smb4KBookmark::Smb4KBookmark( Smb4KShareItem *item, const TQString &ip, const TQString &label )
: m_host( item->host() ), m_share( item->name() ), m_workgroup( item->workgroup() ),
m_type( item->plainType() ), m_label( label )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
- m_bookmark = QString( "//%1/%2" ).arg( m_host, m_share );
+ m_ip = ipIsValid( ip ) ? ip : TQString();
+ m_bookmark = TQString( "//%1/%2" ).tqarg( m_host, m_share );
}
@@ -57,27 +57,27 @@ Smb4KBookmark::~Smb4KBookmark()
}
-void Smb4KBookmark::setShareName( const QString &name )
+void Smb4KBookmark::setShareName( const TQString &name )
{
m_share = name;
- m_bookmark = QString( "//%1/%2" ).arg( m_host, m_share );
+ m_bookmark = TQString( "//%1/%2" ).tqarg( m_host, m_share );
}
-void Smb4KBookmark::setIP( const QString &ip )
+void Smb4KBookmark::setIP( const TQString &ip )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
}
-void Smb4KBookmark::setLabel( const QString &text )
+void Smb4KBookmark::setLabel( const TQString &text )
{
m_label = text;
}
-bool Smb4KBookmark::ipIsValid( const QString &ip )
+bool Smb4KBookmark::ipIsValid( const TQString &ip )
{
if ( !ip.isEmpty() )
{
diff --git a/smb4k/core/smb4kbookmark.h b/smb4k/core/smb4kbookmark.h
index c4e8b25..a4d3753 100644
--- a/smb4k/core/smb4kbookmark.h
+++ b/smb4k/core/smb4kbookmark.h
@@ -28,8 +28,8 @@
#ifndef SMB4KBOOKMARK_H
#define SMB4KBOOKMARK_H
-// Qt includes
-#include <qstring.h>
+// TQt includes
+#include <tqstring.h>
// forward declarations
class Smb4KShareItem;
@@ -56,12 +56,12 @@ class Smb4KBookmark
*
* @param label An alternative label to the share name.
*/
- Smb4KBookmark( const QString &hostname,
- const QString &sharename,
- const QString &workgroup,
- const QString &ip,
- const QString &type,
- const QString &label = QString::null );
+ Smb4KBookmark( const TQString &hostname,
+ const TQString &sharename,
+ const TQString &workgroup,
+ const TQString &ip,
+ const TQString &type,
+ const TQString &label = TQString() );
/**
* An alternative constructor.
@@ -74,8 +74,8 @@ class Smb4KBookmark
* @param label An alternative label to the share name.
*/
Smb4KBookmark( Smb4KShareItem *item,
- const QString &ip,
- const QString &label = QString::null );
+ const TQString &ip,
+ const TQString &label = TQString() );
/**
* The empty constructor.
@@ -92,14 +92,14 @@ class Smb4KBookmark
*
* @returns The share name
*/
- const QString &share() const { return m_share; };
+ const TQString &share() const { return m_share; };
/**
* This function returns the workgroup/domain the share is located in.
*
* @returns The workgroup
*/
- const QString &workgroup() const { return m_workgroup; }
+ const TQString &workgroup() const { return m_workgroup; }
/**
* This function returns the IP address of the host that carries the
@@ -107,7 +107,7 @@ class Smb4KBookmark
*
* @returns The IP address
*/
- const QString &ip() const { return m_ip; }
+ const TQString &ip() const { return m_ip; }
/**
* This function returns the type of the share, i.e. either "Disk" or
@@ -115,7 +115,7 @@ class Smb4KBookmark
*
* @returns The type of the share
*/
- const QString &type() const { return m_type; }
+ const TQString &type() const { return m_type; }
/**
* This function sets the share name of the bookmark. It is normally not
@@ -124,78 +124,78 @@ class Smb4KBookmark
*
* @param name The share name
*/
- void setShareName( const QString &name );
+ void setShareName( const TQString &name );
/**
* This function returns the bookmark name.
*
* @returns The name of the bookmark
*/
- const QString &bookmark() const { return m_bookmark; }
+ const TQString &bookmark() const { return m_bookmark; }
/**
* This function returns the host name.
*
* @returns The name of the host
*/
- const QString &host() const { return m_host; }
+ const TQString &host() const { return m_host; }
/**
* This function sets the IP address.
*
* @param ip The IP address
*/
- void setIP( const QString &ip );
+ void setIP( const TQString &ip );
/**
* Return the alternative bookmark label.
*
* @returns the label.
*/
- const QString &label() const { return m_label; }
+ const TQString &label() const { return m_label; }
/**
* Sets the alternative bookmark label.
*
* @param text The new text for the label
*/
- void setLabel( const QString &text );
+ void setLabel( const TQString &text );
private:
/**
* The host name.
*/
- QString m_host;
+ TQString m_host;
/**
* The share name.
*/
- QString m_share;
+ TQString m_share;
/**
* The workgroup
*/
- QString m_workgroup;
+ TQString m_workgroup;
/**
* The IP address
*/
- QString m_ip;
+ TQString m_ip;
/**
* The type of the share;
*/
- QString m_type;
+ TQString m_type;
/**
* The bookmark string.
*/
- QString m_bookmark;
+ TQString m_bookmark;
/**
* The alternative label
*/
- QString m_label;
+ TQString m_label;
/**
* This function checks if the IP address is valid, i.e. the
@@ -206,7 +206,7 @@ class Smb4KBookmark
*
* @returns TRUE if the IP address is valid and FALSE otherwise.
*/
- bool ipIsValid( const QString &ip );
+ bool ipIsValid( const TQString &ip );
};
#endif
diff --git a/smb4k/core/smb4kbookmarkhandler.cpp b/smb4k/core/smb4kbookmarkhandler.cpp
index 113d601..6d5d253 100644
--- a/smb4k/core/smb4kbookmarkhandler.cpp
+++ b/smb4k/core/smb4kbookmarkhandler.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qdir.h>
-#include <qfile.h>
+// TQt includes
+#include <tqdir.h>
+#include <tqfile.h>
// KDE includes
#include <kstandarddirs.h>
@@ -47,13 +47,13 @@
using namespace Smb4KGlobal;
-Smb4KBookmarkHandler::Smb4KBookmarkHandler( QValueList<Smb4KHostItem *> *hosts,
-QObject *parent, const char *name )
-: QObject( parent, name ), m_hosts( hosts )
+Smb4KBookmarkHandler::Smb4KBookmarkHandler( TQValueList<Smb4KHostItem *> *hosts,
+TQObject *tqparent, const char *name )
+: TQObject( tqparent, name ), m_hosts( hosts )
{
// First we need the directory.
KStandardDirs *stddir = new KStandardDirs();
- QString dir = locateLocal( "data", "smb4k", KGlobal::instance() );
+ TQString dir = locateLocal( "data", "smb4k", KGlobal::instance() );
if ( !stddir->exists( dir ) )
{
@@ -68,7 +68,7 @@ QObject *parent, const char *name )
Smb4KBookmarkHandler::~Smb4KBookmarkHandler()
{
- for ( QValueList<Smb4KBookmark *>::Iterator it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
+ for ( TQValueList<Smb4KBookmark *>::Iterator it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
{
delete *it;
}
@@ -88,15 +88,15 @@ void Smb4KBookmarkHandler::addBookmark( Smb4KBookmark *bookmark )
return;
}
- if ( QString::compare( bookmark->type(), "Printer" ) == 0 )
+ if ( TQString::compare( bookmark->type(), "Printer" ) == 0 )
{
Smb4KError::error( ERROR_BOOKMARK_PRINTER );
return;
}
- if ( QString::compare( bookmark->share(), "homes" ) == 0 )
+ if ( TQString::compare( bookmark->share(), "homes" ) == 0 )
{
- QString share = specifyUser( bookmark->host(), kapp->mainWidget() ? kapp->mainWidget() : 0, "SpecifyUser" );
+ TQString share = specifyUser( bookmark->host(), kapp->mainWidget() ? kapp->mainWidget() : 0, "SpecifyUser" );
bookmark->setShareName( share );
}
@@ -106,7 +106,7 @@ void Smb4KBookmarkHandler::addBookmark( Smb4KBookmark *bookmark )
if ( result )
{
- if ( QString::compare( result->workgroup().upper(), bookmark->workgroup().upper() ) == 0 )
+ if ( TQString::compare( result->workgroup().upper(), bookmark->workgroup().upper() ) == 0 )
{
// It's the same bookmark. We'll update it in a very
// brutal but efficient way:
@@ -130,11 +130,11 @@ void Smb4KBookmarkHandler::addBookmark( Smb4KBookmark *bookmark )
}
-void Smb4KBookmarkHandler::writeBookmarkList( const QValueList<Smb4KBookmark *> &list )
+void Smb4KBookmarkHandler::writeBookmarkList( const TQValueList<Smb4KBookmark *> &list )
{
if ( list != m_bookmarks )
{
- for ( QValueListIterator<Smb4KBookmark *> it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
+ for ( TQValueListIterator<Smb4KBookmark *> it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
{
delete *it;
}
@@ -144,28 +144,28 @@ void Smb4KBookmarkHandler::writeBookmarkList( const QValueList<Smb4KBookmark *>
m_bookmarks = list;
}
- QFile file( locateLocal( "data", "smb4k/bookmarks", KGlobal::instance() ) );
+ TQFile file( locateLocal( "data", "smb4k/bookmarks", KGlobal::instance() ) );
if ( file.open( IO_WriteOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
int serial_number = 0;
- for ( QValueListConstIterator<Smb4KBookmark *> it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
+ for ( TQValueListConstIterator<Smb4KBookmark *> it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
{
if ( !(*it)->label().isEmpty() )
{
Smb4KBookmark *result = findBookmarkByLabel( (*it)->label() );
if ( result &&
- (QString::compare( result->bookmark().upper(), (*it)->bookmark().upper() ) != 0 ||
- QString::compare( result->workgroup().upper(), (*it)->workgroup().upper() ) != 0) )
+ (TQString::compare( result->bookmark().upper(), (*it)->bookmark().upper() ) != 0 ||
+ TQString::compare( result->workgroup().upper(), (*it)->workgroup().upper() ) != 0) )
{
Smb4KError::information( INFO_BOOKMARK_LABEL_IN_USE, (*it)->label(), (*it)->bookmark() );
- (*it)->setLabel( QString( "%1 (%2)" ).arg( (*it)->label() ).arg( serial_number++ ) );
+ (*it)->setLabel( TQString( "%1 (%2)" ).tqarg( (*it)->label() ).tqarg( serial_number++ ) );
}
}
@@ -180,7 +180,7 @@ void Smb4KBookmarkHandler::writeBookmarkList( const QValueList<Smb4KBookmark *>
}
else
{
- Smb4KError::error( ERROR_WRITING_FILE, QDir::currentDirPath()+"/"+file.name() );
+ Smb4KError::error( ERROR_WRITING_FILE, TQDir::currentDirPath()+"/"+file.name() );
return;
}
@@ -190,23 +190,23 @@ void Smb4KBookmarkHandler::writeBookmarkList( const QValueList<Smb4KBookmark *>
void Smb4KBookmarkHandler::loadBookmarks()
{
- QFile file( locateLocal( "data", "smb4k/bookmarks", KGlobal::instance() ) );
+ TQFile file( locateLocal( "data", "smb4k/bookmarks", KGlobal::instance() ) );
- QStringList contents;
+ TQStringList contents;
if ( file.open( IO_ReadOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- contents = QStringList::split( '\n', ts.read(), false );
+ contents = TQStringList::split( '\n', ts.read(), false );
file.close();
- for ( QStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
+ for ( TQStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
{
if ( (*it).startsWith( "#" ) || (*it).startsWith( "[" ) ||
- QString::compare( (*it).stripWhiteSpace(), QString::null ) == 0 )
+ TQString::compare( (*it).stripWhiteSpace(), TQString() ) == 0 )
{
continue;
}
@@ -215,16 +215,16 @@ void Smb4KBookmarkHandler::loadBookmarks()
// Load old bookmark entries (prior to version 0.7.0)
if ( ((*it).stripWhiteSpace())[0].isDigit() )
{
- QString bookmark = (*it).section( "=", 1, -1 ).stripWhiteSpace();
- m_bookmarks.append( new Smb4KBookmark( bookmark.section( "/", 2, 2 ).stripWhiteSpace(), bookmark.section( "/", 3, 3 ).stripWhiteSpace(), QString::null, QString::null, "Disk" ) );
+ TQString bookmark = (*it).section( "=", 1, -1 ).stripWhiteSpace();
+ m_bookmarks.append( new Smb4KBookmark( bookmark.section( "/", 2, 2 ).stripWhiteSpace(), bookmark.section( "/", 3, 3 ).stripWhiteSpace(), TQString(), TQString(), "Disk" ) );
}
else
{
- QString host = (*it).section( ",", 0, 0 ).stripWhiteSpace();
- QString share = (*it).section( ",", 1, 1 ).stripWhiteSpace();
- QString workgroup = (*it).section( ",", 2, 2 ).stripWhiteSpace();
- QString ip = (*it).section( ",", 3, 3 ).stripWhiteSpace();
- QString label = (*it).section( ",", 4, 4 ).stripWhiteSpace();
+ TQString host = (*it).section( ",", 0, 0 ).stripWhiteSpace();
+ TQString share = (*it).section( ",", 1, 1 ).stripWhiteSpace();
+ TQString workgroup = (*it).section( ",", 2, 2 ).stripWhiteSpace();
+ TQString ip = (*it).section( ",", 3, 3 ).stripWhiteSpace();
+ TQString label = (*it).section( ",", 4, 4 ).stripWhiteSpace();
m_bookmarks.append( new Smb4KBookmark( host, share, workgroup, ip, "Disk", label ) );
}
@@ -247,17 +247,17 @@ void Smb4KBookmarkHandler::loadBookmarks()
}
-Smb4KBookmark *Smb4KBookmarkHandler::findBookmarkByName( const QString &bookmark )
+Smb4KBookmark *Smb4KBookmarkHandler::findBookmarkByName( const TQString &bookmark )
{
// Update the bookmarks:
update();
// Find the bookmark:
- QValueListConstIterator<Smb4KBookmark *> it;
+ TQValueListConstIterator<Smb4KBookmark *> it;
for ( it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
{
- if ( QString::compare( (*it)->bookmark().upper(), bookmark.upper() ) == 0 )
+ if ( TQString::compare( (*it)->bookmark().upper(), bookmark.upper() ) == 0 )
{
break;
}
@@ -267,17 +267,17 @@ Smb4KBookmark *Smb4KBookmarkHandler::findBookmarkByName( const QString &bookmark
}
-Smb4KBookmark *Smb4KBookmarkHandler::findBookmarkByLabel( const QString &label )
+Smb4KBookmark *Smb4KBookmarkHandler::findBookmarkByLabel( const TQString &label )
{
// Update the bookmarks:
update();
// Find the bookmark:
- QValueListConstIterator<Smb4KBookmark *> it;
+ TQValueListConstIterator<Smb4KBookmark *> it;
for ( it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
{
- if ( QString::compare( (*it)->label().upper(), label.upper() ) == 0 )
+ if ( TQString::compare( (*it)->label().upper(), label.upper() ) == 0 )
{
break;
}
@@ -287,7 +287,7 @@ Smb4KBookmark *Smb4KBookmarkHandler::findBookmarkByLabel( const QString &label )
}
-const QValueList<Smb4KBookmark *> &Smb4KBookmarkHandler::getBookmarks()
+const TQValueList<Smb4KBookmark *> &Smb4KBookmarkHandler::getBookmarks()
{
// Update the bookmarks:
update();
@@ -307,18 +307,18 @@ void Smb4KBookmarkHandler::update()
}
// Search the list of hosts for new IP addresses:
- for ( QValueList<Smb4KBookmark *>::Iterator it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
+ for ( TQValueList<Smb4KBookmark *>::Iterator it = m_bookmarks.begin(); it != m_bookmarks.end(); ++it )
{
- for ( QValueList<Smb4KHostItem *>::ConstIterator i = m_hosts->begin(); i != m_hosts->end(); ++i )
+ for ( TQValueList<Smb4KHostItem *>::ConstIterator i = m_hosts->begin(); i != m_hosts->end(); ++i )
{
- if ( QString::compare( (*it)->workgroup().lower(), (*i)->workgroup().lower() ) != 0 )
+ if ( TQString::compare( (*it)->workgroup().lower(), (*i)->workgroup().lower() ) != 0 )
{
// Continue, if the workgroup is not the same:
continue;
}
else
{
- if ( QString::compare( (*it)->host().lower(), (*i)->name().lower() ) != 0 )
+ if ( TQString::compare( (*it)->host().lower(), (*i)->name().lower() ) != 0 )
{
// Continue if the host name is not the same:
continue;
@@ -327,7 +327,7 @@ void Smb4KBookmarkHandler::update()
{
// Set the IP address if it changed:
if ( !(*i)->ip().stripWhiteSpace().isEmpty() &&
- QString::compare( (*it)->ip(), (*i)->ip() ) != 0 )
+ TQString::compare( (*it)->ip(), (*i)->ip() ) != 0 )
{
(*it)->setIP( (*i)->ip() );
}
diff --git a/smb4k/core/smb4kbookmarkhandler.h b/smb4k/core/smb4kbookmarkhandler.h
index 56e7302..4e4f29f 100644
--- a/smb4k/core/smb4kbookmarkhandler.h
+++ b/smb4k/core/smb4kbookmarkhandler.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qvaluelist.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqvaluelist.h>
// forward declarations
class Smb4KHostItem;
@@ -46,9 +46,10 @@ class Smb4KBookmark;
* @author Alexander Reinholdt <dustpuppy@mail.berlios.de>
*/
-class Smb4KBookmarkHandler : public QObject
+class Smb4KBookmarkHandler : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -60,12 +61,12 @@ class Smb4KBookmarkHandler : public QObject
* In case a NULL pointer is passed, the bookmarks won't
* be updated.
*
- * @param parent The parent of this object
+ * @param tqparent The tqparent of this object
*
* @param name This object's name
*/
- Smb4KBookmarkHandler( QValueList<Smb4KHostItem *> *hosts = 0,
- QObject *parent = 0,
+ Smb4KBookmarkHandler( TQValueList<Smb4KHostItem *> *hosts = 0,
+ TQObject *tqparent = 0,
const char *name = 0 );
/**
@@ -93,7 +94,7 @@ class Smb4KBookmarkHandler : public QObject
* @param list The (new) list of bookmarks that is to be written
* to the bookmark file
*/
- void writeBookmarkList( const QValueList<Smb4KBookmark *> &list );
+ void writeBookmarkList( const TQValueList<Smb4KBookmark *> &list );
/**
* Get the list of bookmarks.
@@ -101,7 +102,7 @@ class Smb4KBookmarkHandler : public QObject
* @returns The current list of bookmarks stored in the
* bookmark file.
*/
- const QValueList<Smb4KBookmark *> &getBookmarks();
+ const TQValueList<Smb4KBookmark *> &getBookmarks();
/**
* This function searches for a bookmark using its name (//HOST/SHARE) and
@@ -113,7 +114,7 @@ class Smb4KBookmarkHandler : public QObject
* @returns The bookmark object that was searched for or NULL if it
* wasn't found.
*/
- Smb4KBookmark *findBookmarkByName( const QString &bookmark );
+ Smb4KBookmark *findBookmarkByName( const TQString &bookmark );
/**
* This function searches for a bookmark using its label and returns a pointer
@@ -124,7 +125,7 @@ class Smb4KBookmarkHandler : public QObject
* @returns The bookmark object that was searched for or NULL if it
* wasn't found.
*/
- Smb4KBookmark *findBookmarkByLabel( const QString &label );
+ Smb4KBookmark *findBookmarkByLabel( const TQString &label );
signals:
/**
@@ -136,7 +137,7 @@ class Smb4KBookmarkHandler : public QObject
/**
* The list of bookmarks.
*/
- QValueList<Smb4KBookmark *> m_bookmarks;
+ TQValueList<Smb4KBookmark *> m_bookmarks;
/**
* This function loads the list of bookmarks from the bookmarks file.
@@ -150,7 +151,7 @@ class Smb4KBookmarkHandler : public QObject
* This lis is a pointer to a global list of all known hosts. It
* is used to update the bookmarks.
*/
- QValueList<Smb4KHostItem *> *m_hosts;
+ TQValueList<Smb4KHostItem *> *m_hosts;
/**
* This function updates the data of the bookmarks, i.e. is searches for
diff --git a/smb4k/core/smb4kcore.cpp b/smb4k/core/smb4kcore.cpp
index 4bf835f..a2b5ebf 100644
--- a/smb4k/core/smb4kcore.cpp
+++ b/smb4k/core/smb4kcore.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qdir.h>
-#include <qmap.h>
-#include <qstringlist.h>
+// TQt includes
+#include <tqdir.h>
+#include <tqmap.h>
+#include <tqstringlist.h>
// KDE includes
#include <kdeversion.h>
@@ -59,7 +59,7 @@ Smb4KCore *Smb4KCore::m_self = 0;
static KStaticDeleter<Smb4KCore> staticSmb4KCoreDeleter;
-Smb4KCore::Smb4KCore() : QObject()
+Smb4KCore::Smb4KCore() : TQObject()
{
// Set default values for settings that depend on the system
// Smb4K is running on:
@@ -83,23 +83,23 @@ Smb4KCore::Smb4KCore() : QObject()
m_previewer_state = PREVIEWER_STOP;
// Connections:
- connect( m_scanner, SIGNAL( state( int ) ),
- this, SLOT( slotSetScannerState( int ) ) );
+ connect( m_scanner, TQT_SIGNAL( state( int ) ),
+ this, TQT_SLOT( slotSetScannerState( int ) ) );
- connect( m_mounter, SIGNAL( state( int ) ),
- this, SLOT( slotSetMounterState( int ) ) );
+ connect( m_mounter, TQT_SIGNAL( state( int ) ),
+ this, TQT_SLOT( slotSetMounterState( int ) ) );
- connect( m_print, SIGNAL( state( int ) ),
- this, SLOT( slotSetPrinterHandlerState( int ) ) );
+ connect( m_print, TQT_SIGNAL( state( int ) ),
+ this, TQT_SLOT( slotSetPrinterHandlerState( int ) ) );
- connect( m_synchronizer, SIGNAL( state( int ) ),
- this, SLOT( slotSetSynchronizerState( int ) ) );
+ connect( m_synchronizer, TQT_SIGNAL( state( int ) ),
+ this, TQT_SLOT( slotSetSynchronizerState( int ) ) );
- connect( m_previewer, SIGNAL( state( int ) ),
- this, SLOT( slotSetSynchronizerState( int ) ) );
+ connect( m_previewer, TQT_SIGNAL( state( int ) ),
+ this, TQT_SLOT( slotSetSynchronizerState( int ) ) );
- connect( kapp, SIGNAL( shutDown() ),
- this, SLOT( slotShutdown() ) );
+ connect( kapp, TQT_SIGNAL( shutDown() ),
+ this, TQT_SLOT( slotShutdown() ) );
}
@@ -109,7 +109,7 @@ Smb4KCore::~Smb4KCore()
// to crashes.
// Clear the list of workgroups.
- for ( QValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups.begin(); it != m_workgroups.end(); ++it )
+ for ( TQValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups.begin(); it != m_workgroups.end(); ++it )
{
delete *it;
}
@@ -117,7 +117,7 @@ Smb4KCore::~Smb4KCore()
m_workgroups.clear();
// Clear the list of hosts.
- for ( QValueList<Smb4KHostItem *>::Iterator it = m_hosts.begin(); it != m_hosts.end(); ++it )
+ for ( TQValueList<Smb4KHostItem *>::Iterator it = m_hosts.begin(); it != m_hosts.end(); ++it )
{
delete *it;
}
@@ -243,9 +243,9 @@ void Smb4KCore::open( Smb4KShare *share, int openWith )
#if KDE_VERSION_MAJOR == 3 && KDE_VERSION_MINOR <= 3 && KDE_VERSION_RELEASE <= 92
- if ( QString::compare( share->filesystem(), "cifs" ) == 0 )
+ if ( TQString::compare( share->filesystem(), "cifs" ) == 0 )
{
- if( KMessageBox::warningContinueCancel( (QWidget *)this, i18n( "Up to KDE 3.3.x, KIO and Konqueror cannot handle CIFS shares. Konqueror will hang if you try to access it.\nDo you want to continue?" ) ) == KMessageBox::Cancel )
+ if( KMessageBox::warningContinueCancel( (TQWidget *)this, i18n( "Up to KDE 3.3.x, KIO and Konqueror cannot handle CIFS shares. Konqueror will hang if you try to access it.\nDo you want to continue?" ) ) == KMessageBox::Cancel )
{
return;
}
@@ -297,19 +297,19 @@ void Smb4KCore::searchPrograms()
Smb4KSettings::self()->readConfig();
// List of paths that should be searched.
- QStringList path_list = QStringList::split( ":", QString( "%1" ).arg( getenv( "PATH" ) ), false );
+ TQStringList path_list = TQStringList::split( ":", TQString( "%1" ).tqarg( getenv( "PATH" ) ), false );
- if ( path_list.find( "/sbin" ) == path_list.end() )
+ if ( path_list.tqfind( "/sbin" ) == path_list.end() )
{
path_list << "/sbin";
}
- if ( path_list.find( "/usr/sbin" ) == path_list.end() )
+ if ( path_list.tqfind( "/usr/sbin" ) == path_list.end() )
{
path_list << "/usr/sbin";
}
- if ( path_list.find( "/usr/local/sbin" ) == path_list.end() )
+ if ( path_list.tqfind( "/usr/local/sbin" ) == path_list.end() )
{
path_list << "/usr/local/sbin";
}
@@ -317,8 +317,8 @@ void Smb4KCore::searchPrograms()
// Put all programs that are needed by Smb4K
// into the map below:
- QMap<QString /*name*/, bool /*located*/> program_list;
- QMap<QString /*name*/, QString /*absolute path*/> program_paths;
+ TQMap<TQString /*name*/, bool /*located*/> program_list;
+ TQMap<TQString /*name*/, TQString /*absolute path*/> program_paths;
// Mandatory programs:
program_list.insert( "grep", false );
@@ -356,17 +356,17 @@ void Smb4KCore::searchPrograms()
program_list.insert( "konsole", false );
- for ( QStringList::ConstIterator it = path_list.begin(); it != path_list.end(); ++it )
+ for ( TQStringList::ConstIterator it = path_list.begin(); it != path_list.end(); ++it )
{
- QDir::setCurrent( *it );
+ TQDir::setCurrent( *it );
- for ( QMap<QString, bool>::Iterator p = program_list.begin(); p != program_list.end(); ++p )
+ for ( TQMap<TQString, bool>::Iterator p = program_list.begin(); p != program_list.end(); ++p )
{
if ( p.data() == false ) // not located yet
{
- if ( QFile::exists( p.key() ) )
+ if ( TQFile::exists( p.key() ) )
{
- program_paths.insert( p.key(), QDir::currentDirPath()+QDir::separator()+p.key() );
+ program_paths.insert( p.key(), TQDir::currentDirPath()+TQDir::separator()+p.key() );
program_list[ p.key() ] = true;
}
else
@@ -382,7 +382,7 @@ void Smb4KCore::searchPrograms()
}
// Find out if Smb4K is to be starting up at all:
- QStringList missing;
+ TQStringList missing;
if ( !program_list["grep"] )
{
@@ -521,7 +521,7 @@ void Smb4KCore::searchPrograms()
// One of the two programs is at least present, so we can do
// it like this:
- QString filesystem;
+ TQString filesystem;
if ( program_list["mount.cifs"] )
{
@@ -561,7 +561,7 @@ void Smb4KCore::searchPrograms()
// One of the two programs is at least present, so we can do
// it like this:
- QString filesystem;
+ TQString filesystem;
if ( program_list["umount.cifs"] )
{
@@ -839,7 +839,7 @@ void Smb4KCore::searchPrograms()
void Smb4KCore::setDefaultSettings()
{
// Samba options that have to be dynamically imported from smb.conf:
- QMap<QString, QString> opts = optionsHandler()->globalSambaOptions();
+ TQMap<TQString, TQString> opts = optionsHandler()->globalSambaOptions();
if ( !opts["netbios name"].isEmpty() )
{
@@ -904,7 +904,7 @@ void Smb4KCore::setDefaultSettings()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KCore::slotSetScannerState( int state )
diff --git a/smb4k/core/smb4kcore.h b/smb4k/core/smb4kcore.h
index fbaa539..c6a2004 100644
--- a/smb4k/core/smb4kcore.h
+++ b/smb4k/core/smb4kcore.h
@@ -30,11 +30,11 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qmap.h>
-#include <qtimer.h>
-#include <qvaluelist.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqmap.h>
+#include <tqtimer.h>
+#include <tqvaluelist.h>
// application specific includes
#include "smb4kscanner.h"
@@ -57,9 +57,10 @@ class Smb4KShare;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KCore : public QObject
+class Smb4KCore : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -335,14 +336,14 @@ class Smb4KCore : public QObject
* the scanner and may be used by all other classes that are invoked
* by Smb4KCore.
*/
- QValueList<Smb4KWorkgroupItem *> m_workgroups;
+ TQValueList<Smb4KWorkgroupItem *> m_workgroups;
/**
* This is the list of remote hosts known to Smb4K. It is filled by
* the scanner and may be used by all other classes that are invoked
* by Smb4KCore.
*/
- QValueList<Smb4KHostItem *> m_hosts;
+ TQValueList<Smb4KHostItem *> m_hosts;
/**
* Set default values for settings that depend on the system Smb4K is
diff --git a/smb4k/core/smb4kerror.cpp b/smb4k/core/smb4kerror.cpp
index 66a3089..b8bffe1 100644
--- a/smb4k/core/smb4kerror.cpp
+++ b/smb4k/core/smb4kerror.cpp
@@ -31,7 +31,7 @@
#include "smb4kerror.h"
#include "smb4kdefs.h"
-void Smb4KError::error( int code, const QString &text, const QString &details )
+void Smb4KError::error( int code, const TQString &text, const TQString &details )
{
switch ( code )
{
@@ -89,7 +89,7 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
}
case ERROR_OPENING_WALLET_FAILED:
{
- KMessageBox::error( 0, i18n( "The wallet \"%1\" could not be opened. KWallet support will be disabled for this session." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The wallet \"%1\" could not be opened. KWallet support will be disabled for this session." ).tqarg( text ) );
break;
}
@@ -116,11 +116,11 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The share \"%1\" could not be mounted.\nDetailed information cannot be provided because there was no error message." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The share \"%1\" could not be mounted.\nDetailed information cannot be provided because there was no error message." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The share \"%1\" could not be mounted.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The share \"%1\" could not be mounted.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
@@ -129,18 +129,18 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The share \"%1\" could not be unmounted.\nDetailed information cannot be provided because there was no error message." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The share \"%1\" could not be unmounted.\nDetailed information cannot be provided because there was no error message." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The share \"%1\" could not be unmounted.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The share \"%1\" could not be unmounted.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
}
case ERROR_FILE_NOT_FOUND:
{
- KMessageBox::error( 0, i18n( "The file \"%1\" could not be found." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" could not be found." ).tqarg( text ) );
break;
}
@@ -148,11 +148,11 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The file \"%1\" could not be read." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" could not be read." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be read.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be read.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
@@ -172,25 +172,25 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
}
case ERROR_MISSING_PROGRAMS:
{
- KMessageBox::error( 0, i18n( "Either your PATH environment variable is not set properly or there are the following programs missing on your system:\n%1\nPlease correct this and restart Smb4K." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "Either your PATH environment variable is not set properly or there are the following programs missing on your system:\n%1\nPlease correct this and restart Smb4K." ).tqarg( text ) );
break;
}
case ERROR_LOCKED:
{
- KMessageBox::error( 0, i18n( "The file \"%1\" is currently being edited by user %2. To avoid any problems, access to this file is denied at the moment. Please try again later." ).arg( text.section( ":", 1, 1 ), text.section( ":", 0, 0 ) ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" is currently being edited by user %2. To avoid any problems, access to this file is denied at the moment. Please try again later." ).tqarg( text.section( ":", 1, 1 ), text.section( ":", 0, 0 ) ) );
break;
}
case ERROR_MKDIR_FAILED:
{
- KMessageBox::error( 0, i18n( "The directory \"%1\" could not be created." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The directory \"%1\" could not be created." ).tqarg( text ) );
break;
}
case ERROR_WRITING_FILE:
{
- KMessageBox::error( 0, i18n( "The file \"%1\" could not be written." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" could not be written." ).tqarg( text ) );
break;
}
@@ -233,7 +233,7 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
}
case ERROR_COMMAND_NOT_FOUND:
{
- KMessageBox::error( 0, i18n( "The command \"%1\" could not be found." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The command \"%1\" could not be found." ).tqarg( text ) );
break;
}
@@ -241,11 +241,11 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The file \"%1\" could not be printed.\nDetailed information cannot be provided because there was no error message." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" could not be printed.\nDetailed information cannot be provided because there was no error message." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be printed.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be printed.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
@@ -254,11 +254,11 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The temporary directory \"%1\" could not be created.\nDetailed information cannot be provided because there was no error message." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The temporary directory \"%1\" could not be created.\nDetailed information cannot be provided because there was no error message." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The temporary directory \"%1\" could not be created.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The temporary directory \"%1\" could not be created.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
@@ -267,24 +267,24 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The temporary file \"%1\" could not be created.\nDetailed information cannot be provided because there was no error message." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The temporary file \"%1\" could not be created.\nDetailed information cannot be provided because there was no error message." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The temporary file \"%1\" could not be created.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The temporary file \"%1\" could not be created.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
}
case ERROR_DIRECTORY_NOT_FOUND:
{
- KMessageBox::error( 0, i18n( "The directory \"%1\" could not be found." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The directory \"%1\" could not be found." ).tqarg( text ) );
break;
}
case ERROR_FILE_IS_IRREGULAR:
{
- KMessageBox::error( 0, i18n( "The file \"%1\" is irregular. That means it is either a symlink, a fifo, or something similar. This could indicate that someone is trying to exploit your system. Please inform your system administrator." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" is irregular. That means it is either a symlink, a fifo, or something similar. This could indicate that someone is trying to exploit your system. Please inform your system administrator." ).tqarg( text ) );
break;
}
@@ -305,11 +305,11 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The file \"%1\" could not be opened." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" could not be opened." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be opened.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be opened.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
@@ -318,18 +318,18 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
{
if ( details.stripWhiteSpace().isEmpty() )
{
- KMessageBox::error( 0, i18n( "The file \"%1\" could not be closed." ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The file \"%1\" could not be closed." ).tqarg( text ) );
}
else
{
- KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be closed.\nRead the error message under \"Details\" to find out more." ).arg( text ), details );
+ KMessageBox::detailedError( 0, i18n( "The file \"%1\" could not be closed.\nRead the error message under \"Details\" to find out more." ).tqarg( text ), details );
}
break;
}
case ERROR_NET_COMMAND:
{
- KMessageBox::error( 0, i18n( "The list of arguments for the \"net\" command could not be assembled.\nAt the moment it reads: %1" ).arg( text ) );
+ KMessageBox::error( 0, i18n( "The list of arguments for the \"net\" command could not be assembled.\nAt the moment it reads: %1" ).tqarg( text ) );
break;
}
@@ -364,7 +364,7 @@ void Smb4KError::error( int code, const QString &text, const QString &details )
}
-int Smb4KError::warning( int code, const QString &, const QString & )
+int Smb4KError::warning( int code, const TQString &, const TQString & )
{
switch ( code )
{
@@ -376,25 +376,25 @@ int Smb4KError::warning( int code, const QString &, const QString & )
}
-void Smb4KError::information( int code, const QString &text, const QString &details )
+void Smb4KError::information( int code, const TQString &text, const TQString &details )
{
switch ( code )
{
case INFO_MIMETYPE_NOT_SUPPORTED:
{
- KMessageBox::information( 0, i18n( "The mimetype \"%1\" is not supported. Please convert the file to PostScript or PDF." ).arg( text ) );
+ KMessageBox::information( 0, i18n( "The mimetype \"%1\" is not supported. Please convert the file to PostScript or PDF." ).tqarg( text ) );
break;
}
case INFO_DISABLE_SUID_FEATURE:
{
- KMessageBox::information( 0, i18n( "You previously chose to use \"%1\", but now it is missing on your system. Smb4K will disable this feature." ).arg( text ) );
+ KMessageBox::information( 0, i18n( "You previously chose to use \"%1\", but now it is missing on your system. Smb4K will disable this feature." ).tqarg( text ) );
break;
}
case INFO_BOOKMARK_LABEL_IN_USE:
{
- KMessageBox::information( 0, i18n( "The label \"%1\" is used more than once. It will automatically be renamed for bookmark \"%2\" to avoid confusion." ).arg( text, details ) );
+ KMessageBox::information( 0, i18n( "The label \"%1\" is used more than once. It will automatically be renamed for bookmark \"%2\" to avoid confusion." ).tqarg( text, details ) );
break;
}
@@ -405,4 +405,4 @@ void Smb4KError::information( int code, const QString &text, const QString &deta
}
}
-// No moc file needs to be included
+// No tqmoc file needs to be included
diff --git a/smb4k/core/smb4kerror.h b/smb4k/core/smb4kerror.h
index fb5f980..5b4eac9 100644
--- a/smb4k/core/smb4kerror.h
+++ b/smb4k/core/smb4kerror.h
@@ -48,8 +48,8 @@ class Smb4KError
* it depends on the kind of error if it is indeed shown.
*/
static void error( int code,
- const QString &text = QString::null,
- const QString &details = QString::null );
+ const TQString &text = TQString(),
+ const TQString &details = TQString() );
/**
* Show a warning.
@@ -68,8 +68,8 @@ class Smb4KError
* is unknown.
*/
static int warning( int code,
- const QString &text = QString::null,
- const QString &details = QString::null );
+ const TQString &text = TQString(),
+ const TQString &details = TQString() );
/**
* Show an information.
@@ -85,8 +85,8 @@ class Smb4KError
* it depends on the kind of error if it is indeed shown.
*/
static void information( int code,
- const QString &text = QString::null,
- const QString &details = QString::null );
+ const TQString &text = TQString(),
+ const TQString &details = TQString() );
};
#endif
diff --git a/smb4k/core/smb4kfileio.cpp b/smb4k/core/smb4kfileio.cpp
index 2b77cf5..f50db01 100644
--- a/smb4k/core/smb4kfileio.cpp
+++ b/smb4k/core/smb4kfileio.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qdir.h>
-#include <qfile.h>
-#include <qtextstream.h>
+// TQt includes
+#include <tqdir.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
// KDE includes
#include <kapplication.h>
@@ -54,7 +54,7 @@ using namespace Smb4KGlobal;
-Smb4KFileIO::Smb4KFileIO( QObject *parent, const char *name ) : QObject( parent, name )
+Smb4KFileIO::Smb4KFileIO( TQObject *tqparent, const char *name ) : TQObject( tqparent, name )
{
m_operation = NoOperation;
m_state = Idle;
@@ -63,17 +63,17 @@ Smb4KFileIO::Smb4KFileIO( QObject *parent, const char *name ) : QObject( parent,
m_proc = new KProcess( this, "FileIOProcess" );
m_proc->setUseShell( true );
- connect( m_proc, SIGNAL( receivedStderr( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStderr( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( processExited( KProcess * ) ),
- this, SLOT( slotProcessExited( KProcess * ) ) );
+ connect( m_proc, TQT_SIGNAL( processExited( KProcess * ) ),
+ this, TQT_SLOT( slotProcessExited( KProcess * ) ) );
- connect( kapp, SIGNAL( shutDown() ),
- this, SLOT( slotShutdown() ) );
+ connect( kapp, TQT_SIGNAL( shutDown() ),
+ this, TQT_SLOT( slotShutdown() ) );
}
@@ -97,12 +97,12 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
return ok;
}
- QString file = "sudoers";
+ TQString file = "sudoers";
if ( createLockFile( file ) )
{
// Find the file first:
- QCString canonical_path = findFile( file );
+ TQCString canonical_path = findFile( file );
if ( !canonical_path.isEmpty() )
{
@@ -135,7 +135,7 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_GIDS, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_GIDS, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -164,7 +164,7 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
// I don't care!
if ( !S_ISREG( buf.st_mode ) || S_ISFIFO( buf.st_mode ) || S_ISLNK( buf.st_mode ) )
{
- Smb4KError::error( ERROR_FILE_IS_IRREGULAR, canonical_path, QString::null );
+ Smb4KError::error( ERROR_FILE_IS_IRREGULAR, canonical_path, TQString() );
emit failed();
emit finished();
@@ -181,15 +181,15 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
{
// The user has read and write access.
- QFile file ( canonical_path );
- QStringList contents;
+ TQFile file ( canonical_path );
+ TQStringList contents;
if ( file.open( IO_ReadWrite ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- contents = QStringList::split( "\n", ts.read(), true );
+ contents = TQStringList::split( "\n", ts.read(), true );
bool write = false;
@@ -203,7 +203,7 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
if ( gethostname( hn, hostnamelen ) == -1 )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_HOSTNAME, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_HOSTNAME, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -213,7 +213,7 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
return ok; // false
}
- QString hostname( hn );
+ TQString hostname( hn );
delete [] hn;
@@ -221,7 +221,7 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
{
contents.append( "# Entries for Smb4K users." );
contents.append( "# Generated by Smb4K. Please do not modify!" );
- contents.append( "User_Alias\tSMB4KUSERS = "+QString( "%1" ).arg( getpwuid( getuid() )->pw_name ) );
+ contents.append( "User_Alias\tSMB4KUSERS = "+TQString( "%1" ).tqarg( getpwuid( getuid() )->pw_name ) );
contents.append( "Defaults:SMB4KUSERS\tenv_keep += \"PASSWD USER\"" );
contents.append( "SMB4KUSERS\t"+hostname+" = NOPASSWD: "+Smb4KSettings::smb4k_kill() );
contents.append( "SMB4KUSERS\t"+hostname+" = NOPASSWD: "+Smb4KSettings::smb4k_umount() );
@@ -234,14 +234,14 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
{
// Find the beginning and the end of the entries in
// the sudoers file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
- if ( (*it).startsWith( "User_Alias\tSMB4KUSERS" ) && (*it).contains( getpwuid( getuid() )->pw_name, true ) == 0 )
+ if ( (*it).startsWith( "User_Alias\tSMB4KUSERS" ) && (*it).tqcontains( getpwuid( getuid() )->pw_name, true ) == 0 )
{
- (*it).append( ","+QString( getpwuid( getuid() )->pw_name ) );
+ (*it).append( ","+TQString( getpwuid( getuid() )->pw_name ) );
write = true;
@@ -260,22 +260,22 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
{
// Find the beginning and the end of the entries in
// the sudoers file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
// Now, check if the user is in the list of users. If he is,
// remove him from there or remove all if he is the only one:
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
if ( (*it).startsWith( "User_Alias\tSMB4KUSERS" ) )
{
- QString users = (*it).section( "=", 1, 1 ).stripWhiteSpace();
+ TQString users = (*it).section( "=", 1, 1 ).stripWhiteSpace();
- if ( users.contains( "," ) == 0 )
+ if ( users.tqcontains( "," ) == 0 )
{
// In this case, there is only one user in the list. Check if
// it is the user who requested the removal:
- if ( QString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
+ if ( TQString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
{
// They are equal. Remove everything:
contents.erase( begin, end );
@@ -295,10 +295,10 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
{
// In this case there is more than one user in the list.
// Remove the user who requested the removal:
- QStringList list = QStringList::split( ",", users, false );
+ TQStringList list = TQStringList::split( ",", users, false );
list.remove( getpwuid( getuid() )->pw_name );
- (*it).replace( users, list.join( "," ) );
+ (*it).tqreplace( users, list.join( "," ) );
write = true;
@@ -329,7 +329,7 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
if ( write )
{
// Prepare the contents: remove empty lines from the end.
- QStringList::Iterator it = contents.end();
+ TQStringList::Iterator it = contents.end();
// Move the iterator to the last entry in the list:
--it;
@@ -378,7 +378,7 @@ bool Smb4KFileIO::writeSudoers( Smb4KFileIO::Operation operation )
// kdesu to get the contents of the file.
// Compose the command:
- QString command;
+ TQString command;
command.append( "kdesu -t -c \"smb4k_cat " );
command.append( canonical_path+"\"" );
command.append( " ; sleep 2" );
@@ -439,12 +439,12 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
return ok;
}
- QString file = "super.tab";
+ TQString file = "super.tab";
if ( createLockFile( file ) )
{
// Find the file first:
- QCString canonical_path = findFile( file );
+ TQCString canonical_path = findFile( file );
if ( !canonical_path.isEmpty() )
{
@@ -477,7 +477,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_GIDS, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_GIDS, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -506,7 +506,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
// I don't care!
if ( !S_ISREG( buf.st_mode ) || S_ISFIFO( buf.st_mode ) || S_ISLNK( buf.st_mode ) )
{
- Smb4KError::error( ERROR_FILE_IS_IRREGULAR, canonical_path, QString::null );
+ Smb4KError::error( ERROR_FILE_IS_IRREGULAR, canonical_path, TQString() );
emit failed();
emit finished();
@@ -523,15 +523,15 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
{
// The user has read and write access.
- QFile file ( canonical_path );
- QStringList contents;
+ TQFile file ( canonical_path );
+ TQStringList contents;
if ( file.open( IO_ReadWrite ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- contents = QStringList::split( "\n", ts.read(), true );
+ contents = TQStringList::split( "\n", ts.read(), true );
bool write = false;
@@ -545,7 +545,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
if ( gethostname( hn, hostnamelen ) == -1 )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_HOSTNAME, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_HOSTNAME, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -555,7 +555,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
return ok; // false
}
- QString hostname( hn );
+ TQString hostname( hn );
delete [] hn;
@@ -563,7 +563,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
{
contents.append( "# Entries for Smb4K users." );
contents.append( "# Generated by Smb4K. Please do not modify!" );
- contents.append( ":define Smb4KUsers "+QString( "%1" ).arg( getpwuid( getuid() )->pw_name ) );
+ contents.append( ":define Smb4KUsers "+TQString( "%1" ).tqarg( getpwuid( getuid() )->pw_name ) );
#ifndef __FreeBSD__
contents.append( "smb4k_kill\t"+Smb4KSettings::smb4k_kill()+
"\t$(Smb4KUsers)\tuid=root\tgid=root" );
@@ -587,14 +587,14 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
{
// Find the beginning and the end of the entries in
// the super.tab file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
- if ( (*it).startsWith( ":define Smb4KUsers" ) && (*it).contains( getpwuid( getuid() )->pw_name, true ) == 0 )
+ if ( (*it).startsWith( ":define Smb4KUsers" ) && (*it).tqcontains( getpwuid( getuid() )->pw_name, true ) == 0 )
{
- (*it).append( ","+QString( getpwuid( getuid() )->pw_name ) );
+ (*it).append( ","+TQString( getpwuid( getuid() )->pw_name ) );
write = true;
@@ -613,22 +613,22 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
{
// Find the beginning and the end of the entries in
// the super.tab file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
// Now, check if the user is in the list of users. If he is,
// remove him from there or remove all if he is the only one:
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
if ( (*it).startsWith( ":define Smb4KUsers" ) )
{
- QString users = (*it).section( "Smb4KUsers", 1, 1 ).stripWhiteSpace();
+ TQString users = (*it).section( "Smb4KUsers", 1, 1 ).stripWhiteSpace();
- if ( users.contains( "," ) == 0 )
+ if ( users.tqcontains( "," ) == 0 )
{
// In this case, there is only one user in the list. Check if
// it is the user who requested the removal:
- if ( QString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
+ if ( TQString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
{
// They are equal. Remove everything:
contents.erase( begin, end );
@@ -648,10 +648,10 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
{
// In this case there is more than one user in the list.
// Remove the user who requested the removal:
- QStringList list = QStringList::split( ",", users, false );
+ TQStringList list = TQStringList::split( ",", users, false );
list.remove( getpwuid( getuid() )->pw_name );
- (*it).replace( users, list.join( "," ) );
+ (*it).tqreplace( users, list.join( "," ) );
write = true;
@@ -682,7 +682,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
if ( write )
{
// Prepare the contents: remove empty lines from the end.
- QStringList::Iterator it = contents.end();
+ TQStringList::Iterator it = contents.end();
// Move the iterator to the last entry in the list:
--it;
@@ -731,7 +731,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
// kdesu to get the contents of the file.
// Compose the command:
- QString command;
+ TQString command;
command.append( "kdesu -t -c \"smb4k_cat " );
command.append( canonical_path+"\"" );
command.append( " ; sleep 2" );
@@ -777,7 +777,7 @@ bool Smb4KFileIO::writeSuperTab( Smb4KFileIO::Operation operation )
}
-bool Smb4KFileIO::createLockFile( const QString &filename )
+bool Smb4KFileIO::createLockFile( const TQString &filename )
{
bool ok = false;
@@ -786,12 +786,12 @@ bool Smb4KFileIO::createLockFile( const QString &filename )
// back to /tmp.
if ( m_lock_file.isEmpty() )
{
- QValueList<QCString> dirs;
+ TQValueList<TQCString> dirs;
dirs << "/var/lock" << "/var/tmp" << "/tmp";
struct stat buf;
- for ( QValueList<QCString>::ConstIterator it = dirs.begin(); it != dirs.end(); ++it )
+ for ( TQValueList<TQCString>::ConstIterator it = dirs.begin(); it != dirs.end(); ++it )
{
// First check if the directory is available and writable
if ( lstat( *it, &buf ) == -1 )
@@ -817,7 +817,7 @@ bool Smb4KFileIO::createLockFile( const QString &filename )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_GIDS, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_GIDS, TQString(), strerror( error_number ) );
return ok; // false
}
@@ -880,7 +880,7 @@ bool Smb4KFileIO::createLockFile( const QString &filename )
int error_number = errno;
// FIXME for >= 0.8.x: Change error code to ERROR_GETTING_STAT
- Smb4KError::error( ERROR_GETTING_PERMISSIONS, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_PERMISSIONS, TQString(), strerror( error_number ) );
return ok;
}
@@ -920,14 +920,14 @@ bool Smb4KFileIO::createLockFile( const QString &filename )
if ( size >= 1000 )
{
// FIXME for >= 0.8.x: Change error code to ERROR_BUFFER_EXCEEDED
- Smb4KError::error( ERROR_UNKNOWN, QString::null, i18n( "Buffer size exceeded" ) );
+ Smb4KError::error( ERROR_UNKNOWN, TQString(), i18n( "Buffer size exceeded" ) );
return ok; // false
}
- QStringList contents = QStringList::split( '\n', QString::fromLocal8Bit( buffer, size ), false );
- QString test_string = ":"+filename;
- QString entry = contents.grep( test_string, true ).join( "\n" ).stripWhiteSpace();
+ TQStringList contents = TQStringList::split( '\n', TQString::fromLocal8Bit( buffer, size ), false );
+ TQString test_string = ":"+filename;
+ TQString entry = contents.grep( test_string, true ).join( "\n" ).stripWhiteSpace();
if ( !entry.isEmpty() )
{
@@ -937,8 +937,8 @@ bool Smb4KFileIO::createLockFile( const QString &filename )
}
else
{
- contents << QString( "%1:%2" ).arg( getpwuid( getuid() )->pw_name ).arg( filename );
- QCString out = contents.join( "\n" ).local8Bit();
+ contents << TQString( "%1:%2" ).tqarg( getpwuid( getuid() )->pw_name ).tqarg( filename );
+ TQCString out = contents.join( "\n" ).local8Bit();
if ( write( file_descriptor, out, out.length() ) == -1 )
{
@@ -1002,7 +1002,7 @@ bool Smb4KFileIO::removeLockFile( const bool error_message )
if ( error_message )
{
// FIXME for >= 0.8.x: Change error code to ERROR_GETTING_STAT
- Smb4KError::error( ERROR_GETTING_PERMISSIONS, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_PERMISSIONS, TQString(), strerror( error_number ) );
}
return ok;
@@ -1054,21 +1054,21 @@ bool Smb4KFileIO::removeLockFile( const bool error_message )
if ( error_message )
{
// FIXME for >= 0.8.x: Change error code to ERROR_BUFFER_EXCEEDED
- Smb4KError::error( ERROR_UNKNOWN, QString::null, i18n( "Buffer size exceeded" ) );
+ Smb4KError::error( ERROR_UNKNOWN, TQString(), i18n( "Buffer size exceeded" ) );
}
return ok; // false
}
- QStringList contents = QStringList::split( '\n', QString::fromLocal8Bit( buffer, size ), false );
+ TQStringList contents = TQStringList::split( '\n', TQString::fromLocal8Bit( buffer, size ), false );
// Prepare the contents of the file and write it to the disk.
// It it should be empty, remove the lock file.
- for ( QStringList::Iterator it = contents.begin(); it != contents.end(); it++ )
+ for ( TQStringList::Iterator it = contents.begin(); it != contents.end(); it++ )
{
- if ( (*it).startsWith( QString( getpwuid( getuid() )->pw_name )+":" ) )
+ if ( (*it).startsWith( TQString( getpwuid( getuid() )->pw_name )+":" ) )
{
- *it = QString::null;
+ *it = TQString();
continue;
}
@@ -1078,13 +1078,13 @@ bool Smb4KFileIO::removeLockFile( const bool error_message )
}
}
- contents.remove( QString::null );
+ contents.remove( TQString() );
if ( !contents.isEmpty() )
{
// Write the remaining contents to the lock file:
- QCString out = contents.join( "\n" ).local8Bit();
+ TQCString out = contents.join( "\n" ).local8Bit();
if ( write( file_descriptor, out, out.length() ) == -1 )
{
@@ -1150,23 +1150,23 @@ bool Smb4KFileIO::removeLockFile( const bool error_message )
}
-const QCString Smb4KFileIO::findFile( const QString &filename )
+const TQCString Smb4KFileIO::findFile( const TQString &filename )
{
- QStringList paths;
+ TQStringList paths;
paths << "/etc";
paths << "/etc/samba";
paths << "/usr/local/etc";
paths << "/usr/local/etc/samba";
- QString canonical_path = QString::null;
+ TQString canonical_path = TQString();
- for ( QStringList::ConstIterator it = paths.begin(); it != paths.end(); it++ )
+ for ( TQStringList::ConstIterator it = paths.begin(); it != paths.end(); it++ )
{
- QDir::setCurrent( *it );
+ TQDir::setCurrent( *it );
- if ( QFile::exists( filename ) )
+ if ( TQFile::exists( filename ) )
{
- canonical_path = QDir::current().canonicalPath()+"/"+filename;
+ canonical_path = TQDir::current().canonicalPath()+"/"+filename;
break;
}
@@ -1195,7 +1195,7 @@ void Smb4KFileIO::processSudoers()
return;
}
- QStringList contents = QStringList::split( "\n", m_buffer, true );
+ TQStringList contents = TQStringList::split( "\n", m_buffer, true );
bool write = false;
switch ( m_operation )
@@ -1208,7 +1208,7 @@ void Smb4KFileIO::processSudoers()
if ( gethostname( hn, hostnamelen ) == -1 )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_HOSTNAME, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_HOSTNAME, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -1216,7 +1216,7 @@ void Smb4KFileIO::processSudoers()
removeLockFile();
}
- QString hostname( hn );
+ TQString hostname( hn );
delete [] hn;
@@ -1224,7 +1224,7 @@ void Smb4KFileIO::processSudoers()
{
contents.append( "# Entries for Smb4K users." );
contents.append( "# Generated by Smb4K. Please do not modify!" );
- contents.append( "User_Alias\tSMB4KUSERS = "+QString( "%1" ).arg( getpwuid( getuid() )->pw_name ) );
+ contents.append( "User_Alias\tSMB4KUSERS = "+TQString( "%1" ).tqarg( getpwuid( getuid() )->pw_name ) );
contents.append( "Defaults:SMB4KUSERS\tenv_keep += \"PASSWD USER\"" );
contents.append( "SMB4KUSERS\t"+hostname+" = NOPASSWD: "+Smb4KSettings::smb4k_kill() );
contents.append( "SMB4KUSERS\t"+hostname+" = NOPASSWD: "+Smb4KSettings::smb4k_umount() );
@@ -1237,14 +1237,14 @@ void Smb4KFileIO::processSudoers()
{
// Find the beginning and the end of the entries in
// the sudoers file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
- if ( (*it).startsWith( "User_Alias\tSMB4KUSERS" ) && (*it).contains( getpwuid( getuid() )->pw_name, true ) == 0 )
+ if ( (*it).startsWith( "User_Alias\tSMB4KUSERS" ) && (*it).tqcontains( getpwuid( getuid() )->pw_name, true ) == 0 )
{
- (*it).append( ","+QString( getpwuid( getuid() )->pw_name ) );
+ (*it).append( ","+TQString( getpwuid( getuid() )->pw_name ) );
write = true;
@@ -1263,22 +1263,22 @@ void Smb4KFileIO::processSudoers()
{
// Find the beginning and the end of the entries in
// the sudoers file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
// Now, check if the user is in the list of users. If he is,
// remove him from there or remove all if he is the only one:
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
if ( (*it).startsWith( "User_Alias\tSMB4KUSERS" ) )
{
- QString users = (*it).section( "=", 1, 1 ).stripWhiteSpace();
+ TQString users = (*it).section( "=", 1, 1 ).stripWhiteSpace();
- if ( users.contains( "," ) == 0 )
+ if ( users.tqcontains( "," ) == 0 )
{
// In this case, there is only one user in the list. Check if
// it is the user who requested the removal:
- if ( QString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
+ if ( TQString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
{
// They are equal. Remove everything:
contents.erase( begin, end );
@@ -1298,10 +1298,10 @@ void Smb4KFileIO::processSudoers()
{
// In this case there is more than one user in the list.
// Remove the user who requested the removal:
- QStringList list = QStringList::split( ",", users, false );
+ TQStringList list = TQStringList::split( ",", users, false );
list.remove( getpwuid( getuid() )->pw_name );
- (*it).replace( users, list.join( "," ) );
+ (*it).tqreplace( users, list.join( "," ) );
write = true;
@@ -1330,7 +1330,7 @@ void Smb4KFileIO::processSudoers()
if ( write )
{
// Prepare the contents: remove empty lines from the end.
- QStringList::Iterator it = contents.end();
+ TQStringList::Iterator it = contents.end();
// Move the iterator to the last entry in the list:
--it;
@@ -1342,11 +1342,11 @@ void Smb4KFileIO::processSudoers()
}
// Create a temporary file and write the data to it:
- QCString template_string = tempDir().local8Bit()+"/XXXXXX";
+ TQCString template_string = tempDir().local8Bit()+"/XXXXXX";
char tmp[template_string.length()+1];
(void) qstrncpy( tmp, template_string, template_string.length()+1 );
- QFile temp_file;
+ TQFile temp_file;
int file_descriptor;
if ( (file_descriptor = mkstemp( tmp )) == -1 )
@@ -1365,8 +1365,8 @@ void Smb4KFileIO::processSudoers()
if ( temp_file.open( IO_WriteOnly, file_descriptor ) )
{
- QTextStream ts( &temp_file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &temp_file );
+ ts.setEncoding( TQTextStream::Locale );
ts << contents.join( "\n" ) << endl;
@@ -1386,14 +1386,14 @@ void Smb4KFileIO::processSudoers()
// Now move the file to the right location. Preserve the permissions
// and the owner:
- QString canonical_path = findFile( "sudoers" );
+ TQString canonical_path = findFile( "sudoers" );
struct stat file_stat;
if ( stat( canonical_path.local8Bit(), &file_stat ) == -1 )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_PERMISSIONS, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_PERMISSIONS, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -1403,14 +1403,14 @@ void Smb4KFileIO::processSudoers()
return;
}
- QString perms = QString( "%1" ).arg( (int)file_stat.st_mode, 0, 8 );
+ TQString perms = TQString( "%1" ).tqarg( (int)file_stat.st_mode, 0, 8 );
perms = perms.right( 4 );
- QString owner = QString( "%1" ).arg( (int)file_stat.st_uid );
- QString group = QString( "%1" ).arg( (int)file_stat.st_gid );
- QString temp_file_name = QString( tmp );
+ TQString owner = TQString( "%1" ).tqarg( (int)file_stat.st_uid );
+ TQString group = TQString( "%1" ).tqarg( (int)file_stat.st_gid );
+ TQString temp_file_name = TQString( tmp );
// Assemble the command.
- QString command;
+ TQString command;
command.append( "kdesu -n -c \"smb4k_mv "+owner+":"+group+" "+perms+" " );
command.append( temp_file_name+" " );
command.append( canonical_path+"\" ; " );
@@ -1447,7 +1447,7 @@ void Smb4KFileIO::processSuperTab()
return;
}
- QStringList contents = QStringList::split( "\n", m_buffer, true );
+ TQStringList contents = TQStringList::split( "\n", m_buffer, true );
bool write = false;
switch ( m_operation )
@@ -1460,7 +1460,7 @@ void Smb4KFileIO::processSuperTab()
if ( gethostname( hn, hostnamelen ) == -1 )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_HOSTNAME, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_HOSTNAME, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -1468,7 +1468,7 @@ void Smb4KFileIO::processSuperTab()
removeLockFile();
}
- QString hostname( hn );
+ TQString hostname( hn );
delete [] hn;
@@ -1476,7 +1476,7 @@ void Smb4KFileIO::processSuperTab()
{
contents.append( "# Entries for Smb4K users." );
contents.append( "# Generated by Smb4K. Please do not modify!" );
- contents.append( ":define Smb4KUsers "+QString( "%1" ).arg( getpwuid( getuid() )->pw_name ) );
+ contents.append( ":define Smb4KUsers "+TQString( "%1" ).tqarg( getpwuid( getuid() )->pw_name ) );
#ifndef __FreeBSD__
contents.append( "smb4k_kill\t"+Smb4KSettings::smb4k_kill()+
"\t$(Smb4KUsers)\tuid=root\tgid=root" );
@@ -1500,14 +1500,14 @@ void Smb4KFileIO::processSuperTab()
{
// Find the beginning and the end of the entries in
// the super.tab file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
- if ( (*it).startsWith( ":define Smb4KUsers" ) && (*it).contains( getpwuid( getuid() )->pw_name, true ) == 0 )
+ if ( (*it).startsWith( ":define Smb4KUsers" ) && (*it).tqcontains( getpwuid( getuid() )->pw_name, true ) == 0 )
{
- (*it).append( ","+QString( getpwuid( getuid() )->pw_name ) );
+ (*it).append( ","+TQString( getpwuid( getuid() )->pw_name ) );
write = true;
@@ -1526,22 +1526,22 @@ void Smb4KFileIO::processSuperTab()
{
// Find the beginning and the end of the entries in
// the super.tab file:
- QStringList::Iterator begin = contents.find( "# Entries for Smb4K users." );
- QStringList::Iterator end = contents.find( "# End of Smb4K user entries." );
+ TQStringList::Iterator begin = contents.tqfind( "# Entries for Smb4K users." );
+ TQStringList::Iterator end = contents.tqfind( "# End of Smb4K user entries." );
// Now, check if the user is in the list of users. If he is,
// remove him from there or remove all if he is the only one:
- for ( QStringList::Iterator it = begin; it != end; ++it )
+ for ( TQStringList::Iterator it = begin; it != end; ++it )
{
if ( (*it).startsWith( ":define Smb4KUsers" ) )
{
- QString users = (*it).section( "Smb4KUsers", 1, 1 ).stripWhiteSpace();
+ TQString users = (*it).section( "Smb4KUsers", 1, 1 ).stripWhiteSpace();
- if ( users.contains( "," ) == 0 )
+ if ( users.tqcontains( "," ) == 0 )
{
// In this case, there is only one user in the list. Check if
// it is the user who requested the removal:
- if ( QString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
+ if ( TQString::compare( users, getpwuid( getuid() )->pw_name ) == 0 )
{
// They are equal. Remove everything:
contents.erase( begin, end );
@@ -1561,10 +1561,10 @@ void Smb4KFileIO::processSuperTab()
{
// In this case there is more than one user in the list.
// Remove the user who requested the removal:
- QStringList list = QStringList::split( ",", users, false );
+ TQStringList list = TQStringList::split( ",", users, false );
list.remove( getpwuid( getuid() )->pw_name );
- (*it).replace( users, list.join( "," ) );
+ (*it).tqreplace( users, list.join( "," ) );
write = true;
@@ -1593,7 +1593,7 @@ void Smb4KFileIO::processSuperTab()
if ( write )
{
// Prepare the contents: remove empty lines from the end.
- QStringList::Iterator it = contents.end();
+ TQStringList::Iterator it = contents.end();
// Move the iterator to the last entry in the list:
--it;
@@ -1605,11 +1605,11 @@ void Smb4KFileIO::processSuperTab()
}
// Create a temporary file and write the data to it:
- QCString template_string = tempDir().local8Bit()+"/XXXXXX";
+ TQCString template_string = tempDir().local8Bit()+"/XXXXXX";
char tmp[template_string.length()+1];
(void) qstrncpy( tmp, template_string, template_string.length()+1 );
- QFile temp_file;
+ TQFile temp_file;
int file_descriptor;
if ( (file_descriptor = mkstemp( tmp )) == -1 )
@@ -1628,8 +1628,8 @@ void Smb4KFileIO::processSuperTab()
if ( temp_file.open( IO_WriteOnly, file_descriptor ) )
{
- QTextStream ts( &temp_file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &temp_file );
+ ts.setEncoding( TQTextStream::Locale );
ts << contents.join( "\n" ) << endl;
@@ -1649,14 +1649,14 @@ void Smb4KFileIO::processSuperTab()
// Now move the file to the right location. Preserve the permissions
// and the owner:
- QString canonical_path = findFile( "super.tab" );
+ TQString canonical_path = findFile( "super.tab" );
struct stat file_stat;
if ( stat( canonical_path.local8Bit(), &file_stat ) == -1 )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_PERMISSIONS, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_PERMISSIONS, TQString(), strerror( error_number ) );
emit failed();
emit finished();
@@ -1666,14 +1666,14 @@ void Smb4KFileIO::processSuperTab()
return;
}
- QString perms = QString( "%1" ).arg( (int)file_stat.st_mode, 0, 8 );
+ TQString perms = TQString( "%1" ).tqarg( (int)file_stat.st_mode, 0, 8 );
perms = perms.right( 4 );
- QString owner = QString( "%1" ).arg( (int)file_stat.st_uid );
- QString group = QString( "%1" ).arg( (int)file_stat.st_gid );
- QString temp_file_name = QString( tmp );
+ TQString owner = TQString( "%1" ).tqarg( (int)file_stat.st_uid );
+ TQString group = TQString( "%1" ).tqarg( (int)file_stat.st_gid );
+ TQString temp_file_name = TQString( tmp );
// Assemble the command.
- QString command;
+ TQString command;
command.append( "kdesu -n -c \"smb4k_mv "+owner+":"+group+" "+perms+" " );
command.append( temp_file_name+" " );
command.append( canonical_path+"\" ; " );
@@ -1695,7 +1695,7 @@ void Smb4KFileIO::processSuperTab()
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KFileIO::slotShutdown()
@@ -1706,13 +1706,13 @@ void Smb4KFileIO::slotShutdown()
void Smb4KFileIO::slotReceivedStderr( KProcess *, char *buf, int len )
{
- QString error_output = QString::fromLocal8Bit( buf, len );
+ TQString error_output = TQString::fromLocal8Bit( buf, len );
- if ( error_output.contains( "smb4k_mv" ) != 0 )
+ if ( error_output.tqcontains( "smb4k_mv" ) != 0 )
{
m_error_occurred = true;
- QString canonical_path = findFile( (m_state == WriteSudoers ? "sudoers" : "super.tab") );
+ TQString canonical_path = findFile( (m_state == WriteSudoers ? "sudoers" : "super.tab") );
Smb4KError::error( ERROR_WRITING_FILE, canonical_path, m_buffer );
@@ -1721,11 +1721,11 @@ void Smb4KFileIO::slotReceivedStderr( KProcess *, char *buf, int len )
removeLockFile();
}
- else if ( error_output.contains( "smb4k_cat" ) != 0 )
+ else if ( error_output.tqcontains( "smb4k_cat" ) != 0 )
{
m_error_occurred = true;
- QString canonical_path = findFile( (m_state == ReadSudoers ? "sudoers" : "super.tab") );
+ TQString canonical_path = findFile( (m_state == ReadSudoers ? "sudoers" : "super.tab") );
Smb4KError::error( ERROR_READING_FILE, canonical_path, m_buffer );
@@ -1739,7 +1739,7 @@ void Smb4KFileIO::slotReceivedStderr( KProcess *, char *buf, int len )
void Smb4KFileIO::slotReceivedStdout( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
@@ -1787,7 +1787,7 @@ void Smb4KFileIO::slotProcessExited( KProcess * )
// necessary things.
}
- m_buffer = QString::null;
+ m_buffer = TQString();
m_state = Idle;
m_error_occurred = false;
}
diff --git a/smb4k/core/smb4kfileio.h b/smb4k/core/smb4kfileio.h
index bbfbbe0..a11b2e9 100644
--- a/smb4k/core/smb4kfileio.h
+++ b/smb4k/core/smb4kfileio.h
@@ -30,10 +30,10 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qstring.h>
-#include <qcstring.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqcstring.h>
// KDE include
#include <kprocess.h>
@@ -46,19 +46,20 @@
* @author Alexander Reinholdt <dustpuppy@mail.berlios.de>
*/
-class Smb4KFileIO : public QObject
+class Smb4KFileIO : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent object of this class
+ * @param tqparent The tqparent object of this class
*
* @param name The name of this class
*/
- Smb4KFileIO( QObject *parent = 0, const char *name = 0 );
+ Smb4KFileIO( TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -81,7 +82,7 @@ class Smb4KFileIO : public QObject
* @returns TRUE if the write process was successfully initiate and FALSE
* otherwise.
*
- * @note You need to connect to the finished() and failed() signals to find
+ * @note You need to connect to the finished() and failed() signals to tqfind
* out if the the write process finished successfully.
*
*/
@@ -97,7 +98,7 @@ class Smb4KFileIO : public QObject
* @returns TRUE if the write process was successfully initiate and FALSE
* otherwise.
*
- * @note You need to connect to the finished() and failed() signals to find
+ * @note You need to connect to the finished() and failed() signals to tqfind
* out if the the write process finished successfully.
*
*/
@@ -168,7 +169,7 @@ class Smb4KFileIO : public QObject
* @returns TRUE if the creation was successful and FALSE if
* something went wrong.
*/
- bool createLockFile( const QString &filename );
+ bool createLockFile( const TQString &filename );
/**
* This function removes the lock file or at least the
@@ -194,7 +195,7 @@ class Smb4KFileIO : public QObject
* @returns the canonical path of the file or an empty string if it could not be
* found.
*/
- const QCString findFile( const QString &filename );
+ const TQCString findFile( const TQString &filename );
/**
* Enumeration that is used to tell the process what has to be done.
@@ -209,7 +210,7 @@ class Smb4KFileIO : public QObject
/**
* This buffer holds the output that was received at Stdout.
*/
- QString m_buffer;
+ TQString m_buffer;
/**
* Process the sudoers file.
@@ -224,7 +225,7 @@ class Smb4KFileIO : public QObject
/**
* This is the absolute path of the lock file.
*/
- QCString m_lock_file;
+ TQCString m_lock_file;
/**
* Which operation should be performed
diff --git a/smb4k/core/smb4kglobal.cpp b/smb4k/core/smb4kglobal.cpp
index c1fe706..4c1fa0c 100644
--- a/smb4k/core/smb4kglobal.cpp
+++ b/smb4k/core/smb4kglobal.cpp
@@ -36,7 +36,7 @@
static Smb4KGlobalPrivate p;
-QTimer *Smb4KGlobal::timer()
+TQTimer *Smb4KGlobal::timer()
{
return p.timer();
}
@@ -48,9 +48,9 @@ const int Smb4KGlobal::timerInterval()
}
-const QString Smb4KGlobal::specifyUser( const QString &host, QWidget *parent, const char *name )
+const TQString Smb4KGlobal::specifyUser( const TQString &host, TQWidget *tqparent, const char *name )
{
- return p.homesHandler()->specifyUser( host, parent, name );
+ return p.homesHandler()->specifyUser( host, tqparent, name );
}
@@ -66,13 +66,13 @@ Smb4KSambaOptionsHandler *Smb4KGlobal::optionsHandler()
}
-const QString &Smb4KGlobal::tempDir()
+const TQString &Smb4KGlobal::tempDir()
{
return p.tempDir();
}
-const QStringList Smb4KGlobal::homesUsers( const QString &host )
+const TQStringList Smb4KGlobal::homesUsers( const TQString &host )
{
return p.homesUsers( host );
}
diff --git a/smb4k/core/smb4kglobal.h b/smb4k/core/smb4kglobal.h
index 815938f..db6d4c0 100644
--- a/smb4k/core/smb4kglobal.h
+++ b/smb4k/core/smb4kglobal.h
@@ -26,8 +26,8 @@
#ifndef SMB4KGLOBAL_H
#define SMB4KGLOBAL_H
-#include <qstring.h>
-#include <qtimer.h>
+#include <tqstring.h>
+#include <tqtimer.h>
#include <kconfig.h>
@@ -51,7 +51,7 @@ namespace Smb4KGlobal
*
* @returns A pointer to the global timer.
*/
- QTimer *timer() KDE_DEPRECATED;
+ TQTimer *timer() KDE_DEPRECATED;
/**
* This function returns the interval of the timer.
@@ -67,13 +67,13 @@ namespace Smb4KGlobal
*
* @param host The host where the homes share is located
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this dialog
*
* @returns A user name
*/
- const QString specifyUser( const QString &host, QWidget *parent = 0, const char *name = 0 );
+ const TQString specifyUser( const TQString &host, TQWidget *tqparent = 0, const char *name = 0 );
/**
* This function returns the password handler.
@@ -100,7 +100,7 @@ namespace Smb4KGlobal
*
* @returns the name of the temporary directory.
*/
- const QString &tempDir();
+ const TQString &tempDir();
/**
* Get the user names that are defined for a homes share.
@@ -109,7 +109,7 @@ namespace Smb4KGlobal
*
* @returns the list of user names for this homes share.
*/
- const QStringList homesUsers( const QString &host );
+ const TQStringList homesUsers( const TQString &host );
};
#endif
diff --git a/smb4k/core/smb4kglobal_p.cpp b/smb4k/core/smb4kglobal_p.cpp
index f5da58f..c4e6009 100644
--- a/smb4k/core/smb4kglobal_p.cpp
+++ b/smb4k/core/smb4kglobal_p.cpp
@@ -36,7 +36,7 @@
Smb4KGlobalPrivate::Smb4KGlobalPrivate()
{
- m_timer = new QTimer();
+ m_timer = new TQTimer();
m_timer->start( TIMER_INTERVAL, false );
// Do NOT initialize these classes here; you'll
@@ -45,7 +45,7 @@ Smb4KGlobalPrivate::Smb4KGlobalPrivate()
m_options_handler = NULL;
m_homes_handler = NULL;
- m_temp_dir = QString::null;
+ m_temp_dir = TQString();
}
@@ -60,7 +60,7 @@ Smb4KGlobalPrivate::~Smb4KGlobalPrivate()
}
-QTimer *Smb4KGlobalPrivate::timer()
+TQTimer *Smb4KGlobalPrivate::timer()
{
return m_timer;
}
@@ -92,7 +92,7 @@ Smb4KSambaOptionsHandler *Smb4KGlobalPrivate::optionsHandler()
}
-const QString &Smb4KGlobalPrivate::tempDir()
+const TQString &Smb4KGlobalPrivate::tempDir()
{
if ( m_temp_dir.isEmpty() )
{
@@ -102,17 +102,17 @@ const QString &Smb4KGlobalPrivate::tempDir()
{
Smb4KError::error( ERROR_CREATING_TEMP_DIR, tmpd_name, strerror( errno ) );
- return QString::null;
+ return TQString();
}
- m_temp_dir = QString( tmpd_name );
+ m_temp_dir = TQString( tmpd_name );
}
return m_temp_dir;
}
-const QStringList Smb4KGlobalPrivate::homesUsers( const QString &host )
+const TQStringList Smb4KGlobalPrivate::homesUsers( const TQString &host )
{
if ( !m_homes_handler )
{
diff --git a/smb4k/core/smb4kglobal_p.h b/smb4k/core/smb4kglobal_p.h
index e1bad0a..f0e329d 100644
--- a/smb4k/core/smb4kglobal_p.h
+++ b/smb4k/core/smb4kglobal_p.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qtimer.h>
+// TQt includes
+#include <tqtimer.h>
// KDE includes
#include <kconfig.h>
@@ -64,7 +64,7 @@ class Smb4KGlobalPrivate
/**
* Returns a pointer to the global timer
*/
- QTimer *timer();
+ TQTimer *timer();
/**
* Returns the handler for homes shares
@@ -84,19 +84,19 @@ class Smb4KGlobalPrivate
/**
* Returns the name of the temporary directory.
*/
- const QString &tempDir();
+ const TQString &tempDir();
/**
* Return the user names defined for a certain homes share
*/
- const QStringList homesUsers( const QString &host );
+ const TQStringList homesUsers( const TQString &host );
private:
- QTimer *m_timer;
+ TQTimer *m_timer;
Smb4KPasswordHandler *m_passwd_handler;
Smb4KSambaOptionsHandler *m_options_handler;
Smb4KHomesSharesHandler *m_homes_handler;
- QString m_temp_dir;
+ TQString m_temp_dir;
};
#endif
diff --git a/smb4k/core/smb4khomesshareshandler.cpp b/smb4k/core/smb4khomesshareshandler.cpp
index a81a6e7..8aec7fa 100644
--- a/smb4k/core/smb4khomesshareshandler.cpp
+++ b/smb4k/core/smb4khomesshareshandler.cpp
@@ -23,11 +23,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qmap.h>
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qfile.h>
+// TQt includes
+#include <tqmap.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqfile.h>
// KDE includes
#include <kdebug.h>
@@ -42,12 +42,12 @@
#include "smb4kerror.h"
-Smb4KHomesSharesHandler::Smb4KHomesSharesHandler( QObject *parent, const char *name )
-: QObject( parent, name )
+Smb4KHomesSharesHandler::Smb4KHomesSharesHandler( TQObject *tqparent, const char *name )
+: TQObject( tqparent, name )
{
// First we need the directory.
KStandardDirs *stddir = new KStandardDirs();
- QString dir = locateLocal( "data", "smb4k", KGlobal::instance() );
+ TQString dir = locateLocal( "data", "smb4k", KGlobal::instance() );
if ( !stddir->exists( dir ) )
{
@@ -66,46 +66,46 @@ Smb4KHomesSharesHandler::~Smb4KHomesSharesHandler()
}
-const QString Smb4KHomesSharesHandler::specifyUser( const QString &host, QWidget *parent, const char *name )
+const TQString Smb4KHomesSharesHandler::specifyUser( const TQString &host, TQWidget *tqparent, const char *name )
{
- QString username = QString::null;
+ TQString username = TQString();
- m_dlg = new KDialogBase( KDialogBase::Plain, i18n( "Specify User" ), KDialogBase::User1|KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, parent, name, true, true );
+ m_dlg = new KDialogBase( KDialogBase::Plain, i18n( "Specify User" ), KDialogBase::User1|KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, tqparent, name, true, true );
m_dlg->setButtonGuiItem( KDialogBase::User1, KGuiItem( i18n( "Clear List" ), "editdelete", 0, 0 ) );
m_dlg->enableButton( KDialogBase::Ok, false );
m_dlg->enableButton( KDialogBase::User1, false );
// Set up the ask pass dialog.
- QFrame *frame = m_dlg->plainPage();
- QGridLayout *layout = new QGridLayout( frame );
- layout->setSpacing( 5 );
+ TQFrame *frame = m_dlg->plainPage();
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
+ tqlayout->setSpacing( 5 );
- QLabel *pic = new QLabel( frame );
+ TQLabel *pic = new TQLabel( frame );
pic->setPixmap( DesktopIcon( "personal" ) );
pic->setMargin( 10 );
- QLabel *text = new QLabel( i18n( "Please specify a user name." ), frame );
+ TQLabel *text = new TQLabel( i18n( "Please specify a user name." ), frame );
- QLabel *userLabel = new QLabel( i18n( "User:" ), frame );
+ TQLabel *userLabel = new TQLabel( i18n( "User:" ), frame );
KComboBox *userCombo = new KComboBox( true, frame, "UserComboBox" );
userCombo->setDuplicatesEnabled( false );
- QSpacerItem *spacer1 = new QSpacerItem( 10, 10, QSizePolicy::Expanding, QSizePolicy::Preferred );
+ TQSpacerItem *spacer1 = new TQSpacerItem( 10, 10, TQSizePolicy::Expanding, TQSizePolicy::Preferred );
- layout->addWidget( pic, 0, 0, 0 );
- layout->addMultiCellWidget( text, 0, 0, 1, 3, 0 );
- layout->addWidget( userLabel, 1, 0, 0 );
- layout->addMultiCellWidget( userCombo, 1, 1, 1, 4, 0 );
- layout->addItem( spacer1, 0, 2 );
+ tqlayout->addWidget( pic, 0, 0, 0 );
+ tqlayout->addMultiCellWidget( text, 0, 0, 1, 3, 0 );
+ tqlayout->addWidget( userLabel, 1, 0, 0 );
+ tqlayout->addMultiCellWidget( userCombo, 1, 1, 1, 4, 0 );
+ tqlayout->addItem( spacer1, 0, 2 );
- connect( userCombo, SIGNAL( textChanged( const QString &) ),
- this, SLOT( slotTextChanged( const QString & ) ) );
- connect( m_dlg, SIGNAL( user1Clicked() ),
- this, SLOT( slotClearClicked() ) );
+ connect( userCombo, TQT_SIGNAL( textChanged( const TQString &) ),
+ this, TQT_SLOT( slotTextChanged( const TQString & ) ) );
+ connect( m_dlg, TQT_SIGNAL( user1Clicked() ),
+ this, TQT_SLOT( slotClearClicked() ) );
// Read the list of logins, that are already defined
// for this 'homes' share.
- QStringList list = read_names( host );
+ TQStringList list = read_names( host );
if ( !list.isEmpty() )
{
@@ -113,11 +113,11 @@ const QString Smb4KHomesSharesHandler::specifyUser( const QString &host, QWidget
m_dlg->enableButton( KDialogBase::User1, true );
}
- userCombo->setCurrentText( QString::null );
+ userCombo->setCurrentText( TQString() );
// Do the last things before showing.
userCombo->setFocus();
- m_dlg->setFixedSize( m_dlg->sizeHint() );
+ m_dlg->setFixedSize( m_dlg->tqsizeHint() );
if ( m_dlg->exec() == KDialogBase::Accepted )
{
@@ -134,7 +134,7 @@ const QString Smb4KHomesSharesHandler::specifyUser( const QString &host, QWidget
while ( index < userCombo->count() )
{
- if ( list.find( userCombo->text( index ) ) == list.end() )
+ if ( list.tqfind( userCombo->text( index ) ) == list.end() )
{
list.append( userCombo->text( index ) );
}
@@ -156,19 +156,19 @@ const QString Smb4KHomesSharesHandler::specifyUser( const QString &host, QWidget
}
-const QStringList &Smb4KHomesSharesHandler::read_names( const QString &host )
+const TQStringList &Smb4KHomesSharesHandler::read_names( const TQString &host )
{
// Clear the old contents of this list:
m_names.clear();
- QFile file( locateLocal( "data", "smb4k/homes_shares", KGlobal::instance() ) );
+ TQFile file( locateLocal( "data", "smb4k/homes_shares", KGlobal::instance() ) );
if ( file.open( IO_ReadOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- QString line;
+ TQString line;
bool get_names = false;
while ( !ts.atEnd() )
@@ -177,7 +177,7 @@ const QStringList &Smb4KHomesSharesHandler::read_names( const QString &host )
if ( !get_names )
{
- if ( QString::compare( line.stripWhiteSpace(), "["+host.upper()+"]" ) == 0 )
+ if ( TQString::compare( line.stripWhiteSpace(), "["+host.upper()+"]" ) == 0 )
{
// Found the host:
get_names = true;
@@ -195,7 +195,7 @@ const QStringList &Smb4KHomesSharesHandler::read_names( const QString &host )
if ( !line.stripWhiteSpace().isEmpty() )
{
// Write the names to the list:
- m_names = QStringList::split( ",", line, false );
+ m_names = TQStringList::split( ",", line, false );
// This is not needed, but let's do it anyway:
get_names = false;
@@ -222,20 +222,20 @@ const QStringList &Smb4KHomesSharesHandler::read_names( const QString &host )
}
-void Smb4KHomesSharesHandler::write_names( const QString &host, const QStringList &names )
+void Smb4KHomesSharesHandler::write_names( const TQString &host, const TQStringList &names )
{
// First get the whole contents of the file, so that
// we can easily modify it:
- QStringList contents;
+ TQStringList contents;
- QFile file( locateLocal( "data", "smb4k/homes_shares", KGlobal::instance() ) );
+ TQFile file( locateLocal( "data", "smb4k/homes_shares", KGlobal::instance() ) );
if ( file.open( IO_ReadOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- contents = QStringList::split( '\n', ts.read(), true );
+ contents = TQStringList::split( '\n', ts.read(), true );
file.close();
}
@@ -250,11 +250,11 @@ void Smb4KHomesSharesHandler::write_names( const QString &host, const QStringLis
}
// Now search for the host:
- QStringList::Iterator it;
+ TQStringList::Iterator it;
for ( it = contents.begin(); it != contents.end(); ++it )
{
- if ( QString::compare( (*it).stripWhiteSpace().upper(), "["+host.upper()+"]" ) == 0 )
+ if ( TQString::compare( (*it).stripWhiteSpace().upper(), "["+host.upper()+"]" ) == 0 )
{
if ( !names.isEmpty() )
{
@@ -303,8 +303,8 @@ void Smb4KHomesSharesHandler::write_names( const QString &host, const QStringLis
{
if ( file.open( IO_WriteOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
ts << contents.join( "\n" );
@@ -325,10 +325,10 @@ void Smb4KHomesSharesHandler::write_names( const QString &host, const QStringLis
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
-void Smb4KHomesSharesHandler::slotTextChanged( const QString &text )
+void Smb4KHomesSharesHandler::slotTextChanged( const TQString &text )
{
if ( !text.isEmpty() )
{
diff --git a/smb4k/core/smb4khomesshareshandler.h b/smb4k/core/smb4khomesshareshandler.h
index cf501e2..4db96f7 100644
--- a/smb4k/core/smb4khomesshareshandler.h
+++ b/smb4k/core/smb4khomesshareshandler.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
+// TQt includes
+#include <tqobject.h>
// KDE includes
#include <kdialogbase.h>
@@ -45,19 +45,20 @@
* @author Alexander Reinholdt <dustpuppy@mail.berlios.de>
*/
-class Smb4KHomesSharesHandler : public QObject
+class Smb4KHomesSharesHandler : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent object of this class
+ * @param tqparent The tqparent object of this class
*
* @param name The name of this class
*/
- Smb4KHomesSharesHandler( QObject *parent = 0, const char *name = 0 );
+ Smb4KHomesSharesHandler( TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -71,13 +72,13 @@ class Smb4KHomesSharesHandler : public QObject
*
* @param host The host where the homes share is located
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this dialog
*
* @returns A user name
*/
- const QString specifyUser( const QString &host, QWidget *parent = 0, const char *name = 0 );
+ const TQString specifyUser( const TQString &host, TQWidget *tqparent = 0, const char *name = 0 );
/**
* Read and return the user names that are defined for a homes share.
@@ -86,7 +87,7 @@ class Smb4KHomesSharesHandler : public QObject
*
* @returns the list of user names for this homes share.
*/
- const QStringList &homesUsers( const QString &host ) { return read_names( host ); }
+ const TQStringList &homesUsers( const TQString &host ) { return read_names( host ); }
protected slots:
/**
@@ -95,7 +96,7 @@ class Smb4KHomesSharesHandler : public QObject
*
* @param text The text in the combo box
*/
- void slotTextChanged( const QString &text );
+ void slotTextChanged( const TQString &text );
/**
* This slot is called if the User1 button, i.e. the "Clear" button
@@ -110,7 +111,7 @@ class Smb4KHomesSharesHandler : public QObject
*
* @param host The host where the homes share is located.
*/
- const QStringList &read_names( const QString &host );
+ const TQStringList &read_names( const TQString &host );
/**
* Write the user names for a certain homes share to the config
@@ -122,7 +123,7 @@ class Smb4KHomesSharesHandler : public QObject
* the homes share and should be written to the
* config file.
*/
- void write_names( const QString &host, const QStringList &names );
+ void write_names( const TQString &host, const TQStringList &names );
/**
* This is the dialog that's shown the user when he/she has to
@@ -133,7 +134,7 @@ class Smb4KHomesSharesHandler : public QObject
/**
* This is a buffer for the list of names defined for a 'homes' share.
*/
- QStringList m_names;
+ TQStringList m_names;
};
#endif
diff --git a/smb4k/core/smb4kmounter.cpp b/smb4k/core/smb4kmounter.cpp
index 45ccc9c..a6f07ae 100644
--- a/smb4k/core/smb4kmounter.cpp
+++ b/smb4k/core/smb4kmounter.cpp
@@ -23,12 +23,12 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qapplication.h>
-#include <qdir.h>
-#include <qtextstream.h>
-#include <qfile.h>
-#include <qtextstream.h>
+// TQt includes
+#include <tqapplication.h>
+#include <tqdir.h>
+#include <tqtextstream.h>
+#include <tqfile.h>
+#include <tqtextstream.h>
// KDE includes
#include <kapplication.h>
@@ -55,7 +55,7 @@
#include <sys/param.h>
#include <sys/ucred.h>
#include <sys/mount.h>
-#include <qfileinfo.h>
+#include <tqfileinfo.h>
#endif
// Application specific includes
@@ -73,7 +73,7 @@
using namespace Smb4KGlobal;
-Smb4KMounter::Smb4KMounter( QObject *parent, const char *name ) : QObject( parent, name )
+Smb4KMounter::Smb4KMounter( TQObject *tqparent, const char *name ) : TQObject( tqparent, name )
{
m_priv = new Smb4KMounterPrivate;
@@ -84,17 +84,17 @@ Smb4KMounter::Smb4KMounter( QObject *parent, const char *name ) : QObject( paren
m_queue.setAutoDelete( true );
- connect( m_proc, SIGNAL( processExited( KProcess * ) ),
- this, SLOT( slotProcessExited( KProcess * ) ) );
+ connect( m_proc, TQT_SIGNAL( processExited( KProcess * ) ),
+ this, TQT_SLOT( slotProcessExited( KProcess * ) ) );
- connect( m_proc, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( receivedStderr( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStderr( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
- connect( kapp, SIGNAL( shutDown() ),
- this, SLOT( slotShutdown() ) );
+ connect( kapp, TQT_SIGNAL( shutDown() ),
+ this, TQT_SLOT( slotShutdown() ) );
}
@@ -102,7 +102,7 @@ Smb4KMounter::~Smb4KMounter()
{
abort();
- for ( QValueList<Smb4KShare *>::Iterator it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueList<Smb4KShare *>::Iterator it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
delete *it;
}
@@ -115,8 +115,8 @@ Smb4KMounter::~Smb4KMounter()
void Smb4KMounter::init()
{
- m_queue.enqueue( new QString( QString( "%1:" ).arg( Import ) ) );
- m_queue.enqueue( new QString( QString( "%1:" ).arg( Remount ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:" ).tqarg( Import ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:" ).tqarg( Remount ) ) );
startTimer( TIMER_INTERVAL );
}
@@ -135,7 +135,7 @@ void Smb4KMounter::abort()
{
if ( Smb4KSettings::alwaysUseSuperUser() )
{
- QString suid_program;
+ TQString suid_program;
switch( Smb4KSettings::superUserProgram() )
{
@@ -160,7 +160,7 @@ void Smb4KMounter::abort()
KProcess proc;
proc.setUseShell( true );
- proc << QString( "%1 smb4k_kill %2" ).arg( suid_program ).arg( m_proc->pid() );
+ proc << TQString( "%1 smb4k_kill %2" ).tqarg( suid_program ).tqarg( m_proc->pid() );
proc.start( KProcess::DontCare, KProcess::NoCommunication );
}
else
@@ -180,20 +180,20 @@ void Smb4KMounter::remount()
{
if ( Smb4KSettings::remountShares() )
{
- const QValueList<Smb4KSambaOptionsInfo *> *list = &(optionsHandler()->customOptionsList());
+ const TQValueList<Smb4KSambaOptionsInfo *> *list = &(optionsHandler()->customOptionsList());
- for ( QValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = list->begin();
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = list->begin();
it != list->end(); ++it )
{
if ( (*it)->remount() )
{
- QValueList<Smb4KShare> list = findShareByName( (*it)->itemName() );
+ TQValueList<Smb4KShare> list = findShareByName( (*it)->itemName() );
bool mount = true;
if ( !list.isEmpty() )
{
- for ( QValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( !(*it).isForeign() )
{
@@ -211,9 +211,9 @@ void Smb4KMounter::remount()
if ( mount )
{
#ifndef __FreeBSD__
- mountShare( QString::null, (*it)->itemName().section( "/", 2, 2 ), QString::null, (*it)->itemName().section( "/", 3, 3 ) );
+ mountShare( TQString(), (*it)->itemName().section( "/", 2, 2 ), TQString(), (*it)->itemName().section( "/", 3, 3 ) );
#else
- mountShare( QString::null, (*it)->itemName().section( "/", 2, 2 ).section( "@", 1, 1 ), QString::null, (*it)->itemName().section( "/", 3, 3 ) );
+ mountShare( TQString(), (*it)->itemName().section( "/", 2, 2 ).section( "@", 1, 1 ), TQString(), (*it)->itemName().section( "/", 3, 3 ) );
#endif
}
@@ -246,7 +246,7 @@ void Smb4KMounter::remount()
void Smb4KMounter::import()
{
- QValueList<Smb4KShare *> shares;
+ TQValueList<Smb4KShare *> shares;
#ifndef __FreeBSD__
@@ -255,7 +255,7 @@ void Smb4KMounter::import()
m_proc_mounts.setName( "/proc/mounts" );
}
- if ( !QFile::exists( m_proc_mounts.name() ) )
+ if ( !TQFile::exists( m_proc_mounts.name() ) )
{
if ( !m_proc_error )
{
@@ -269,16 +269,16 @@ void Smb4KMounter::import()
}
else
{
- QStringList contents, list;
+ TQStringList contents, list;
// Read /proc/mounts:
if ( m_proc_mounts.open( IO_ReadOnly ) )
{
- QTextStream ts( &m_proc_mounts );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &m_proc_mounts );
+ ts.setEncoding( TQTextStream::Locale );
- contents = QStringList::split( "\n", ts.read(), false );
+ contents = TQStringList::split( "\n", ts.read(), false );
m_proc_mounts.close();
}
@@ -296,20 +296,20 @@ void Smb4KMounter::import()
if ( !list.isEmpty() )
{
- for ( QStringList::Iterator it = list.begin(); it != list.end(); it++ )
+ for ( TQStringList::Iterator it = list.begin(); it != list.end(); it++ )
{
Smb4KShare *new_share = NULL;
- if ( (*it).contains( " smbfs ", false ) != 0 )
+ if ( (*it).tqcontains( " smbfs ", false ) != 0 )
{
- QString share_and_path = (*it).section( " smbfs ", 0, 0 ).stripWhiteSpace();
- QString name = share_and_path.section( " ", 0, 0 ).stripWhiteSpace().replace( "\\040", "\040" );
- QString path = share_and_path.section( " ", 1, 1 ).stripWhiteSpace();
+ TQString share_and_path = (*it).section( " smbfs ", 0, 0 ).stripWhiteSpace();
+ TQString name = share_and_path.section( " ", 0, 0 ).stripWhiteSpace().tqreplace( "\\040", "\040" );
+ TQString path = share_and_path.section( " ", 1, 1 ).stripWhiteSpace();
- if ( path.contains( "\\040" ) != 0 || path.contains( "\040" ) != 0 )
+ if ( path.tqcontains( "\\040" ) != 0 || path.tqcontains( "\040" ) != 0 )
{
- name.replace( "_", "\040" );
- path.replace( "\\040", "\040" );
+ name.tqreplace( "_", "\040" );
+ path.tqreplace( "\\040", "\040" );
}
int uid = (*it).section( "uid=", 1, 1 ).section( ",", 0, 0 ).stripWhiteSpace().toInt();
@@ -317,19 +317,19 @@ void Smb4KMounter::import()
new_share = new Smb4KShare( name, path, "smbfs", uid, gid );
}
- else if ( (*it).contains( " cifs ", false ) != 0 )
+ else if ( (*it).tqcontains( " cifs ", false ) != 0 )
{
- QString share_and_path = (*it).section( " cifs ", 0, 0 ).stripWhiteSpace();
- QString name = share_and_path.section( " ", 0, 0 ).stripWhiteSpace().replace( "\\040", "\040" );
- QString path = share_and_path.section( " ", 1, 1 ).stripWhiteSpace();
+ TQString share_and_path = (*it).section( " cifs ", 0, 0 ).stripWhiteSpace();
+ TQString name = share_and_path.section( " ", 0, 0 ).stripWhiteSpace().tqreplace( "\\040", "\040" );
+ TQString path = share_and_path.section( " ", 1, 1 ).stripWhiteSpace();
- if ( path.contains( "\\040" ) != 0 || path.contains( "\040" ) != 0 )
+ if ( path.tqcontains( "\\040" ) != 0 || path.tqcontains( "\040" ) != 0 )
{
- name.replace( "_", "\040" );
- path.replace( "\\040", "\040" );
+ name.tqreplace( "_", "\040" );
+ path.tqreplace( "\\040", "\040" );
}
- QString login = (*it).section( "username=", 1, 1 ).section( ",", 0, 0 ).stripWhiteSpace();
+ TQString login = (*it).section( "username=", 1, 1 ).section( ",", 0, 0 ).stripWhiteSpace();
new_share = new Smb4KShare( name, path, "cifs", login );
}
@@ -363,22 +363,22 @@ void Smb4KMounter::import()
// anything here.
}
- if ( !existing_share && QString::compare( new_share->filesystem(), "cifs" ) == 0 )
+ if ( !existing_share && TQString::compare( new_share->filesystem(), "cifs" ) == 0 )
{
bool foreign = true;
if ( (!new_share->isBroken() &&
- (qstrncmp( new_share->canonicalPath(),
- QDir( Smb4KSettings::mountPrefix() ).canonicalPath(),
- QDir( Smb4KSettings::mountPrefix() ).canonicalPath().length() ) == 0 ||
- qstrncmp( new_share->canonicalPath(),
- QDir::home().canonicalPath(),
- QDir::home().canonicalPath().length() ) == 0)) ||
+ (tqstrncmp( new_share->canonicalPath(),
+ TQDir( Smb4KSettings::mountPrefix() ).canonicalPath(),
+ TQDir( Smb4KSettings::mountPrefix() ).canonicalPath().length() ) == 0 ||
+ tqstrncmp( new_share->canonicalPath(),
+ TQDir::home().canonicalPath(),
+ TQDir::home().canonicalPath().length() ) == 0)) ||
(new_share->isBroken() &&
- (qstrncmp( new_share->path(),
- QDir::homeDirPath(),
- QDir::homeDirPath().length() ) == 0 ||
- qstrncmp( new_share->path(),
+ (tqstrncmp( new_share->path(),
+ TQDir::homeDirPath(),
+ TQDir::homeDirPath().length() ) == 0 ||
+ tqstrncmp( new_share->path(),
Smb4KSettings::mountPrefix(),
Smb4KSettings::mountPrefix().length() ) == 0)) )
{
@@ -403,7 +403,7 @@ void Smb4KMounter::import()
{
int err_code = errno;
- Smb4KError::error( ERROR_IMPORTING_SHARES, QString::null, strerror( err_code ) );
+ Smb4KError::error( ERROR_IMPORTING_SHARES, TQString(), strerror( err_code ) );
m_working = false;
return;
@@ -413,11 +413,11 @@ void Smb4KMounter::import()
{
if ( !strcmp( buf[i].f_fstypename, "smbfs" ) )
{
- QString share_name( buf[i].f_mntfromname );
- QString path( buf[i].f_mntonname );
- QString fs( buf[i].f_fstypename );
+ TQString share_name( buf[i].f_mntfromname );
+ TQString path( buf[i].f_mntonname );
+ TQString fs( buf[i].f_fstypename );
- QFileInfo info( QString( buf[i].f_mntonname )+"/." );
+ TQFileInfo info( TQString( buf[i].f_mntonname )+"/." );
int uid = (int)info.ownerId();
int gid = (int)info.groupId();
@@ -449,13 +449,13 @@ void Smb4KMounter::import()
}
}
- // Apparently, under FreeBSD we do not need to delete
+ // Aptqparently, under FreeBSD we do not need to delete
// the pointer (see manual page).
#endif
// Delete all entries of m_mounted_shares.
- for ( QValueList<Smb4KShare *>::Iterator it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueList<Smb4KShare *>::Iterator it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
delete *it;
}
@@ -474,11 +474,11 @@ void Smb4KMounter::import()
Mounts a share. (Public part)
***************************************************************************/
-void Smb4KMounter::mountShare( const QString &workgroup, const QString &host, const QString &ip, const QString &share )
+void Smb4KMounter::mountShare( const TQString &workgroup, const TQString &host, const TQString &ip, const TQString &share )
{
- QString share_name = QString::null;
+ TQString share_name = TQString();
- if ( QString::compare( share, "homes" ) == 0 )
+ if ( TQString::compare( share, "homes" ) == 0 )
{
share_name = specifyUser( host, kapp->mainWidget() ? kapp->mainWidget() : 0, "SpecifyUser" );
}
@@ -491,9 +491,9 @@ void Smb4KMounter::mountShare( const QString &workgroup, const QString &host, co
{
// Before doing anything else let's check that the
// share has not been mounted by the user already:
- QValueList<Smb4KShare> list = findShareByName( QString( "//%1/%2" ).arg( host, share_name ) );
+ TQValueList<Smb4KShare> list = findShareByName( TQString( "//%1/%2" ).tqarg( host, share_name ) );
- for ( QValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( !(*it).isForeign() )
{
@@ -503,9 +503,9 @@ void Smb4KMounter::mountShare( const QString &workgroup, const QString &host, co
}
}
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4:%5" ).arg( Mount )
- .arg( workgroup, host )
- .arg( ip, share_name ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4:%5" ).tqarg( Mount )
+ .tqarg( workgroup, host )
+ .tqarg( ip, share_name ) ) );
}
}
@@ -515,7 +515,7 @@ void Smb4KMounter::mountShare( const QString &workgroup, const QString &host, co
Mounts a share. (Private part)
***************************************************************************/
-void Smb4KMounter::mount( const QString &workgroup, const QString &host, const QString &ip, const QString &share )
+void Smb4KMounter::mount( const TQString &workgroup, const TQString &host, const TQString &ip, const TQString &share )
{
m_priv->setWorkgroup( workgroup );
m_priv->setHost( host );
@@ -523,7 +523,7 @@ void Smb4KMounter::mount( const QString &workgroup, const QString &host, const Q
m_priv->setIP( ip );
// Create the mount point:
- QDir *dir = new QDir( Smb4KSettings::mountPrefix() );
+ TQDir *dir = new TQDir( Smb4KSettings::mountPrefix() );
if ( !dir->exists() )
{
@@ -571,12 +571,12 @@ void Smb4KMounter::mount( const QString &workgroup, const QString &host, const Q
}
}
- m_priv->setPath( QDir::cleanDirPath( dir->path() ) );
+ m_priv->setPath( TQDir::cleanDirPath( dir->path() ) );
delete dir;
// Now we are prepared to mount the share:
- QString command, suid_program;
+ TQString command, suid_program;
switch ( Smb4KSettings::superUserProgram() )
{
@@ -604,14 +604,14 @@ void Smb4KMounter::mount( const QString &workgroup, const QString &host, const Q
#ifndef __FreeBSD__
// Let's see if the options handler knows the share:
- Smb4KSambaOptionsInfo *info = optionsHandler()->findItem( QString( "//%1/%2" ).arg( m_priv->host(), m_priv->share() ), true );
+ Smb4KSambaOptionsInfo *info = optionsHandler()->findItem( TQString( "//%1/%2" ).tqarg( m_priv->host(), m_priv->share() ), true );
// Determine the file system we have to use:
int filesystem;
if ( info )
{
- filesystem = QString::compare( info->filesystem().lower(), "cifs" ) == 0 ?
+ filesystem = TQString::compare( info->filesystem().lower(), "cifs" ) == 0 ?
Smb4KSettings::EnumFilesystem::CIFS :
Smb4KSettings::EnumFilesystem::SMBFS;
}
@@ -626,28 +626,28 @@ void Smb4KMounter::mount( const QString &workgroup, const QString &host, const Q
case Smb4KSettings::EnumFilesystem::CIFS:
{
command.append( Smb4KSettings::alwaysUseSuperUser() ? // FIXME: Check if suid program is installed
- QString( "%1 smb4k_mount -s -t cifs " ).arg( suid_program ) :
+ TQString( "%1 smb4k_mount -s -t cifs " ).tqarg( suid_program ) :
"smb4k_mount -n -t cifs " );
command.append( "-o " );
- command.append( optionsHandler()->mountOptions( QString( "//%1/%2" ).arg( m_priv->host(), m_priv->share() ) ) );
+ command.append( optionsHandler()->mountOptions( TQString( "//%1/%2" ).tqarg( m_priv->host(), m_priv->share() ) ) );
command.append( !m_priv->workgroup().stripWhiteSpace().isEmpty() ?
- QString( "domain='%1'," ).arg( m_priv->workgroup() ) :
+ TQString( "domain='%1'," ).tqarg( m_priv->workgroup() ) :
"" );
command.append( !m_priv->ip().stripWhiteSpace().isEmpty() ?
- QString( "ip=%1," ).arg( m_priv->ip() ) :
+ TQString( "ip=%1," ).tqarg( m_priv->ip() ) :
"" );
command.append( !authInfo.user().isEmpty() ?
- QString( "user=%1" ).arg( authInfo.user() ) :
+ TQString( "user=%1" ).tqarg( authInfo.user().data() ) :
"guest" );
command.append( " -- " );
- command.append( QString( "//'%1'/'%2' '%3'" ).arg( m_priv->host(), m_priv->share(), m_priv->path() ) );
+ command.append( TQString( "//'%1'/'%2' '%3'" ).tqarg( m_priv->host(), m_priv->share(), m_priv->path() ) );
m_priv->setCIFSLogin( !authInfo.user().isEmpty() ?
authInfo.user() :
@@ -660,28 +660,28 @@ void Smb4KMounter::mount( const QString &workgroup, const QString &host, const Q
case Smb4KSettings::EnumFilesystem::SMBFS:
{
command.append( Smb4KSettings::alwaysUseSuperUser() ? // FIXME: Check if suid program is installed
- QString( "%1 smb4k_mount -s -t smbfs " ).arg( suid_program ) :
+ TQString( "%1 smb4k_mount -s -t smbfs " ).tqarg( suid_program ) :
"smb4k_mount -n -t smbfs " );
command.append( "-o " );
- command.append( optionsHandler()->mountOptions( QString( "//%1/%2" ).arg( m_priv->host(), m_priv->share() ) ) );
+ command.append( optionsHandler()->mountOptions( TQString( "//%1/%2" ).tqarg( m_priv->host(), m_priv->share() ) ) );
command.append( !m_priv->workgroup().stripWhiteSpace().isEmpty() ?
- QString( "workgroup='%1'," ).arg( m_priv->workgroup() ) :
+ TQString( "workgroup='%1'," ).tqarg( m_priv->workgroup() ) :
"" );
command.append( !m_priv->ip().stripWhiteSpace().isEmpty() ?
- QString( "ip=%1," ).arg( m_priv->ip() ) :
+ TQString( "ip=%1," ).tqarg( m_priv->ip() ) :
"" );
command.append( !authInfo.user().isEmpty() ?
- QString( "username=%1" ).arg( authInfo.user() ) :
+ TQString( "username=%1" ).tqarg( authInfo.user().data() ) :
"guest" );
command.append( " -- " );
- command.append( QString( "//'%1'/'%2' '%3'" ).arg( m_priv->host(), m_priv->share(), m_priv->path() ) );
+ command.append( TQString( "//'%1'/'%2' '%3'" ).tqarg( m_priv->host(), m_priv->share(), m_priv->path() ) );
m_priv->setFileSystem( "smbfs" );
@@ -704,27 +704,27 @@ void Smb4KMounter::mount( const QString &workgroup, const QString &host, const Q
Smb4KSettings::remotePort();
command.append( Smb4KSettings::alwaysUseSuperUser() ? // FIXME: Check if suid program is installed
- QString( "%1 smb4k_mount " ).arg( suid_program ) :
+ TQString( "%1 smb4k_mount " ).tqarg( suid_program ) :
"smb4k_mount " );
- command.append( optionsHandler()->mountOptions( QString( "//%1/%2" ).arg( m_priv->host(), m_priv->share() ) ) );
+ command.append( optionsHandler()->mountOptions( TQString( "//%1/%2" ).tqarg( m_priv->host(), m_priv->share() ) ) );
command.append( !m_priv->workgroup().stripWhiteSpace().isEmpty() ?
- QString( " -W '%1'" ).arg( m_priv->workgroup() ) :
+ TQString( " -W '%1'" ).tqarg( m_priv->workgroup() ) :
"" );
command.append( !m_priv->ip().stripWhiteSpace().isEmpty() ?
- QString( " -I %1" ).arg( m_priv->ip() ) :
+ TQString( " -I %1" ).tqarg( m_priv->ip() ) :
"" );
command.append( " -N" );
command.append( " -- " );
- command.append( QString( "//%1@'%2':%3/'%4' '%5'" ).arg( !authInfo.user().isEmpty() ? authInfo.user() : "guest" )
- .arg( m_priv->host() )
- .arg( port )
- .arg( m_priv->share(), m_priv->path() ) );
+ command.append( TQString( "//%1@'%2':%3/'%4' '%5'" ).tqarg( !authInfo.user().isEmpty() ? authInfo.user() : "guest" )
+ .tqarg( m_priv->host() )
+ .tqarg( port )
+ .tqarg( m_priv->share(), m_priv->path() ) );
#endif
@@ -743,9 +743,9 @@ void Smb4KMounter::unmountShare( Smb4KShare *share, bool force, bool noMessage )
{
// Do *not* change share->canonicalPath(). It is necessary for the
// checks below to work.
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4" ).arg( Unmount )
- .arg( share->canonicalPath() )
- .arg( force, noMessage ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4" ).tqarg( Unmount )
+ .tqarg( share->canonicalPath().data() )
+ .tqarg( force, noMessage ) ) );
}
@@ -753,7 +753,7 @@ void Smb4KMounter::unmountShare( Smb4KShare *share, bool force, bool noMessage )
Unmount a share. (Private part)
***************************************************************************/
-void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessage )
+void Smb4KMounter::unmount( const TQString &mountpoint, bool force, bool noMessage )
{
// First let's see if all requirements are fullfilled:
@@ -775,10 +775,10 @@ void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessag
{
bool execute = false;
- QString path = mountpoint;
- m_priv->setPath( path.replace( '\044', "\044" ) );
+ TQString path = mountpoint;
+ m_priv->setPath( path.tqreplace( '\044', "\044" ) );
- QString suid_program, command;
+ TQString suid_program, command;
if ( Smb4KSettings::useForceUnmount() || Smb4KSettings::alwaysUseSuperUser() )
{
@@ -812,15 +812,15 @@ void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessag
{
if ( force )
{
- if ( KMessageBox::questionYesNo( 0, i18n( "Do you really want to force the unmounting of this share?" ), QString::null, KStdGuiItem::yes(), KStdGuiItem::no(), "Dont Ask Forced", KMessageBox::Notify ) == KMessageBox::Yes )
+ if ( KMessageBox::questionYesNo( 0, i18n( "Do you really want to force the unmounting of this share?" ), TQString(), KStdGuiItem::yes(), KStdGuiItem::no(), "Dont Ask Forced", KMessageBox::Notify ) == KMessageBox::Yes )
{
#ifdef __linux__
- command.append( QString( "%1 smb4k_umount -s -l " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount -s -l " ).tqarg( suid_program ) );
#else
#ifdef __FreeBSD__
- command.append( QString( "%1 smb4k_umount " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount " ).tqarg( suid_program ) );
#else
- command.append( QString( "%1 smb4k_umount -s " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount -s " ).tqarg( suid_program ) );
#endif
#endif
execute = true;
@@ -846,9 +846,9 @@ void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessag
else
{
#ifndef __FreeBSD__
- command.append( QString( "%1 smb4k_umount -s " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount -s " ).tqarg( suid_program ) );
#else
- command.append( QString( "%1 smb4k_umount " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount " ).tqarg( suid_program ) );
#endif
}
}
@@ -859,15 +859,15 @@ void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessag
{
if ( force )
{
- if ( KMessageBox::questionYesNo( 0, i18n( "Do you really want to force the unmounting of this share?" ), QString::null, KStdGuiItem::yes(), KStdGuiItem::no(), "Dont Ask Forced", KMessageBox::Notify ) == KMessageBox::Yes )
+ if ( KMessageBox::questionYesNo( 0, i18n( "Do you really want to force the unmounting of this share?" ), TQString(), KStdGuiItem::yes(), KStdGuiItem::no(), "Dont Ask Forced", KMessageBox::Notify ) == KMessageBox::Yes )
{
#ifdef __linux__
- command.append( QString( "%1 smb4k_umount -s -l " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount -s -l " ).tqarg( suid_program ) );
#else
#ifdef __FreeBSD__
- command.append( QString( "%1 smb4k_umount " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount " ).tqarg( suid_program ) );
#else
- command.append( QString( "%1 smb4k_umount -s " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount -s " ).tqarg( suid_program ) );
#endif
#endif
execute = true;
@@ -893,9 +893,9 @@ void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessag
else
{
#ifndef __FreeBSD__
- command.append( QString( "%1 smb4k_umount -s " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount -s " ).tqarg( suid_program ) );
#else
- command.append( QString( "%1 smb4k_umount " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount " ).tqarg( suid_program ) );
#endif
}
}
@@ -915,9 +915,9 @@ void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessag
}
#ifndef __FreeBSD__
- command.append( QString( "-t %1 " ).arg( share->filesystem() ) );
+ command.append( TQString( "-t %1 " ).tqarg( share->filesystem() ) );
#endif
- command.append( QString( "'%1'" ).arg( m_priv->path() ) );
+ command.append( TQString( "'%1'" ).tqarg( m_priv->path() ) );
if ( force && !execute )
{
@@ -952,7 +952,7 @@ void Smb4KMounter::unmount( const QString &mountpoint, bool force, bool noMessag
void Smb4KMounter::unmountAllShares()
{
- m_queue.enqueue( new QString( QString( "%1" ).arg( UnmountAll ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1" ).tqarg( UnmountAll ) ) );
}
@@ -962,7 +962,7 @@ void Smb4KMounter::unmountAllShares()
void Smb4KMounter::unmountAll()
{
- for ( QValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
unmountShare( *it, false, true );
}
@@ -977,12 +977,12 @@ void Smb4KMounter::unmountAll()
void Smb4KMounter::startProcess( int state )
{
- m_buffer = QString::null;
+ m_buffer = TQString();
m_state = state;
if ( m_state != Import )
{
- QApplication::setOverrideCursor( waitCursor );
+ TQApplication::setOverrideCursor( waitCursor );
}
m_proc->start( KProcess::NotifyOnExit, KProcess::AllOutput );
@@ -1012,7 +1012,7 @@ void Smb4KMounter::endProcess()
m_priv->clearData();
- QApplication::restoreOverrideCursor();
+ TQApplication::restoreOverrideCursor();
m_proc->clearArguments();
m_working = false;
@@ -1032,18 +1032,18 @@ void Smb4KMounter::processMount()
if ( m_proc->normalExit() )
{
- if ( m_buffer.contains( "smb4k_mount:", true ) == 0 &&
- m_buffer.contains( "failed", true ) == 0 &&
- m_buffer.contains( "ERR", true ) == 0 &&
- m_buffer.contains( "/bin/sh:" ) == 0 &&
- m_buffer.contains( "mount:", true ) == 0 &&
- m_buffer.contains( "smbmnt" ) == 0 &&
- m_buffer.contains( m_priv->path() ) == 0 &&
- m_buffer.contains( "mount error" ) == 0 &&
- m_buffer.contains( "bad user name" ) == 0 &&
- m_buffer.contains( "bad group name" ) == 0 )
+ if ( m_buffer.tqcontains( "smb4k_mount:", true ) == 0 &&
+ m_buffer.tqcontains( "failed", true ) == 0 &&
+ m_buffer.tqcontains( "ERR", true ) == 0 &&
+ m_buffer.tqcontains( "/bin/sh:" ) == 0 &&
+ m_buffer.tqcontains( "mount:", true ) == 0 &&
+ m_buffer.tqcontains( "smbmnt" ) == 0 &&
+ m_buffer.tqcontains( m_priv->path() ) == 0 &&
+ m_buffer.tqcontains( "mount error" ) == 0 &&
+ m_buffer.tqcontains( "bad user name" ) == 0 &&
+ m_buffer.tqcontains( "bad group name" ) == 0 )
{
- QString name = QString( "//%1/%2" ).arg( m_priv->host() ).arg( m_priv->share() );
+ TQString name = TQString( "//%1/%2" ).tqarg( m_priv->host() ).tqarg( m_priv->share() );
// Check file system
#if !defined(__solaris__)
@@ -1061,15 +1061,15 @@ void Smb4KMounter::processMount()
#endif
{
// The query failed. Go with the file system already defined in m_priv.
- if ( QString::compare( m_priv->filesystem(), "smbfs" ) == 0 )
+ if ( TQString::compare( m_priv->filesystem(), "smbfs" ) == 0 )
{
share = new Smb4KShare( name, m_priv->path(), m_priv->filesystem(), (int)getuid(), (int)getgid() );
m_mounted_shares.append( share );
}
- else if ( QString::compare( m_priv->filesystem(), "cifs" ) == 0 )
+ else if ( TQString::compare( m_priv->filesystem(), "cifs" ) == 0 )
{
// The user name will be send if no login was specified.
- QString cifs_login = !m_priv->cifsLogin().isEmpty() ?
+ TQString cifs_login = !m_priv->cifsLogin().isEmpty() ?
m_priv->cifsLogin() :
getpwuid( getuid() )->pw_name;
@@ -1083,7 +1083,7 @@ void Smb4KMounter::processMount()
if ( (uint)filesystem.f_type == 0xFF534D42 /* CIFS */)
{
// The user name will be send if no login was specified.
- QString cifs_login = !m_priv->cifsLogin().isEmpty() ?
+ TQString cifs_login = !m_priv->cifsLogin().isEmpty() ?
m_priv->cifsLogin() :
getpwuid( getuid() )->pw_name;
@@ -1099,7 +1099,7 @@ void Smb4KMounter::processMount()
if ( (uint)filesystem.f_basetype == 0xFF534D42 /* CIFS */)
{
// The user name will be send if no login was specified.
- QString cifs_login = !m_priv->cifsLogin().isEmpty() ?
+ TQString cifs_login = !m_priv->cifsLogin().isEmpty() ?
m_priv->cifsLogin() :
getpwuid( getuid() )->pw_name;
@@ -1115,7 +1115,7 @@ void Smb4KMounter::processMount()
if ( (uint)filesystem.f_fstyp == 0xFF534D42 /* CIFS */)
{
// The user name will be send if no login was specified.
- QString cifs_login = !m_priv->cifsLogin().isEmpty() ?
+ TQString cifs_login = !m_priv->cifsLogin().isEmpty() ?
m_priv->cifsLogin() :
getpwuid( getuid() )->pw_name;
@@ -1144,21 +1144,21 @@ void Smb4KMounter::processMount()
}
else
{
- if ( m_buffer.contains( "ERRbadpw" ) != 0 ||
- m_buffer.contains( "ERRnoaccess" ) != 0 ||
- m_buffer.contains( "mount error 13 = Permission denied" ) != 0 )
+ if ( m_buffer.tqcontains( "ERRbadpw" ) != 0 ||
+ m_buffer.tqcontains( "ERRnoaccess" ) != 0 ||
+ m_buffer.tqcontains( "mount error 13 = Permission denied" ) != 0 )
{
int state = Smb4KPasswordHandler::None;
- if ( m_buffer.contains( "ERRbadpw" ) != 0 )
+ if ( m_buffer.tqcontains( "ERRbadpw" ) != 0 )
{
state = Smb4KPasswordHandler::BadPassword;
}
- else if ( m_buffer.contains( "ERRnoaccess" ) != 0 )
+ else if ( m_buffer.tqcontains( "ERRnoaccess" ) != 0 )
{
state = Smb4KPasswordHandler::AccessDenied;
}
- else if ( m_buffer.contains( "mount error 13 = Permission denied" ) != 0 )
+ else if ( m_buffer.tqcontains( "mount error 13 = Permission denied" ) != 0 )
{
state = Smb4KPasswordHandler::PermDenied;
}
@@ -1169,14 +1169,14 @@ void Smb4KMounter::processMount()
mountShare( m_priv->workgroup(), m_priv->host(), m_priv->ip(), m_priv->share() );
}
}
- else if ( m_buffer.contains( "ERRnosuchshare" ) != 0 && m_priv->share().contains( "_" ) != 0 )
+ else if ( m_buffer.tqcontains( "ERRnosuchshare" ) != 0 && m_priv->share().tqcontains( "_" ) != 0 )
{
- QString share_string = static_cast<QString>( m_priv->share() ).replace( "_", " " );
+ TQString share_string = static_cast<TQString>( m_priv->share() ).tqreplace( "_", " " );
mountShare( m_priv->workgroup(), m_priv->host(), m_priv->ip(), share_string );
}
else
{
- QString name = QString( "//%1/%2" ).arg( m_priv->host() ).arg( m_priv->share() );
+ TQString name = TQString( "//%1/%2" ).tqarg( m_priv->host() ).tqarg( m_priv->share() );
Smb4KError::error( ERROR_MOUNTING_SHARE, name, m_buffer );
}
@@ -1187,20 +1187,20 @@ void Smb4KMounter::processMount()
if ( m_proc->normalExit() )
{
- if ( m_buffer.contains( "smb4k_mount:", true ) == 0 &&
- m_buffer.contains( "syserr =", true ) == 0 &&
+ if ( m_buffer.tqcontains( "smb4k_mount:", true ) == 0 &&
+ m_buffer.tqcontains( "syserr =", true ) == 0 &&
/* To make sure we catch all errors, also check for the following
strings. Maybe we can remove them?? */
- m_buffer.contains( "Authentication error", true ) == 0 &&
- m_buffer.contains( "Connection refused", true ) == 0 &&
- m_buffer.contains( "Operation not permitted", true ) == 0 )
+ m_buffer.tqcontains( "Authentication error", true ) == 0 &&
+ m_buffer.tqcontains( "Connection refused", true ) == 0 &&
+ m_buffer.tqcontains( "Operation not permitted", true ) == 0 )
{
import(); // FIXME: *cough* What is this for???
Smb4KAuthInfo authInfo( m_priv->workgroup(), m_priv->host(), m_priv->share() );
(void) passwordHandler()->readAuth( &authInfo );
- QString name = QString( "//%1@%2/%3" ).arg( authInfo.user().upper(), m_priv->host().upper(), m_priv->share().upper() );
+ TQString name = TQString( "//%1@%2/%3" ).tqarg( authInfo.user().upper(), m_priv->host().upper(), m_priv->share().upper() );
share = new Smb4KShare( name, m_priv->path(), m_priv->filesystem(), (int)getuid(), (int)getgid() );
m_mounted_shares.append( share );
@@ -1212,7 +1212,7 @@ void Smb4KMounter::processMount()
}
else
{
- if ( m_buffer.contains( "Authentication error" ) != 0 )
+ if ( m_buffer.tqcontains( "Authentication error" ) != 0 )
{
// If the user supplied auth information, we will retry mounting.
if ( passwordHandler()->askpass( m_priv->workgroup(), m_priv->host(), m_priv->share(), Smb4KPasswordHandler::AuthError ) )
@@ -1225,7 +1225,7 @@ void Smb4KMounter::processMount()
Smb4KAuthInfo authInfo( m_priv->workgroup(), m_priv->host(), m_priv->share() );
(void) passwordHandler()->readAuth( &authInfo );
- QString name = QString( "//%1@%2/%3" ).arg( authInfo.user().upper(), m_priv->host().upper(), m_priv->share().upper() );
+ TQString name = TQString( "//%1@%2/%3" ).tqarg( authInfo.user().upper(), m_priv->host().upper(), m_priv->share().upper() );
Smb4KError::error( ERROR_MOUNTING_SHARE, name, m_buffer );
}
@@ -1251,11 +1251,11 @@ void Smb4KMounter::processUnmount()
{
if ( m_buffer.isEmpty() )
{
- if ( qstrncmp( share->canonicalPath(),
- QDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit(),
- QDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit().length() ) == 0 )
+ if ( tqstrncmp( share->canonicalPath(),
+ TQDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit(),
+ TQDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit().length() ) == 0 )
{
- QDir dir( share->canonicalPath() );
+ TQDir dir( share->canonicalPath() );
if ( dir.rmdir( dir.canonicalPath(), true ) )
{
@@ -1272,7 +1272,7 @@ void Smb4KMounter::processUnmount()
// rare circumstances it might occur that sudo reports an error,
// because it is not able to resolve the host. This error message
// will be removed, because it does not affect the unmounting:
- if ( m_buffer.contains( "sudo: unable to resolve host", true ) != 0 )
+ if ( m_buffer.tqcontains( "sudo: unable to resolve host", true ) != 0 )
{
size_t hostnamelen = 255;
char *hostname = new char[hostnamelen];
@@ -1280,11 +1280,11 @@ void Smb4KMounter::processUnmount()
if ( gethostname( hostname, hostnamelen ) == -1 )
{
int error_number = errno;
- Smb4KError::error( ERROR_GETTING_HOSTNAME, QString::null, strerror( error_number ) );
+ Smb4KError::error( ERROR_GETTING_HOSTNAME, TQString(), strerror( error_number ) );
}
else
{
- QString str = QString( "sudo: unable to resolve host %1\n" ).arg( hostname );
+ TQString str = TQString( "sudo: unable to resolve host %1\n" ).tqarg( hostname );
m_buffer.remove( str, false /* case insensitive */ );
@@ -1294,11 +1294,11 @@ void Smb4KMounter::processUnmount()
}
else
{
- if ( qstrncmp( share->canonicalPath(),
- QDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit(),
- QDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit().length() ) == 0 )
+ if ( tqstrncmp( share->canonicalPath(),
+ TQDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit(),
+ TQDir( Smb4KSettings::mountPrefix() ).canonicalPath().local8Bit().length() ) == 0 )
{
- QDir dir( share->canonicalPath() );
+ TQDir dir( share->canonicalPath() );
if ( dir.rmdir( dir.canonicalPath(), true ) )
{
@@ -1328,15 +1328,15 @@ void Smb4KMounter::processUnmount()
Check if a share is already mounted
***************************************************************************/
-bool Smb4KMounter::isMounted( const QString &name, bool userOnly )
+bool Smb4KMounter::isMounted( const TQString &name, bool userOnly )
{
- QValueList<Smb4KShare> list = findShareByName( name );
+ TQValueList<Smb4KShare> list = findShareByName( name );
bool mounted = false;
if ( !list.isEmpty() && userOnly )
{
- for ( QValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQValueList<Smb4KShare>::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( !(*it).isForeign() )
{
@@ -1363,7 +1363,7 @@ bool Smb4KMounter::isMounted( const QString &name, bool userOnly )
Find a share in the list with its path
***************************************************************************/
-Smb4KShare* Smb4KMounter::findShareByPath( const QString &path )
+Smb4KShare* Smb4KMounter::findShareByPath( const TQString &path )
{
if ( path.isEmpty() || m_mounted_shares.isEmpty() )
{
@@ -1372,10 +1372,10 @@ Smb4KShare* Smb4KMounter::findShareByPath( const QString &path )
Smb4KShare *share = NULL;
- for ( QValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
- if( QString::compare( path.upper(), QString::fromLocal8Bit( (*it)->path(), -1 ).upper() ) == 0 ||
- QString::compare( path.upper(), QString::fromLocal8Bit( (*it)->canonicalPath(), -1 ).upper() ) == 0 )
+ if( TQString::compare( path.upper(), TQString(TQString::fromLocal8Bit( (*it)->path(), -1 )).upper() ) == 0 ||
+ TQString::compare( path.upper(), TQString(TQString::fromLocal8Bit( (*it)->canonicalPath(), -1 )).upper() ) == 0 )
{
share = *it;
@@ -1391,21 +1391,21 @@ Smb4KShare* Smb4KMounter::findShareByPath( const QString &path )
Find the list of mounts of a share
***************************************************************************/
-QValueList<Smb4KShare> Smb4KMounter::findShareByName( const QString &name )
+TQValueList<Smb4KShare> Smb4KMounter::findShareByName( const TQString &name )
{
- QValueList<Smb4KShare> list;
+ TQValueList<Smb4KShare> list;
if ( name.isEmpty() || m_mounted_shares.isEmpty() )
{
return list; // is empty
}
- QString n = name;
+ TQString n = name;
- for ( QValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
- if( QString::compare( (*it)->name().upper(), name.upper() ) == 0 ||
- QString::compare( (*it)->name().upper(), n.replace( " ", "_" ).upper() ) == 0 )
+ if( TQString::compare( (*it)->name().upper(), name.upper() ) == 0 ||
+ TQString::compare( (*it)->name().upper(), n.tqreplace( " ", "_" ).upper() ) == 0 )
{
list.append( *(*it) );
@@ -1425,11 +1425,11 @@ QValueList<Smb4KShare> Smb4KMounter::findShareByName( const QString &name )
Returns a list of mount points that belong to broken shares
***************************************************************************/
-const QValueList<Smb4KShare *> Smb4KMounter::getBrokenShares()
+const TQValueList<Smb4KShare *> Smb4KMounter::getBrokenShares()
{
- QValueList<Smb4KShare *> broken_shares;
+ TQValueList<Smb4KShare *> broken_shares;
- for ( QValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
if ( (*it)->isBroken() )
{
@@ -1474,14 +1474,14 @@ void Smb4KMounter::checkAccessibility( Smb4KShare *share )
}
-void Smb4KMounter::timerEvent( QTimerEvent * )
+void Smb4KMounter::timerEvent( TQTimerEvent * )
{
if ( !m_working && !m_queue.isEmpty() )
{
// Tell the mounter, that it is busy.
m_working = true;
- QString *item = m_queue.dequeue();
+ TQString *item = m_queue.dequeue();
int todo = item->section( ":", 0, 0 ).toInt();
switch ( todo )
@@ -1527,14 +1527,14 @@ void Smb4KMounter::timerEvent( QTimerEvent * )
if ( m_priv->timerTicks * timerInterval() >= Smb4KSettings::checkInterval() /* msec */ &&
(!m_working || m_queue.isEmpty()) )
{
- m_queue.enqueue( new QString( QString( "%1:" ).arg( Import ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:" ).tqarg( Import ) ) );
m_priv->timerTicks = 0;
}
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
@@ -1546,13 +1546,13 @@ void Smb4KMounter::slotProcessExited( KProcess * )
void Smb4KMounter::slotReceivedStdout( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
void Smb4KMounter::slotReceivedStderr( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
@@ -1564,7 +1564,7 @@ void Smb4KMounter::slotShutdown()
// Prepare for shutdown:
if ( Smb4KSettings::remountShares() && !m_mounted_shares.isEmpty() )
{
- for ( QValueList<Smb4KShare *>::ConstIterator it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueList<Smb4KShare *>::ConstIterator it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
optionsHandler()->remount( *it, !(*it)->isForeign() );
}
@@ -1572,26 +1572,26 @@ void Smb4KMounter::slotShutdown()
optionsHandler()->sync();
- QDir dir;
+ TQDir dir;
dir.cd( Smb4KSettings::mountPrefix() );
- QStringList dirs = dir.entryList( QDir::Dirs, QDir::DefaultSort );
+ TQStringList dirs = dir.entryList( TQDir::Dirs, TQDir::DefaultSort );
- QValueList<Smb4KShare *> broken_shares = getBrokenShares();
+ TQValueList<Smb4KShare *> broken_shares = getBrokenShares();
- for ( QStringList::ConstIterator it = dirs.begin(); it != dirs.end(); ++it )
+ for ( TQStringList::ConstIterator it = dirs.begin(); it != dirs.end(); ++it )
{
- if ( QString::compare( *it, "." ) != 0 && QString::compare( *it, ".." ) != 0 )
+ if ( TQString::compare( *it, "." ) != 0 && TQString::compare( *it, ".." ) != 0 )
{
bool broken = false;
- for ( QValueListIterator<Smb4KShare *> bs = broken_shares.begin(); bs != broken_shares.end(); ++bs )
+ for ( TQValueListIterator<Smb4KShare *> bs = broken_shares.begin(); bs != broken_shares.end(); ++bs )
{
- if ( qstrncmp( (*bs)->path(),
+ if ( tqstrncmp( (*bs)->path(),
Smb4KSettings::mountPrefix()+*it,
(Smb4KSettings::mountPrefix()+*it).length() ) == 0 ||
- qstrncmp( (*bs)->canonicalPath(),
+ tqstrncmp( (*bs)->canonicalPath(),
Smb4KSettings::mountPrefix()+*it,
(Smb4KSettings::mountPrefix()+*it).length() ) == 0 )
{
@@ -1609,11 +1609,11 @@ void Smb4KMounter::slotShutdown()
{
dir.cd( *it );
- QStringList subdirs = dir.entryList( QDir::Dirs, QDir::DefaultSort );
+ TQStringList subdirs = dir.entryList( TQDir::Dirs, TQDir::DefaultSort );
- for ( QStringList::ConstIterator i = subdirs.begin(); i != subdirs.end(); ++i )
+ for ( TQStringList::ConstIterator i = subdirs.begin(); i != subdirs.end(); ++i )
{
- if ( QString::compare( *i, "." ) != 0 && QString::compare( *i, ".." ) != 0 )
+ if ( TQString::compare( *i, "." ) != 0 && TQString::compare( *i, ".." ) != 0 )
{
dir.rmdir( *i );
}
@@ -1629,7 +1629,7 @@ void Smb4KMounter::slotShutdown()
if ( Smb4KSettings::unmountSharesOnExit() )
{
- QString suid_program, command;
+ TQString suid_program, command;
switch( Smb4KSettings::superUserProgram() )
{
@@ -1656,16 +1656,16 @@ void Smb4KMounter::slotShutdown()
proc.setUseShell( true );
proc.detach();
- for ( QValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
+ for ( TQValueListIterator<Smb4KShare *> it = m_mounted_shares.begin(); it != m_mounted_shares.end(); ++it )
{
if ( !(*it)->isForeign() )
{
if ( Smb4KSettings::alwaysUseSuperUser() )
{
#ifndef __FreeBSD__
- command.append( QString( "%1 smb4k_umount -s -t %2 " ).arg( suid_program ).arg( (*it)->filesystem() ) );
+ command.append( TQString( "%1 smb4k_umount -s -t %2 " ).tqarg( suid_program ).tqarg( (*it)->filesystem() ) );
#else
- command.append( QString( "%1 smb4k_umount " ).arg( suid_program ) );
+ command.append( TQString( "%1 smb4k_umount " ).tqarg( suid_program ) );
#endif
command.append( KProcess::quote( (*it)->path() ) );
command.append( " ; " );
@@ -1673,7 +1673,7 @@ void Smb4KMounter::slotShutdown()
else
{
#ifndef __FreeBSD__
- command.append( QString( "smb4k_umount -n -t %1 " ).arg( (*it)->filesystem() ) );
+ command.append( TQString( "smb4k_umount -n -t %1 " ).tqarg( (*it)->filesystem() ) );
#else
command.append( "smb4k_umount " );
#endif
diff --git a/smb4k/core/smb4kmounter.h b/smb4k/core/smb4kmounter.h
index a5f51db..be29116 100644
--- a/smb4k/core/smb4kmounter.h
+++ b/smb4k/core/smb4kmounter.h
@@ -30,11 +30,11 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qstringlist.h>
-#include <qptrqueue.h>
-#include <qfile.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqstringlist.h>
+#include <tqptrqueue.h>
+#include <tqfile.h>
// KDE includes
#include <kprocess.h>
@@ -56,15 +56,16 @@ class Smb4KShare;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KMounter : public QObject
+class Smb4KMounter : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*/
- Smb4KMounter( QObject *parent = 0, const char *name = 0 );
+ Smb4KMounter( TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor.
*/
@@ -112,17 +113,17 @@ class Smb4KMounter : public QObject
*
* @param share The name of the share.
*/
- void mountShare( const QString &workgroup, const QString &host, const QString &ip, const QString &share );
+ void mountShare( const TQString &workgroup, const TQString &host, const TQString &ip, const TQString &share );
/**
* Returns the unsorted list of mounted shares.
*/
- const QValueList<Smb4KShare *> &getShares() { return m_mounted_shares; };
+ const TQValueList<Smb4KShare *> &getShares() { return m_mounted_shares; };
/**
* Find a share in the list with its path.
*/
- Smb4KShare* findShareByPath( const QString &path );
+ Smb4KShare* findShareByPath( const TQString &path );
/**
* Find all mounts of the particular share @p share on the system.
@@ -131,7 +132,7 @@ class Smb4KMounter : public QObject
*
* @returns the complete list of mounts of @p share.
*/
- QValueList<Smb4KShare> findShareByName( const QString &name );
+ TQValueList<Smb4KShare> findShareByName( const TQString &name );
/**
* This function returns TRUE if a share is mounted and FALSE otherwise.
@@ -145,7 +146,7 @@ class Smb4KMounter : public QObject
*
* @return TRUE if the share is mounted and FALSE otherwise.
*/
- bool isMounted( const QString &name, bool userOnly = true );
+ bool isMounted( const TQString &name, bool userOnly = true );
/**
* This function reports if the mounter is running or not.
@@ -159,7 +160,7 @@ class Smb4KMounter : public QObject
*
* @returns The list of broken shares.
*/
- const QValueList<Smb4KShare *> getBrokenShares();
+ const TQValueList<Smb4KShare *> getBrokenShares();
/**
* This function executes Smb4KMounter::slotShutdown(). Under normal circumstances,
@@ -195,7 +196,7 @@ class Smb4KMounter : public QObject
*
* @param mountpoint The mount point of the share.
*/
- void mountedShare( const QString &mountpoint );
+ void mountedShare( const TQString &mountpoint );
/**
* This signal is emitted just before a share is unmounted.
@@ -203,7 +204,7 @@ class Smb4KMounter : public QObject
* @param mountpoint The mount point of the share that is going to
* be unmounted.
*/
- void aboutToUnmount( const QString &mountpoint );
+ void aboutToUnmount( const TQString &mountpoint );
protected:
/**
@@ -228,9 +229,9 @@ class Smb4KMounter : public QObject
void processUnmount();
/**
- * Reimplemented from QObject
+ * Reimplemented from TQObject
*/
- void timerEvent( QTimerEvent *e );
+ void timerEvent( TQTimerEvent *e );
protected slots:
/**
@@ -269,12 +270,12 @@ class Smb4KMounter : public QObject
/**
* Mounts a selected share.
*/
- void mount( const QString &workgroup, const QString &host, const QString &ip, const QString &share );
+ void mount( const TQString &workgroup, const TQString &host, const TQString &ip, const TQString &share );
/**
* Unmounts the selected item.
*/
- void unmount( const QString &mountpoint, bool noMessage, bool force = false );
+ void unmount( const TQString &mountpoint, bool noMessage, bool force = false );
/**
* Unmounts all shares at once.
@@ -298,12 +299,12 @@ class Smb4KMounter : public QObject
/**
* The buffer.
*/
- QString m_buffer;
+ TQString m_buffer;
/**
* The queue, where the incoming requests are stored.
*/
- QPtrQueue<QString> m_queue;
+ TQPtrQueue<TQString> m_queue;
/**
* Determines, whether the mounter is running or not.
@@ -313,7 +314,7 @@ class Smb4KMounter : public QObject
/**
* Holds the list of currently mounted shares as a pointer list.
*/
- QValueList<Smb4KShare *> m_mounted_shares;
+ TQValueList<Smb4KShare *> m_mounted_shares;
/**
* Makes sure that the error message concerning the missing of
@@ -331,7 +332,7 @@ class Smb4KMounter : public QObject
/**
* This file object points to /proc/mounts.
*/
- QFile m_proc_mounts;
+ TQFile m_proc_mounts;
#endif
/**
diff --git a/smb4k/core/smb4kmounter_p.cpp b/smb4k/core/smb4kmounter_p.cpp
index 96d1149..90bc6ab 100644
--- a/smb4k/core/smb4kmounter_p.cpp
+++ b/smb4k/core/smb4kmounter_p.cpp
@@ -41,95 +41,95 @@ Smb4KMounterPrivate::~Smb4KMounterPrivate()
void Smb4KMounterPrivate::clearData()
{
- m_workgroup = QString::null;
- m_host = QString::null;
- m_share = QString::null;
- m_ip = QString::null;
- m_path = QString::null;
- m_filesystem = QString::null;
- m_cifsLogin = QString::null;
+ m_workgroup = TQString();
+ m_host = TQString();
+ m_share = TQString();
+ m_ip = TQString();
+ m_path = TQString();
+ m_filesystem = TQString();
+ m_cifsLogin = TQString();
}
-const QString &Smb4KMounterPrivate::workgroup()
+const TQString &Smb4KMounterPrivate::workgroup()
{
return m_workgroup;
}
-const QString &Smb4KMounterPrivate::host()
+const TQString &Smb4KMounterPrivate::host()
{
return m_host;
}
-const QString &Smb4KMounterPrivate::share()
+const TQString &Smb4KMounterPrivate::share()
{
return m_share;
}
-const QString &Smb4KMounterPrivate::ip()
+const TQString &Smb4KMounterPrivate::ip()
{
return m_ip;
}
-const QString &Smb4KMounterPrivate::path()
+const TQString &Smb4KMounterPrivate::path()
{
return m_path;
}
-const QString &Smb4KMounterPrivate::filesystem()
+const TQString &Smb4KMounterPrivate::filesystem()
{
return m_filesystem;
}
-const QString &Smb4KMounterPrivate::cifsLogin()
+const TQString &Smb4KMounterPrivate::cifsLogin()
{
return m_cifsLogin;
}
-void Smb4KMounterPrivate::setWorkgroup( const QString &wg )
+void Smb4KMounterPrivate::setWorkgroup( const TQString &wg )
{
m_workgroup = wg;
}
-void Smb4KMounterPrivate::setHost( const QString &h )
+void Smb4KMounterPrivate::setHost( const TQString &h )
{
m_host = h;
}
-void Smb4KMounterPrivate::setShare( const QString &s )
+void Smb4KMounterPrivate::setShare( const TQString &s )
{
m_share = s;
}
-void Smb4KMounterPrivate::setIP( const QString &i )
+void Smb4KMounterPrivate::setIP( const TQString &i )
{
m_ip = i;
}
-void Smb4KMounterPrivate::setPath( const QString &p )
+void Smb4KMounterPrivate::setPath( const TQString &p )
{
m_path = p;
}
-void Smb4KMounterPrivate::setFileSystem( const QString &f )
+void Smb4KMounterPrivate::setFileSystem( const TQString &f )
{
m_filesystem = f;
}
-void Smb4KMounterPrivate::setCIFSLogin( const QString &l )
+void Smb4KMounterPrivate::setCIFSLogin( const TQString &l )
{
m_cifsLogin = l;
}
diff --git a/smb4k/core/smb4kmounter_p.h b/smb4k/core/smb4kmounter_p.h
index 334ffa3..a6dc145 100644
--- a/smb4k/core/smb4kmounter_p.h
+++ b/smb4k/core/smb4kmounter_p.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qthread.h>
-#include <qstring.h>
+// TQt includes
+#include <tqthread.h>
+#include <tqstring.h>
// KDE includes
#include <kdebug.h>
@@ -47,13 +47,13 @@ class Smb4KMounterPrivate
~Smb4KMounterPrivate();
int timerTicks;
- class Thread : public QThread
+ class Thread : public TQThread
{
public:
- Thread() : QThread(), m_mountpoint( QString::null ), m_broken( true ) {}
+ Thread() : TQThread(), m_mountpoint( TQString() ), m_broken( true ) {}
~Thread() {}
- void setMountpoint( const QString &mp ) { m_mountpoint = mp; }
+ void setMountpoint( const TQString &mp ) { m_mountpoint = mp; }
virtual void run()
{
@@ -82,7 +82,7 @@ class Smb4KMounterPrivate
m_free = free;
}
- m_mountpoint = QString::null;
+ m_mountpoint = TQString();
}
bool isBroken() { return m_broken; }
@@ -90,7 +90,7 @@ class Smb4KMounterPrivate
double freeDiskSpace() { return m_free; }
private:
- QString m_mountpoint;
+ TQString m_mountpoint;
bool m_broken;
double m_total;
double m_free;
@@ -98,29 +98,29 @@ class Smb4KMounterPrivate
Thread thread;
void clearData();
- const QString &workgroup();
- const QString &host();
- const QString &share();
- const QString &ip();
- const QString &path();
- const QString &filesystem();
- const QString &cifsLogin();
- void setWorkgroup ( const QString &wg );
- void setHost( const QString &h );
- void setShare( const QString &s );
- void setIP( const QString &i );
- void setPath( const QString &p );
- void setFileSystem( const QString &f );
- void setCIFSLogin( const QString &l );
+ const TQString &workgroup();
+ const TQString &host();
+ const TQString &share();
+ const TQString &ip();
+ const TQString &path();
+ const TQString &filesystem();
+ const TQString &cifsLogin();
+ void setWorkgroup ( const TQString &wg );
+ void setHost( const TQString &h );
+ void setShare( const TQString &s );
+ void setIP( const TQString &i );
+ void setPath( const TQString &p );
+ void setFileSystem( const TQString &f );
+ void setCIFSLogin( const TQString &l );
private:
- QString m_workgroup;
- QString m_host;
- QString m_share;
- QString m_ip;
- QString m_path;
- QString m_filesystem;
- QString m_cifsLogin;
+ TQString m_workgroup;
+ TQString m_host;
+ TQString m_share;
+ TQString m_ip;
+ TQString m_path;
+ TQString m_filesystem;
+ TQString m_cifsLogin;
};
#endif
diff --git a/smb4k/core/smb4knetworkitems.cpp b/smb4k/core/smb4knetworkitems.cpp
index b278640..9bf9f1a 100644
--- a/smb4k/core/smb4knetworkitems.cpp
+++ b/smb4k/core/smb4knetworkitems.cpp
@@ -36,10 +36,10 @@
Smb4KWorkgroupItem class
****************************************************************************/
-Smb4KWorkgroupItem::Smb4KWorkgroupItem( const QString &name, const QString &master, const QString &masterIP )
+Smb4KWorkgroupItem::Smb4KWorkgroupItem( const TQString &name, const TQString &master, const TQString &masterIP )
: m_name( name ), m_master( master ), m_pseudo( false )
{
- m_ip = ipIsValid( masterIP ) ? masterIP : QString::null;
+ m_ip = ipIsValid( masterIP ) ? masterIP : TQString();
}
@@ -54,21 +54,21 @@ void Smb4KWorkgroupItem::setPseudoMaster()
}
-void Smb4KWorkgroupItem::setMasterIP( const QString &ip )
+void Smb4KWorkgroupItem::setMasterIP( const TQString &ip )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
}
-void Smb4KWorkgroupItem::setMaster( const QString &name, const QString &ip, bool pseudo )
+void Smb4KWorkgroupItem::setMaster( const TQString &name, const TQString &ip, bool pseudo )
{
m_master = name;
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
m_pseudo = pseudo;
}
-bool Smb4KWorkgroupItem::ipIsValid( const QString &ip )
+bool Smb4KWorkgroupItem::ipIsValid( const TQString &ip )
{
if ( !ip.isEmpty() )
{
@@ -92,12 +92,12 @@ bool Smb4KWorkgroupItem::ipIsValid( const QString &ip )
Smb4KHostItem class
****************************************************************************/
-Smb4KHostItem::Smb4KHostItem( const QString &workgroup, const QString &name, const QString &comment, const QString &ip )
-: m_workgroup( workgroup ), m_name( name ), m_comment( comment ), m_server_string( QString::null ),
- m_os_string( QString::null ), m_master( false ), m_ip_checked( m_ip.stripWhiteSpace().isEmpty() ? false : true ),
+Smb4KHostItem::Smb4KHostItem( const TQString &workgroup, const TQString &name, const TQString &comment, const TQString &ip )
+: m_workgroup( workgroup ), m_name( name ), m_comment( comment ), m_server_string( TQString() ),
+ m_os_string( TQString() ), m_master( false ), m_ip_checked( m_ip.stripWhiteSpace().isEmpty() ? false : true ),
m_info_checked( false )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
}
@@ -116,13 +116,13 @@ Smb4KHostItem::~Smb4KHostItem()
}
-void Smb4KHostItem::setServerString( const QString &server )
+void Smb4KHostItem::setServerString( const TQString &server )
{
m_server_string = server;
}
-void Smb4KHostItem::setOSString( const QString &os )
+void Smb4KHostItem::setOSString( const TQString &os )
{
m_os_string = os;
}
@@ -134,13 +134,13 @@ void Smb4KHostItem::setMaster( bool master )
}
-void Smb4KHostItem::setIPAddress( const QString &ip )
+void Smb4KHostItem::setIPAddress( const TQString &ip )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
}
-void Smb4KHostItem::setComment( const QString &comment )
+void Smb4KHostItem::setComment( const TQString &comment )
{
m_comment = comment;
}
@@ -158,7 +158,7 @@ void Smb4KHostItem::setInfoChecked( bool yes )
}
-bool Smb4KHostItem::ipIsValid( const QString &ip )
+bool Smb4KHostItem::ipIsValid( const TQString &ip )
{
if ( !ip.isEmpty() )
{
@@ -182,7 +182,7 @@ bool Smb4KHostItem::ipIsValid( const QString &ip )
Smb4KShareItem class
****************************************************************************/
-Smb4KShareItem::Smb4KShareItem( const QString &workgroup, const QString &host, const QString &name, const QString &type, const QString &comment )
+Smb4KShareItem::Smb4KShareItem( const TQString &workgroup, const TQString &host, const TQString &name, const TQString &type, const TQString &comment )
: m_workgroup( workgroup ), m_host( host ), m_name( name ), m_type( type ), m_comment( comment )
{
}
@@ -193,15 +193,15 @@ Smb4KShareItem::~Smb4KShareItem()
}
-const QString Smb4KShareItem::translatedType() const
+const TQString Smb4KShareItem::translatedType() const
{
- QString return_string;
+ TQString return_string;
- if ( QString::compare( m_type, "Disk" ) == 0 )
+ if ( TQString::compare( m_type, "Disk" ) == 0 )
{
return_string = i18n( "Disk" );
}
- else if ( QString::compare( m_type, "Print" ) == 0 || QString::compare( m_type, "Printer" ) == 0 )
+ else if ( TQString::compare( m_type, "Print" ) == 0 || TQString::compare( m_type, "Printer" ) == 0 )
{
return_string = i18n( "Printer" );
}
@@ -222,18 +222,18 @@ bool Smb4KShareItem::isHidden() const
bool Smb4KShareItem::isPrinter() const
{
- return (QString::compare( m_type, "Print" ) == 0 || QString::compare( m_type, "Printer" ) == 0);
+ return (TQString::compare( m_type, "Print" ) == 0 || TQString::compare( m_type, "Printer" ) == 0);
}
bool Smb4KShareItem::isIPC() const
{
- return (QString::compare( m_name.stripWhiteSpace(), "IPC$" ) == 0);
+ return (TQString::compare( m_name.stripWhiteSpace(), "IPC$" ) == 0);
}
bool Smb4KShareItem::isADMIN() const
{
- return (QString::compare( m_name.stripWhiteSpace(), "ADMIN$" ) == 0);
+ return (TQString::compare( m_name.stripWhiteSpace(), "ADMIN$" ) == 0);
}
diff --git a/smb4k/core/smb4knetworkitems.h b/smb4k/core/smb4knetworkitems.h
index abfff2a..963093f 100644
--- a/smb4k/core/smb4knetworkitems.h
+++ b/smb4k/core/smb4knetworkitems.h
@@ -31,9 +31,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qstring.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqstring.h>
/**
* This class provides a container for a workgroup/domain found in the network
@@ -52,9 +52,9 @@ class Smb4KWorkgroupItem
*
* @param masterIP The IP address of the workgroup master browser.
*/
- Smb4KWorkgroupItem( const QString &name,
- const QString &master,
- const QString &masterIP = QString::null );
+ Smb4KWorkgroupItem( const TQString &name,
+ const TQString &master,
+ const TQString &masterIP = TQString() );
/**
* Empty constructor.
@@ -69,21 +69,21 @@ class Smb4KWorkgroupItem
/**
* Returns the workgroup name.
*/
- const QString &name() const { return m_name; }
+ const TQString &name() const { return m_name; }
/**
* Returns the name of the master browser.
*/
- const QString &master() const { return m_master; }
+ const TQString &master() const { return m_master; }
/**
* Returns the IP address of the master browser. If it is not a valid
- * IPv4 or IPv6 address, QString::null is returned.
+ * IPv4 or IPv6 address, TQString() is returned.
*
* @returns the valid IP v4 or v6 address of the workgroup master browser
- * or QString::null.
+ * or TQString().
*/
- const QString &masterIP() const { return m_ip; }
+ const TQString &masterIP() const { return m_ip; }
/**
* You can mark the master as 'pseudo' with this function. That means that
@@ -103,7 +103,7 @@ class Smb4KWorkgroupItem
*
* @param ip The IP address of the master browser
*/
- void setMasterIP( const QString &ip );
+ void setMasterIP( const TQString &ip );
/**
* This function sets the master browser.
@@ -115,25 +115,25 @@ class Smb4KWorkgroupItem
* @param pseudo Determines if this is a real master browser or if
* it is a faked one, i.e. a pseudo master.
*/
- void setMaster( const QString &name,
- const QString &ip,
+ void setMaster( const TQString &name,
+ const TQString &ip,
bool pseudo = false );
private:
/**
* The name of the workgroup.
*/
- QString m_name;
+ TQString m_name;
/**
* The name of the workgroup master.
*/
- QString m_master;
+ TQString m_master;
/**
* The IP address of the master.
*/
- QString m_ip;
+ TQString m_ip;
/**
* Determines whether the master is a 'pseudo'-master.
@@ -149,7 +149,7 @@ class Smb4KWorkgroupItem
*
* @returns TRUE if the IP address is valid and FALSE otherwise.
*/
- bool ipIsValid( const QString &ip );
+ bool ipIsValid( const TQString &ip );
};
@@ -172,10 +172,10 @@ class Smb4KHostItem
*
* @param ip The IP address of the host
*/
- Smb4KHostItem( const QString &workgroup,
- const QString &name,
- const QString &comment = QString::null,
- const QString &ip = QString::null );
+ Smb4KHostItem( const TQString &workgroup,
+ const TQString &name,
+ const TQString &comment = TQString(),
+ const TQString &ip = TQString() );
/**
* The copy constructor.
@@ -197,42 +197,42 @@ class Smb4KHostItem
/**
* Returns the workgroup the host is in.
*/
- const QString &workgroup() const { return m_workgroup; }
+ const TQString &workgroup() const { return m_workgroup; }
/**
* Returns the name of the host.
*/
- const QString &name() const { return m_name; }
+ const TQString &name() const { return m_name; }
/**
* Returns the IP address of the host.
*/
- const QString &ip() const { return m_ip; }
+ const TQString &ip() const { return m_ip; }
/**
* Returns the comment for this host.
*/
- const QString &comment() const { return m_comment; }
+ const TQString &comment() const { return m_comment; }
/**
* Sets the Server string that is reported by the host.
*/
- void setServerString( const QString &server );
+ void setServerString( const TQString &server );
/**
* Returns the Server string.
*/
- const QString &serverString() const { return m_server_string; }
+ const TQString &serverString() const { return m_server_string; }
/**
* Sets the OS string that is reported by the host.
*/
- void setOSString( const QString &os );
+ void setOSString( const TQString &os );
/**
* Returns the OS string.
*/
- const QString &osString() const { return m_os_string; }
+ const TQString &osString() const { return m_os_string; }
/**
* This functions determines whether this host should be
@@ -254,14 +254,14 @@ class Smb4KHostItem
*
* @param ip The IP address of a host
*/
- void setIPAddress( const QString &ip );
+ void setIPAddress( const TQString &ip );
/**
* This function sets the command for a host.
*
* @param comment The comment
*/
- void setComment( const QString &comment );
+ void setComment( const TQString &comment );
/**
* This function is used to tell the host item, if a
@@ -298,32 +298,32 @@ class Smb4KHostItem
/**
* The name of the workgroup.
*/
- QString m_workgroup;
+ TQString m_workgroup;
/**
* The name of the host.
*/
- QString m_name;
+ TQString m_name;
/**
* The comment for this host.
*/
- QString m_comment;
+ TQString m_comment;
/**
* The IP address of the host.
*/
- QString m_ip;
+ TQString m_ip;
/**
* The Server string as reported by the host.
*/
- QString m_server_string;
+ TQString m_server_string;
/**
* The operating system string as reported by the host.
*/
- QString m_os_string;
+ TQString m_os_string;
/**
* This boolian determines if the host is a master browser
@@ -352,7 +352,7 @@ class Smb4KHostItem
*
* @returns TRUE if the IP address is valid and FALSE otherwise.
*/
- bool ipIsValid( const QString &ip );
+ bool ipIsValid( const TQString &ip );
};
@@ -378,11 +378,11 @@ class Smb4KShareItem
*
* @param comment The comment of the share.
*/
- Smb4KShareItem( const QString &workgroup,
- const QString &host,
- const QString &name,
- const QString &type,
- const QString &comment );
+ Smb4KShareItem( const TQString &workgroup,
+ const TQString &host,
+ const TQString &name,
+ const TQString &type,
+ const TQString &comment );
/**
* Empty constructor.
@@ -397,34 +397,34 @@ class Smb4KShareItem
/**
* Returns the workgroup of the host where the share is located.
*/
- const QString &workgroup() const { return m_workgroup; }
+ const TQString &workgroup() const { return m_workgroup; }
/**
* Returns the name of the host where the share is located.
*/
- const QString &host() const { return m_host; }
+ const TQString &host() const { return m_host; }
/**
* Returns the name of the share.
*/
- const QString &name() const { return m_name; }
+ const TQString &name() const { return m_name; }
/**
* Returns the type of the share.
*/
- const QString &plainType() const { return m_type; }
+ const TQString &plainType() const { return m_type; }
/**
* Returns a translated version of the type of the share.
*
* @returns The translated share type
*/
- const QString translatedType() const;
+ const TQString translatedType() const;
/**
* Returns the comment for this share.
*/
- const QString &comment() const { return m_comment; }
+ const TQString &comment() const { return m_comment; }
/**
* This function tells if the share is a hidden one.
@@ -461,27 +461,27 @@ class Smb4KShareItem
/**
* The workgroup object.
*/
- QString m_workgroup;
+ TQString m_workgroup;
/**
* The host name.
*/
- QString m_host;
+ TQString m_host;
/**
* The name of the share.
*/
- QString m_name;
+ TQString m_name;
/**
* The type of the share.
*/
- QString m_type;
+ TQString m_type;
/**
* The comment for this share.
*/
- QString m_comment;
+ TQString m_comment;
};
#endif
diff --git a/smb4k/core/smb4kpasswordhandler.cpp b/smb4k/core/smb4kpasswordhandler.cpp
index 0eb896b..fcda266 100644
--- a/smb4k/core/smb4kpasswordhandler.cpp
+++ b/smb4k/core/smb4kpasswordhandler.cpp
@@ -24,15 +24,15 @@
***************************************************************************/
-// Qt includes
-#include <qframe.h>
-#include <qlayout.h>
-#include <qstring.h>
-#include <qgroupbox.h>
-#include <qlabel.h>
-#include <qdir.h>
-#include <qfile.h>
-#include <qstringlist.h>
+// TQt includes
+#include <tqframe.h>
+#include <tqlayout.h>
+#include <tqstring.h>
+#include <tqgroupbox.h>
+#include <tqlabel.h>
+#include <tqdir.h>
+#include <tqfile.h>
+#include <tqstringlist.h>
// KDE includes
#include <klocale.h>
@@ -60,11 +60,11 @@
#ifndef __FreeBSD__
-Smb4KPasswordHandler::Smb4KPasswordHandler( Smb4KHomesSharesHandler *handler, QObject *parent, const char *name )
-: QObject( parent, name ), m_handler( handler ), m_wallet_support_disabled( false )
+Smb4KPasswordHandler::Smb4KPasswordHandler( Smb4KHomesSharesHandler *handler, TQObject *tqparent, const char *name )
+: TQObject( tqparent, name ), m_handler( handler ), m_wallet_support_disabled( false )
#else
-Smb4KPasswordHandler::Smb4KPasswordHandler( Smb4KHomesSharesHandler *s_handler, Smb4KSambaOptionsHandler *o_handler, QObject *parent, const char *name )
-: QObject( parent, name ), m_handler( s_handler ), m_options_handler( o_handler ),
+Smb4KPasswordHandler::Smb4KPasswordHandler( Smb4KHomesSharesHandler *s_handler, Smb4KSambaOptionsHandler *o_handler, TQObject *tqparent, const char *name )
+: TQObject( tqparent, name ), m_handler( s_handler ), m_options_handler( o_handler ),
m_wallet_support_disabled( false )
#endif
{
@@ -89,7 +89,7 @@ Smb4KPasswordHandler::Smb4KPasswordHandler( Smb4KHomesSharesHandler *s_handler,
Smb4KPasswordHandler::~Smb4KPasswordHandler()
{
- for ( QValueList<Smb4KAuthInfo *>::Iterator it = m_auth_list.begin(); it != m_auth_list.end(); ++it )
+ for ( TQValueList<Smb4KAuthInfo *>::Iterator it = m_auth_list.begin(); it != m_auth_list.end(); ++it )
{
delete *it;
}
@@ -136,7 +136,7 @@ void Smb4KPasswordHandler::open_close_wallet()
}
else
{
- Smb4KError::error( ERROR_OPENING_WALLET_FAILED, KWallet::Wallet::NetworkWallet(), QString::null );
+ Smb4KError::error( ERROR_OPENING_WALLET_FAILED, KWallet::Wallet::NetworkWallet(), TQString() );
delete m_wallet;
m_wallet = NULL;
@@ -166,24 +166,24 @@ void Smb4KPasswordHandler::convert_old_entries()
// new map based format.
if ( !m_wallet->entryList().isEmpty() )
{
- QStringList entries = m_wallet->entryList();
+ TQStringList entries = m_wallet->entryList();
// Since in the old format the keys contained a string like
// this: HOST:USER, we only need to test whether the first
// key contains a ":". If that's the case, we need to convert
// the entries, otherwise we don't.
- if ( entries.first().contains( ":" ) != 0 )
+ if ( entries.first().tqcontains( ":" ) != 0 )
{
- for ( QStringList::Iterator it = entries.begin(); it != entries.end(); ++it )
+ for ( TQStringList::Iterator it = entries.begin(); it != entries.end(); ++it )
{
// Get the password.
- QString pass;
+ TQString pass;
m_wallet->readPassword( *it, pass );
if ( (*it).startsWith( "DEFAULT:" ) )
{
// Convert the data to the new format.
- QMap<QString,QString> map;
+ TQMap<TQString,TQString> map;
map["Login"] = (*it).section( ":", 1, 1 );
map["Password"] = pass;
@@ -192,16 +192,16 @@ void Smb4KPasswordHandler::convert_old_entries()
else
{
// Convert the data to the new format.
- QMap<QString,QString> map;
+ TQMap<TQString,TQString> map;
map["Login"] = (*it).section( ":", 3, 3 );
map["Password"] = pass;
- if ( QString::compare( (*it).section( ":", 0, 0 ), "*" ) != 0 )
+ if ( TQString::compare( (*it).section( ":", 0, 0 ), "*" ) != 0 )
{
map["Workgroup"] = (*it).section( ":", 0, 0 ).upper();
}
- if ( QString::compare( (*it).section( ":", 2, 2 ), "*" ) == 0 )
+ if ( TQString::compare( (*it).section( ":", 2, 2 ), "*" ) == 0 )
{
m_wallet->writeMap( (*it).section( ":", 1, 1 ).upper(), map );
}
@@ -228,27 +228,27 @@ void Smb4KPasswordHandler::convert_old_entries()
}
-bool Smb4KPasswordHandler::askpass( const QString &workgroup, const QString &host, const QString &share, int desc, QWidget *parent, const char *name )
+bool Smb4KPasswordHandler::askpass( const TQString &workgroup, const TQString &host, const TQString &share, int desc, TQWidget *tqparent, const char *name )
{
// m_auth is NULL:
m_auth = readAuth( new Smb4KAuthInfo( workgroup, host, share ) );
// Set up the askpass dialog:
m_dlg = new KDialogBase( KDialogBase::Plain, i18n( "Authentication" ), KDialogBase::Ok|KDialogBase::Cancel,
- KDialogBase::Ok, parent, name, true, true );
+ KDialogBase::Ok, tqparent, name, true, true );
- QFrame *frame = m_dlg->plainPage();
- QGridLayout *layout = new QGridLayout( frame );
- layout->setSpacing( 5 );
- layout->setMargin( 0 );
+ TQFrame *frame = m_dlg->plainPage();
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
+ tqlayout->setSpacing( 5 );
+ tqlayout->setMargin( 0 );
- QLabel *pixmap_label = new QLabel( frame );
+ TQLabel *pixmap_label = new TQLabel( frame );
pixmap_label->setPixmap( DesktopIcon( "identity" ) );
pixmap_label->adjustSize();
- layout->addWidget( pixmap_label, 0, 0, Qt::AlignCenter );
+ tqlayout->addWidget( pixmap_label, 0, 0, TQt::AlignCenter );
- QString message;
+ TQString message;
switch ( desc )
{
@@ -275,66 +275,66 @@ bool Smb4KPasswordHandler::askpass( const QString &workgroup, const QString &hos
if ( m_auth->share().stripWhiteSpace().isEmpty() )
{
- message.append( i18n( "Please enter authentication data for server %1." ).arg( m_auth->host() ) );
+ message.append( i18n( "Please enter authentication data for server %1." ).tqarg( m_auth->host() ) );
}
else
{
- message.append( i18n( "Please enter authentication data for share %1." ).arg( "//"+m_auth->host()+"/"+m_auth->share() ) );
+ message.append( i18n( "Please enter authentication data for share %1." ).tqarg( "//"+m_auth->host()+"/"+m_auth->share() ) );
}
- QLabel *message_label = new QLabel( frame );
+ TQLabel *message_label = new TQLabel( frame );
message_label->setText( message.stripWhiteSpace() );
- message_label->setTextFormat( Qt::RichText );
+ message_label->setTextFormat( TQt::RichText );
- layout->addWidget( message_label, 0, 1, 0 );
+ tqlayout->addWidget( message_label, 0, 1, 0 );
- QLabel *user_label = new QLabel( i18n( "User:" ), frame );
- layout->addWidget( user_label, 1, 0, 0 );
+ TQLabel *user_label = new TQLabel( i18n( "User:" ), frame );
+ tqlayout->addWidget( user_label, 1, 0, 0 );
KLineEdit *user_edit = NULL;
KComboBox *user_combo = NULL;
- if ( QString::compare( m_auth->share(), "homes" ) != 0 )
+ if ( TQString::compare( m_auth->share(), "homes" ) != 0 )
{
user_edit = new KLineEdit( frame, "AskPassUserEdit" );
user_edit->setMinimumWidth( 200 );
- layout->addWidget( user_edit, 1, 1, 0 );
+ tqlayout->addWidget( user_edit, 1, 1, 0 );
}
else
{
user_combo = new KComboBox( frame, "AskPassUserCombo" );
user_combo->setEditable( true );
user_combo->setMinimumWidth( 200 );
- layout->addWidget( user_combo, 1, 1, 0 );
+ tqlayout->addWidget( user_combo, 1, 1, 0 );
}
- QLabel *password_label = new QLabel( i18n( "Password:" ), frame );
- layout->addWidget( password_label, 2, 0, 0 );
+ TQLabel *password_label = new TQLabel( i18n( "Password:" ), frame );
+ tqlayout->addWidget( password_label, 2, 0, 0 );
KLineEdit *pass_edit = new KLineEdit( frame, "AskPassPasswordEdit" );
pass_edit->setEchoMode( KLineEdit::Password );
- layout->addWidget( pass_edit, 2, 1, 0 );
+ tqlayout->addWidget( pass_edit, 2, 1, 0 );
m_dlg->setMainWidget( frame );
- m_dlg->setFixedSize( 350, m_dlg->sizeHint().height() );
+ m_dlg->setFixedSize( 350, m_dlg->tqsizeHint().height() );
m_dlg->enableButtonOK( false );
// Since we have to allow empty passwords, we will only connect
// the edit line for the user to enable/disable the OK button.
if ( user_edit )
{
- connect( user_edit, SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotEnableOKButton( const QString& ) ) );
+ connect( user_edit, TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotEnableOKButton( const TQString& ) ) );
}
else
{
- connect( user_combo, SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotEnableOKButton( const QString& ) ) );
+ connect( user_combo, TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotEnableOKButton( const TQString& ) ) );
}
// Process the authentication data:
- if ( QString::compare( share, "homes" ) != 0 )
+ if ( TQString::compare( share, "homes" ) != 0 )
{
user_edit->setText( m_auth->user() );
pass_edit->setText( m_auth->password() );
@@ -350,13 +350,13 @@ bool Smb4KPasswordHandler::askpass( const QString &workgroup, const QString &hos
}
else
{
- QStringList list = m_handler->homesUsers( host );
+ TQStringList list = m_handler->homesUsers( host );
user_combo->insertStringList( list );
- user_combo->setCurrentText( QString::null );
+ user_combo->setCurrentText( TQString() );
- connect( user_combo, SIGNAL( activated( const QString & ) ),
- this, SLOT( slotGetPassword( const QString & ) ) );
+ connect( user_combo, TQT_SIGNAL( activated( const TQString & ) ),
+ this, TQT_SLOT( slotGetPassword( const TQString & ) ) );
user_combo->setFocus();
}
@@ -365,10 +365,10 @@ bool Smb4KPasswordHandler::askpass( const QString &workgroup, const QString &hos
if ( m_dlg->exec() == KDialogBase::Accepted )
{
- if ( QString::compare( share, "homes" ) != 0 )
+ if ( TQString::compare( share, "homes" ) != 0 )
{
- QString user = user_edit->text();
- QString pass = pass_edit->text();
+ TQString user = user_edit->text();
+ TQString pass = pass_edit->text();
m_auth->setUser( user );
m_auth->setPassword( pass );
@@ -377,8 +377,8 @@ bool Smb4KPasswordHandler::askpass( const QString &workgroup, const QString &hos
}
else
{
- QString user = user_combo->currentText();
- QString pass = pass_edit->text();
+ TQString user = user_combo->currentText();
+ TQString pass = pass_edit->text();
m_auth->setUser( user );
m_auth->setPassword( pass );
@@ -416,7 +416,7 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readAuth( Smb4KAuthInfo *authInfo )
// Get the authentication information from the wallet.
// Always prefer either the exact match or the information
// that was provided for the host.
- QMap<QString,QString> map;
+ TQMap<TQString,TQString> map;
if ( !authInfo->share().isEmpty() )
{
@@ -450,9 +450,9 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readAuth( Smb4KAuthInfo *authInfo )
else
{
// Check that the workgroup is correct.
- if ( map.contains( "Workgroup" ) && !authInfo->workgroup().isEmpty() )
+ if ( map.tqcontains( "Workgroup" ) && !authInfo->workgroup().isEmpty() )
{
- if ( QString::compare( map["Workgroup"].upper(), authInfo->workgroup().upper() ) != 0 )
+ if ( TQString::compare( map["Workgroup"].upper(), authInfo->workgroup().upper() ) != 0 )
{
return authInfo;
}
@@ -473,9 +473,9 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readAuth( Smb4KAuthInfo *authInfo )
else
{
// Check that the workgroup is correct.
- if ( map.contains( "Workgroup" ) && !authInfo->workgroup().isEmpty() )
+ if ( map.tqcontains( "Workgroup" ) && !authInfo->workgroup().isEmpty() )
{
- if ( QString::compare( map["Workgroup"].upper(), authInfo->workgroup().upper() ) != 0 )
+ if ( TQString::compare( map["Workgroup"].upper(), authInfo->workgroup().upper() ) != 0 )
{
return authInfo;
}
@@ -516,9 +516,9 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readAuth( Smb4KAuthInfo *authInfo )
else
{
// Check that the workgroup is correct.
- if ( map.contains( "Workgroup" ) && !authInfo->workgroup().isEmpty() )
+ if ( map.tqcontains( "Workgroup" ) && !authInfo->workgroup().isEmpty() )
{
- if ( QString::compare( map["Workgroup"].upper(), authInfo->workgroup().upper() ) != 0 )
+ if ( TQString::compare( map["Workgroup"].upper(), authInfo->workgroup().upper() ) != 0 )
{
return authInfo;
}
@@ -552,14 +552,14 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readAuth( Smb4KAuthInfo *authInfo )
{
if ( !m_auth_list.isEmpty() )
{
- for ( QValueList<Smb4KAuthInfo *>::Iterator it = m_auth_list.begin(); it != m_auth_list.end(); ++it )
+ for ( TQValueList<Smb4KAuthInfo *>::Iterator it = m_auth_list.begin(); it != m_auth_list.end(); ++it )
{
if ( !authInfo->share().isEmpty() )
{
- if ( QString::compare( authInfo->host().upper(), (*it)->host().upper() ) == 0 &&
- QString::compare( authInfo->share().upper(), (*it)->share().upper() ) == 0 )
+ if ( TQString::compare( authInfo->host().upper(), (*it)->host().upper() ) == 0 &&
+ TQString::compare( authInfo->share().upper(), (*it)->share().upper() ) == 0 )
{
- if ( QString::compare( authInfo->workgroup().upper(), (*it)->workgroup().upper() ) == 0 ||
+ if ( TQString::compare( authInfo->workgroup().upper(), (*it)->workgroup().upper() ) == 0 ||
(*it)->workgroup().isEmpty() )
{
// Either the workgroup is OK, or we cannot check if it is OK.
@@ -575,9 +575,9 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readAuth( Smb4KAuthInfo *authInfo )
continue;
}
}
- else if ( QString::compare( authInfo->host().upper(), (*it)->host().upper() ) == 0 )
+ else if ( TQString::compare( authInfo->host().upper(), (*it)->host().upper() ) == 0 )
{
- if ( QString::compare( authInfo->workgroup().upper(), (*it)->workgroup().upper() ) == 0 ||
+ if ( TQString::compare( authInfo->workgroup().upper(), (*it)->workgroup().upper() ) == 0 ||
(*it)->workgroup().isEmpty() )
{
// Either the workgroup is OK, or we cannot check if it is OK.
@@ -601,9 +601,9 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readAuth( Smb4KAuthInfo *authInfo )
}
else
{
- if ( QString::compare( authInfo->host().upper(), (*it)->host().upper() ) == 0 )
+ if ( TQString::compare( authInfo->host().upper(), (*it)->host().upper() ) == 0 )
{
- if ( QString::compare( authInfo->workgroup().upper(), (*it)->workgroup().upper() ) == 0 ||
+ if ( TQString::compare( authInfo->workgroup().upper(), (*it)->workgroup().upper() ) == 0 ||
(*it)->workgroup().isEmpty() )
{
// Either the workgroup is OK, or we cannot check if it is OK.
@@ -659,7 +659,7 @@ void Smb4KPasswordHandler::writeAuth( Smb4KAuthInfo *authInfo )
if ( walletIsOpen() )
{
- QMap<QString,QString> map;
+ TQMap<TQString,TQString> map;
map["Login"] = authInfo->user();
map["Password"] = authInfo->password();
@@ -685,12 +685,12 @@ void Smb4KPasswordHandler::writeAuth( Smb4KAuthInfo *authInfo )
{
Smb4KAuthInfo *tmp = NULL;
- for ( QValueList<Smb4KAuthInfo *>::Iterator it = m_auth_list.begin(); it != m_auth_list.end(); ++it )
+ for ( TQValueList<Smb4KAuthInfo *>::Iterator it = m_auth_list.begin(); it != m_auth_list.end(); ++it )
{
if ( ((*it)->workgroup().isEmpty() ||
- QString::compare( (*it)->workgroup().upper(), authInfo->workgroup().upper() ) == 0) &&
- QString::compare( (*it)->host().upper(), authInfo->host().upper() ) == 0 &&
- QString::compare( (*it)->host().upper(), authInfo->share().upper() ) == 0 )
+ TQString::compare( (*it)->workgroup().upper(), authInfo->workgroup().upper() ) == 0) &&
+ TQString::compare( (*it)->host().upper(), authInfo->host().upper() ) == 0 &&
+ TQString::compare( (*it)->host().upper(), authInfo->share().upper() ) == 0 )
{
tmp = *it;
@@ -738,7 +738,7 @@ Smb4KAuthInfo *Smb4KPasswordHandler::readDefaultAuth( Smb4KAuthInfo *authInfo )
if ( walletIsOpen() )
{
// Read the default authentication information.
- QMap<QString,QString> map;
+ TQMap<TQString,TQString> map;
m_wallet->readMap( "DEFAULT_LOGIN", map );
@@ -767,7 +767,7 @@ void Smb4KPasswordHandler::writeDefaultAuth( Smb4KAuthInfo *authInfo )
if ( walletIsOpen() )
{
- QMap<QString,QString> map;
+ TQMap<TQString,TQString> map;
map["Login"] = authInfo->user();
map["Password"] = authInfo->password();
@@ -786,12 +786,12 @@ void Smb4KPasswordHandler::writeToSMBConfFile( Smb4KAuthInfo *authInfo )
KProcess *p = new KProcess();
p->setUseShell( true );
- connect( p, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivePassword( KProcess *, char *, int ) ) );
- connect( p, SIGNAL( processExited( KProcess * ) ),
- this, SLOT( slotWritePassword( KProcess * ) ) );
+ connect( p, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivePassword( KProcess *, char *, int ) ) );
+ connect( p, TQT_SIGNAL( processExited( KProcess * ) ),
+ this, TQT_SLOT( slotWritePassword( KProcess * ) ) );
- *p << QString( "smbutil crypt %1" ).arg( m_nsmbrc_auth.password() );
+ *p << TQString( "smbutil crypt %1" ).tqarg( m_nsmbrc_auth.password() );
p->start( KProcess::NotifyOnExit, KProcess::AllOutput );
}
@@ -800,11 +800,11 @@ void Smb4KPasswordHandler::writeToSMBConfFile( Smb4KAuthInfo *authInfo )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
-void Smb4KPasswordHandler::slotGetPassword( const QString &username )
+void Smb4KPasswordHandler::slotGetPassword( const TQString &username )
{
if ( m_dlg && m_auth )
{
@@ -812,7 +812,7 @@ void Smb4KPasswordHandler::slotGetPassword( const QString &username )
// of the homes shares:
Smb4KAuthInfo *auth = readAuth( new Smb4KAuthInfo( m_auth->workgroup().upper(), m_auth->host().upper(), username ) );
- KLineEdit *lineEdit = static_cast<KLineEdit *>( m_dlg->child( "AskPassPasswordEdit", "KLineEdit", true ) );
+ KLineEdit *lineEdit = static_cast<KLineEdit *>( TQT_TQWIDGET(m_dlg->child( "AskPassPasswordEdit", "KLineEdit", true )) );
lineEdit->setText( auth->password() );
delete auth;
@@ -822,7 +822,7 @@ void Smb4KPasswordHandler::slotGetPassword( const QString &username )
}
-void Smb4KPasswordHandler::slotEnableOKButton( const QString &text )
+void Smb4KPasswordHandler::slotEnableOKButton( const TQString &text )
{
if ( m_dlg )
{
@@ -833,7 +833,7 @@ void Smb4KPasswordHandler::slotEnableOKButton( const QString &text )
#ifdef __FreeBSD__
void Smb4KPasswordHandler::slotReceivePassword( KProcess *, char *buffer, int buflen )
{
- m_buffer.append( QString::fromLocal8Bit( buffer, buflen ) );
+ m_buffer.append( TQString::fromLocal8Bit( buffer, buflen ) );
#else
void Smb4KPasswordHandler::slotReceivePassword( KProcess *, char *, int )
{
@@ -848,21 +848,21 @@ void Smb4KPasswordHandler::slotWritePassword( KProcess *proc )
#ifdef __FreeBSD__
- QString pass = m_buffer.remove( "\n" ).stripWhiteSpace();
- m_buffer = QString::null;
+ TQString pass = m_buffer.remove( "\n" ).stripWhiteSpace();
+ m_buffer = TQString();
- QDir::setCurrent( QDir::homeDirPath() );
+ TQDir::setCurrent( TQDir::homeDirPath() );
- QFile file( ".nsmbrc" );
+ TQFile file( ".nsmbrc" );
- QStringList contents;
+ TQStringList contents;
if ( file.exists() )
{
if ( file.open( IO_ReadOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
while ( !ts.atEnd() )
{
@@ -874,14 +874,14 @@ void Smb4KPasswordHandler::slotWritePassword( KProcess *proc )
}
// Check if the [default] section is present.
- if ( contents.find( "[default]" ) == contents.end() &&
- contents.find( "[DEFAULT]" ) == contents.end() )
+ if ( contents.tqfind( "[default]" ) == contents.end() &&
+ contents.tqfind( "[DEFAULT]" ) == contents.end() )
{
- QMap<QString,QString> map = m_options_handler->globalSambaOptions();
- QString workgroup = map["workgroup"];
- QString wins = m_options_handler->winsServer();
+ TQMap<TQString,TQString> map = m_options_handler->globalSambaOptions();
+ TQString workgroup = map["workgroup"];
+ TQString wins = m_options_handler->winsServer();
- QStringList::Iterator it = contents.prepend( "[default]" );
+ TQStringList::Iterator it = contents.prepend( "[default]" );
it++;
if ( !workgroup.isEmpty() )
@@ -897,24 +897,24 @@ void Smb4KPasswordHandler::slotWritePassword( KProcess *proc )
// FIXME: Should we write the charsets here, too??
}
- QString section;
+ TQString section;
if ( m_nsmbrc_auth.share().isEmpty() )
{
- section.append( QString( "[%1:%2]" ).arg( m_nsmbrc_auth.host().upper(), m_nsmbrc_auth.user().isEmpty() ? "GUEST" : m_nsmbrc_auth.user().upper() ) );
+ section.append( TQString( "[%1:%2]" ).tqarg( m_nsmbrc_auth.host().upper(), m_nsmbrc_auth.user().isEmpty() ? "GUEST" : m_nsmbrc_auth.user().upper() ) );
}
else
{
- section.append( QString( "[%1:%2:%3]" ).arg( m_nsmbrc_auth.host().upper(), m_nsmbrc_auth.user().isEmpty() ? "GUEST" : m_nsmbrc_auth.user().upper(), m_nsmbrc_auth.share().upper() ) );
+ section.append( TQString( "[%1:%2:%3]" ).tqarg( m_nsmbrc_auth.host().upper(), m_nsmbrc_auth.user().isEmpty() ? "GUEST" : m_nsmbrc_auth.user().upper(), m_nsmbrc_auth.share().upper() ) );
}
- QStringList::Iterator it = contents.find( section );
+ TQStringList::Iterator it = contents.tqfind( section );
if ( it == contents.end() )
{
- if ( contents.last() != QString::null )
+ if ( contents.last() != TQString() )
{
- contents.append( QString::null );
+ contents.append( TQString() );
}
contents.append( section );
@@ -927,13 +927,13 @@ void Smb4KPasswordHandler::slotWritePassword( KProcess *proc )
}
else
{
- for ( QStringList::Iterator i = ++it; i != contents.end(); ++i )
+ for ( TQStringList::Iterator i = ++it; i != contents.end(); ++i )
{
- if ( (*i).contains( "password=" ) )
+ if ( (*i).tqcontains( "password=" ) )
{
- QString old_pass = (*i).section( "password=", 1, 1 ).stripWhiteSpace();
+ TQString old_pass = (*i).section( "password=", 1, 1 ).stripWhiteSpace();
- if ( QString::compare( pass, old_pass ) == 0 )
+ if ( TQString::compare( pass, old_pass ) == 0 )
{
// The passwords are identical, so stop here.
return;
@@ -955,14 +955,14 @@ void Smb4KPasswordHandler::slotWritePassword( KProcess *proc )
}
}
- QDir::setCurrent( QDir::homeDirPath() );
+ TQDir::setCurrent( TQDir::homeDirPath() );
if ( file.open( IO_WriteOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- for ( QStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
+ for ( TQStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
{
ts << *it << endl;
}
@@ -971,13 +971,13 @@ void Smb4KPasswordHandler::slotWritePassword( KProcess *proc )
}
else
{
- Smb4KError::error( ERROR_WRITING_FILE, "~/.nsmbrc", QString::null );
+ Smb4KError::error( ERROR_WRITING_FILE, "~/.nsmbrc", TQString() );
return;
}
// Get minimal security: Fix permissions.
- QString path = QDir::homeDirPath()+"/"+file.name();
+ TQString path = TQDir::homeDirPath()+"/"+file.name();
int fd;
diff --git a/smb4k/core/smb4kpasswordhandler.h b/smb4k/core/smb4kpasswordhandler.h
index 513f399..744aa15 100644
--- a/smb4k/core/smb4kpasswordhandler.h
+++ b/smb4k/core/smb4kpasswordhandler.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qcheckbox.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqcheckbox.h>
// KDE includes
#include <kwallet.h>
@@ -60,9 +60,10 @@ class Smb4KAuthInfo;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KPasswordHandler : public QObject
+class Smb4KPasswordHandler : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
#ifndef __FreeBSD__
@@ -75,12 +76,12 @@ class Smb4KPasswordHandler : public QObject
* infos in case we need to look up authentication information for
* 'homes' shares.
*
- * @param parent The parent object.
+ * @param tqparent The tqparent object.
*
* @param name The name this class should carry.
*/
Smb4KPasswordHandler( Smb4KHomesSharesHandler *handler,
- QObject *parent = 0,
+ TQObject *tqparent = 0,
const char *name = 0 );
#else
/**
@@ -93,13 +94,13 @@ class Smb4KPasswordHandler : public QObject
* @param o_handler The Smb4KSambaOptionsHandler object. It is needed to write the
* ~/.nsmbrc file correctly.
*
- * @param parent The parent object.
+ * @param tqparent The tqparent object.
*
* @param name The name this class should carry.
*/
Smb4KPasswordHandler( Smb4KHomesSharesHandler *s_handler,
Smb4KSambaOptionsHandler *o_handler,
- QObject *parent = 0,
+ TQObject *tqparent = 0,
const char *name = 0 );
#endif
@@ -121,13 +122,13 @@ class Smb4KPasswordHandler : public QObject
* Values are taken from the Smb4KPasswordHandler::AskPass::Description
* enumeration.
*
- * @param parent The parent of this dialog.
+ * @param tqparent The tqparent of this dialog.
*
* @param name The name of this dialog.
*
* @returns TRUE if a new password has been supplied and FALSE otherwise.
*/
- bool askpass( const QString &workgroup, const QString &host, const QString &share, int desc, QWidget *parent = 0, const char *name = 0 );
+ bool askpass( const TQString &workgroup, const TQString &host, const TQString &share, int desc, TQWidget *tqparent = 0, const char *name = 0 );
/**
* Returns the authentication data that was found for the defined share. You need to
@@ -191,7 +192,7 @@ class Smb4KPasswordHandler : public QObject
/**
* Get the password for a specific share and user name.
*/
- void slotGetPassword( const QString &username );
+ void slotGetPassword( const TQString &username );
/**
* This slot is used to enable the OK button of the askpass
@@ -200,7 +201,7 @@ class Smb4KPasswordHandler : public QObject
*
* @param text The text that has been entered.
*/
- void slotEnableOKButton( const QString &text );
+ void slotEnableOKButton( const TQString &text );
/**
* FreeBSD specific: This slot receives output from the process that encrypts
@@ -253,7 +254,7 @@ class Smb4KPasswordHandler : public QObject
* This list holds the authentication data the user supplied if he/she
* does not want to use KWallet.
*/
- QValueList<Smb4KAuthInfo *> m_auth_list;
+ TQValueList<Smb4KAuthInfo *> m_auth_list;
/**
* If the user neither wants to store the passwords in a wallet nor in a
@@ -292,7 +293,7 @@ class Smb4KPasswordHandler : public QObject
/**
* The buffer for the process that encrypts the password.
*/
- QString m_buffer;
+ TQString m_buffer;
/**
* The Smb4KSambaOptionsHandler object.
diff --git a/smb4k/core/smb4kpreviewer.cpp b/smb4k/core/smb4kpreviewer.cpp
index 2d3c850..52ebbab 100644
--- a/smb4k/core/smb4kpreviewer.cpp
+++ b/smb4k/core/smb4kpreviewer.cpp
@@ -23,8 +23,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qapplication.h>
+// TQt includes
+#include <tqapplication.h>
// KDE includes
#include <kapplication.h>
@@ -43,26 +43,26 @@
using namespace Smb4KGlobal;
-Smb4KPreviewer::Smb4KPreviewer( QObject *parent, const char *name )
-: QObject( parent, name )
+Smb4KPreviewer::Smb4KPreviewer( TQObject *tqparent, const char *name )
+: TQObject( tqparent, name )
{
m_item = NULL;
- m_buffer = QString::null;
+ m_buffer = TQString();
m_working = false;
m_proc = new KProcess( this, "PreviewProcess" );
m_proc->setUseShell( true );
- connect( m_proc, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( processExited( KProcess* ) ),
- this, SLOT( slotProcessExited( KProcess * ) ) );
+ connect( m_proc, TQT_SIGNAL( processExited( KProcess* ) ),
+ this, TQT_SLOT( slotProcessExited( KProcess * ) ) );
- connect( m_proc, SIGNAL( receivedStderr( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStderr( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
}
@@ -81,9 +81,9 @@ bool Smb4KPreviewer::preview( Smb4KPreviewItem *item )
return false;
}
- if ( QString::compare( item->share(), "homes" ) == 0 )
+ if ( TQString::compare( item->share(), "homes" ) == 0 )
{
- QString share_name = specifyUser( item->host(), kapp->mainWidget() ? kapp->mainWidget() : 0, "SpecifyUser" );
+ TQString share_name = specifyUser( item->host(), kapp->mainWidget() ? kapp->mainWidget() : 0, "SpecifyUser" );
if ( !share_name.isEmpty() )
{
@@ -117,7 +117,7 @@ void Smb4KPreviewer::abort()
}
-void Smb4KPreviewer::timerEvent( QTimerEvent * )
+void Smb4KPreviewer::timerEvent( TQTimerEvent * )
{
if ( m_working )
{
@@ -138,14 +138,14 @@ void Smb4KPreviewer::timerEvent( QTimerEvent * )
// special characters.
// (b) Do not pass the path unquoted, or you'll get a NT_STATUS_OBJECT_NAME_NOT_FOUND
// error message in the case the path is empty.
- QString command;
- command.append( QString( "smbclient //%1/%2 " ).arg( KProcess::quote( m_item->host() ), KProcess::quote( m_item->share() ) ) );
- command.append( QString( " -d1 -W %1 -D %2 " ).arg( KProcess::quote( m_item->workgroup() ), KProcess::quote( m_item->path() ) ) );
+ TQString command;
+ command.append( TQString( "smbclient //%1/%2 " ).tqarg( KProcess::quote( m_item->host() ), KProcess::quote( m_item->share() ) ) );
+ command.append( TQString( " -d1 -W %1 -D %2 " ).tqarg( KProcess::quote( m_item->workgroup() ), KProcess::quote( m_item->path() ) ) );
command.append( " -c \"ls\" " );
if ( !m_item->ip().isEmpty() )
{
- command.append( QString( " -I %1 " ).arg( m_item->ip() ) );
+ command.append( TQString( " -I %1 " ).tqarg( m_item->ip() ) );
}
command.append( optionsHandler()->smbclientOptions( "//"+m_item->host()+"/"+m_item->share() ) );
@@ -154,7 +154,7 @@ void Smb4KPreviewer::timerEvent( QTimerEvent * )
if ( !auth->user().isEmpty() )
{
- command.append( QString( " -U %1" ).arg( KProcess::quote( auth->user() ) ) );
+ command.append( TQString( " -U %1" ).tqarg( KProcess::quote( auth->user() ) ) );
if ( !auth->password().isEmpty() )
{
@@ -170,25 +170,25 @@ void Smb4KPreviewer::timerEvent( QTimerEvent * )
*m_proc << command;
- QApplication::setOverrideCursor( waitCursor );
+ TQApplication::setOverrideCursor( waitCursor );
m_proc->start( KProcess::NotifyOnExit, KProcess::AllOutput );
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KPreviewer::slotReceivedStdout( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
void Smb4KPreviewer::slotReceivedStderr( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
@@ -202,9 +202,9 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
m_proc->clearArguments();
- QStringList list = QStringList::split( "\n", m_buffer, false );
+ TQStringList list = TQStringList::split( "\n", m_buffer, false );
- m_buffer = QString::null;
+ m_buffer = TQString();
// Check whether an error occurred:
if ( list.grep( "NT_STATUS" ).count() != 0 )
@@ -212,25 +212,25 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
// Something went wrong. Let's check if this "only" an
// authentication issue or if we have to error out:
- QString error_code = list.grep( "NT_STATUS" ).first().stripWhiteSpace().section( " ", 0, 0 );
+ TQString error_code = list.grep( "NT_STATUS" ).first().stripWhiteSpace().section( " ", 0, 0 );
// The error output of smbclient is a little bit inconsistent:
- if ( error_code.contains( "NT_STATUS" ) == 0 )
+ if ( error_code.tqcontains( "NT_STATUS" ) == 0 )
{
error_code = list.grep( "NT_STATUS" ).first().stripWhiteSpace().section( " ", -1, -1 );
}
// Authentication issue?
- if ( QString::compare( error_code, "NT_STATUS_ACCESS_DENIED" ) == 0 ||
- QString::compare( error_code, "NT_STATUS_LOGON_FAILURE" ) == 0 )
+ if ( TQString::compare( error_code, "NT_STATUS_ACCESS_DENIED" ) == 0 ||
+ TQString::compare( error_code, "NT_STATUS_LOGON_FAILURE" ) == 0 )
{
int state = Smb4KPasswordHandler::None;
- if ( QString::compare( error_code, "NT_STATUS_ACCESS_DENIED" ) == 0 )
+ if ( TQString::compare( error_code, "NT_STATUS_ACCESS_DENIED" ) == 0 )
{
state = Smb4KPasswordHandler::AccessDenied;
}
- else if ( QString::compare( error_code, "NT_STATUS_LOGON_FAILURE" ) == 0 )
+ else if ( TQString::compare( error_code, "NT_STATUS_LOGON_FAILURE" ) == 0 )
{
state = Smb4KPasswordHandler::LogonFailure;
}
@@ -259,7 +259,7 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
else
{
// OK, error out. We cannot recover from it:
- Smb4KError::error( ERROR_GETTING_PREVIEW, QString::null, m_buffer );
+ Smb4KError::error( ERROR_GETTING_PREVIEW, TQString(), m_buffer );
m_item->clearContents();
@@ -271,7 +271,7 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
list.grep( "NT_STATUS" ).count() == 0) )
{
// These are errors that we cannot work around. Error out.
- Smb4KError::error( ERROR_GETTING_PREVIEW, QString::null, m_buffer );
+ Smb4KError::error( ERROR_GETTING_PREVIEW, TQString(), m_buffer );
m_item->clearContents();
@@ -279,7 +279,7 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
}
else
{
- for ( QStringList::Iterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::Iterator it = list.begin(); it != list.end(); ++it )
{
if ( (*it).stripWhiteSpace().startsWith( "Domain" ) ||
(*it).stripWhiteSpace().startsWith( "OS" ) ||
@@ -287,22 +287,22 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
{
continue;
}
- else if ( (*it).contains( "blocks of size" ) != 0 )
+ else if ( (*it).tqcontains( "blocks of size" ) != 0 )
{
continue;
}
else
{
- QString tmp = (*it).stripWhiteSpace().section( " ", 0, -9 ).stripWhiteSpace();
+ TQString tmp = (*it).stripWhiteSpace().section( " ", 0, -9 ).stripWhiteSpace();
- QString item = tmp.section( " ", 0, -2 ).stripWhiteSpace();
+ TQString item = tmp.section( " ", 0, -2 ).stripWhiteSpace();
- if ( !item.isEmpty() && tmp.section( " ", -1, -1 ).contains( "D" ) != 0 )
+ if ( !item.isEmpty() && tmp.section( " ", -1, -1 ).tqcontains( "D" ) != 0 )
{
// We have a directory here.
if ( item.startsWith( "." ) &&
- (QString::compare( item.stripWhiteSpace(), "." ) != 0 &&
- QString::compare( item.stripWhiteSpace(), ".." ) != 0) )
+ (TQString::compare( item.stripWhiteSpace(), "." ) != 0 &&
+ TQString::compare( item.stripWhiteSpace(), ".." ) != 0) )
{
m_item->addContents( ContentsItem( Smb4KPreviewItem::HiddenDirectory, item ) );
}
@@ -313,7 +313,7 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
continue;
}
- else if ( item.isEmpty() || tmp.section( " ", -1, -1 ).contains( "D" ) == 0 )
+ else if ( item.isEmpty() || tmp.section( " ", -1, -1 ).tqcontains( "D" ) == 0 )
{
// We have a file
if ( item.isEmpty() )
@@ -351,7 +351,7 @@ void Smb4KPreviewer::slotProcessExited( KProcess * )
emit result( m_item );
- QApplication::restoreOverrideCursor();
+ TQApplication::restoreOverrideCursor();
m_working = false;
diff --git a/smb4k/core/smb4kpreviewer.h b/smb4k/core/smb4kpreviewer.h
index f946f9f..bc99ca8 100644
--- a/smb4k/core/smb4kpreviewer.h
+++ b/smb4k/core/smb4kpreviewer.h
@@ -30,10 +30,10 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qstring.h>
-#include <qptrqueue.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqptrqueue.h>
// KDE includes
#include <kprocess.h>
@@ -48,19 +48,20 @@ class Smb4KPreviewItem;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KPreviewer : public QObject
+class Smb4KPreviewer : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent object
+ * @param tqparent The tqparent object
*
* @param name The name of this object
*/
- Smb4KPreviewer( QObject *parent = 0, const char *name = 0 );
+ Smb4KPreviewer( TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -119,9 +120,9 @@ class Smb4KPreviewer : public QObject
protected:
/**
- * Reimplemented from QObject
+ * Reimplemented from TQObject
*/
- void timerEvent( QTimerEvent *e );
+ void timerEvent( TQTimerEvent *e );
protected slots:
/**
@@ -162,7 +163,7 @@ class Smb4KPreviewer : public QObject
/**
* The output buffer
*/
- QString m_buffer;
+ TQString m_buffer;
/**
* This is the pointer to the Smb4KPreviewItem that's
@@ -179,7 +180,7 @@ class Smb4KPreviewer : public QObject
* This pointer queue holds the pointers to the Smb4KPreviewItem
* objects that are to be processed.
*/
- QPtrQueue<Smb4KPreviewItem> m_queue;
+ TQPtrQueue<Smb4KPreviewItem> m_queue;
/**
* The timer id
diff --git a/smb4k/core/smb4kpreviewitem.cpp b/smb4k/core/smb4kpreviewitem.cpp
index c712a48..98c9dba 100644
--- a/smb4k/core/smb4kpreviewitem.cpp
+++ b/smb4k/core/smb4kpreviewitem.cpp
@@ -29,10 +29,10 @@
// application specific includes
#include "smb4kpreviewitem.h"
-Smb4KPreviewItem::Smb4KPreviewItem( Smb4KShareItem *item, const QString &ip, const QString &path )
+Smb4KPreviewItem::Smb4KPreviewItem( Smb4KShareItem *item, const TQString &ip, const TQString &path )
: m_workgroup( item->workgroup() ), m_host( item->host() ), m_share( item->name() ), m_path( path )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
m_location = "//"+m_host+"/"+m_share+"/"+m_path;
}
@@ -42,22 +42,22 @@ Smb4KPreviewItem::~Smb4KPreviewItem()
}
-void Smb4KPreviewItem::setShare( const QString &share )
+void Smb4KPreviewItem::setShare( const TQString &share )
{
- if ( QString::compare( m_share, "homes" ) == 0 )
+ if ( TQString::compare( m_share, "homes" ) == 0 )
{
m_share = share;
}
}
-void Smb4KPreviewItem::setIP( const QString &ip )
+void Smb4KPreviewItem::setIP( const TQString &ip )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
}
-void Smb4KPreviewItem::setPath( const QString &path )
+void Smb4KPreviewItem::setPath( const TQString &path )
{
m_path = path;
m_location = "//"+m_host+"/"+m_share+"/"+m_path;
@@ -80,7 +80,7 @@ void Smb4KPreviewItem::clearContents()
}
-bool Smb4KPreviewItem::ipIsValid( const QString &ip )
+bool Smb4KPreviewItem::ipIsValid( const TQString &ip )
{
if ( !ip.isEmpty() )
{
diff --git a/smb4k/core/smb4kpreviewitem.h b/smb4k/core/smb4kpreviewitem.h
index d3663d5..2ef4f72 100644
--- a/smb4k/core/smb4kpreviewitem.h
+++ b/smb4k/core/smb4kpreviewitem.h
@@ -30,15 +30,15 @@
#include <config.h>
#endif
-// Qt includes
-#include <qstring.h>
-#include <qmap.h>
-#include <qpair.h>
+// TQt includes
+#include <tqstring.h>
+#include <tqmap.h>
+#include <tqpair.h>
// application specific includes
#include "smb4knetworkitems.h"
-typedef QPair<int, QString> ContentsItem;
+typedef TQPair<int, TQString> ContentsItem;
/**
* This class provides a container for the preview of the contents of a remote
@@ -60,7 +60,7 @@ class Smb4KPreviewItem
*
* @param path The path for that the preview should be collected.
*/
- Smb4KPreviewItem( Smb4KShareItem *item, const QString &ip = QString::null, const QString &path = QString::null );
+ Smb4KPreviewItem( Smb4KShareItem *item, const TQString &ip = TQString(), const TQString &path = TQString() );
/**
* The empty constructor.
@@ -75,17 +75,17 @@ class Smb4KPreviewItem
/**
* Returns the workgroup where the host is located
*/
- const QString &workgroup() const { return m_workgroup; }
+ const TQString &workgroup() const { return m_workgroup; }
/**
* Return the name of the host where the share is located.
*/
- const QString &host() const { return m_host; }
+ const TQString &host() const { return m_host; }
/**
* Return the name of the share that is to be previewed.
*/
- const QString &share() const { return m_share; }
+ const TQString &share() const { return m_share; }
/**
* With this function you can set the share name if this item
@@ -94,25 +94,25 @@ class Smb4KPreviewItem
*
* @param share The new share name
*/
- void setShare( const QString &share );
+ void setShare( const TQString &share );
/**
* Return the path that is to be previewed.
*/
- const QString &path() const { return m_path; }
+ const TQString &path() const { return m_path; }
/**
* Returns the IP address of the host where the share
* is located.
*/
- const QString &ip() const { return m_ip; }
+ const TQString &ip() const { return m_ip; }
/**
* Set the IP address of the host.
*
* @param ip The IP address of the host.
*/
- void setIP( const QString &ip );
+ void setIP( const TQString &ip );
/**
* Set the path for which the preview.
@@ -122,7 +122,7 @@ class Smb4KPreviewItem
* @note As soon as this function is used, the list of files and directories
* will be cleared.
*/
- void setPath( const QString &path );
+ void setPath( const TQString &path );
/**
* Returns the current location in the form //HOST/SHARE/PATH.
@@ -130,7 +130,7 @@ class Smb4KPreviewItem
*
* @returns The current location
*/
- const QString &location() const { return m_location; }
+ const TQString &location() const { return m_location; }
/**
* This enumeration is used for the contents. It determines if
@@ -144,12 +144,12 @@ class Smb4KPreviewItem
*
* @returns a map of (hidden) files and (hidden) directories.
*/
- const QValueList<ContentsItem> &contents() const { return m_contents; }
+ const TQValueList<ContentsItem> &contents() const { return m_contents; }
/**
* Add a file or directory to the contents.
*
- * @param item A ContentsItem object. This is a QPair<int,QString>
+ * @param item A ContentsItem object. This is a TQPair<int,TQString>
* with the integer being a value from the Contents
* enumeration and the string being the full path of
* the file or directory.
@@ -168,38 +168,38 @@ class Smb4KPreviewItem
/**
* The workgroup of the host
*/
- QString m_workgroup;
+ TQString m_workgroup;
/**
* The host's name
*/
- QString m_host;
+ TQString m_host;
/**
* The share name
*/
- QString m_share;
+ TQString m_share;
/**
* The IP address of the host
*/
- QString m_ip;
+ TQString m_ip;
/**
* The path that has to be previewed.
*/
- QString m_path;
+ TQString m_path;
/**
* The current location
*/
- QString m_location;
+ TQString m_location;
/**
* This map stores the contents of the current
* location.
*/
- QValueList<ContentsItem> m_contents;
+ TQValueList<ContentsItem> m_contents;
/**
* This function checks if the IP address is valid, i.e. the
@@ -210,7 +210,7 @@ class Smb4KPreviewItem
*
* @returns TRUE if the IP address is valid and FALSE otherwise.
*/
- bool ipIsValid( const QString &ip );
+ bool ipIsValid( const TQString &ip );
};
#endif
diff --git a/smb4k/core/smb4kprint.cpp b/smb4k/core/smb4kprint.cpp
index 9567926..d666ed5 100644
--- a/smb4k/core/smb4kprint.cpp
+++ b/smb4k/core/smb4kprint.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qtimer.h>
-#include <qfile.h>
+// TQt includes
+#include <tqtimer.h>
+#include <tqfile.h>
// KDE includes
#include <kurl.h>
@@ -50,7 +50,7 @@ using namespace Smb4KGlobal;
-Smb4KPrint::Smb4KPrint( QObject *parent, const char *name ) : QObject( parent, name )
+Smb4KPrint::Smb4KPrint( TQObject *tqparent, const char *name ) : TQObject( tqparent, name )
{
m_proc = new KProcess( this, "PrintProcess" );
m_proc->setUseShell( true );
@@ -59,14 +59,14 @@ Smb4KPrint::Smb4KPrint( QObject *parent, const char *name ) : QObject( parent, n
m_working = false;
- connect( m_proc, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( receivedStderr( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStderr( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( processExited( KProcess * ) ),
- this, SLOT( slotProcessExited( KProcess * ) ) );
+ connect( m_proc, TQT_SIGNAL( processExited( KProcess * ) ),
+ this, TQT_SLOT( slotProcessExited( KProcess * ) ) );
}
@@ -105,7 +105,7 @@ bool Smb4KPrint::print( Smb4KPrintInfo *info )
m_info = info;
// Start processing the file:
- if ( QFile::exists( m_info->path() ) )
+ if ( TQFile::exists( m_info->path() ) )
{
// Determine the mimetype of the file:
KURL url;
@@ -113,14 +113,14 @@ bool Smb4KPrint::print( Smb4KPrintInfo *info )
KFileItem file_item = KFileItem( KFileItem::Unknown, KFileItem::Unknown, url, false );
- if ( QString::compare( file_item.mimetype(), "application/postscript" ) == 0 ||
- QString::compare( file_item.mimetype(), "application/pdf" ) == 0 ||
+ if ( TQString::compare( file_item.mimetype(), "application/postscript" ) == 0 ||
+ TQString::compare( file_item.mimetype(), "application/pdf" ) == 0 ||
file_item.mimetype().startsWith( "image" ) )
{
setDeviceURI();
printNormal();
}
- else if ( QString::compare( file_item.mimetype(), "application/x-dvi" ) == 0 &&
+ else if ( TQString::compare( file_item.mimetype(), "application/x-dvi" ) == 0 &&
!Smb4KSettings::dvips().isEmpty() )
{
setDeviceURI();
@@ -128,7 +128,7 @@ bool Smb4KPrint::print( Smb4KPrintInfo *info )
}
else if ( (file_item.mimetype().startsWith( "text" ) ||
file_item.mimetype().startsWith( "message" ) ||
- QString::compare( file_item.mimetype(), "application/x-shellscript" ) == 0) &&
+ TQString::compare( file_item.mimetype(), "application/x-shellscript" ) == 0) &&
!Smb4KSettings::enscript().isEmpty() )
{
setDeviceURI();
@@ -171,7 +171,7 @@ void Smb4KPrint::setDeviceURI()
Smb4KAuthInfo *auth = passwordHandler()->readAuth( new Smb4KAuthInfo( m_info->workgroup(),
m_info->host(), m_info->printer() ) );
- QString uri;
+ TQString uri;
// It seems that we must not quote the entries for the DEVICE_URI
// environment variable. Printing will fail if you do it.
@@ -180,22 +180,22 @@ void Smb4KPrint::setDeviceURI()
{
if ( !auth->user().isEmpty() )
{
- uri = QString( "smb://%1:%2@%3/%4/%5" ).arg( auth->user(), auth->password() ).arg( m_info->workgroup(), m_info->host(), m_info->printer() );
+ uri = TQString( "smb://%1:%2@%3/%4/%5" ).tqarg( auth->user().data(), auth->password().data() ).tqarg( m_info->workgroup(), m_info->host(), m_info->printer() );
}
else
{
- uri = QString( "smb://%1/%2/%3" ).arg( m_info->workgroup(), m_info->host(), m_info->printer() );
+ uri = TQString( "smb://%1/%2/%3" ).tqarg( m_info->workgroup(), m_info->host(), m_info->printer() );
}
}
else
{
if ( !auth->user().isEmpty() )
{
- uri = QString( "smb://%1:%2@%3/%4" ).arg( auth->user(), auth->password() ).arg( m_info->host(), m_info->printer() );
+ uri = TQString( "smb://%1:%2@%3/%4" ).tqarg( auth->user().data(), auth->password().data() ).tqarg( m_info->host(), m_info->printer() );
}
else
{
- uri = QString( "smb://%1/%2" ).arg( m_info->host(), m_info->printer() );
+ uri = TQString( "smb://%1/%2" ).tqarg( m_info->host(), m_info->printer() );
}
}
@@ -211,10 +211,10 @@ void Smb4KPrint::setDeviceURI()
void Smb4KPrint::printNormal()
{
- QString command;
+ TQString command;
- command.append( "smbspool 111 "+QString( getpwuid( getuid() )->pw_name ) );
- command.append( " \"Smb4K print job\" "+QString( "%1" ).arg( m_info->copies() ) );
+ command.append( "smbspool 111 "+TQString( getpwuid( getuid() )->pw_name ) );
+ command.append( " \"Smb4K print job\" "+TQString( "%1" ).tqarg( m_info->copies() ) );
command.append( " \"\" "+KProcess::quote( m_info->path() ) );
*m_proc << command;
@@ -232,17 +232,17 @@ void Smb4KPrint::printNormal()
void Smb4KPrint::printDVI()
{
// The temporary file.
- QString temp_file = tempDir()+"/smb4k_print.ps";
+ TQString temp_file = tempDir()+"/smb4k_print.ps";
- QString command;
+ TQString command;
// First we need the conversion:
command.append( "cd "+KProcess::quote( m_info->path().section( "/", 0, -2 ) )+" && " );
command.append( "dvips -P pdf -o "+temp_file+" "+KProcess::quote( m_info->path().section( "/", -1, -1 ) )+" && " );
// The actual print command:
- command.append( "smbspool 111 "+QString( getpwuid( getuid() )->pw_name ) );
- command.append( " \"Smb4K print job\" "+QString( "%1" ).arg( m_info->copies() ) );
+ command.append( "smbspool 111 "+TQString( getpwuid( getuid() )->pw_name ) );
+ command.append( " \"Smb4K print job\" "+TQString( "%1" ).tqarg( m_info->copies() ) );
command.append( " \"\" "+KProcess::quote( temp_file )+" && " );
// Clean up:
@@ -263,9 +263,9 @@ void Smb4KPrint::printDVI()
void Smb4KPrint::printText()
{
// The temporary file.
- QString temp_file = tempDir()+"/smb4k_print.ps";
+ TQString temp_file = tempDir()+"/smb4k_print.ps";
- QString command;
+ TQString command;
// Conversion:
command.append( "enscript --columns=1 --no-header --ps-level=2 " );
@@ -273,8 +273,8 @@ void Smb4KPrint::printText()
command.append( KProcess::quote( m_info->path() )+ " && " );
// The actual print command:
- command.append( "smbspool 111 "+QString( getpwuid( getuid() )->pw_name ) );
- command.append( " \"Smb4K print job\" "+QString( "%1" ).arg( m_info->copies() ) );
+ command.append( "smbspool 111 "+TQString( getpwuid( getuid() )->pw_name ) );
+ command.append( " \"Smb4K print job\" "+TQString( "%1" ).tqarg( m_info->copies() ) );
command.append( " \"\" "+KProcess::quote( temp_file )+" && " );
// Clean up:
@@ -289,20 +289,20 @@ void Smb4KPrint::printText()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KPrint::slotReceivedStdout( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
void Smb4KPrint::slotReceivedStderr( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
- if ( m_buffer.contains( "NT_STATUS" ) != 0 )
+ if ( m_buffer.tqcontains( "NT_STATUS" ) != 0 )
{
abort();
}
@@ -313,19 +313,19 @@ void Smb4KPrint::slotProcessExited( KProcess * )
{
bool retry = false;
- if ( m_buffer.contains( "NT_STATUS", true ) != 0 ||
- m_buffer.contains( "enscript", true ) != 0 ||
- m_buffer.contains( "dvips", true ) != 0 )
+ if ( m_buffer.tqcontains( "NT_STATUS", true ) != 0 ||
+ m_buffer.tqcontains( "enscript", true ) != 0 ||
+ m_buffer.tqcontains( "dvips", true ) != 0 )
{
- if ( m_buffer.contains( "NT_STATUS_ACCESS_DENIED" ) != 0 || m_buffer.contains( "NT_STATUS_LOGON_FAILURE" ) != 0 )
+ if ( m_buffer.tqcontains( "NT_STATUS_ACCESS_DENIED" ) != 0 || m_buffer.tqcontains( "NT_STATUS_LOGON_FAILURE" ) != 0 )
{
int state = Smb4KPasswordHandler::None;
- if ( m_buffer.contains( "NT_STATUS_ACCESS_DENIED" ) != 0 )
+ if ( m_buffer.tqcontains( "NT_STATUS_ACCESS_DENIED" ) != 0 )
{
state = Smb4KPasswordHandler::AccessDenied;
}
- else if (m_buffer.contains( "NT_STATUS_LOGON_FAILURE" ) != 0 )
+ else if (m_buffer.tqcontains( "NT_STATUS_LOGON_FAILURE" ) != 0 )
{
state = Smb4KPasswordHandler::LogonFailure;
}
@@ -333,7 +333,7 @@ void Smb4KPrint::slotProcessExited( KProcess * )
if ( passwordHandler()->askpass( m_info->workgroup(), m_info->host(), m_info->printer(), state ) )
{
retry = true;
- QTimer::singleShot( 50, this, SLOT( slotRetry() ) );
+ TQTimer::singleShot( 50, this, TQT_SLOT( slotRetry() ) );
}
}
else
@@ -341,13 +341,13 @@ void Smb4KPrint::slotProcessExited( KProcess * )
Smb4KError::error( ERROR_PRINTING, m_info->path(), m_buffer );
// Clean up:
- QFile::remove( QString( "%1/smb4k_print.ps" ).arg( tempDir() ) );
+ TQFile::remove( TQString( "%1/smb4k_print.ps" ).tqarg( tempDir() ) );
}
}
else
{
// Clean up:
- QFile::remove( QString( "%1/smb4k_print.ps" ).arg( tempDir() ) );
+ TQFile::remove( TQString( "%1/smb4k_print.ps" ).tqarg( tempDir() ) );
}
m_proc->clearArguments();
diff --git a/smb4k/core/smb4kprint.h b/smb4k/core/smb4kprint.h
index 8a9a5cd..2f75de2 100644
--- a/smb4k/core/smb4kprint.h
+++ b/smb4k/core/smb4kprint.h
@@ -30,10 +30,10 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qstring.h>
-#include <qwidget.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqwidget.h>
// KDE includes
#include <kprocess.h>
@@ -52,15 +52,16 @@ class Smb4KPrintInfo;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KPrint : public QObject
+class Smb4KPrint : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*/
- Smb4KPrint( QObject *parent = 0, const char *name = 0 );
+ Smb4KPrint( TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -133,7 +134,7 @@ class Smb4KPrint : public QObject
/**
* The buffer
*/
- QString m_buffer;
+ TQString m_buffer;
/**
* This boolean is TRUE if the printer handler is running and
diff --git a/smb4k/core/smb4kprintinfo.cpp b/smb4k/core/smb4kprintinfo.cpp
index 7f546c7..daca02e 100644
--- a/smb4k/core/smb4kprintinfo.cpp
+++ b/smb4k/core/smb4kprintinfo.cpp
@@ -30,11 +30,11 @@
#include "smb4kprintinfo.h"
-Smb4KPrintInfo::Smb4KPrintInfo( Smb4KShareItem *item, const QString &ip, const QString &path, int copies )
+Smb4KPrintInfo::Smb4KPrintInfo( Smb4KShareItem *item, const TQString &ip, const TQString &path, int copies )
: m_workgroup( item->workgroup() ), m_host( item->host() ), m_printer( item->name() ), m_path( path ),
m_copies( copies ), m_comment( item->comment() )
{
- m_ip = ipIsValid( ip ) ? ip : QString::null;
+ m_ip = ipIsValid( ip ) ? ip : TQString();
}
@@ -43,7 +43,7 @@ Smb4KPrintInfo::~Smb4KPrintInfo()
}
-void Smb4KPrintInfo::setPath( const QString &path )
+void Smb4KPrintInfo::setPath( const TQString &path )
{
m_path = path;
}
@@ -55,7 +55,7 @@ void Smb4KPrintInfo::setCopies( int num )
}
-bool Smb4KPrintInfo::ipIsValid( const QString &ip )
+bool Smb4KPrintInfo::ipIsValid( const TQString &ip )
{
if ( !ip.isEmpty() )
{
diff --git a/smb4k/core/smb4kprintinfo.h b/smb4k/core/smb4kprintinfo.h
index 9b25c9e..d9ccabb 100644
--- a/smb4k/core/smb4kprintinfo.h
+++ b/smb4k/core/smb4kprintinfo.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qstring.h>
+// TQt includes
+#include <tqstring.h>
// application specific includes
#include "smb4knetworkitems.h"
@@ -55,7 +55,7 @@ class Smb4KPrintInfo
*
* @param copies The number of copies
*/
- Smb4KPrintInfo( Smb4KShareItem *item, const QString &ip, const QString &filepath = QString::null, int copies = 1 );
+ Smb4KPrintInfo( Smb4KShareItem *item, const TQString &ip, const TQString &filepath = TQString(), int copies = 1 );
/**
* Empty constructor.
*/
@@ -67,27 +67,27 @@ class Smb4KPrintInfo
/**
* Returns the path of the file.
*/
- const QString &path() const { return m_path; }
+ const TQString &path() const { return m_path; }
/**
* Returns the host where the printer is located.
*/
- const QString &host() const { return m_host; }
+ const TQString &host() const { return m_host; }
/**
* Returns the workgroup in which the host located.
*/
- const QString &workgroup() const { return m_workgroup; }
+ const TQString &workgroup() const { return m_workgroup; }
/**
* Returns the name of the printer.
*/
- const QString &printer() const { return m_printer; }
+ const TQString &printer() const { return m_printer; }
/**
* Returns the IP address of the host.
*/
- const QString &ip() const { return m_ip; }
+ const TQString &ip() const { return m_ip; }
/**
* Sets the path to the file to print.
*/
- void setPath( const QString &path );
+ void setPath( const TQString &path );
/**
* Returns the number of copies the user wants to have.
*/
@@ -99,29 +99,29 @@ class Smb4KPrintInfo
/**
* Returns the comment.
*/
- const QString &comment() const { return m_comment; }
+ const TQString &comment() const { return m_comment; }
private:
/**
* The workgroup.
*/
- QString m_workgroup;
+ TQString m_workgroup;
/**
* The host.
*/
- QString m_host;
+ TQString m_host;
/**
* The IP address.
*/
- QString m_ip;
+ TQString m_ip;
/**
* The printer name.
*/
- QString m_printer;
+ TQString m_printer;
/**
* The path to the file to print.
*/
- QString m_path;
+ TQString m_path;
/**
* Holds the number of copies the user wants to have.
*/
@@ -129,7 +129,7 @@ class Smb4KPrintInfo
/**
* The comment
*/
- QString m_comment;
+ TQString m_comment;
/**
* This function checks if the IP address is valid, i.e. the
@@ -140,7 +140,7 @@ class Smb4KPrintInfo
*
* @returns TRUE if the IP address is valid and FALSE otherwise.
*/
- bool ipIsValid( const QString &ip );
+ bool ipIsValid( const TQString &ip );
};
#endif
diff --git a/smb4k/core/smb4ksambaoptionshandler.cpp b/smb4k/core/smb4ksambaoptionshandler.cpp
index e31648d..5a2facd 100644
--- a/smb4k/core/smb4ksambaoptionshandler.cpp
+++ b/smb4k/core/smb4ksambaoptionshandler.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qfile.h>
-#include <qtextstream.h>
-#include <qdir.h>
+// TQt includes
+#include <tqfile.h>
+#include <tqtextstream.h>
+#include <tqdir.h>
// KDE includes
#include <kstandarddirs.h>
@@ -51,12 +51,12 @@
using namespace Smb4KGlobal;
-Smb4KSambaOptionsHandler::Smb4KSambaOptionsHandler( QObject *parent, const char *name )
-: QObject( parent, name )
+Smb4KSambaOptionsHandler::Smb4KSambaOptionsHandler( TQObject *tqparent, const char *name )
+: TQObject( tqparent, name )
{
// We need the directory.
KStandardDirs *stddir = new KStandardDirs();
- QString dir = locateLocal( "data", "smb4k", KGlobal::instance() );
+ TQString dir = locateLocal( "data", "smb4k", KGlobal::instance() );
if ( !stddir->exists( dir ) )
{
@@ -65,13 +65,13 @@ Smb4KSambaOptionsHandler::Smb4KSambaOptionsHandler( QObject *parent, const char
delete stddir;
- m_wins_server = QString::null;
+ m_wins_server = TQString();
}
Smb4KSambaOptionsHandler::~Smb4KSambaOptionsHandler()
{
- for ( QValueList<Smb4KSambaOptionsInfo *>::Iterator it = m_list.begin();
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::Iterator it = m_list.begin();
it != m_list.end(); ++it )
{
delete *it;
@@ -81,7 +81,7 @@ Smb4KSambaOptionsHandler::~Smb4KSambaOptionsHandler()
}
-const QValueList<Smb4KSambaOptionsInfo *> &Smb4KSambaOptionsHandler::customOptionsList()
+const TQValueList<Smb4KSambaOptionsInfo *> &Smb4KSambaOptionsHandler::customOptionsList()
{
if ( m_list.isEmpty() )
{
@@ -97,7 +97,7 @@ void Smb4KSambaOptionsHandler::read_options()
// Clear the list before filling it (again)
if ( !m_list.isEmpty() )
{
- for ( QValueList<Smb4KSambaOptionsInfo *>::Iterator it = m_list.begin();
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::Iterator it = m_list.begin();
it != m_list.end(); ++it )
{
delete *it;
@@ -106,16 +106,16 @@ void Smb4KSambaOptionsHandler::read_options()
m_list.clear();
}
- QFile file( locateLocal( "data", "smb4k/custom_options", KGlobal::instance() ) );
+ TQFile file( locateLocal( "data", "smb4k/custom_options", KGlobal::instance() ) );
- QStringList contents;
+ TQStringList contents;
if ( file.open( IO_ReadOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- contents = QStringList::split( '\n', ts.read(), true );
+ contents = TQStringList::split( '\n', ts.read(), true );
file.close();
}
@@ -131,17 +131,17 @@ void Smb4KSambaOptionsHandler::read_options()
if ( !contents.isEmpty() )
{
- for ( QStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
+ for ( TQStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
{
if ( (*it).startsWith( "[" ) )
{
Smb4KSambaOptionsInfo *info = new Smb4KSambaOptionsInfo( (*it).section( "[", 1, -1 ).section( "]", -2, 0 ) );
- for ( QStringList::ConstIterator i = ++it; i != contents.end(); ++i )
+ for ( TQStringList::ConstIterator i = ++it; i != contents.end(); ++i )
{
if ( (*i).startsWith( "remount=" ) )
{
- bool remount = QString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 ? true : false;
+ bool remount = TQString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 ? true : false;
info->setRemount( remount );
@@ -164,13 +164,13 @@ void Smb4KSambaOptionsHandler::read_options()
}
else if ( (*i).startsWith( "read-write=" ) ) // Deprecated since version 0.9.0
{
- info->setWriteAccess( QString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 );
+ info->setWriteAccess( TQString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 );
continue;
}
else if ( (*i).startsWith( "write access=" ) )
{
- info->setWriteAccess( QString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 );
+ info->setWriteAccess( TQString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 );
continue;
}
@@ -183,7 +183,7 @@ void Smb4KSambaOptionsHandler::read_options()
}
else if ( (*i).startsWith( "kerberos=" ) )
{
- info->setKerberos( QString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 );
+ info->setKerberos( TQString::compare( (*i).section( "=", 1, 1 ).stripWhiteSpace(), "true" ) == 0 );
continue;
}
@@ -224,7 +224,7 @@ void Smb4KSambaOptionsHandler::read_options()
void Smb4KSambaOptionsHandler::write_options()
{
- QString protocol_hint;
+ TQString protocol_hint;
// Determine the protocol hint specified by the user:
switch ( Smb4KSettings::protocolHint() )
@@ -233,7 +233,7 @@ void Smb4KSambaOptionsHandler::write_options()
{
// In this case the user leaves it to the net
// command to determine the right protocol.
- protocol_hint = QString::null;
+ protocol_hint = TQString();
break;
}
@@ -257,7 +257,7 @@ void Smb4KSambaOptionsHandler::write_options()
}
default:
{
- protocol_hint = QString::null;
+ protocol_hint = TQString();
break;
}
@@ -265,7 +265,7 @@ void Smb4KSambaOptionsHandler::write_options()
#ifndef __FreeBSD__
- QString default_filesystem;
+ TQString default_filesystem;
switch( Smb4KSettings::filesystem() )
{
@@ -312,16 +312,16 @@ void Smb4KSambaOptionsHandler::write_options()
#endif
- QFile file( locateLocal( "data", "smb4k/custom_options", KGlobal::instance() ) );
+ TQFile file( locateLocal( "data", "smb4k/custom_options", KGlobal::instance() ) );
if ( !m_list.isEmpty() )
{
if ( file.open( IO_WriteOnly ) )
{
- QTextStream ts( &file );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &file );
+ ts.setEncoding( TQTextStream::Locale );
- for ( QValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = m_list.begin(); it != m_list.end(); ++it )
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = m_list.begin(); it != m_list.end(); ++it )
{
switch ( (*it)->type() )
{
@@ -435,7 +435,7 @@ void Smb4KSambaOptionsHandler::sync()
}
-Smb4KSambaOptionsInfo *Smb4KSambaOptionsHandler::find_item( const QString &item, bool exactMatch )
+Smb4KSambaOptionsInfo *Smb4KSambaOptionsHandler::find_item( const TQString &item, bool exactMatch )
{
// If the list is empty, we'll read the file.
if ( m_list.isEmpty() )
@@ -443,22 +443,22 @@ Smb4KSambaOptionsInfo *Smb4KSambaOptionsHandler::find_item( const QString &item,
read_options();
}
- QString host = item.section( "/", 2, 2 ).stripWhiteSpace();
+ TQString host = item.section( "/", 2, 2 ).stripWhiteSpace();
Smb4KSambaOptionsInfo *info = NULL;
if ( !item.stripWhiteSpace().isEmpty() )
{
- for ( QValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = m_list.begin();
+ for ( TQValueList<Smb4KSambaOptionsInfo *>::ConstIterator it = m_list.begin();
it != m_list.end(); ++it )
{
- if ( QString::compare( item.lower(), (*it)->itemName().lower() ) == 0 )
+ if ( TQString::compare( item.lower(), (*it)->itemName().lower() ) == 0 )
{
info = *it;
break;
}
- else if ( QString::compare( host.lower(), (*it)->itemName().lower() ) == 0 )
+ else if ( TQString::compare( host.lower(), (*it)->itemName().lower() ) == 0 )
{
if ( !info && !exactMatch )
{
@@ -478,39 +478,39 @@ Smb4KSambaOptionsInfo *Smb4KSambaOptionsHandler::find_item( const QString &item,
}
-const QString Smb4KSambaOptionsHandler::smbclientOptions( const QString &share )
+const TQString Smb4KSambaOptionsHandler::smbclientOptions( const TQString &share )
{
// Get the global Samba options
(void) globalSambaOptions();
Smb4KSambaOptionsInfo *info = find_item( share );
- QString args = QString::null;
+ TQString args = TQString();
// Get the strings that are needed to put the
// argument list together:
- QString resolve_order = (!Smb4KSettings::nameResolveOrder().isEmpty() &&
- QString::compare( Smb4KSettings::nameResolveOrder(),
+ TQString resolve_order = (!Smb4KSettings::nameResolveOrder().isEmpty() &&
+ TQString::compare( Smb4KSettings::nameResolveOrder(),
m_samba_options["name resolve order"] ) != 0) ?
Smb4KSettings::nameResolveOrder() :
- QString::null;
+ TQString();
- QString netbios_name = (!Smb4KSettings::netBIOSName().isEmpty() &&
- QString::compare( Smb4KSettings::netBIOSName(),
+ TQString netbios_name = (!Smb4KSettings::netBIOSName().isEmpty() &&
+ TQString::compare( Smb4KSettings::netBIOSName(),
m_samba_options["netbios name"] ) != 0) ?
Smb4KSettings::netBIOSName() :
- QString::null;
+ TQString();
- QString netbios_scope = (!Smb4KSettings::netBIOSScope().isEmpty() &&
- QString::compare( Smb4KSettings::netBIOSScope(),
+ TQString netbios_scope = (!Smb4KSettings::netBIOSScope().isEmpty() &&
+ TQString::compare( Smb4KSettings::netBIOSScope(),
m_samba_options["netbios scope"] ) != 0) ?
Smb4KSettings::netBIOSScope() :
- QString::null;
+ TQString();
- QString socket_options = (!Smb4KSettings::socketOptions().isEmpty() &&
- QString::compare( Smb4KSettings::socketOptions(),
+ TQString socket_options = (!Smb4KSettings::socketOptions().isEmpty() &&
+ TQString::compare( Smb4KSettings::socketOptions(),
m_samba_options["socket options"] ) != 0) ?
Smb4KSettings::socketOptions() :
- QString::null;
+ TQString();
bool kerberos = info ?
info->kerberos() :
@@ -522,26 +522,26 @@ const QString Smb4KSambaOptionsHandler::smbclientOptions( const QString &share )
// Options that are not customizable:
args.append( !resolve_order.isEmpty() ?
- QString( " -R '%1'" ).arg( resolve_order ) :
- QString::null );
+ TQString( " -R '%1'" ).tqarg( resolve_order ) :
+ TQString() );
args.append( !netbios_name.isEmpty() ?
- QString( " -n '%1'" ).arg( netbios_name ) :
- QString::null );
+ TQString( " -n '%1'" ).tqarg( netbios_name ) :
+ TQString() );
args.append( !netbios_scope.isEmpty() ?
- QString( " -i '%1'" ).arg( netbios_scope ) :
- QString::null );
+ TQString( " -i '%1'" ).tqarg( netbios_scope ) :
+ TQString() );
args.append( !socket_options.isEmpty() ?
- QString( " -O '%1'" ).arg( socket_options ) :
- QString::null );
+ TQString( " -O '%1'" ).tqarg( socket_options ) :
+ TQString() );
args.append( Smb4KSettings::bufferSize() != 65520 ?
- QString( " -b %1" ).arg( Smb4KSettings::bufferSize() ) :
- QString::null );
+ TQString( " -b %1" ).tqarg( Smb4KSettings::bufferSize() ) :
+ TQString() );
- args.append( Smb4KSettings::machineAccount() ? " -P" : QString::null );
+ args.append( Smb4KSettings::machineAccount() ? " -P" : TQString() );
switch ( Smb4KSettings::signingState() )
{
@@ -575,81 +575,81 @@ const QString Smb4KSambaOptionsHandler::smbclientOptions( const QString &share )
}
}
- args.append( kerberos ? " -k" : QString::null );
+ args.append( kerberos ? " -k" : TQString() );
- args.append( QString( " -p %1" ).arg( port ) );
+ args.append( TQString( " -p %1" ).tqarg( port ) );
return args;
}
-const QString Smb4KSambaOptionsHandler::nmblookupOptions( bool with_broadcast )
+const TQString Smb4KSambaOptionsHandler::nmblookupOptions( bool with_broadcast )
{
// Get the global Samba options
(void) globalSambaOptions();
- QString args = QString::null;
+ TQString args = TQString();
- QString netbios_name = (!Smb4KSettings::netBIOSName().isEmpty() &&
- QString::compare( Smb4KSettings::netBIOSName(),
+ TQString netbios_name = (!Smb4KSettings::netBIOSName().isEmpty() &&
+ TQString::compare( Smb4KSettings::netBIOSName(),
m_samba_options["netbios name"] ) != 0) ?
Smb4KSettings::netBIOSName() :
- QString::null;
+ TQString();
- QString netbios_scope = (!Smb4KSettings::netBIOSScope().isEmpty() &&
- QString::compare( Smb4KSettings::netBIOSScope(),
+ TQString netbios_scope = (!Smb4KSettings::netBIOSScope().isEmpty() &&
+ TQString::compare( Smb4KSettings::netBIOSScope(),
m_samba_options["netbios scope"] ) != 0) ?
Smb4KSettings::netBIOSScope() :
- QString::null;
+ TQString();
- QString socket_options = (!Smb4KSettings::socketOptions().isEmpty() &&
- QString::compare( Smb4KSettings::socketOptions(),
+ TQString socket_options = (!Smb4KSettings::socketOptions().isEmpty() &&
+ TQString::compare( Smb4KSettings::socketOptions(),
m_samba_options["socket options"] ) != 0) ?
Smb4KSettings::socketOptions() :
- QString::null;
+ TQString();
- QString domain = (!Smb4KSettings::domainName().isEmpty() &&
- QString::compare( Smb4KSettings::domainName(),
+ TQString domain = (!Smb4KSettings::domainName().isEmpty() &&
+ TQString::compare( Smb4KSettings::domainName(),
m_samba_options["workgroup"] ) != 0) ?
Smb4KSettings::domainName() :
- QString::null;
+ TQString();
args.append( !netbios_name.isEmpty() ?
- QString( " -n '%1'" ).arg( netbios_name ) :
- QString::null );
+ TQString( " -n '%1'" ).tqarg( netbios_name ) :
+ TQString() );
args.append( !netbios_scope.isEmpty() ?
- QString( " -i '%1'" ).arg( netbios_scope ) :
- QString::null );
+ TQString( " -i '%1'" ).tqarg( netbios_scope ) :
+ TQString() );
args.append( !socket_options.isEmpty() ?
- QString( " -O '%1'" ).arg( socket_options ) :
- QString::null );
+ TQString( " -O '%1'" ).tqarg( socket_options ) :
+ TQString() );
args.append( !domain.isEmpty() ?
- QString( " -W '%1'" ).arg( domain ) :
- QString::null );
+ TQString( " -W '%1'" ).tqarg( domain ) :
+ TQString() );
args.append( (!Smb4KSettings::broadcastAddress().isEmpty() &&
with_broadcast) ?
- QString( " -B %1" ).arg( Smb4KSettings::broadcastAddress() ) :
- QString::null );
+ TQString( " -B %1" ).tqarg( Smb4KSettings::broadcastAddress() ) :
+ TQString() );
args.append( Smb4KSettings::usePort137() ?
" -r" :
- QString::null );
+ TQString() );
return args;
}
-const QString Smb4KSambaOptionsHandler::netOptions( int command, const QString &networkItem, const QString &protocol )
+const TQString Smb4KSambaOptionsHandler::netOptions( int command, const TQString &networkItem, const TQString &protocol )
{
- QString args = QString::null;
+ TQString args = TQString();
Smb4KSambaOptionsInfo *info = find_item( networkItem );
- QString protocol_hint;
+ TQString protocol_hint;
// Determine the protocol hint specified by the user:
switch ( Smb4KSettings::protocolHint() )
@@ -658,7 +658,7 @@ const QString Smb4KSambaOptionsHandler::netOptions( int command, const QString &
{
// In this case the user leaves it to the net
// command to determine the right protocol.
- protocol_hint = QString::null;
+ protocol_hint = TQString();
break;
}
@@ -682,27 +682,27 @@ const QString Smb4KSambaOptionsHandler::netOptions( int command, const QString &
}
default:
{
- protocol_hint = QString::null;
+ protocol_hint = TQString();
break;
}
}
- QString default_protocol = (info && !info->protocol().isEmpty()) ?
+ TQString default_protocol = (info && !info->protocol().isEmpty()) ?
info->protocol() :
protocol_hint;
- QString netbios_name = (!Smb4KSettings::netBIOSName().isEmpty() &&
- QString::compare( Smb4KSettings::netBIOSName(),
+ TQString netbios_name = (!Smb4KSettings::netBIOSName().isEmpty() &&
+ TQString::compare( Smb4KSettings::netBIOSName(),
m_samba_options["netbios name"] ) != 0) ?
Smb4KSettings::netBIOSName() :
- QString::null;
+ TQString();
- QString domain = (!Smb4KSettings::domainName().isEmpty() &&
- QString::compare( Smb4KSettings::domainName(),
+ TQString domain = (!Smb4KSettings::domainName().isEmpty() &&
+ TQString::compare( Smb4KSettings::domainName(),
m_samba_options["workgroup"] ) != 0) ?
Smb4KSettings::domainName() :
- QString::null;
+ TQString();
int port = (info && info->port() != -1) ?
info->port() :
@@ -719,13 +719,13 @@ const QString Smb4KSambaOptionsHandler::netOptions( int command, const QString &
// Protocol can only be defined by us developers,
// and we should know what we are doing. So, no
// checks for the right protocol here:
- args.append( QString( " %1" ).arg( protocol ) );
+ args.append( TQString( " %1" ).tqarg( protocol ) );
}
else
{
- args.append( QString( " %1" ).arg( QString::compare( default_protocol, "ads" ) != 0 ?
+ args.append( TQString( " %1" ).tqarg( TQString::compare( default_protocol, "ads" ) != 0 ?
default_protocol :
- QString::null /* FIXME: Is that the best way how to do it? */) );
+ TQString() /* FIXME: Is that the best way how to do it? */) );
}
args.append( " share -l" );
@@ -754,7 +754,7 @@ const QString Smb4KSambaOptionsHandler::netOptions( int command, const QString &
}
// This lookup command takes no protocol:
- args.append( QString( " lookup host %1" ).arg( networkItem ) );
+ args.append( TQString( " lookup host %1" ).tqarg( networkItem ) );
break;
}
@@ -769,7 +769,7 @@ const QString Smb4KSambaOptionsHandler::netOptions( int command, const QString &
}
// This lookup command takes no protocol:
- args.append( QString( " lookup master '%1'" ).arg( networkItem ) );
+ args.append( TQString( " lookup master '%1'" ).tqarg( networkItem ) );
break;
}
@@ -789,41 +789,41 @@ const QString Smb4KSambaOptionsHandler::netOptions( int command, const QString &
}
args.append( !domain.isEmpty() ?
- QString( " -W '%1'" ).arg( domain ) :
- QString::null );
+ TQString( " -W '%1'" ).tqarg( domain ) :
+ TQString() );
args.append( !netbios_name.isEmpty() ?
- QString( " -n '%1'" ).arg( netbios_name ) :
- QString::null );
+ TQString( " -n '%1'" ).tqarg( netbios_name ) :
+ TQString() );
args.append( Smb4KSettings::machineAccount() ?
" -P" :
- QString::null );
+ TQString() );
- args.append( QString( " -p %1" ).arg( port ) );
+ args.append( TQString( " -p %1" ).tqarg( port ) );
return args;
}
-const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
+const TQString Smb4KSambaOptionsHandler::mountOptions( const TQString &share )
{
Smb4KSambaOptionsInfo *info = find_item( share );
- QString args;
+ TQString args;
// Read the global Samba options from smb.conf:
(void) globalSambaOptions();
// Get the strings needed to put the argument list together:
- QString uid = (info && !info->uid().isEmpty()) ?
+ TQString uid = (info && !info->uid().isEmpty()) ?
info->uid() :
Smb4KSettings::userID();
- QString gid = (info && !info->gid().isEmpty()) ?
+ TQString gid = (info && !info->gid().isEmpty()) ?
info->gid() :
Smb4KSettings::groupID();
- QString charset, codepage;
+ TQString charset, codepage;
switch ( Smb4KSettings::clientCharset() )
{
@@ -1167,7 +1167,7 @@ const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
}
case Smb4KSettings::EnumServerCodepage::unicode:
{
- codepage = "unicode";
+ codepage = "tqunicode";
break;
}
@@ -1179,21 +1179,21 @@ const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
#ifndef __FreeBSD__
- QString netbios_name = !Smb4KSettings::netBIOSName().isEmpty() ?
+ TQString netbios_name = !Smb4KSettings::netBIOSName().isEmpty() ?
Smb4KSettings::netBIOSName() :
m_samba_options["netbios name"];
- QString socket_options = (!Smb4KSettings::socketOptions().isEmpty() &&
- QString::compare( Smb4KSettings::socketOptions(),
+ TQString socket_options = (!Smb4KSettings::socketOptions().isEmpty() &&
+ TQString::compare( Smb4KSettings::socketOptions(),
m_samba_options["socket options"] ) != 0) ?
Smb4KSettings::socketOptions() :
- QString::null;
+ TQString();
- QString netbios_scope = (!Smb4KSettings::netBIOSScope().isEmpty() &&
- QString::compare( Smb4KSettings::netBIOSScope(),
+ TQString netbios_scope = (!Smb4KSettings::netBIOSScope().isEmpty() &&
+ TQString::compare( Smb4KSettings::netBIOSScope(),
m_samba_options["netbios scope"] ) != 0) ?
Smb4KSettings::netBIOSScope() :
- QString::null;
+ TQString();
int port = info && info->port() != -1 ?
info->port() :
@@ -1209,22 +1209,22 @@ const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
// Compile the arguments list:
args.append( !netbios_name.isEmpty() ?
- QString( "netbiosname='%1'," ).arg( netbios_name ) :
- QString::null );
+ TQString( "netbiosname='%1'," ).tqarg( netbios_name ) :
+ TQString() );
args.append( !uid.isEmpty() ?
- QString( "uid=%1," ).arg( uid ) :
- QString::null );
+ TQString( "uid=%1," ).tqarg( uid ) :
+ TQString() );
args.append( !gid.isEmpty() ?
- QString( "gid=%1," ).arg( gid ) :
- QString::null );
+ TQString( "gid=%1," ).tqarg( gid ) :
+ TQString() );
- args.append( QString( "port=%1," ).arg( port ) );
+ args.append( TQString( "port=%1," ).tqarg( port ) );
args.append( !charset.isEmpty() ?
- QString( "iocharset=%1," ).arg( charset ) :
- QString::null );
+ TQString( "iocharset=%1," ).tqarg( charset ) :
+ TQString() );
args.append( read_write ? "rw," : "ro," );
@@ -1233,12 +1233,12 @@ const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
case Smb4KSettings::EnumFilesystem::CIFS:
{
args.append( !Smb4KSettings::fileMask().isEmpty() ?
- QString( "file_mode=%1," ).arg( Smb4KSettings::fileMask() ) :
- QString::null );
+ TQString( "file_mode=%1," ).tqarg( Smb4KSettings::fileMask() ) :
+ TQString() );
args.append( !Smb4KSettings::directoryMask().isEmpty() ?
- QString( "dir_mode=%1," ).arg( Smb4KSettings::directoryMask() ) :
- QString::null );
+ TQString( "dir_mode=%1," ).tqarg( Smb4KSettings::directoryMask() ) :
+ TQString() );
args.append( Smb4KSettings::permissionChecks() ?
"perm," :
@@ -1254,7 +1254,7 @@ const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
args.append( Smb4KSettings::inodeDataCaching() ?
"directio," :
- QString::null ); // FIXME: Does 'nodirectio' exist?
+ TQString() ); // FIXME: Does 'nodirectio' exist?
args.append( Smb4KSettings::translateReservedChars() ?
"mapchars," :
@@ -1262,49 +1262,49 @@ const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
args.append( Smb4KSettings::noLocking() ?
"nolock," :
- QString::null ); // FIXME: Does 'lock' exist?
+ TQString() ); // FIXME: Does 'lock' exist?
args.append( !Smb4KSettings::customCIFSOptions().isEmpty() ?
Smb4KSettings::customCIFSOptions() :
- QString::null );
+ TQString() );
break;
}
case Smb4KSettings::EnumFilesystem::SMBFS:
{
args.append( !socket_options.isEmpty() ?
- QString( "sockopt='%1'," ).arg( socket_options ) :
- QString::null );
+ TQString( "sockopt='%1'," ).tqarg( socket_options ) :
+ TQString() );
args.append( !netbios_scope.isEmpty() ?
- QString( "scope=%1," ).arg( netbios_scope ) :
- QString::null );
+ TQString( "scope=%1," ).tqarg( netbios_scope ) :
+ TQString() );
args.append( !codepage.isEmpty() ?
- QString( "codepage=%1," ).arg( codepage ) :
- QString::null );
+ TQString( "codepage=%1," ).tqarg( codepage ) :
+ TQString() );
args.append( !Smb4KSettings::fileMask().isEmpty() ?
- QString( "fmask=%1," ).arg( Smb4KSettings::fileMask() ) :
- QString::null );
+ TQString( "ftqmask=%1," ).tqarg( Smb4KSettings::fileMask() ) :
+ TQString() );
args.append( !Smb4KSettings::directoryMask().isEmpty() ?
- QString( "dmask=%1," ).arg( Smb4KSettings::directoryMask() ) :
- QString::null );
+ TQString( "dtqmask=%1," ).tqarg( Smb4KSettings::directoryMask() ) :
+ TQString() );
- args.append( kerberos ? "krb," : QString::null );
+ args.append( kerberos ? "krb," : TQString() );
args.append( Smb4KSettings::cachingTime() != 1000 ?
- QString( "ttl=%1," ).arg( Smb4KSettings::cachingTime() ) :
- QString::null );
+ TQString( "ttl=%1," ).tqarg( Smb4KSettings::cachingTime() ) :
+ TQString() );
args.append( Smb4KSettings::unicodeSupport() ?
- "unicode," :
- QString::null );
+ "tqunicode," :
+ TQString() );
args.append( Smb4KSettings::largeFileSystemSupport() ?
"lfs," :
- QString::null );
+ TQString() );
break;
}
@@ -1318,24 +1318,24 @@ const QString Smb4KSambaOptionsHandler::mountOptions( const QString &share )
// Compile the arguments list:
args.append( !uid.isEmpty() ?
- QString( " -u %1" ).arg( uid ) :
- QString::null );
+ TQString( " -u %1" ).tqarg( uid ) :
+ TQString() );
args.append( !gid.isEmpty() ?
- QString( " -g %1" ).arg( gid ) :
- QString::null );
+ TQString( " -g %1" ).tqarg( gid ) :
+ TQString() );
args.append( !charset.isEmpty() && !codepage.isEmpty() ?
- QString( " -E %1:%2" ).arg( charset, codepage ) :
- QString::null );
+ TQString( " -E %1:%2" ).tqarg( charset, codepage ) :
+ TQString() );
args.append( !Smb4KSettings::fileMask().isEmpty() ?
- QString( " -f %1" ).arg( Smb4KSettings::fileMask() ) :
- QString::null );
+ TQString( " -f %1" ).tqarg( Smb4KSettings::fileMask() ) :
+ TQString() );
args.append( !Smb4KSettings::directoryMask().isEmpty() ?
- QString( " -d %1" ).arg( Smb4KSettings::directoryMask() ) :
- QString::null );
+ TQString( " -d %1" ).tqarg( Smb4KSettings::directoryMask() ) :
+ TQString() );
// NOTE: Under FreeBSD the port must be managed by the mounter.
@@ -1353,29 +1353,29 @@ void Smb4KSambaOptionsHandler::read_smb_conf()
// Clear the options list before reading.
m_samba_options.clear();
- QStringList paths;
+ TQStringList paths;
paths << "/etc";
paths << "/etc/samba";
paths << "/usr/local/etc";
paths << "/usr/local/etc/samba";
- QFile f( "smb.conf" );
+ TQFile f( "smb.conf" );
- QStringList contents;
+ TQStringList contents;
// Locate the file and read its contents:
- for ( QStringList::Iterator it = paths.begin(); it != paths.end(); ++it )
+ for ( TQStringList::Iterator it = paths.begin(); it != paths.end(); ++it )
{
- QDir::setCurrent( *it );
+ TQDir::setCurrent( *it );
if ( f.exists() )
{
if ( f.open( IO_ReadOnly ) )
{
- QTextStream ts( &f );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &f );
+ ts.setEncoding( TQTextStream::Locale );
- contents = QStringList::split( '\n', ts.read(), false );
+ contents = TQStringList::split( '\n', ts.read(), false );
}
f.close();
@@ -1389,35 +1389,35 @@ void Smb4KSambaOptionsHandler::read_smb_conf()
}
// Process the file contents.
- for ( QStringList::Iterator it = contents.erase( contents.begin(), ++(contents.find( "[global]" )) ); it != contents.end(); ++it )
+ for ( TQStringList::Iterator it = contents.erase( contents.begin(), ++(contents.tqfind( "[global]" )) ); it != contents.end(); ++it )
{
if ( (*it).stripWhiteSpace().startsWith( "#" ) || (*it).stripWhiteSpace().startsWith( ";" ) )
{
- *it = QString::null;
+ *it = TQString();
}
else if ( (*it).stripWhiteSpace().startsWith( "include" ) )
{
// Put the contents of the included at this position.
- QString file = (*it).section( "=", 1, 1 ).stripWhiteSpace();
- *it = QString::null;
+ TQString file = (*it).section( "=", 1, 1 ).stripWhiteSpace();
+ *it = TQString();
f.setName( file );
- QStringList include;
+ TQStringList include;
if ( f.exists() )
{
if ( f.open( IO_ReadOnly ) )
{
- QTextStream ts( &f );
- ts.setEncoding( QTextStream::Locale );
+ TQTextStream ts( &f );
+ ts.setEncoding( TQTextStream::Locale );
- include = QStringList::split( '\n', ts.read(), false );
+ include = TQStringList::split( '\n', ts.read(), false );
}
f.close();
}
- for ( QStringList::Iterator i = include.begin(); i != include.end(); ++i )
+ for ( TQStringList::Iterator i = include.begin(); i != include.end(); ++i )
{
if ( !(*i).stripWhiteSpace().isEmpty() )
{
@@ -1445,18 +1445,18 @@ void Smb4KSambaOptionsHandler::read_smb_conf()
}
}
- contents.remove( QString::null );
+ contents.remove( TQString() );
// Write all options into the map:
- for ( QStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
+ for ( TQStringList::ConstIterator it = contents.begin(); it != contents.end(); ++it )
{
- QString key = (*it).section( "=", 0, 0 ).stripWhiteSpace().lower();
- m_samba_options[key] = QString( (*it).section( "=", 1, 1 ).stripWhiteSpace().upper() );
+ TQString key = (*it).section( "=", 0, 0 ).stripWhiteSpace().lower();
+ m_samba_options[key] = TQString( (*it).section( "=", 1, 1 ).stripWhiteSpace().upper() );
}
// Post-processing. Some values should be entered with their defaults, if they are
// not already present.
- if ( !m_samba_options.contains( "netbios name" ) )
+ if ( !m_samba_options.tqcontains( "netbios name" ) )
{
size_t hostnamelen = 255;
char *hostname = new char[hostnamelen];
@@ -1464,11 +1464,11 @@ void Smb4KSambaOptionsHandler::read_smb_conf()
if ( gethostname( hostname, hostnamelen ) == -1 )
{
int error = errno;
- Smb4KError::error( ERROR_GETTING_HOSTNAME, QString::null, strerror( error ) );
+ Smb4KError::error( ERROR_GETTING_HOSTNAME, TQString(), strerror( error ) );
}
else
{
- m_samba_options["netbios name"] = ( QString( "%1" ).arg( hostname ) ).upper();
+ m_samba_options["netbios name"] = ( TQString( "%1" ).tqarg( hostname ) ).upper();
}
delete [] hostname;
@@ -1476,7 +1476,7 @@ void Smb4KSambaOptionsHandler::read_smb_conf()
}
-const QMap<QString,QString> &Smb4KSambaOptionsHandler::globalSambaOptions()
+const TQMap<TQString,TQString> &Smb4KSambaOptionsHandler::globalSambaOptions()
{
if ( m_samba_options.isEmpty() )
{
@@ -1487,7 +1487,7 @@ const QMap<QString,QString> &Smb4KSambaOptionsHandler::globalSambaOptions()
}
-const QString &Smb4KSambaOptionsHandler::winsServer()
+const TQString &Smb4KSambaOptionsHandler::winsServer()
{
if ( m_wins_server.isEmpty() )
{
@@ -1498,8 +1498,8 @@ const QString &Smb4KSambaOptionsHandler::winsServer()
m_wins_server = m_samba_options["wins server"];
}
else if ( !m_samba_options["wins support"].isEmpty() &&
- (QString::compare( m_samba_options["wins support"].lower(), "yes" ) == 0 ||
- QString::compare( m_samba_options["wins support"].lower(), "true" ) == 0) )
+ (TQString::compare( m_samba_options["wins support"].lower(), "yes" ) == 0 ||
+ TQString::compare( m_samba_options["wins support"].lower(), "true" ) == 0) )
{
m_wins_server = "127.0.0.1";
}
@@ -1513,7 +1513,7 @@ void Smb4KSambaOptionsHandler::addItem( Smb4KSambaOptionsInfo *info, bool s )
{
Smb4KSambaOptionsInfo *item = find_item( info->itemName() );
- if ( item && QString::compare( item->itemName().lower(), info->itemName().lower() ) == 0 )
+ if ( item && TQString::compare( item->itemName().lower(), info->itemName().lower() ) == 0 )
{
item->setPort( info->port() );
#ifndef __FreeBSD__
@@ -1540,11 +1540,11 @@ void Smb4KSambaOptionsHandler::addItem( Smb4KSambaOptionsInfo *info, bool s )
}
-void Smb4KSambaOptionsHandler::removeItem( const QString &name, bool s )
+void Smb4KSambaOptionsHandler::removeItem( const TQString &name, bool s )
{
Smb4KSambaOptionsInfo *item = find_item( name );
- if ( item && QString::compare( item->itemName().lower(), name.lower() ) == 0 )
+ if ( item && TQString::compare( item->itemName().lower(), name.lower() ) == 0 )
{
m_list.remove( item );
delete item;
diff --git a/smb4k/core/smb4ksambaoptionshandler.h b/smb4k/core/smb4ksambaoptionshandler.h
index 6bb5565..d14f0fb 100644
--- a/smb4k/core/smb4ksambaoptionshandler.h
+++ b/smb4k/core/smb4ksambaoptionshandler.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qmap.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqmap.h>
// KDE includes
#include <kconfig.h>
@@ -49,19 +49,20 @@ class Smb4KShare;
* @author Alexander Reinholdt <dustpuppy@mail.berlios.de>
*/
-class Smb4KSambaOptionsHandler : public QObject
+class Smb4KSambaOptionsHandler : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent object
+ * @param tqparent The tqparent object
*
* @param name The name of this object
*/
- Smb4KSambaOptionsHandler( QObject *parent = 0, const char *name = 0 );
+ Smb4KSambaOptionsHandler( TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -75,7 +76,7 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @returns the list of all shares that have custom options defined.
*/
- const QValueList<Smb4KSambaOptionsInfo *> &customOptionsList();
+ const TQValueList<Smb4KSambaOptionsInfo *> &customOptionsList();
/**
* This functions sets the remount flag of the share @p share to TRUE or FALSE.
@@ -105,7 +106,7 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @returns a list of arguments for use with the 'smbclient' program.
*/
- const QString smbclientOptions( const QString &share = QString::null );
+ const TQString smbclientOptions( const TQString &share = TQString() );
/**
* This function returns the "global" options for nmblookup, i.e. the domain
@@ -115,7 +116,7 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @returns a string with the "global" options for nmblookup
*/
- const QString nmblookupOptions( bool with_broadcast = true );
+ const TQString nmblookupOptions( bool with_broadcast = true );
/**
* This function returns the options defined in the global section of the smb.conf
@@ -124,14 +125,14 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @returns a list of the options defined in smb.conf.
*/
- const QMap<QString,QString> &globalSambaOptions();
+ const TQMap<TQString,TQString> &globalSambaOptions();
/**
* This function returns the WINS server the system is using.
*
* @returns the name or IP of the WINS server
*/
- const QString &winsServer();
+ const TQString &winsServer();
/**
* This enumeration is for use with the netOptions() function. It tells which
@@ -148,9 +149,9 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @param protocol Force a certain protocol (rap/rpc/ads) to be used.
*
- * @returns the list of arguments for the net command or QString::null if an error occurred.
+ * @returns the list of arguments for the net command or TQString() if an error occurred.
*/
- const QString netOptions( int command, const QString &networkItem, const QString &protocol = QString::null );
+ const TQString netOptions( int command, const TQString &networkItem, const TQString &protocol = TQString() );
/**
* This function returns the options for smbmount/mount.cifs under Linux
@@ -161,7 +162,7 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @param share The share that is to be mounted.
*/
- const QString mountOptions( const QString &share );
+ const TQString mountOptions( const TQString &share );
/**
* Find a network item in the list.
@@ -177,7 +178,7 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @returns the network item.
*/
- Smb4KSambaOptionsInfo *findItem( const QString &item, bool exactMatch = false ) { return find_item( item, exactMatch ); }
+ Smb4KSambaOptionsInfo *findItem( const TQString &item, bool exactMatch = false ) { return find_item( item, exactMatch ); }
/**
* Add a new Smb4KSambaOptionsInfo object to the list of custom options. If the item already exists,
@@ -196,13 +197,13 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @param sync If TRUE, the list is sync'ed with the config file.
*/
- void removeItem( const QString &name, bool sync );
+ void removeItem( const TQString &name, bool sync );
private:
/**
* The list of network items that have custom options defined.
*/
- QValueList<Smb4KSambaOptionsInfo *> m_list;
+ TQValueList<Smb4KSambaOptionsInfo *> m_list;
/**
* This function reads the options from the config file.
@@ -228,7 +229,7 @@ class Smb4KSambaOptionsHandler : public QObject
*
* @returns The Smb4KSambaOptionsInfo object associated with the network item.
*/
- Smb4KSambaOptionsInfo *find_item( const QString &item, bool exactMatch = false );
+ Smb4KSambaOptionsInfo *find_item( const TQString &item, bool exactMatch = false );
/**
* This function reads the entries of the global section of Samba's configuration
@@ -241,12 +242,12 @@ class Smb4KSambaOptionsHandler : public QObject
* file smb.conf. You can access a certain value by providing the lower case option name
* as key.
*/
- QMap<QString,QString> m_samba_options;
+ TQMap<TQString,TQString> m_samba_options;
/**
* The WINS server
*/
- QString m_wins_server;
+ TQString m_wins_server;
};
diff --git a/smb4k/core/smb4ksambaoptionsinfo.cpp b/smb4k/core/smb4ksambaoptionsinfo.cpp
index 5ea5b51..c9e7990 100644
--- a/smb4k/core/smb4ksambaoptionsinfo.cpp
+++ b/smb4k/core/smb4ksambaoptionsinfo.cpp
@@ -30,13 +30,13 @@
#include "smb4kshare.h"
-Smb4KSambaOptionsInfo::Smb4KSambaOptionsInfo( const QString &name )
+Smb4KSambaOptionsInfo::Smb4KSambaOptionsInfo( const TQString &name )
: m_name( name ), m_remount( false ), m_port( -1 ),
#ifndef __FreeBSD__
-m_filesystem( QString::null ), m_write_access( true ),
+m_filesystem( TQString() ), m_write_access( true ),
#endif
-m_protocol( QString::null ), m_kerberos( false ),
-m_uid( QString::null ), m_gid( QString::null )
+m_protocol( TQString() ), m_kerberos( false ),
+m_uid( TQString() ), m_gid( TQString() )
{
}
@@ -46,8 +46,8 @@ Smb4KSambaOptionsInfo::Smb4KSambaOptionsInfo( Smb4KShare *share )
#ifndef __FreeBSD__
m_filesystem( share->filesystem() ), m_write_access( true ),
#endif
-m_protocol( QString::null ), m_kerberos( false ),
-m_uid( QString( "%1" ).arg( share->uid() ) ), m_gid( QString( "%1" ).arg( share->gid() ) )
+m_protocol( TQString() ), m_kerberos( false ),
+m_uid( TQString( "%1" ).tqarg( share->uid() ) ), m_gid( TQString( "%1" ).tqarg( share->gid() ) )
{
}
@@ -75,7 +75,7 @@ void Smb4KSambaOptionsInfo::setRemount( bool rm )
}
-void Smb4KSambaOptionsInfo::setItemName( const QString &name )
+void Smb4KSambaOptionsInfo::setItemName( const TQString &name )
{
m_name = name;
}
@@ -86,15 +86,15 @@ void Smb4KSambaOptionsInfo::setPort( int port )
m_port = port;
}
-void Smb4KSambaOptionsInfo::setProtocol( const QString &p )
+void Smb4KSambaOptionsInfo::setProtocol( const TQString &p )
{
- if ( QString::compare( p, "auto" ) != 0 )
+ if ( TQString::compare( p, "auto" ) != 0 )
{
m_protocol = p;
}
else
{
- m_protocol = QString::null;
+ m_protocol = TQString();
}
}
@@ -107,23 +107,23 @@ void Smb4KSambaOptionsInfo::setKerberos( bool krb )
int Smb4KSambaOptionsInfo::type()
{
- return m_name.contains( "/" ) == 3 ? Share : Host;
+ return m_name.tqcontains( "/" ) == 3 ? Share : Host;
}
-void Smb4KSambaOptionsInfo::setUID( const QString &uid )
+void Smb4KSambaOptionsInfo::setUID( const TQString &uid )
{
m_uid = uid;
}
-void Smb4KSambaOptionsInfo::setGID( const QString &gid )
+void Smb4KSambaOptionsInfo::setGID( const TQString &gid )
{
m_gid = gid;
}
#ifndef __FreeBSD__
-void Smb4KSambaOptionsInfo::setFilesystem( const QString &fs )
+void Smb4KSambaOptionsInfo::setFilesystem( const TQString &fs )
{
m_filesystem = fs;
}
diff --git a/smb4k/core/smb4ksambaoptionsinfo.h b/smb4k/core/smb4ksambaoptionsinfo.h
index 706aa66..800cc84 100644
--- a/smb4k/core/smb4ksambaoptionsinfo.h
+++ b/smb4k/core/smb4ksambaoptionsinfo.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qstring.h>
+// TQt includes
+#include <tqstring.h>
// forward declarations
class Smb4KShare;
@@ -55,7 +55,7 @@ class Smb4KSambaOptionsInfo
*
* @param name The network item's name.
*/
- Smb4KSambaOptionsInfo( const QString &name );
+ Smb4KSambaOptionsInfo( const TQString &name );
/**
* Constructor. It takes a Smb4KShare object and extracts the name and the
@@ -98,7 +98,7 @@ class Smb4KSambaOptionsInfo
*
* @param name The name of the network item
*/
- void setItemName( const QString &name );
+ void setItemName( const TQString &name );
/**
* This function returns the name of the network item, i.e. the server or
@@ -106,7 +106,7 @@ class Smb4KSambaOptionsInfo
*
* @returns the name of the network item.
*/
- const QString &itemName() const { return m_name; }
+ const TQString &itemName() const { return m_name; }
/**
* This function sets the port that should be used when querying this share.
@@ -131,14 +131,14 @@ class Smb4KSambaOptionsInfo
*
* @param protocol the protocol
*/
- void setProtocol( const QString &protocol );
+ void setProtocol( const TQString &protocol );
/**
* This function returns the protocol to use with the net command.
*
* @retuns the protocol
*/
- const QString &protocol() const { return m_protocol; }
+ const TQString &protocol() const { return m_protocol; }
/**
* Set the 'Use Kerberos' flag.
@@ -163,14 +163,14 @@ class Smb4KSambaOptionsInfo
*
* @param uid The UID
*/
- void setUID( const QString &uid );
+ void setUID( const TQString &uid );
/**
* This functions returns the UID defined for this item.
*
* @returns the UID.
*/
- const QString &uid() const { return m_uid; }
+ const TQString &uid() const { return m_uid; }
/**
* With this function you can set the GID you want to use for this item.
@@ -178,14 +178,14 @@ class Smb4KSambaOptionsInfo
*
* @param gid The GID
*/
- void setGID( const QString &gid );
+ void setGID( const TQString &gid );
/**
* This functions returns the GID defined for this item.
*
* @returns the GID.
*/
- const QString &gid() const { return m_gid; }
+ const TQString &gid() const { return m_gid; }
/**
* This function returns the type of the network item for which the options
@@ -208,7 +208,7 @@ class Smb4KSambaOptionsInfo
*
* @param fs the file system name
*/
- void setFilesystem( const QString &fs );
+ void setFilesystem( const TQString &fs );
/**
* This function returns the file system that is to be used.
@@ -217,7 +217,7 @@ class Smb4KSambaOptionsInfo
*
* @returns the file system name
*/
- const QString &filesystem() const { return m_filesystem; }
+ const TQString &filesystem() const { return m_filesystem; }
/**
* Set if the share is to be mounted read-write or read-only.
@@ -243,7 +243,7 @@ class Smb4KSambaOptionsInfo
/**
* The share name.
*/
- QString m_name;
+ TQString m_name;
/**
* Should be remounted?
@@ -259,7 +259,7 @@ class Smb4KSambaOptionsInfo
/**
* The file system
*/
- QString m_filesystem;
+ TQString m_filesystem;
/**
* Mount read-write or read-only?
@@ -270,7 +270,7 @@ class Smb4KSambaOptionsInfo
/**
* The protocol
*/
- QString m_protocol;
+ TQString m_protocol;
/**
* Use Kerberos or not
@@ -280,12 +280,12 @@ class Smb4KSambaOptionsInfo
/**
* The UID
*/
- QString m_uid;
+ TQString m_uid;
/**
* The GID
*/
- QString m_gid;
+ TQString m_gid;
};
#endif
diff --git a/smb4k/core/smb4kscanner.cpp b/smb4k/core/smb4kscanner.cpp
index 737bf55..b4da920 100644
--- a/smb4k/core/smb4kscanner.cpp
+++ b/smb4k/core/smb4kscanner.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qapplication.h>
-#include <qmap.h>
-#include <qdeepcopy.h>
+// TQt includes
+#include <tqapplication.h>
+#include <tqmap.h>
+#include <tqdeepcopy.h>
// KDE includes
#include <klocale.h>
@@ -55,16 +55,16 @@ static bool created_hosts_list = false;
-Smb4KScanner::Smb4KScanner( QValueList<Smb4KWorkgroupItem *> *workgroups, QValueList<Smb4KHostItem *> *hosts,
-QObject *parent, const char *name )
-: QObject( parent, name ), m_workgroups_list( workgroups ), m_hosts_list( hosts )
+Smb4KScanner::Smb4KScanner( TQValueList<Smb4KWorkgroupItem *> *workgroups, TQValueList<Smb4KHostItem *> *hosts,
+TQObject *tqparent, const char *name )
+: TQObject( tqparent, name ), m_workgroups_list( workgroups ), m_hosts_list( hosts )
{
m_priv = new Smb4KScannerPrivate;
if ( !m_workgroups_list )
{
created_workgroups_list = true;
- m_workgroups_list = new QValueList<Smb4KWorkgroupItem *>;
+ m_workgroups_list = new TQValueList<Smb4KWorkgroupItem *>;
}
else
{
@@ -74,7 +74,7 @@ QObject *parent, const char *name )
if ( !m_hosts_list )
{
created_hosts_list = true;
- m_hosts_list = new QValueList<Smb4KHostItem *>;
+ m_hosts_list = new TQValueList<Smb4KHostItem *>;
}
else
{
@@ -88,14 +88,14 @@ QObject *parent, const char *name )
m_queue.setAutoDelete( true );
- connect( m_proc, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( processExited( KProcess* ) ),
- this, SLOT( slotProcessExited( KProcess * ) ) );
+ connect( m_proc, TQT_SIGNAL( processExited( KProcess* ) ),
+ this, TQT_SLOT( slotProcessExited( KProcess * ) ) );
- connect( m_proc, SIGNAL( receivedStderr( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStderr( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
}
@@ -106,7 +106,7 @@ Smb4KScanner::~Smb4KScanner()
// Delete the list of workgroups, if necessary:
if ( created_workgroups_list )
{
- for ( QValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups_list->begin(); it != m_workgroups_list->end(); ++it )
+ for ( TQValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups_list->begin(); it != m_workgroups_list->end(); ++it )
{
delete *it;
}
@@ -123,7 +123,7 @@ Smb4KScanner::~Smb4KScanner()
// Delete the list of hosts, if necessary:
if ( created_hosts_list )
{
- for ( QValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
+ for ( TQValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
{
delete *it;
}
@@ -150,7 +150,7 @@ void Smb4KScanner::init()
void Smb4KScanner::rescan()
{
- m_queue.enqueue( new QString( QString( "%1:" ).arg( Init ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:" ).tqarg( Init ) ) );
}
@@ -158,9 +158,9 @@ void Smb4KScanner::rescan()
Scans for workgroup members. (public part)
****************************************************************************/
-void Smb4KScanner::getWorkgroupMembers( const QString &workgroup, const QString &master, const QString &ip )
+void Smb4KScanner::getWorkgroupMembers( const TQString &workgroup, const TQString &master, const TQString &ip )
{
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4" ).arg( Hosts ).arg( workgroup, master, ip ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4" ).tqarg( Hosts ).tqarg( workgroup, master, ip ) ) );
}
@@ -168,9 +168,9 @@ void Smb4KScanner::getWorkgroupMembers( const QString &workgroup, const QString
Scans for shares on a selected host. (public part)
****************************************************************************/
-void Smb4KScanner::getShares( const QString &workgroup, const QString &host, const QString &ip, const QString &protocol )
+void Smb4KScanner::getShares( const TQString &workgroup, const TQString &host, const TQString &ip, const TQString &protocol )
{
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4:%5" ).arg( Shares ).arg( workgroup, host, ip ).arg( protocol ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4:%5" ).tqarg( Shares ).tqarg( workgroup, host, ip ).tqarg( protocol ) ) );
}
@@ -178,7 +178,7 @@ void Smb4KScanner::getShares( const QString &workgroup, const QString &host, con
Gets more info on a selected host. (public part)
****************************************************************************/
-void Smb4KScanner::getInfo( const QString &workgroup, const QString &host, const QString &ip )
+void Smb4KScanner::getInfo( const TQString &workgroup, const TQString &host, const TQString &ip )
{
Smb4KHostItem *item = getHost( host, workgroup );
@@ -194,7 +194,7 @@ void Smb4KScanner::getInfo( const QString &workgroup, const QString &host, const
item->setInfoChecked( true );
}
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4" ).arg( Info ).arg( workgroup, host, ip ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4" ).tqarg( Info ).tqarg( workgroup, host, ip ) ) );
}
@@ -202,7 +202,7 @@ void Smb4KScanner::getInfo( const QString &workgroup, const QString &host, const
Searches for a host. (public part)
****************************************************************************/
-void Smb4KScanner::search( const QString &host )
+void Smb4KScanner::search( const TQString &host )
{
// Check whether we already have this host in
// the list:
@@ -215,7 +215,7 @@ void Smb4KScanner::search( const QString &host )
return;
}
- m_queue.enqueue( new QString( QString( "%1:%2" ).arg( Search ).arg( host ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2" ).tqarg( Search ).tqarg( host ) ) );
}
@@ -242,12 +242,12 @@ void Smb4KScanner::scanNetwork()
{
abort();
- QString command;
+ TQString command;
// Look up the workgroups/domains and their master browsers.
// At the moment we have three methods:
// (1) Smb4KSettings::EnumBrowseList::LookupDomains: This method is
- // the most reliable one. It uses nmblookup and will only find
+ // the most reliable one. It uses nmblookup and will only tqfind
// *active* workgroup master browsers and thus active domains.
// (2) Smb4KSettings::EnumBrowseList::QueryCurrentMaster: This
// method will query the current master browser of the local
@@ -268,7 +268,7 @@ void Smb4KScanner::scanNetwork()
command.append( optionsHandler()->nmblookupOptions() );
command.append( " -- - | grep '<01>' | awk '{print $1}'" );
command.append( !optionsHandler()->winsServer().isEmpty() ?
- QString( " | xargs nmblookup -R -U %1 -A " ).arg( optionsHandler()->winsServer() ) :
+ TQString( " | xargs nmblookup -R -U %1 -A " ).tqarg( optionsHandler()->winsServer() ) :
" | xargs nmblookup -A " );
command.append( optionsHandler()->nmblookupOptions() );
@@ -285,7 +285,7 @@ void Smb4KScanner::scanNetwork()
Smb4KSettings::domainName() ) );
command.append( " -U % | xargs net " );
command.append( optionsHandler()->netOptions( Smb4KSambaOptionsHandler::Domain,
- QString::null ) );
+ TQString() ) );
command.append( " -U % -S" );
*m_proc << command;
@@ -302,7 +302,7 @@ void Smb4KScanner::scanNetwork()
command.append( " -U % -S "+KProcess::quote( Smb4KSettings::customMasterBrowser() ) );
command.append( " | xargs net " );
command.append( optionsHandler()->netOptions( Smb4KSambaOptionsHandler::Domain,
- QString::null ) );
+ TQString() ) );
command.append( " -U % -S "+KProcess::quote( Smb4KSettings::customMasterBrowser() )+" -I " );
*m_proc << command;
@@ -314,10 +314,10 @@ void Smb4KScanner::scanNetwork()
case Smb4KSettings::EnumBrowseList::ScanBroadcastAreas:
{
// Get the broadcast addresses that are to be scanned:
- QStringList addresses = QStringList::split( ",", Smb4KSettings::broadcastAreas(), false );
+ TQStringList addresses = TQStringList::split( ",", Smb4KSettings::broadcastAreas(), false );
// Build the command:
- for ( QStringList::ConstIterator it = addresses.begin(); it != addresses.end(); ++it )
+ for ( TQStringList::ConstIterator it = addresses.begin(); it != addresses.end(); ++it )
{
if ( !(*it).isEmpty() )
{
@@ -366,27 +366,27 @@ void Smb4KScanner::scanNetwork()
Scans for workgroup members. (private part)
****************************************************************************/
-void Smb4KScanner::scanForWorkgroupMembers( const QString &workgroup, const QString &master, const QString &ip )
+void Smb4KScanner::scanForWorkgroupMembers( const TQString &workgroup, const TQString &master, const TQString &ip )
{
m_priv->setWorkgroup( workgroup );
m_priv->setHost( master );
m_priv->setIP( ip );
- QString command;
+ TQString command;
if ( !ip.isEmpty() )
{
- command.append( "net "+optionsHandler()->netOptions( Smb4KSambaOptionsHandler::ServerDomain, QString::null ) );
+ command.append( "net "+optionsHandler()->netOptions( Smb4KSambaOptionsHandler::ServerDomain, TQString() ) );
command.append( " -I "+ip );
command.append( " -w "+KProcess::quote( workgroup ) );
command.append( " -S "+KProcess::quote( master ) );
- Smb4KAuthInfo authInfo( workgroup, master, QString::null );
+ Smb4KAuthInfo authInfo( workgroup, master, TQString() );
(void) passwordHandler()->readAuth( &authInfo );
if ( !authInfo.user().isEmpty() )
{
- command.append( QString( " -U %1" ).arg( KProcess::quote( authInfo.user() ) ) );
+ command.append( TQString( " -U %1" ).tqarg( KProcess::quote( authInfo.user() ) ) );
if ( !authInfo.password().isEmpty() )
{
@@ -407,17 +407,17 @@ void Smb4KScanner::scanForWorkgroupMembers( const QString &workgroup, const QStr
command.append( "| xargs -IIPADDR " );
command.append( getenv( "SHELL" ) );
command.append( " -c 'echo \"*** "+master+": IPADDR ***\" && " );
- command.append( "net "+optionsHandler()->netOptions( Smb4KSambaOptionsHandler::ServerDomain, QString::null ) );
+ command.append( "net "+optionsHandler()->netOptions( Smb4KSambaOptionsHandler::ServerDomain, TQString() ) );
command.append( " -I IPADDR" );
command.append( " -w "+KProcess::quote( workgroup ) );
command.append( " -S "+KProcess::quote( master ) );
- Smb4KAuthInfo authInfo( workgroup, master, QString::null );
+ Smb4KAuthInfo authInfo( workgroup, master, TQString() );
(void) passwordHandler()->readAuth( &authInfo );
if ( !authInfo.user().isEmpty() )
{
- command.append( QString( " -U %1'" ).arg( KProcess::quote( authInfo.user() ) ) );
+ command.append( TQString( " -U %1'" ).tqarg( KProcess::quote( authInfo.user() ) ) );
if ( !authInfo.password().isEmpty() )
{
@@ -440,26 +440,26 @@ void Smb4KScanner::scanForWorkgroupMembers( const QString &workgroup, const QStr
Scans for shares on a selected host. (private part)
****************************************************************************/
-void Smb4KScanner::scanForShares( const QString &workgroup, const QString &host, const QString &ip, const QString &protocol )
+void Smb4KScanner::scanForShares( const TQString &workgroup, const TQString &host, const TQString &ip, const TQString &protocol )
{
m_priv->setWorkgroup( workgroup );
m_priv->setHost( host );
m_priv->setIP( ip );
- Smb4KAuthInfo *auth = passwordHandler()->readAuth( new Smb4KAuthInfo( workgroup, host, QString::null ) );
+ Smb4KAuthInfo *auth = passwordHandler()->readAuth( new Smb4KAuthInfo( workgroup, host, TQString() ) );
- QString command;
+ TQString command;
- command = QString( "net %1 -w %2 -S %3" ).arg( optionsHandler()->netOptions( Smb4KSambaOptionsHandler::Share, host, protocol ) ).arg( KProcess::quote( workgroup ), KProcess::quote( host ) );
+ command = TQString( "net %1 -w %2 -S %3" ).tqarg( optionsHandler()->netOptions( Smb4KSambaOptionsHandler::Share, host, protocol ) ).tqarg( KProcess::quote( workgroup ), KProcess::quote( host ) );
if ( !ip.isEmpty() )
{
- command.append( QString( " -I %1" ).arg( KProcess::quote( ip ) ) );
+ command.append( TQString( " -I %1" ).tqarg( KProcess::quote( ip ) ) );
}
if ( !auth->user().isEmpty() )
{
- command.append( QString( " -U %1" ).arg( KProcess::quote( auth->user() ) ) );
+ command.append( TQString( " -U %1" ).tqarg( KProcess::quote( auth->user() ) ) );
if ( !auth->password().isEmpty() )
{
@@ -483,19 +483,19 @@ void Smb4KScanner::scanForShares( const QString &workgroup, const QString &host,
Gets more info on a selected host. (private part)
****************************************************************************/
-void Smb4KScanner::scanForInfo( const QString &workgroup, const QString &host, const QString &ip )
+void Smb4KScanner::scanForInfo( const TQString &workgroup, const TQString &host, const TQString &ip )
{
m_priv->setWorkgroup( workgroup );
m_priv->setHost( host );
m_priv->setIP( ip );
- QString smbclient_options = optionsHandler()->smbclientOptions();
+ TQString smbclient_options = optionsHandler()->smbclientOptions();
- QString command = QString( "smbclient -d1 -U guest% -W %1 -L %2" ).arg( KProcess::quote( workgroup ) ).arg( KProcess::quote( host ) );
+ TQString command = TQString( "smbclient -d1 -U guest% -W %1 -L %2" ).tqarg( KProcess::quote( workgroup ) ).tqarg( KProcess::quote( host ) );
if ( !ip.isEmpty() )
{
- command.append( QString( " -I %1" ).arg( KProcess::quote( ip ) ) );
+ command.append( TQString( " -I %1" ).tqarg( KProcess::quote( ip ) ) );
}
if ( !smbclient_options.stripWhiteSpace().isEmpty() )
@@ -513,7 +513,7 @@ void Smb4KScanner::scanForInfo( const QString &workgroup, const QString &host, c
Searches for a host. (private part)
****************************************************************************/
-void Smb4KScanner::searchForHost( const QString &host )
+void Smb4KScanner::searchForHost( const TQString &host )
{
// We need this because smbclient won't return the host name.
KNetwork::KIpAddress ip_address = KNetwork::KIpAddress( host );
@@ -529,43 +529,43 @@ void Smb4KScanner::searchForHost( const QString &host )
m_priv->setHost( host );
- QString wins = optionsHandler()->winsServer();
- QString nmblookup_options = optionsHandler()->nmblookupOptions();
- QString smbclient_options = optionsHandler()->smbclientOptions();
+ TQString wins = optionsHandler()->winsServer();
+ TQString nmblookup_options = optionsHandler()->nmblookupOptions();
+ TQString smbclient_options = optionsHandler()->smbclientOptions();
- QString command;
+ TQString command;
switch ( Smb4KSettings::searchMethod() )
{
case Smb4KSettings::EnumSearchMethod::Nmblookup:
{
- command = QString( "nmblookup" );
+ command = TQString( "nmblookup" );
if ( !nmblookup_options.stripWhiteSpace().isEmpty() )
{
command.append( nmblookup_options );
}
- if ( host.contains( '.', true ) != 3 )
+ if ( host.tqcontains( '.', true ) != 3 )
{
if ( !wins.isEmpty() )
{
- command.append( QString( " -R -U %1 %2 -S | grep '<00>' | sed -e 's/<00>.*//'" ).arg( wins ).arg( m_priv->host() ) );
+ command.append( TQString( " -R -U %1 %2 -S | grep '<00>' | sed -e 's/<00>.*//'" ).tqarg( wins ).tqarg( m_priv->host() ) );
}
else
{
- command.append( QString( " %1 -S | grep '<00>' | sed -e 's/<00>.*//'" ).arg( m_priv->host() ) );
+ command.append( TQString( " %1 -S | grep '<00>' | sed -e 's/<00>.*//'" ).tqarg( m_priv->host() ) );
}
}
else
{
if ( !wins.isEmpty() )
{
- command.append( QString( " -R -U %1 %2 -A | grep '<00>' | sed -e 's/<00>.*//'" ).arg( wins ).arg( m_priv->host() ) );
+ command.append( TQString( " -R -U %1 %2 -A | grep '<00>' | sed -e 's/<00>.*//'" ).tqarg( wins ).tqarg( m_priv->host() ) );
}
else
{
- command.append( QString( " %1 -A | grep '<00>' | sed -e 's/<00>.*//'" ).arg( m_priv->host() ) );
+ command.append( TQString( " %1 -A | grep '<00>' | sed -e 's/<00>.*//'" ).tqarg( m_priv->host() ) );
}
}
@@ -573,7 +573,7 @@ void Smb4KScanner::searchForHost( const QString &host )
}
case Smb4KSettings::EnumSearchMethod::Smbclient:
{
- command = QString( "smbclient -d2 -U % -L %1" ).arg( m_priv->host() );
+ command = TQString( "smbclient -d2 -U % -L %1" ).tqarg( m_priv->host() );
if ( !smbclient_options.stripWhiteSpace().isEmpty() )
{
@@ -602,11 +602,11 @@ void Smb4KScanner::searchForHost( const QString &host )
void Smb4KScanner::startProcess( int state )
{
m_state = state;
- m_buffer = QString::null;
+ m_buffer = TQString();
if ( state != Info )
{
- QApplication::setOverrideCursor( waitCursor );
+ TQApplication::setOverrideCursor( waitCursor );
}
m_proc->start( KProcess::NotifyOnExit, KProcess::AllOutput );
@@ -648,7 +648,7 @@ void Smb4KScanner::endProcess()
m_priv->clearData();
- QApplication::restoreOverrideCursor();
+ TQApplication::restoreOverrideCursor();
m_proc->clearArguments();
@@ -664,14 +664,14 @@ void Smb4KScanner::endProcess()
void Smb4KScanner::processWorkgroups()
{
- QStringList list = QStringList::split( '\n', m_buffer, false );
+ TQStringList list = TQStringList::split( '\n', m_buffer, false );
- for ( QValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups_list->begin(); it != m_workgroups_list->end(); ++it )
+ for ( TQValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups_list->begin(); it != m_workgroups_list->end(); ++it )
{
delete *it;
}
- for ( QValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
+ for ( TQValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
{
delete *it;
}
@@ -681,9 +681,9 @@ void Smb4KScanner::processWorkgroups()
if ( m_state == Workgroups )
{
- QString workgroup, master, ip;
+ TQString workgroup, master, ip;
- for ( QStringList::Iterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::Iterator it = list.begin(); it != list.end(); ++it )
{
if ( (*it).stripWhiteSpace().startsWith( "Looking" ) )
{
@@ -691,7 +691,7 @@ void Smb4KScanner::processWorkgroups()
continue;
}
- else if ( (*it).contains( "<00>" ) != 0 && (*it).contains( "<GROUP>" ) == 0 )
+ else if ( (*it).tqcontains( "<00>" ) != 0 && (*it).tqcontains( "<GROUP>" ) == 0 )
{
if ( workgroup.isEmpty() && master.isEmpty() && !ip.isEmpty() )
{
@@ -700,22 +700,22 @@ void Smb4KScanner::processWorkgroups()
continue;
}
- else if ( (*it).contains( "<00>" ) != 0 && (*it).contains( "<GROUP>" ) != 0 )
+ else if ( (*it).tqcontains( "<00>" ) != 0 && (*it).tqcontains( "<GROUP>" ) != 0 )
{
if ( workgroup.isEmpty() && !master.isEmpty() && !ip.isEmpty() )
{
- workgroup = (*it).left( (*it).find( "<00>" ) ).stripWhiteSpace();
+ workgroup = (*it).left( (*it).tqfind( "<00>" ) ).stripWhiteSpace();
m_workgroups_list->append( new Smb4KWorkgroupItem( workgroup, master, ip ) );
- Smb4KHostItem *master_item = new Smb4KHostItem( workgroup, master, QString::null, ip );
+ Smb4KHostItem *master_item = new Smb4KHostItem( workgroup, master, TQString(), ip );
master_item->setMaster( true );
m_hosts_list->append( master_item );
- workgroup = QString::null;
- master = QString::null;
- ip = QString::null;
+ workgroup = TQString();
+ master = TQString();
+ ip = TQString();
}
continue;
@@ -726,9 +726,9 @@ void Smb4KScanner::processWorkgroups()
{
bool process = false;
- for ( QStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
{
- QString line = (*it).stripWhiteSpace();
+ TQString line = (*it).stripWhiteSpace();
if ( line.startsWith( "-------------" ) )
{
@@ -739,10 +739,10 @@ void Smb4KScanner::processWorkgroups()
if ( process && !line.isEmpty() )
{
- QString workgroup = line.section( " ", 0, 0 ).stripWhiteSpace();
- QString master = line.section( " ", 1, -1 ).stripWhiteSpace();
+ TQString workgroup = line.section( " ", 0, 0 ).stripWhiteSpace();
+ TQString master = line.section( " ", 1, -1 ).stripWhiteSpace();
- m_workgroups_list->append( new Smb4KWorkgroupItem( workgroup, master, QString::null ) );
+ m_workgroups_list->append( new Smb4KWorkgroupItem( workgroup, master, TQString() ) );
Smb4KHostItem *master_item = new Smb4KHostItem( workgroup, master );
master_item->setMaster( true );
@@ -771,14 +771,14 @@ void Smb4KScanner::processWorkgroups()
void Smb4KScanner::processIPScan()
{
- QStringList list = QStringList::split( '\n', m_buffer, true );
+ TQStringList list = TQStringList::split( '\n', m_buffer, true );
- for ( QValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups_list->begin(); it != m_workgroups_list->end(); ++it )
+ for ( TQValueList<Smb4KWorkgroupItem *>::Iterator it = m_workgroups_list->begin(); it != m_workgroups_list->end(); ++it )
{
delete *it;
}
- for ( QValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
+ for ( TQValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
{
delete *it;
}
@@ -787,22 +787,22 @@ void Smb4KScanner::processIPScan()
m_hosts_list->clear();
// Process the data:
- for ( QStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( (*it).startsWith( "Looking up status of" ) )
{
- QString workgroup, host, ip;
+ TQString workgroup, host, ip;
bool master = false;
// Get the IP address of this host.
ip = (*it).section( "of", 1, 1 ).stripWhiteSpace();
// Loop through the data:
- for ( QStringList::ConstIterator i = it; i != list.end(); ++i )
+ for ( TQStringList::ConstIterator i = it; i != list.end(); ++i )
{
- if ( (*i).contains( " <00> " ) != 0 )
+ if ( (*i).tqcontains( " <00> " ) != 0 )
{
- if ( (*i).contains( " <GROUP> " ) != 0 )
+ if ( (*i).tqcontains( " <GROUP> " ) != 0 )
{
workgroup = (*i).section( "<00>", 0, 0 ).stripWhiteSpace();
}
@@ -813,13 +813,13 @@ void Smb4KScanner::processIPScan()
continue;
}
- else if ( (*i).contains( "__MSBROWSE__" ) != 0 && (*i).contains( " <01> " ) != 0 )
+ else if ( (*i).tqcontains( "__MSBROWSE__" ) != 0 && (*i).tqcontains( " <01> " ) != 0 )
{
master = true;
continue;
}
- else if ( (*i).contains( "MAC Address" ) != 0 || (*i).stripWhiteSpace().isEmpty() )
+ else if ( (*i).tqcontains( "MAC Address" ) != 0 || (*i).stripWhiteSpace().isEmpty() )
{
it = i;
@@ -854,11 +854,11 @@ void Smb4KScanner::processIPScan()
}
else
{
- m_workgroups_list->append( new Smb4KWorkgroupItem( workgroup, QString::null, QString::null ) );
+ m_workgroups_list->append( new Smb4KWorkgroupItem( workgroup, TQString(), TQString() ) );
}
}
- Smb4KHostItem *host_item = new Smb4KHostItem( workgroup, host, QString::null, ip );
+ Smb4KHostItem *host_item = new Smb4KHostItem( workgroup, host, TQString(), ip );
host_item->setMaster( master );
m_hosts_list->append( host_item );
@@ -889,7 +889,7 @@ void Smb4KScanner::processIPScan()
void Smb4KScanner::processWorkgroupMembers()
{
- QStringList list = QStringList::split( '\n', m_buffer, false );
+ TQStringList list = TQStringList::split( '\n', m_buffer, false );
switch ( Smb4KSettings::browseList() )
{
@@ -897,27 +897,27 @@ void Smb4KScanner::processWorkgroupMembers()
case Smb4KSettings::EnumBrowseList::QueryCurrentMaster:
case Smb4KSettings::EnumBrowseList::QueryCustomMaster:
{
- if ( m_buffer.contains( "NT_STATUS_ACCESS_DENIED" ) != 0 ||
- m_buffer.contains( "NT_STATUS_LOGON_FAILURE" ) != 0 ||
- m_buffer.contains( "The username or password was not correct" ) != 0 )
+ if ( m_buffer.tqcontains( "NT_STATUS_ACCESS_DENIED" ) != 0 ||
+ m_buffer.tqcontains( "NT_STATUS_LOGON_FAILURE" ) != 0 ||
+ m_buffer.tqcontains( "The username or password was not correct" ) != 0 )
{
// Authentication failed:
emit failed();
if ( passwordHandler()->askpass( m_priv->workgroup(), m_priv->host(),
- QString::null, Smb4KPasswordHandler::AccessDenied,
+ TQString(), Smb4KPasswordHandler::AccessDenied,
kapp->mainWidget() ? kapp->mainWidget() : 0, "AskPass" ) )
{
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4" ).arg( Hosts ).arg( m_priv->workgroup(), m_priv->host(), m_priv->ip() ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4" ).tqarg( Hosts ).tqarg( m_priv->workgroup(), m_priv->host(), m_priv->ip() ) ) );
}
return;
}
- else if ( m_buffer.contains( "Could not connect to server" ) != 0 ||
- m_buffer.contains( "Unable to find a suitable server" ) != 0 ||
- m_buffer.contains( "Invalid ip address specified" ) != 0 )
+ else if ( m_buffer.tqcontains( "Could not connect to server" ) != 0 ||
+ m_buffer.tqcontains( "Unable to find a suitable server" ) != 0 ||
+ m_buffer.tqcontains( "Invalid ip address specified" ) != 0 )
{
- // If the IP address is empty, the shell output contains
+ // If the IP address is empty, the shell output tqcontains
// the IP address. Remove it, because it will confuse
// the user:
if ( m_priv->ip().isEmpty() )
@@ -929,7 +929,7 @@ void Smb4KScanner::processWorkgroupMembers()
emit failed();
// Notify the user:
- Smb4KError::error( ERROR_GETTING_MEMBERS, QString::null, list.join( "\n" ) );
+ Smb4KError::error( ERROR_GETTING_MEMBERS, TQString(), list.join( "\n" ) );
return;
}
@@ -938,13 +938,13 @@ void Smb4KScanner::processWorkgroupMembers()
// Do nothing
}
- QValueList<Smb4KHostItem *> hosts;
+ TQValueList<Smb4KHostItem *> hosts;
bool process = false;
- for ( QStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
{
- QString line = (*it).stripWhiteSpace();
+ TQString line = (*it).stripWhiteSpace();
if ( !process )
{
@@ -972,9 +972,9 @@ void Smb4KScanner::processWorkgroupMembers()
{
if ( !line.isEmpty() )
{
- QString host, comment;
+ TQString host, comment;
- if ( line.contains( " " ) == 0 )
+ if ( line.tqcontains( " " ) == 0 )
{
host = line;
}
@@ -986,7 +986,7 @@ void Smb4KScanner::processWorkgroupMembers()
Smb4KHostItem *item = new Smb4KHostItem( m_priv->workgroup(), host, comment );
- if ( QString::compare( item->name(), m_priv->host() ) == 0 )
+ if ( TQString::compare( item->name(), m_priv->host() ) == 0 )
{
// The item is identical to the master browser! Give the
// respective workgroup item the IP address of the master
@@ -1028,15 +1028,15 @@ void Smb4KScanner::processWorkgroupMembers()
emit members( m_priv->workgroup(), hosts );
// Now put the hosts in m_hosts_list:
- for ( QValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
+ for ( TQValueList<Smb4KHostItem *>::Iterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
{
- if ( QString::compare( (*it)->workgroup(), m_priv->workgroup() ) == 0 )
+ if ( TQString::compare( (*it)->workgroup(), m_priv->workgroup() ) == 0 )
{
bool found = false;
- for ( QValueList<Smb4KHostItem *>::Iterator i = hosts.begin(); i != hosts.end(); ++i )
+ for ( TQValueList<Smb4KHostItem *>::Iterator i = hosts.begin(); i != hosts.end(); ++i )
{
- if ( *i && QString::compare( (*i)->name(), (*it)->name() ) == 0 )
+ if ( *i && TQString::compare( (*i)->name(), (*it)->name() ) == 0 )
{
found = true;
@@ -1079,25 +1079,25 @@ void Smb4KScanner::processWorkgroupMembers()
}
case Smb4KSettings::EnumBrowseList::ScanBroadcastAreas:
{
- if ( m_buffer.contains( "NT_STATUS_ACCESS_DENIED" ) != 0 ||
- m_buffer.contains( "NT_STATUS_LOGON_FAILURE" ) != 0 ||
- m_buffer.contains( "The username or password was not correct" ) != 0 )
+ if ( m_buffer.tqcontains( "NT_STATUS_ACCESS_DENIED" ) != 0 ||
+ m_buffer.tqcontains( "NT_STATUS_LOGON_FAILURE" ) != 0 ||
+ m_buffer.tqcontains( "The username or password was not correct" ) != 0 )
{
// Authentication failed:
emit failed();
if ( passwordHandler()->askpass( m_priv->workgroup(), m_priv->host(),
- QString::null, Smb4KPasswordHandler::AccessDenied,
+ TQString(), Smb4KPasswordHandler::AccessDenied,
kapp->mainWidget() ? kapp->mainWidget() : 0, "AskPass" ) )
{
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4" ).arg( Hosts ).arg( m_priv->workgroup(), m_priv->host(), m_priv->ip() ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4" ).tqarg( Hosts ).tqarg( m_priv->workgroup(), m_priv->host(), m_priv->ip() ) ) );
}
return;
}
- else if ( m_buffer.contains( "Could not connect to server" ) != 0 ||
- m_buffer.contains( "Unable to find a suitable server" ) != 0 ||
- m_buffer.contains( "Invalid ip address specified" ) != 0 )
+ else if ( m_buffer.tqcontains( "Could not connect to server" ) != 0 ||
+ m_buffer.tqcontains( "Unable to find a suitable server" ) != 0 ||
+ m_buffer.tqcontains( "Invalid ip address specified" ) != 0 )
{
// We are in IP scan mode, so we can ignore the error and emit
// what we already have:
@@ -1112,7 +1112,7 @@ void Smb4KScanner::processWorkgroupMembers()
bool process = false;
- for ( QStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( (*it).stripWhiteSpace().startsWith( "-------------" ) )
{
@@ -1123,12 +1123,12 @@ void Smb4KScanner::processWorkgroupMembers()
if ( process && !(*it).stripWhiteSpace().isEmpty() )
{
- QString line = (*it).stripWhiteSpace();
+ TQString line = (*it).stripWhiteSpace();
// Extract host name and comment:
- QString host, comment;
+ TQString host, comment;
- if ( line.contains( " " ) == 0 )
+ if ( line.tqcontains( " " ) == 0 )
{
host = line;
}
@@ -1179,49 +1179,49 @@ void Smb4KScanner::processWorkgroupMembers()
void Smb4KScanner::processShares()
{
// Error handling
- if ( m_buffer.contains( "The username or password was not correct.", true ) != 0 ||
- m_buffer.contains( "NT_STATUS_ACCOUNT_DISABLED" ) != 0 /* Active Directory error */ )
+ if ( m_buffer.tqcontains( "The username or password was not correct.", true ) != 0 ||
+ m_buffer.tqcontains( "NT_STATUS_ACCOUNT_DISABLED" ) != 0 /* Active Directory error */ )
{
// Authentication failed:
emit failed();
- if ( passwordHandler()->askpass( m_priv->workgroup(), m_priv->host(), QString::null, Smb4KPasswordHandler::AccessDenied, kapp->mainWidget() ? kapp->mainWidget() : 0, "AskPass" ) )
+ if ( passwordHandler()->askpass( m_priv->workgroup(), m_priv->host(), TQString(), Smb4KPasswordHandler::AccessDenied, kapp->mainWidget() ? kapp->mainWidget() : 0, "AskPass" ) )
{
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4:%5" ).arg( Shares ).arg( m_priv->workgroup(), m_priv->host(), m_priv->ip(), QString::null ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4:%5" ).tqarg( Shares ).tqarg( m_priv->workgroup(), m_priv->host(), m_priv->ip(), TQString() ) ) );
}
return;
}
- else if ( m_buffer.contains( "could not obtain sid for domain", true ) != 0 )
+ else if ( m_buffer.tqcontains( "could not obtain sid for domain", true ) != 0 )
{
// FIXME: Does this error only occur when we scan a server that is
// only capable of the RAP protocol or also under other conditions?
- m_queue.enqueue( new QString( QString( "%1:%2:%3:%4:%5" ).arg( Shares ).arg( m_priv->workgroup(), m_priv->host(), m_priv->ip(), "rap" ) ) );
+ m_queue.enqueue( new TQString( TQString( "%1:%2:%3:%4:%5" ).tqarg( Shares ).tqarg( m_priv->workgroup(), m_priv->host(), m_priv->ip(), "rap" ) ) );
m_priv->retry = true;
return;
}
- else if ( (m_buffer.contains( "Could not connect to server", true ) != 0 &&
- m_buffer.contains( "The username or password was not correct.", true ) == 0) ||
- m_buffer.contains( "Unable to find a suitable server" ) != 0 )
+ else if ( (m_buffer.tqcontains( "Could not connect to server", true ) != 0 &&
+ m_buffer.tqcontains( "The username or password was not correct.", true ) == 0) ||
+ m_buffer.tqcontains( "Unable to find a suitable server" ) != 0 )
{
// We could not get the list of shares:
emit failed();
// Notify the user:
- Smb4KError::error( ERROR_GETTING_SHARES, QString::null, m_buffer );
+ Smb4KError::error( ERROR_GETTING_SHARES, TQString(), m_buffer );
return;
}
- QStringList list = QStringList::split( '\n', m_buffer, false );
+ TQStringList list = TQStringList::split( '\n', m_buffer, false );
- QValueList<Smb4KShareItem *> share_list;
+ TQValueList<Smb4KShareItem *> share_list;
bool process = false;
- for ( QStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( (*it).startsWith( "---" ) )
{
@@ -1230,21 +1230,21 @@ void Smb4KScanner::processShares()
if ( process )
{
- QString name, type, comment;
+ TQString name, type, comment;
- if ( (*it).contains( " Disk ", true ) != 0 )
+ if ( (*it).tqcontains( " Disk ", true ) != 0 )
{
name = (*it).section( " Disk ", 0, 0 ).stripWhiteSpace();
type = "Disk";
comment = (*it).section( " Disk ", 1, 1 ).stripWhiteSpace();
}
- else if ( (*it).contains( " Print ", true ) != 0 )
+ else if ( (*it).tqcontains( " Print ", true ) != 0 )
{
name = (*it).section( " Print ", 0, 0 ).stripWhiteSpace();
type = "Printer";
comment = (*it).section( " Print ", 1, 1 ).stripWhiteSpace();
}
- else if ( (*it).contains( " IPC ", true ) != 0 )
+ else if ( (*it).tqcontains( " IPC ", true ) != 0 )
{
name = (*it).section( " IPC ", 0, 0 ).stripWhiteSpace();
type = "IPC";
@@ -1278,15 +1278,15 @@ void Smb4KScanner::processSearch()
// Stop right here if the user searched for illegal
// strings like #, ', () etc.
- if ( m_buffer.contains( "Usage:", true ) != 0 ||
- m_buffer.contains( "/bin/sh:", true ) != 0 )
+ if ( m_buffer.tqcontains( "Usage:", true ) != 0 ||
+ m_buffer.tqcontains( "/bin/sh:", true ) != 0 )
{
emit searchResult( new Smb4KHostItem() );
return;
}
- QStringList data = QStringList::split( '\n', m_buffer.stripWhiteSpace(), false );
+ TQStringList data = TQStringList::split( '\n', m_buffer.stripWhiteSpace(), false );
switch ( Smb4KSettings::searchMethod() )
{
@@ -1295,10 +1295,10 @@ void Smb4KScanner::processSearch()
if ( !data.isEmpty() )
{
// The last entry in the list is the workgroup:
- QString workgroup = data.last().stripWhiteSpace();
- QString host, ip;
+ TQString workgroup = data.last().stripWhiteSpace();
+ TQString host, ip;
- if ( m_priv->host().contains( ".", true ) != 3 )
+ if ( m_priv->host().tqcontains( ".", true ) != 3 )
{
// The IP address is in the first entry:
ip = data.first().stripWhiteSpace().section( " ", 0, 0 );
@@ -1311,7 +1311,7 @@ void Smb4KScanner::processSearch()
host = data[0].stripWhiteSpace();
}
- emit searchResult( new Smb4KHostItem( workgroup, host, QString::null, ip ) );
+ emit searchResult( new Smb4KHostItem( workgroup, host, TQString(), ip ) );
}
else
{
@@ -1324,16 +1324,16 @@ void Smb4KScanner::processSearch()
{
if ( data.count() > 1 && !data[1].isEmpty() )
{
- if ( m_buffer.contains( QString( "Connection to %1 failed" ).arg( m_priv->host() ) ) != 0 )
+ if ( m_buffer.tqcontains( TQString( "Connection to %1 failed" ).tqarg( m_priv->host() ) ) != 0 )
{
emit searchResult( new Smb4KHostItem() );
}
else
{
- QString workgroup = data.grep( "Domain" ).first().section( "Domain=[", 1, 1 ).section( "]", 0, 0 );
- QString ip = data.grep( "Got a positive name query" ).first().section( "(", 1, 1 ).section( ")", 0, 0 ).stripWhiteSpace();
+ TQString workgroup = data.grep( "Domain" ).first().section( "Domain=[", 1, 1 ).section( "]", 0, 0 );
+ TQString ip = data.grep( "Got a positive name query" ).first().section( "(", 1, 1 ).section( ")", 0, 0 ).stripWhiteSpace();
- emit searchResult( new Smb4KHostItem( workgroup, m_priv->host().upper(), QString::null, ip ) );
+ emit searchResult( new Smb4KHostItem( workgroup, m_priv->host().upper(), TQString(), ip ) );
}
}
else
@@ -1359,13 +1359,13 @@ void Smb4KScanner::processInfo()
{
if ( m_proc->normalExit() )
{
- QStringList list = QStringList::split( '\n', m_buffer, false );
+ TQStringList list = TQStringList::split( '\n', m_buffer, false );
Smb4KHostItem *host = getHost( m_priv->host(), m_priv->workgroup() );
if ( host )
{
- for ( QStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
+ for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it )
{
if ( (*it).stripWhiteSpace().startsWith( "Domain" ) || (*it).stripWhiteSpace().startsWith( "OS" ) )
{
@@ -1377,7 +1377,7 @@ void Smb4KScanner::processInfo()
break;
}
- else if ( (*it).contains( "Connection to", true ) != 0 )
+ else if ( (*it).tqcontains( "Connection to", true ) != 0 )
{
// The lookup of the info failed:
emit failed();
@@ -1407,13 +1407,13 @@ void Smb4KScanner::processInfo()
Get a workgroup item out of the workgroup list.
****************************************************************************/
-Smb4KWorkgroupItem *Smb4KScanner::getWorkgroup( const QString &workgroup )
+Smb4KWorkgroupItem *Smb4KScanner::getWorkgroup( const TQString &workgroup )
{
- QValueListIterator<Smb4KWorkgroupItem *> it;
+ TQValueListIterator<Smb4KWorkgroupItem *> it;
for ( it = m_workgroups_list->begin(); it != m_workgroups_list->end(); ++it )
{
- if ( QString::compare( (*it)->name(), workgroup ) == 0 )
+ if ( TQString::compare( (*it)->name(), workgroup ) == 0 )
{
break;
}
@@ -1431,19 +1431,19 @@ Smb4KWorkgroupItem *Smb4KScanner::getWorkgroup( const QString &workgroup )
Get a workgroup item out of the workgroup list.
****************************************************************************/
-Smb4KHostItem *Smb4KScanner::getHost( const QString &name, const QString &workgroup )
+Smb4KHostItem *Smb4KScanner::getHost( const TQString &name, const TQString &workgroup )
{
- QValueListIterator<Smb4KHostItem *> it;
+ TQValueListIterator<Smb4KHostItem *> it;
for ( it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
{
if ( !workgroup.stripWhiteSpace().isEmpty() &&
- QString::compare( (*it)->workgroup().upper(), workgroup.upper() ) != 0 )
+ TQString::compare( (*it)->workgroup().upper(), workgroup.upper() ) != 0 )
{
continue;
}
- if ( QString::compare( (*it)->name().upper(), name.upper() ) == 0 )
+ if ( TQString::compare( (*it)->name().upper(), name.upper() ) == 0 )
{
break;
}
@@ -1511,13 +1511,13 @@ void Smb4KScanner::appendWorkgroup( Smb4KWorkgroupItem *item )
}
-void Smb4KScanner::timerEvent( QTimerEvent * )
+void Smb4KScanner::timerEvent( TQTimerEvent * )
{
// Look for the thing to do (next).
// At this point, the topmost item will not be
// dequeued. This will be done below.
int todo = Idle;
- QString *head = NULL;
+ TQString *head = NULL;
if ( (head = m_queue.head()) != 0 )
{
@@ -1527,7 +1527,7 @@ void Smb4KScanner::timerEvent( QTimerEvent * )
if ( !m_working && !m_queue.isEmpty() )
{
// Start processing with dequeueing the item:
- QString *item = m_queue.dequeue();
+ TQString *item = m_queue.dequeue();
// Tell the program, that the scanner is running.
m_working = true;
@@ -1582,7 +1582,7 @@ void Smb4KScanner::timerEvent( QTimerEvent * )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
@@ -1592,7 +1592,7 @@ void Smb4KScanner::timerEvent( QTimerEvent * )
void Smb4KScanner::slotReceivedStdout( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
@@ -1604,7 +1604,7 @@ void Smb4KScanner::slotProcessExited( KProcess * )
void Smb4KScanner::slotReceivedStderr( KProcess *, char *buf, int len )
{
- m_buffer.append( QString::fromLocal8Bit( buf, len ) );
+ m_buffer.append( TQString::fromLocal8Bit( buf, len ) );
}
@@ -1622,9 +1622,9 @@ void Smb4KScanner::slotReceivedStderr( KProcess *, char *buf, int len )
void Smb4KScanner::lookupIPAddresses()
{
bool start = false;
- QString command = QString::null;
+ TQString command = TQString();
- for ( QValueList<Smb4KHostItem *>::ConstIterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
+ for ( TQValueList<Smb4KHostItem *>::ConstIterator it = m_hosts_list->begin(); it != m_hosts_list->end(); ++it )
{
if ( (*it)->ip().stripWhiteSpace().isEmpty() && !(*it)->ipAddressChecked() )
{
@@ -1656,10 +1656,10 @@ void Smb4KScanner::lookupIPAddresses()
KProcess *proc = new KProcess( this );
proc->setUseShell( true );
- connect( proc, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedIPAddresses( KProcess *, char *, int ) ) );
- connect( proc, SIGNAL( processExited( KProcess * ) ),
- this, SLOT( slotIPAddressProcessExited( KProcess * ) ) );
+ connect( proc, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedIPAddresses( KProcess *, char *, int ) ) );
+ connect( proc, TQT_SIGNAL( processExited( KProcess * ) ),
+ this, TQT_SLOT( slotIPAddressProcessExited( KProcess * ) ) );
*proc << command;
proc->start( KProcess::NotifyOnExit, KProcess::Stdout );
@@ -1675,12 +1675,12 @@ void Smb4KScanner::slotReceivedIPAddresses( KProcess *, char *buf, int len )
{
// WARNING: Do not implement error handling here!!!
- QString buffer = QString::fromLocal8Bit( buf, len );
+ TQString buffer = TQString::fromLocal8Bit( buf, len );
if ( !buffer.stripWhiteSpace().isEmpty() )
{
- QString ip = buffer.stripWhiteSpace().section( " ", 0, 0 ).stripWhiteSpace();
- QString host = buffer.stripWhiteSpace().section( " ", 1, 1 ).section( "<00>", 0, 0 ).stripWhiteSpace();
+ TQString ip = buffer.stripWhiteSpace().section( " ", 0, 0 ).stripWhiteSpace();
+ TQString host = buffer.stripWhiteSpace().section( " ", 1, 1 ).section( "<00>", 0, 0 ).stripWhiteSpace();
if ( !host.isEmpty() && !ip.isEmpty() )
{
diff --git a/smb4k/core/smb4kscanner.h b/smb4k/core/smb4kscanner.h
index 3930d5e..4a5f4ad 100644
--- a/smb4k/core/smb4kscanner.h
+++ b/smb4k/core/smb4kscanner.h
@@ -30,10 +30,10 @@
#include <config.h>
#endif
-// Qt includes
-#include <qobject.h>
-#include <qstringlist.h>
-#include <qptrqueue.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqstringlist.h>
+#include <tqptrqueue.h>
// KDE includes
#include <kprocess.h>
@@ -55,9 +55,10 @@ class Smb4KShareItem;
* @author Alexander Reinholdt <dustpuppy@mail.berlios.de>
*/
-class Smb4KScanner : public QObject
+class Smb4KScanner : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -71,13 +72,13 @@ class Smb4KScanner : public QObject
* with the list of available hosts. If a NULL pointer is passed, a
* private list will be created which cannot be accessed from outside.
*
- * @param parent The parent of this class.
+ * @param tqparent The tqparent of this class.
*
* @param name The name of this class.
*/
- Smb4KScanner( QValueList<Smb4KWorkgroupItem *> *workgroups = 0,
- QValueList<Smb4KHostItem *> *hosts = 0,
- QObject *parent = 0,
+ Smb4KScanner( TQValueList<Smb4KWorkgroupItem *> *workgroups = 0,
+ TQValueList<Smb4KHostItem *> *hosts = 0,
+ TQObject *tqparent = 0,
const char *name = 0 );
/**
@@ -118,10 +119,10 @@ class Smb4KScanner : public QObject
* the net command has to use. Normally, you do not have
* to set here anything.
*/
- void getShares( const QString &workgroup,
- const QString &host,
- const QString &ip,
- const QString &protocol = QString::null );
+ void getShares( const TQString &workgroup,
+ const TQString &host,
+ const TQString &ip,
+ const TQString &protocol = TQString() );
/**
* Scans for workgroup members.
@@ -132,9 +133,9 @@ class Smb4KScanner : public QObject
*
* @param ip The IP address of the master browser.
*/
- void getWorkgroupMembers( const QString &workgroup,
- const QString &master,
- const QString &ip );
+ void getWorkgroupMembers( const TQString &workgroup,
+ const TQString &master,
+ const TQString &ip );
/**
* Get more info about a share (i.e. server and OS string, etc.).
@@ -145,9 +146,9 @@ class Smb4KScanner : public QObject
*
* @param ip The host's IP address
*/
- void getInfo( const QString &workgroup,
- const QString &host,
- const QString &ip );
+ void getInfo( const TQString &workgroup,
+ const TQString &host,
+ const TQString &ip );
/**
* Starts the search for a host that matches @p string. If the host is already
@@ -157,7 +158,7 @@ class Smb4KScanner : public QObject
*
* @param string The user supplied search string.
*/
- void search( const QString &string );
+ void search( const TQString &string );
/**
* This function returns an Smb4KWorkgroupItem, if the the workgroup
@@ -165,7 +166,7 @@ class Smb4KScanner : public QObject
*
* @param workgroup The name of the workgroup
*/
- Smb4KWorkgroupItem *getWorkgroup( const QString &workgroup );
+ Smb4KWorkgroupItem *getWorkgroup( const TQString &workgroup );
/**
* This function reports if the scanner is running or not.
@@ -185,8 +186,8 @@ class Smb4KScanner : public QObject
*
* @returns A host item
*/
- Smb4KHostItem *getHost( const QString &name,
- const QString &workgroup = QString::null );
+ Smb4KHostItem *getHost( const TQString &name,
+ const TQString &workgroup = TQString() );
/**
* This function inserts a @p host into the list of known servers. If it belongs to
@@ -219,7 +220,7 @@ class Smb4KScanner : public QObject
*
* @param list The list of workgroups in the network neighborhood.
*/
- void workgroups( const QValueList<Smb4KWorkgroupItem *> &list );
+ void workgroups( const TQValueList<Smb4KWorkgroupItem *> &list );
/**
* Emits the list of workgroup members.
@@ -228,7 +229,7 @@ class Smb4KScanner : public QObject
*
* @param list The list of workgroup members.
*/
- void members( const QString &workgroup, const QValueList<Smb4KHostItem *> &list );
+ void members( const TQString &workgroup, const TQValueList<Smb4KHostItem *> &list );
/**
* Emits the list of shares.
@@ -237,7 +238,7 @@ class Smb4KScanner : public QObject
*
* @param list The list of shares
*/
- void shares( const QString &host, const QValueList<Smb4KShareItem *> &list );
+ void shares( const TQString &host, const TQValueList<Smb4KShareItem *> &list );
/**
* This signal provides info about a certain host. It passes the server
@@ -324,9 +325,9 @@ class Smb4KScanner : public QObject
void processIPScan();
/**
- * Reimplemented from QObject
+ * Reimplemented from TQObject
*/
- void timerEvent( QTimerEvent *e );
+ void timerEvent( TQTimerEvent *e );
protected slots:
/**
@@ -393,30 +394,30 @@ class Smb4KScanner : public QObject
/**
* Scans the group master for the group members.
*/
- void scanForWorkgroupMembers( const QString &workgroup,
- const QString &master,
- const QString &ip );
+ void scanForWorkgroupMembers( const TQString &workgroup,
+ const TQString &master,
+ const TQString &ip );
/**
* Scans the chosen host for its shares. This is the private part
* of @see Smb4KScanner::getShares().
*/
- void scanForShares( const QString &workgroup,
- const QString &host,
- const QString &ip,
- const QString &protocol );
+ void scanForShares( const TQString &workgroup,
+ const TQString &host,
+ const TQString &ip,
+ const TQString &protocol );
/**
* Scans a given host for its OS and Server string.
*/
- void scanForInfo( const QString &workgroup,
- const QString &host,
- const QString &ip );
+ void scanForInfo( const TQString &workgroup,
+ const TQString &host,
+ const TQString &ip );
/**
* Searches for a given host.
*/
- void searchForHost( const QString &host );
+ void searchForHost( const TQString &host );
/**
* This function initializes the lookup of IP addresses.
@@ -442,12 +443,12 @@ class Smb4KScanner : public QObject
/**
* The buffer for the main process.
*/
- QString m_buffer;
+ TQString m_buffer;
/**
* This queue stores the incoming requests until they are processed.
*/
- QPtrQueue<QString> m_queue;
+ TQPtrQueue<TQString> m_queue;
/**
* Is set to true, if the scanner is running.
@@ -458,13 +459,13 @@ class Smb4KScanner : public QObject
* The list of workgroups including the master browser and their
* IP addresses.
*/
- QValueList<Smb4KWorkgroupItem *> *m_workgroups_list;
+ TQValueList<Smb4KWorkgroupItem *> *m_workgroups_list;
/**
* This list contains all hosts, that are found by the scanner and
* that are currently active.
*/
- QValueList<Smb4KHostItem *> *m_hosts_list;
+ TQValueList<Smb4KHostItem *> *m_hosts_list;
/**
* The internal state of the main process. Do not mix this up with
diff --git a/smb4k/core/smb4kscanner_p.cpp b/smb4k/core/smb4kscanner_p.cpp
index a4e03c3..bfbc687 100644
--- a/smb4k/core/smb4kscanner_p.cpp
+++ b/smb4k/core/smb4kscanner_p.cpp
@@ -41,56 +41,56 @@ Smb4KScannerPrivate::~Smb4KScannerPrivate()
void Smb4KScannerPrivate::clearData()
{
- m_workgroup = QString::null;
- m_host = QString::null;
- m_ip = QString::null;
- m_share = QString::null;
+ m_workgroup = TQString();
+ m_host = TQString();
+ m_ip = TQString();
+ m_share = TQString();
}
-void Smb4KScannerPrivate::setWorkgroup( const QString &w )
+void Smb4KScannerPrivate::setWorkgroup( const TQString &w )
{
m_workgroup = w;
}
-void Smb4KScannerPrivate::setHost( const QString &h )
+void Smb4KScannerPrivate::setHost( const TQString &h )
{
m_host = h;
}
-void Smb4KScannerPrivate::setIP( const QString &i )
+void Smb4KScannerPrivate::setIP( const TQString &i )
{
m_ip = i;
}
-void Smb4KScannerPrivate::setShare( const QString &s )
+void Smb4KScannerPrivate::setShare( const TQString &s )
{
m_share = s;
}
-const QString &Smb4KScannerPrivate::workgroup()
+const TQString &Smb4KScannerPrivate::workgroup()
{
return m_workgroup;
}
-const QString &Smb4KScannerPrivate::host()
+const TQString &Smb4KScannerPrivate::host()
{
return m_host;
}
-const QString &Smb4KScannerPrivate::ip()
+const TQString &Smb4KScannerPrivate::ip()
{
return m_ip;
}
-const QString &Smb4KScannerPrivate::share()
+const TQString &Smb4KScannerPrivate::share()
{
return m_share;
}
diff --git a/smb4k/core/smb4kscanner_p.h b/smb4k/core/smb4kscanner_p.h
index be0a364..c17fc90 100644
--- a/smb4k/core/smb4kscanner_p.h
+++ b/smb4k/core/smb4kscanner_p.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qstring.h>
+// TQt includes
+#include <tqstring.h>
class Smb4KScannerPrivate
{
@@ -40,20 +40,20 @@ class Smb4KScannerPrivate
~Smb4KScannerPrivate();
bool retry;
void clearData();
- void setWorkgroup( const QString &w );
- void setHost( const QString &h );
- void setIP( const QString &i );
- void setShare( const QString &s );
- const QString &workgroup();
- const QString &host();
- const QString &ip();
- const QString &share();
+ void setWorkgroup( const TQString &w );
+ void setHost( const TQString &h );
+ void setIP( const TQString &i );
+ void setShare( const TQString &s );
+ const TQString &workgroup();
+ const TQString &host();
+ const TQString &ip();
+ const TQString &share();
private:
- QString m_workgroup;
- QString m_host;
- QString m_ip;
- QString m_share;
+ TQString m_workgroup;
+ TQString m_host;
+ TQString m_ip;
+ TQString m_share;
};
#endif
diff --git a/smb4k/core/smb4ksettings.cpp b/smb4k/core/smb4ksettings.cpp
index 3a88f66..92aa79b 100644
--- a/smb4k/core/smb4ksettings.cpp
+++ b/smb4k/core/smb4ksettings.cpp
@@ -21,1067 +21,1067 @@ Smb4KSettings *Smb4KSettings::self()
}
Smb4KSettings::Smb4KSettings( )
- : KConfigSkeleton( QString::fromLatin1( "smb4krc" ) )
+ : KConfigSkeleton( TQString::tqfromLatin1( "smb4krc" ) )
{
mSelf = this;
- setCurrentGroup( QString::fromLatin1( "Programs" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "Programs" ) );
- mGrepItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "grep" ), mGrep );
+ mGrepItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "grep" ), mGrep );
mGrepItem->setLabel( i18n("The path to the program \"grep\"") );
- addItem( mGrepItem, QString::fromLatin1( "grep" ) );
- mAwkItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "awk" ), mAwk );
+ addItem( mGrepItem, TQString::tqfromLatin1( "grep" ) );
+ mAwkItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "awk" ), mAwk );
mAwkItem->setLabel( i18n("The path to the program \"awk\"") );
- addItem( mAwkItem, QString::fromLatin1( "awk" ) );
- mSedItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "sed" ), mSed );
+ addItem( mAwkItem, TQString::tqfromLatin1( "awk" ) );
+ mSedItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "sed" ), mSed );
mSedItem->setLabel( i18n("The path to the program \"sed\"") );
- addItem( mSedItem, QString::fromLatin1( "sed" ) );
- mXargsItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "xargs" ), mXargs );
+ addItem( mSedItem, TQString::tqfromLatin1( "sed" ) );
+ mXargsItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "xargs" ), mXargs );
mXargsItem->setLabel( i18n("The path to the program \"xargs\"") );
- addItem( mXargsItem, QString::fromLatin1( "xargs" ) );
- mRmdirItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "rmdir" ), mRmdir );
+ addItem( mXargsItem, TQString::tqfromLatin1( "xargs" ) );
+ mRmdirItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "rmdir" ), mRmdir );
mRmdirItem->setLabel( i18n("The path to the program \"rmdir\"") );
- addItem( mRmdirItem, QString::fromLatin1( "rmdir" ) );
- mNmblookupItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "nmblookup" ), mNmblookup );
+ addItem( mRmdirItem, TQString::tqfromLatin1( "rmdir" ) );
+ mNmblookupItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "nmblookup" ), mNmblookup );
mNmblookupItem->setLabel( i18n("The path to the program \"nmblookup\"") );
- addItem( mNmblookupItem, QString::fromLatin1( "nmblookup" ) );
- mSmbclientItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smbclient" ), mSmbclient );
+ addItem( mNmblookupItem, TQString::tqfromLatin1( "nmblookup" ) );
+ mSmbclientItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smbclient" ), mSmbclient );
mSmbclientItem->setLabel( i18n("The path to the program \"smbclient\"") );
- addItem( mSmbclientItem, QString::fromLatin1( "smbclient" ) );
- mSmbspoolItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smbspool" ), mSmbspool );
+ addItem( mSmbclientItem, TQString::tqfromLatin1( "smbclient" ) );
+ mSmbspoolItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smbspool" ), mSmbspool );
mSmbspoolItem->setLabel( i18n("The path to the program \"smbspool\"") );
- addItem( mSmbspoolItem, QString::fromLatin1( "smbspool" ) );
- mNetItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "net" ), mNet );
+ addItem( mSmbspoolItem, TQString::tqfromLatin1( "smbspool" ) );
+ mNetItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "net" ), mNet );
mNetItem->setLabel( i18n("The path to the program \"net\"") );
- addItem( mNetItem, QString::fromLatin1( "net" ) );
- mMount_cifsItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "mount_cifs" ), mMount_cifs );
+ addItem( mNetItem, TQString::tqfromLatin1( "net" ) );
+ mMount_cifsItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "mount_cifs" ), mMount_cifs );
mMount_cifsItem->setLabel( i18n("The path to the program \"mount.cifs\"") );
- addItem( mMount_cifsItem, QString::fromLatin1( "mount_cifs" ) );
- mUmount_cifsItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "umount_cifs" ), mUmount_cifs );
+ addItem( mMount_cifsItem, TQString::tqfromLatin1( "mount_cifs" ) );
+ mUmount_cifsItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "umount_cifs" ), mUmount_cifs );
mUmount_cifsItem->setLabel( i18n("The path to the program \"umount.cifs\"") );
- addItem( mUmount_cifsItem, QString::fromLatin1( "umount_cifs" ) );
- mSmbmountItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smbmount" ), mSmbmount );
+ addItem( mUmount_cifsItem, TQString::tqfromLatin1( "umount_cifs" ) );
+ mSmbmountItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smbmount" ), mSmbmount );
mSmbmountItem->setLabel( i18n("The path to the program \"smbmount\"") );
- addItem( mSmbmountItem, QString::fromLatin1( "smbmount" ) );
- mSmbumountItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smbumount" ), mSmbumount );
+ addItem( mSmbmountItem, TQString::tqfromLatin1( "smbmount" ) );
+ mSmbumountItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smbumount" ), mSmbumount );
mSmbumountItem->setLabel( i18n("The path to the program \"smbumount\"") );
- addItem( mSmbumountItem, QString::fromLatin1( "smbumount" ) );
- mMountItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "mount" ), mMount );
+ addItem( mSmbumountItem, TQString::tqfromLatin1( "smbumount" ) );
+ mMountItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "mount" ), mMount );
mMountItem->setLabel( i18n("The path to the program \"mount\"") );
- addItem( mMountItem, QString::fromLatin1( "mount" ) );
- mMount_smbfsItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "mount_smbfs" ), mMount_smbfs );
+ addItem( mMountItem, TQString::tqfromLatin1( "mount" ) );
+ mMount_smbfsItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "mount_smbfs" ), mMount_smbfs );
mMount_smbfsItem->setLabel( i18n("The path to the program \"mount_smbfs\" (FreeBSD only)") );
- addItem( mMount_smbfsItem, QString::fromLatin1( "mount_smbfs" ) );
- mSmbutilItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smbutil" ), mSmbutil );
+ addItem( mMount_smbfsItem, TQString::tqfromLatin1( "mount_smbfs" ) );
+ mSmbutilItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smbutil" ), mSmbutil );
mSmbutilItem->setLabel( i18n("The path to the program \"smbutil\" (FreeBSD only)") );
- addItem( mSmbutilItem, QString::fromLatin1( "smbutil" ) );
- mUmountItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "umount" ), mUmount );
+ addItem( mSmbutilItem, TQString::tqfromLatin1( "smbutil" ) );
+ mUmountItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "umount" ), mUmount );
mUmountItem->setLabel( i18n("The path to the program \"umount\"") );
- addItem( mUmountItem, QString::fromLatin1( "umount" ) );
- mSmb4k_mountItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smb4k_mount" ), mSmb4k_mount );
+ addItem( mUmountItem, TQString::tqfromLatin1( "umount" ) );
+ mSmb4k_mountItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smb4k_mount" ), mSmb4k_mount );
mSmb4k_mountItem->setLabel( i18n("The path to the program \"smb4k_mount\"") );
- addItem( mSmb4k_mountItem, QString::fromLatin1( "smb4k_mount" ) );
- mSmb4k_umountItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smb4k_umount" ), mSmb4k_umount );
+ addItem( mSmb4k_mountItem, TQString::tqfromLatin1( "smb4k_mount" ) );
+ mSmb4k_umountItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smb4k_umount" ), mSmb4k_umount );
mSmb4k_umountItem->setLabel( i18n("The path to the program \"smb4k_umount\"") );
- addItem( mSmb4k_umountItem, QString::fromLatin1( "smb4k_umount" ) );
- mSmb4k_killItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smb4k_kill" ), mSmb4k_kill );
+ addItem( mSmb4k_umountItem, TQString::tqfromLatin1( "smb4k_umount" ) );
+ mSmb4k_killItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smb4k_kill" ), mSmb4k_kill );
mSmb4k_killItem->setLabel( i18n("The path to the program \"smb4k_kill\"") );
- addItem( mSmb4k_killItem, QString::fromLatin1( "smb4k_kill" ) );
- mSmb4k_catItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smb4k_cat" ), mSmb4k_cat );
+ addItem( mSmb4k_killItem, TQString::tqfromLatin1( "smb4k_kill" ) );
+ mSmb4k_catItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smb4k_cat" ), mSmb4k_cat );
mSmb4k_catItem->setLabel( i18n("The path to the program \"smb4k_cat\"") );
- addItem( mSmb4k_catItem, QString::fromLatin1( "smb4k_cat" ) );
- mSmb4k_mvItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "smb4k_mv" ), mSmb4k_mv );
+ addItem( mSmb4k_catItem, TQString::tqfromLatin1( "smb4k_cat" ) );
+ mSmb4k_mvItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "smb4k_mv" ), mSmb4k_mv );
mSmb4k_mvItem->setLabel( i18n("The path to the program \"smb4k_mv\"") );
- addItem( mSmb4k_mvItem, QString::fromLatin1( "smb4k_mv" ) );
- mSuperItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "super" ), mSuper );
+ addItem( mSmb4k_mvItem, TQString::tqfromLatin1( "smb4k_mv" ) );
+ mSuperItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "super" ), mSuper );
mSuperItem->setLabel( i18n("The path to the program \"super\" (optional)") );
- addItem( mSuperItem, QString::fromLatin1( "super" ) );
- mSudoItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "sudo" ), mSudo );
+ addItem( mSuperItem, TQString::tqfromLatin1( "super" ) );
+ mSudoItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "sudo" ), mSudo );
mSudoItem->setLabel( i18n("The path to the program \"sudo\" (optional)") );
- addItem( mSudoItem, QString::fromLatin1( "sudo" ) );
- mDvipsItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "dvips" ), mDvips );
+ addItem( mSudoItem, TQString::tqfromLatin1( "sudo" ) );
+ mDvipsItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "dvips" ), mDvips );
mDvipsItem->setLabel( i18n("The path to the program \"dvips\" (optional)") );
- addItem( mDvipsItem, QString::fromLatin1( "dvips" ) );
- mEnscriptItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "enscript" ), mEnscript );
+ addItem( mDvipsItem, TQString::tqfromLatin1( "dvips" ) );
+ mEnscriptItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "enscript" ), mEnscript );
mEnscriptItem->setLabel( i18n("The path to the program \"enscript\" (optional)") );
- addItem( mEnscriptItem, QString::fromLatin1( "enscript" ) );
- mRsyncItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "rsync" ), mRsync );
+ addItem( mEnscriptItem, TQString::tqfromLatin1( "enscript" ) );
+ mRsyncItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "rsync" ), mRsync );
mRsyncItem->setLabel( i18n("The path to the program \"rsync\" (optional)") );
- addItem( mRsyncItem, QString::fromLatin1( "rsync" ) );
- mKonsoleItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "konsole" ), mKonsole );
+ addItem( mRsyncItem, TQString::tqfromLatin1( "rsync" ) );
+ mKonsoleItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "konsole" ), mKonsole );
mKonsoleItem->setLabel( i18n("The path to the program \"konsole\" (optional)") );
- addItem( mKonsoleItem, QString::fromLatin1( "konsole" ) );
+ addItem( mKonsoleItem, TQString::tqfromLatin1( "konsole" ) );
- setCurrentGroup( QString::fromLatin1( "UserInterface" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "UserInterface" ) );
- mShowCustomBookmarkLabelItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowCustomBookmarkLabel" ), mShowCustomBookmarkLabel, true );
+ mShowCustomBookmarkLabelItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowCustomBookmarkLabel" ), mShowCustomBookmarkLabel, true );
mShowCustomBookmarkLabelItem->setLabel( i18n("Show custom bookmark label if available") );
mShowCustomBookmarkLabelItem->setWhatsThis( i18n("Do not show the name of the share that is represented by the bookmark but the custom label that was defined in the bookmark editor.") );
- addItem( mShowCustomBookmarkLabelItem, QString::fromLatin1( "ShowCustomBookmarkLabel" ) );
- mEmbedIntoSystemTrayItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "EmbedIntoSystemTray" ), mEmbedIntoSystemTray, true );
+ addItem( mShowCustomBookmarkLabelItem, TQString::tqfromLatin1( "ShowCustomBookmarkLabel" ) );
+ mEmbedIntoSystemTrayItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "EmbedIntoSystemTray" ), mEmbedIntoSystemTray, true );
mEmbedIntoSystemTrayItem->setLabel( i18n("Embed application into system tray") );
mEmbedIntoSystemTrayItem->setWhatsThis( i18n("Embed the application into the system tray. The system tray widget provides a popup menu with several commonly used tasks so that you do not need to bring up the main window everytime. If this setting is chosen you have to use \"Quit\" from the \"File\" menu or the system tray widget to exit the application.") );
- addItem( mEmbedIntoSystemTrayItem, QString::fromLatin1( "EmbedIntoSystemTray" ) );
- mStartMainWindowDockedItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "StartMainWindowDocked" ), mStartMainWindowDocked, false );
+ addItem( mEmbedIntoSystemTrayItem, TQString::tqfromLatin1( "EmbedIntoSystemTray" ) );
+ mStartMainWindowDockedItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "StartMainWindowDocked" ), mStartMainWindowDocked, false );
mStartMainWindowDockedItem->setLabel( i18n("Start docked") );
mStartMainWindowDockedItem->setWhatsThis( i18n("Start the application docked to the system tray, i.e. only the system tray widget is shown and the main window is hidden. You can bring the main window up by clicking on the system tray widget or by choosing \"Restore\" from its popup menu.") );
- addItem( mStartMainWindowDockedItem, QString::fromLatin1( "StartMainWindowDocked" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesSharesView;
+ addItem( mStartMainWindowDockedItem, TQString::tqfromLatin1( "StartMainWindowDocked" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesSharesView;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "IconView" );
+ choice.name = TQString::tqfromLatin1( "IconView" );
valuesSharesView.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "ListView" );
+ choice.name = TQString::tqfromLatin1( "ListView" );
valuesSharesView.append( choice );
}
- mSharesViewItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "SharesView" ), mSharesView, valuesSharesView, EnumSharesView::IconView );
+ mSharesViewItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "SharesView" ), mSharesView, valuesSharesView, EnumSharesView::IconView );
mSharesViewItem->setLabel( i18n("How the shares should be displayed") );
mSharesViewItem->setWhatsThis( i18n("Choose the kind of view you prefer for displaying the mounted shares. There is an icon view or a list view available.") );
- addItem( mSharesViewItem, QString::fromLatin1( "SharesView" ) );
- mShowPrinterSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowPrinterShares" ), mShowPrinterShares, true );
+ addItem( mSharesViewItem, TQString::tqfromLatin1( "SharesView" ) );
+ mShowPrinterSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowPrinterShares" ), mShowPrinterShares, true );
mShowPrinterSharesItem->setLabel( i18n("Show printer shares") );
mShowPrinterSharesItem->setWhatsThis( i18n("Printer shares will be displayed in the network browser.") );
- addItem( mShowPrinterSharesItem, QString::fromLatin1( "ShowPrinterShares" ) );
- mShowHiddenSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowHiddenShares" ), mShowHiddenShares, true );
+ addItem( mShowPrinterSharesItem, TQString::tqfromLatin1( "ShowPrinterShares" ) );
+ mShowHiddenSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowHiddenShares" ), mShowHiddenShares, true );
mShowHiddenSharesItem->setLabel( i18n("Show hidden shares") );
mShowHiddenSharesItem->setWhatsThis( i18n("Hidden shares will be displayed in the network browser. Hidden shares are ending with a $ sign, e.g. Musik$ or IPC$.") );
- addItem( mShowHiddenSharesItem, QString::fromLatin1( "ShowHiddenShares" ) );
- mShowHiddenIPCSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowHiddenIPCShares" ), mShowHiddenIPCShares, true );
+ addItem( mShowHiddenSharesItem, TQString::tqfromLatin1( "ShowHiddenShares" ) );
+ mShowHiddenIPCSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowHiddenIPCShares" ), mShowHiddenIPCShares, true );
mShowHiddenIPCSharesItem->setLabel( i18n("Show hidden IPC$ shares") );
mShowHiddenIPCSharesItem->setWhatsThis( i18n("Hidden IPC$ shares will be displayed in the network browser.") );
- addItem( mShowHiddenIPCSharesItem, QString::fromLatin1( "ShowHiddenIPCShares" ) );
- mShowHiddenADMINSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowHiddenADMINShares" ), mShowHiddenADMINShares, true );
+ addItem( mShowHiddenIPCSharesItem, TQString::tqfromLatin1( "ShowHiddenIPCShares" ) );
+ mShowHiddenADMINSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowHiddenADMINShares" ), mShowHiddenADMINShares, true );
mShowHiddenADMINSharesItem->setLabel( i18n("Show hidden ADMIN$ shares") );
mShowHiddenADMINSharesItem->setWhatsThis( i18n("Hidden ADMIN$ shares will be displayed in the network browser.") );
- addItem( mShowHiddenADMINSharesItem, QString::fromLatin1( "ShowHiddenADMINShares" ) );
- mShowTypeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowType" ), mShowType, true );
+ addItem( mShowHiddenADMINSharesItem, TQString::tqfromLatin1( "ShowHiddenADMINShares" ) );
+ mShowTypeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowType" ), mShowType, true );
mShowTypeItem->setLabel( i18n("Show the type of a share") );
mShowTypeItem->setWhatsThis( i18n("The type of a share will be displayed in a separate column in the network browser. It can either be Disk, Print or IPC.") );
- addItem( mShowTypeItem, QString::fromLatin1( "ShowType" ) );
- mShowIPAddressItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowIPAddress" ), mShowIPAddress, true );
+ addItem( mShowTypeItem, TQString::tqfromLatin1( "ShowType" ) );
+ mShowIPAddressItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowIPAddress" ), mShowIPAddress, true );
mShowIPAddressItem->setLabel( i18n("Show the IP address of a server") );
mShowIPAddressItem->setWhatsThis( i18n("The IP address of the server will be displayed in a separate column in the network browser.") );
- addItem( mShowIPAddressItem, QString::fromLatin1( "ShowIPAddress" ) );
- mShowCommentItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowComment" ), mShowComment, true );
+ addItem( mShowIPAddressItem, TQString::tqfromLatin1( "ShowIPAddress" ) );
+ mShowCommentItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowComment" ), mShowComment, true );
mShowCommentItem->setLabel( i18n("Show the comment of a share") );
mShowCommentItem->setWhatsThis( i18n("The comment describing the server or share will be displayed in a separate column in the network browser.") );
- addItem( mShowCommentItem, QString::fromLatin1( "ShowComment" ) );
- mShowNetworkItemToolTipItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowNetworkItemToolTip" ), mShowNetworkItemToolTip, true );
+ addItem( mShowCommentItem, TQString::tqfromLatin1( "ShowComment" ) );
+ mShowNetworkItemToolTipItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowNetworkItemToolTip" ), mShowNetworkItemToolTip, true );
mShowNetworkItemToolTipItem->setLabel( i18n("Show a tooltip with information about the network item") );
mShowNetworkItemToolTipItem->setWhatsThis( i18n("The tooltip shows various information about the current network item.") );
- addItem( mShowNetworkItemToolTipItem, QString::fromLatin1( "ShowNetworkItemToolTip" ) );
- mShowMountPointItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowMountPoint" ), mShowMountPoint, false );
+ addItem( mShowNetworkItemToolTipItem, TQString::tqfromLatin1( "ShowNetworkItemToolTip" ) );
+ mShowMountPointItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowMountPoint" ), mShowMountPoint, false );
mShowMountPointItem->setLabel( i18n("Show the mount point of a share instead of its name") );
mShowMountPointItem->setWhatsThis( i18n("A share is normally displayed with its name in the shares view. Choosing this feature will cause the exchange of the share name by the mount point.") );
- addItem( mShowMountPointItem, QString::fromLatin1( "ShowMountPoint" ) );
- mShowAllSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowAllShares" ), mShowAllShares, false );
+ addItem( mShowMountPointItem, TQString::tqfromLatin1( "ShowMountPoint" ) );
+ mShowAllSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowAllShares" ), mShowAllShares, false );
mShowAllSharesItem->setLabel( i18n("Show all shares that are mounted on the system") );
mShowAllSharesItem->setWhatsThis( i18n("You will not only see the shares that were mounted and are owned by you, but also all other mounts using the SMBFS and CIFS file system that are present on the system.") );
- addItem( mShowAllSharesItem, QString::fromLatin1( "ShowAllShares" ) );
- mEnableDropSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "EnableDropSupport" ), mEnableDropSupport, false );
+ addItem( mShowAllSharesItem, TQString::tqfromLatin1( "ShowAllShares" ) );
+ mEnableDropSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "EnableDropSupport" ), mEnableDropSupport, false );
mEnableDropSupportItem->setLabel( i18n("Allow the dropping of files and directories onto share icons") );
mEnableDropSupportItem->setWhatsThis( i18n("This setting allows you to drop files or whole directories onto the share icons, which will cause them to be copied.") );
- addItem( mEnableDropSupportItem, QString::fromLatin1( "EnableDropSupport" ) );
- mEnableDragSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "EnableDragSupport" ), mEnableDragSupport, false );
+ addItem( mEnableDropSupportItem, TQString::tqfromLatin1( "EnableDropSupport" ) );
+ mEnableDragSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "EnableDragSupport" ), mEnableDragSupport, false );
mEnableDragSupportItem->setLabel( i18n("Allow the dragging of share icons") );
mEnableDragSupportItem->setWhatsThis( i18n("This setting allows you to drag a share item out of Smb4K and onto the desktop or into a file manager. Only enable it if you think you absolutely need it and read the handbook before you mark this checkbox.") );
- addItem( mEnableDragSupportItem, QString::fromLatin1( "EnableDragSupport" ) );
- mShowShareToolTipItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowShareToolTip" ), mShowShareToolTip, true );
+ addItem( mEnableDragSupportItem, TQString::tqfromLatin1( "EnableDragSupport" ) );
+ mShowShareToolTipItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowShareToolTip" ), mShowShareToolTip, true );
mShowShareToolTipItem->setLabel( i18n("Show a tooltip with information about the share") );
mShowShareToolTipItem->setWhatsThis( i18n("The tooltip shows various information about the current share.") );
- addItem( mShowShareToolTipItem, QString::fromLatin1( "ShowShareToolTip" ) );
- mPreviewHiddenItemsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreviewHiddenItems" ), mPreviewHiddenItems, false );
+ addItem( mShowShareToolTipItem, TQString::tqfromLatin1( "ShowShareToolTip" ) );
+ mPreviewHiddenItemsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreviewHiddenItems" ), mPreviewHiddenItems, false );
mPreviewHiddenItemsItem->setLabel( i18n("Show hidden files and directories when previewing a share") );
mPreviewHiddenItemsItem->setWhatsThis( i18n("Display hidden files and directories in the preview dialog. The names of hidden files and directories are beginning with a period and are usually needed for very specific purposes (configuration file of an application, etc.). Since they are not of any importance for your regular work, you normally do not need to enable this feature.") );
- addItem( mPreviewHiddenItemsItem, QString::fromLatin1( "PreviewHiddenItems" ) );
- mShowOwnerItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowOwner" ), mShowOwner, false );
+ addItem( mPreviewHiddenItemsItem, TQString::tqfromLatin1( "PreviewHiddenItems" ) );
+ mShowOwnerItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowOwner" ), mShowOwner, false );
mShowOwnerItem->setLabel( i18n("Show owner and group (SMBFS only)") );
mShowOwnerItem->setWhatsThis( i18n("Show the UID and GID that own all files on the mounted file system. At the moment the column will only contain an entry if the share was mounted with the SMBFS file system.") );
- addItem( mShowOwnerItem, QString::fromLatin1( "ShowOwner" ) );
- mShowLoginItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowLogin" ), mShowLogin, false );
+ addItem( mShowOwnerItem, TQString::tqfromLatin1( "ShowOwner" ) );
+ mShowLoginItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowLogin" ), mShowLogin, false );
mShowLoginItem->setLabel( i18n("Show login (CIFS only)") );
mShowLoginItem->setWhatsThis( i18n("Show the login that was used to authenticate to the server. The column will only contain an entry if the share was mounted with the CIFS file system.") );
- addItem( mShowLoginItem, QString::fromLatin1( "ShowLogin" ) );
- mShowFileSystemItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowFileSystem" ), mShowFileSystem, true );
+ addItem( mShowLoginItem, TQString::tqfromLatin1( "ShowLogin" ) );
+ mShowFileSystemItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowFileSystem" ), mShowFileSystem, true );
mShowFileSystemItem->setLabel( i18n("Show file system") );
mShowFileSystemItem->setWhatsThis( i18n("Show the file system that was used for mounting the share.") );
- addItem( mShowFileSystemItem, QString::fromLatin1( "ShowFileSystem" ) );
- mShowFreeDiskSpaceItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowFreeDiskSpace" ), mShowFreeDiskSpace, false );
+ addItem( mShowFileSystemItem, TQString::tqfromLatin1( "ShowFileSystem" ) );
+ mShowFreeDiskSpaceItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowFreeDiskSpace" ), mShowFreeDiskSpace, false );
mShowFreeDiskSpaceItem->setLabel( i18n("Show free disk space") );
mShowFreeDiskSpaceItem->setWhatsThis( i18n("Show the free disk space that is left on the share.") );
- addItem( mShowFreeDiskSpaceItem, QString::fromLatin1( "ShowFreeDiskSpace" ) );
- mShowUsedDiskSpaceItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowUsedDiskSpace" ), mShowUsedDiskSpace, false );
+ addItem( mShowFreeDiskSpaceItem, TQString::tqfromLatin1( "ShowFreeDiskSpace" ) );
+ mShowUsedDiskSpaceItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowUsedDiskSpace" ), mShowUsedDiskSpace, false );
mShowUsedDiskSpaceItem->setLabel( i18n("Show used disk space") );
mShowUsedDiskSpaceItem->setWhatsThis( i18n("Show the disk space that is already used on the share.") );
- addItem( mShowUsedDiskSpaceItem, QString::fromLatin1( "ShowUsedDiskSpace" ) );
- mShowTotalDiskSpaceItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowTotalDiskSpace" ), mShowTotalDiskSpace, false );
+ addItem( mShowUsedDiskSpaceItem, TQString::tqfromLatin1( "ShowUsedDiskSpace" ) );
+ mShowTotalDiskSpaceItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowTotalDiskSpace" ), mShowTotalDiskSpace, false );
mShowTotalDiskSpaceItem->setLabel( i18n("Show total disk space") );
mShowTotalDiskSpaceItem->setWhatsThis( i18n("Show the total disk space of the share.") );
- addItem( mShowTotalDiskSpaceItem, QString::fromLatin1( "ShowTotalDiskSpace" ) );
- mShowDiskUsageItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ShowDiskUsage" ), mShowDiskUsage, true );
+ addItem( mShowTotalDiskSpaceItem, TQString::tqfromLatin1( "ShowTotalDiskSpace" ) );
+ mShowDiskUsageItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ShowDiskUsage" ), mShowDiskUsage, true );
mShowDiskUsageItem->setLabel( i18n("Show disk usage") );
mShowDiskUsageItem->setWhatsThis( i18n("Show the space that is used on the share in percent.") );
- addItem( mShowDiskUsageItem, QString::fromLatin1( "ShowDiskUsage" ) );
+ addItem( mShowDiskUsageItem, TQString::tqfromLatin1( "ShowDiskUsage" ) );
- setCurrentGroup( QString::fromLatin1( "Network" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "Network" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesBrowseList;
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesBrowseList;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "LookupDomains" );
+ choice.name = TQString::tqfromLatin1( "LookupDomains" );
valuesBrowseList.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "QueryCurrentMaster" );
+ choice.name = TQString::tqfromLatin1( "QueryCurrentMaster" );
valuesBrowseList.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "QueryCustomMaster" );
+ choice.name = TQString::tqfromLatin1( "QueryCustomMaster" );
valuesBrowseList.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "ScanBroadcastAreas" );
+ choice.name = TQString::tqfromLatin1( "ScanBroadcastAreas" );
valuesBrowseList.append( choice );
}
- mBrowseListItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "BrowseList" ), mBrowseList, valuesBrowseList, EnumBrowseList::LookupDomains );
+ mBrowseListItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "BrowseList" ), mBrowseList, valuesBrowseList, EnumBrowseList::LookupDomains );
mBrowseListItem->setLabel( i18n("Method how to retrieve the browse list") );
mBrowseListItem->setWhatsThis( i18n("Choose the method how to compile the initial browse list. There are four options available: The first one is the default one and employs \"nmblookup -M -- -\" to discover all workgroups, domains, and their master browsers on your network neighborhood. The second one instructs Smb4K to query the current master browser of your workgroup or domain to retrieve the browse list. The third is similar to the second one except that you can define the master browser that should be queried. If you choose the last option, the provided list of broadcast areas will be scanned using \"nmblookup -B x.x.x.x -- '*'\".") );
- addItem( mBrowseListItem, QString::fromLatin1( "BrowseList" ) );
- mCustomMasterBrowserItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "CustomMasterBrowser" ), mCustomMasterBrowser );
+ addItem( mBrowseListItem, TQString::tqfromLatin1( "BrowseList" ) );
+ mCustomMasterBrowserItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "CustomMasterBrowser" ), mCustomMasterBrowser );
mCustomMasterBrowserItem->setLabel( i18n("A custom master browser that is to be queried") );
mCustomMasterBrowserItem->setWhatsThis( i18n("Enter the name or IP address of a master browser here that should be queried to compile the initial browse list.") );
- addItem( mCustomMasterBrowserItem, QString::fromLatin1( "CustomMasterBrowser" ) );
- mBroadcastAreasItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "BroadcastAreas" ), mBroadcastAreas );
+ addItem( mCustomMasterBrowserItem, TQString::tqfromLatin1( "CustomMasterBrowser" ) );
+ mBroadcastAreasItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "BroadcastAreas" ), mBroadcastAreas );
mBroadcastAreasItem->setLabel( i18n("A custom list of broadcast addresses") );
mBroadcastAreasItem->setWhatsThis( i18n("Enter a comma-separated list of broadcast addresses here (e.g. 192.168.0.255, 192.168.1.255). It is used to scan for all known hosts in the respective broadcast areas.") );
- addItem( mBroadcastAreasItem, QString::fromLatin1( "BroadcastAreas" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesSearchMethod;
+ addItem( mBroadcastAreasItem, TQString::tqfromLatin1( "BroadcastAreas" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesSearchMethod;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "Nmblookup" );
+ choice.name = TQString::tqfromLatin1( "Nmblookup" );
valuesSearchMethod.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "Smbclient" );
+ choice.name = TQString::tqfromLatin1( "Smbclient" );
valuesSearchMethod.append( choice );
}
- mSearchMethodItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "SearchMethod" ), mSearchMethod, valuesSearchMethod, EnumSearchMethod::Nmblookup );
+ mSearchMethodItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "SearchMethod" ), mSearchMethod, valuesSearchMethod, EnumSearchMethod::Nmblookup );
mSearchMethodItem->setLabel( i18n("Method for searching for remote hosts") );
mSearchMethodItem->setWhatsThis( i18n("Smb4K is able to search for remote hosts either using nmblookup or smbclient. The nmblookup method is very reliable and works well. However, if your network is configured uncommonly and you experience problems when searching, you should try the smbclient method. But please note that you lose the ability to search for IP addresses in that case.") );
- addItem( mSearchMethodItem, QString::fromLatin1( "SearchMethod" ) );
+ addItem( mSearchMethodItem, TQString::tqfromLatin1( "SearchMethod" ) );
- setCurrentGroup( QString::fromLatin1( "Shares" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "Shares" ) );
- mMountPrefixItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "MountPrefix" ), mMountPrefix, QString::fromLatin1( "${HOME}/smb4k/" ) );
+ mMountPrefixItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "MountPrefix" ), mMountPrefix, TQString::tqfromLatin1( "${HOME}/smb4k/" ) );
mMountPrefixItem->setLabel( i18n("The mount prefix") );
mMountPrefixItem->setWhatsThis( i18n("This is the prefix where Smb4K will create the mount points and mount the remote shares.") );
- addItem( mMountPrefixItem, QString::fromLatin1( "MountPrefix" ) );
- mForceLowerCaseSubdirsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ForceLowerCaseSubdirs" ), mForceLowerCaseSubdirs, false );
+ addItem( mMountPrefixItem, TQString::tqfromLatin1( "MountPrefix" ) );
+ mForceLowerCaseSubdirsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ForceLowerCaseSubdirs" ), mForceLowerCaseSubdirs, false );
mForceLowerCaseSubdirsItem->setLabel( i18n("Force the subdirectories created by Smb4K to be lowercase") );
mForceLowerCaseSubdirsItem->setWhatsThis( i18n("All names of the subdirectories created by Smb4K below the mount prefix will be lowercase.") );
- addItem( mForceLowerCaseSubdirsItem, QString::fromLatin1( "ForceLowerCaseSubdirs" ) );
- mUnmountSharesOnExitItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UnmountSharesOnExit" ), mUnmountSharesOnExit, false );
+ addItem( mForceLowerCaseSubdirsItem, TQString::tqfromLatin1( "ForceLowerCaseSubdirs" ) );
+ mUnmountSharesOnExitItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UnmountSharesOnExit" ), mUnmountSharesOnExit, false );
mUnmountSharesOnExitItem->setLabel( i18n("Unmount the shares owned by the user on exit") );
mUnmountSharesOnExitItem->setWhatsThis( i18n("Unmount all shares that belong to you when the program exits.") );
- addItem( mUnmountSharesOnExitItem, QString::fromLatin1( "UnmountSharesOnExit" ) );
- mRemountSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "RemountShares" ), mRemountShares, false );
+ addItem( mUnmountSharesOnExitItem, TQString::tqfromLatin1( "UnmountSharesOnExit" ) );
+ mRemountSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "RemountShares" ), mRemountShares, false );
mRemountSharesItem->setLabel( i18n("Remount shares") );
mRemountSharesItem->setWhatsThis( i18n("Remount all your shares that were still mounted when you exited the program. Shares that were mounted by other users are ignored.") );
- addItem( mRemountSharesItem, QString::fromLatin1( "RemountShares" ) );
- mUnmountForeignSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UnmountForeignShares" ), mUnmountForeignShares, false );
+ addItem( mRemountSharesItem, TQString::tqfromLatin1( "RemountShares" ) );
+ mUnmountForeignSharesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UnmountForeignShares" ), mUnmountForeignShares, false );
mUnmountForeignSharesItem->setLabel( i18n("Allow the unmounting of shares owned by other users") );
mUnmountForeignSharesItem->setWhatsThis( i18n("Allow the unmounting of shares that were mounted by other users. In most cases you need super user privileges for this. Please think before you enable this option!") );
- addItem( mUnmountForeignSharesItem, QString::fromLatin1( "UnmountForeignShares" ) );
- mCheckIntervalItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "CheckInterval" ), mCheckInterval, 2500 );
+ addItem( mUnmountForeignSharesItem, TQString::tqfromLatin1( "UnmountForeignShares" ) );
+ mCheckIntervalItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "CheckInterval" ), mCheckInterval, 2500 );
mCheckIntervalItem->setMinValue(500);
mCheckIntervalItem->setMaxValue(300000);
mCheckIntervalItem->setLabel( i18n("Interval between checks for new and inaccessible shares") );
mCheckIntervalItem->setWhatsThis( i18n("This is the time that elapses until Smb4K checks again for new mounts and unmounts. The lower limit is 500 ms, the upper one 300000 ms. Please note that the smaller the interval gets the higher is your system load.") );
- addItem( mCheckIntervalItem, QString::fromLatin1( "CheckInterval" ) );
+ addItem( mCheckIntervalItem, TQString::tqfromLatin1( "CheckInterval" ) );
- setCurrentGroup( QString::fromLatin1( "Authentication" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "Authentication" ) );
- mUseWalletItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseWallet" ), mUseWallet, true );
+ mUseWalletItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseWallet" ), mUseWallet, true );
mUseWalletItem->setLabel( i18n("Use a wallet to store authentication data") );
mUseWalletItem->setWhatsThis( i18n("Use a wallet to store the authentication data. The login name and the password name are stored encrypted on your hard drive. If this setting is disabled, the authentication data is not stored permanently but only temporarily.") );
- addItem( mUseWalletItem, QString::fromLatin1( "UseWallet" ) );
- mRememberPasswordsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "RememberPasswords" ), mRememberPasswords, true );
+ addItem( mUseWalletItem, TQString::tqfromLatin1( "UseWallet" ) );
+ mRememberPasswordsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "RememberPasswords" ), mRememberPasswords, true );
mRememberPasswordsItem->setLabel( i18n("Remember passwords if no wallet is used") );
mRememberPasswordsItem->setWhatsThis( i18n("If you decided to store the login names and passwords only temporarily, Smb4K will remember them until the program exits. If you disable this setting, you will have to provide the authentication data everytime it is needed.") );
- addItem( mRememberPasswordsItem, QString::fromLatin1( "RememberPasswords" ) );
- mUseDefaultLoginItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseDefaultLogin" ), mUseDefaultLogin, false );
+ addItem( mRememberPasswordsItem, TQString::tqfromLatin1( "RememberPasswords" ) );
+ mUseDefaultLoginItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseDefaultLogin" ), mUseDefaultLogin, false );
mUseDefaultLoginItem->setLabel( i18n("Use a default login") );
mUseDefaultLoginItem->setWhatsThis( i18n("Enable the usage of a default login name and password. The authentication data provided below is then used by default to authenticate to a remote server. This is very useful e.g. if you are working in an Active Directory environment or an NT domain.") );
- addItem( mUseDefaultLoginItem, QString::fromLatin1( "UseDefaultLogin" ) );
+ addItem( mUseDefaultLoginItem, TQString::tqfromLatin1( "UseDefaultLogin" ) );
- setCurrentGroup( QString::fromLatin1( "Samba" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "Samba" ) );
- mNetBIOSNameItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "NetBIOSName" ), mNetBIOSName );
+ mNetBIOSNameItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "NetBIOSName" ), mNetBIOSName );
mNetBIOSNameItem->setLabel( i18n("The NetBIOS name of this computer") );
mNetBIOSNameItem->setWhatsThis( i18n("This is the NetBIOS name of this computer that is used by Smb4K. By default, it is either the NetBIOS name that is defined in the smb.conf file or the host name.") );
- addItem( mNetBIOSNameItem, QString::fromLatin1( "NetBIOSName" ) );
- mDomainNameItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "DomainName" ), mDomainName );
+ addItem( mNetBIOSNameItem, TQString::tqfromLatin1( "NetBIOSName" ) );
+ mDomainNameItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "DomainName" ), mDomainName );
mDomainNameItem->setLabel( i18n("The name of the workgroup/domain this computer is in") );
mDomainNameItem->setWhatsThis( i18n("This is the workgroup or domain this computer is or should be in. By default, it is the workgroup that is defined in the smb.conf file.") );
- addItem( mDomainNameItem, QString::fromLatin1( "DomainName" ) );
- mSocketOptionsItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "SocketOptions" ), mSocketOptions );
+ addItem( mDomainNameItem, TQString::tqfromLatin1( "DomainName" ) );
+ mSocketOptionsItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "SocketOptions" ), mSocketOptions );
mSocketOptionsItem->setLabel( i18n("The socket options") );
mSocketOptionsItem->setWhatsThis( i18n("These are the TCP socket options that are used by nmblookup, smbmount and smbclient. Socket options are controls on the networking layer of the operating systems which allow the connection to be tuned. See the manual page of smb.conf for more information.") );
- addItem( mSocketOptionsItem, QString::fromLatin1( "SocketOptions" ) );
- mNetBIOSScopeItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "NetBIOSScope" ), mNetBIOSScope );
+ addItem( mSocketOptionsItem, TQString::tqfromLatin1( "SocketOptions" ) );
+ mNetBIOSScopeItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "NetBIOSScope" ), mNetBIOSScope );
mNetBIOSScopeItem->setLabel( i18n("The NetBIOS scope") );
mNetBIOSScopeItem->setWhatsThis( i18n("This sets the NetBIOS scope that nmblookup, smbmount and smbclient will operate under. It should not be set unless every machine on your network neighborhood sets this value.") );
- addItem( mNetBIOSScopeItem, QString::fromLatin1( "NetBIOSScope" ) );
- mRemotePortItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "RemotePort" ), mRemotePort, 139 );
+ addItem( mNetBIOSScopeItem, TQString::tqfromLatin1( "NetBIOSScope" ) );
+ mRemotePortItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "RemotePort" ), mRemotePort, 139 );
mRemotePortItem->setMinValue(1);
mRemotePortItem->setMaxValue(65535);
mRemotePortItem->setLabel( i18n("The remote SMB port") );
mRemotePortItem->setWhatsThis( i18n("This is the port that is to be used for connecting to remote servers. Please note that this is independent of the settings in the smb.conf file.") );
- addItem( mRemotePortItem, QString::fromLatin1( "RemotePort" ) );
- mUseKerberosItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseKerberos" ), mUseKerberos, false );
+ addItem( mRemotePortItem, TQString::tqfromLatin1( "RemotePort" ) );
+ mUseKerberosItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseKerberos" ), mUseKerberos, false );
mUseKerberosItem->setLabel( i18n("Use Kerberos for authentication") );
mUseKerberosItem->setWhatsThis( i18n("Try to authenticate with Kerberos. This is only useful in an Active Directory environment. The setting affects the smbmount and smbclient command.") );
- addItem( mUseKerberosItem, QString::fromLatin1( "UseKerberos" ) );
- mMachineAccountItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "MachineAccount" ), mMachineAccount, false );
+ addItem( mUseKerberosItem, TQString::tqfromLatin1( "UseKerberos" ) );
+ mMachineAccountItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "MachineAccount" ), mMachineAccount, false );
mMachineAccountItem->setLabel( i18n("Use machine account for login") );
mMachineAccountItem->setWhatsThis( i18n("Make queries to the remote server using the machine account of the local server. The setting affects the net and the smbclient command.") );
- addItem( mMachineAccountItem, QString::fromLatin1( "MachineAccount" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesFilesystem;
+ addItem( mMachineAccountItem, TQString::tqfromLatin1( "MachineAccount" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesFilesystem;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "CIFS" );
+ choice.name = TQString::tqfromLatin1( "CIFS" );
valuesFilesystem.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "SMBFS" );
+ choice.name = TQString::tqfromLatin1( "SMBFS" );
valuesFilesystem.append( choice );
}
- mFilesystemItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "Filesystem" ), mFilesystem, valuesFilesystem, EnumFilesystem::CIFS );
+ mFilesystemItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "Filesystem" ), mFilesystem, valuesFilesystem, EnumFilesystem::CIFS );
mFilesystemItem->setLabel( i18n("The file system that is used for mounting remote shares") );
mFilesystemItem->setWhatsThis( i18n("This is the file system that will be used to mount the remote shares. The Common Internet File System (CIFS) is supported by Windows 2000 and above as well as by Samba. It offers many improvements and advancements compared to the Server Message Block File System (SMBFS) which is used by Windows 9x and below.") );
- addItem( mFilesystemItem, QString::fromLatin1( "Filesystem" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesClientCharset;
+ addItem( mFilesystemItem, TQString::tqfromLatin1( "Filesystem" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesClientCharset;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "default_charset" );
+ choice.name = TQString::tqfromLatin1( "default_charset" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_1" );
+ choice.name = TQString::tqfromLatin1( "iso8859_1" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_2" );
+ choice.name = TQString::tqfromLatin1( "iso8859_2" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_3" );
+ choice.name = TQString::tqfromLatin1( "iso8859_3" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_4" );
+ choice.name = TQString::tqfromLatin1( "iso8859_4" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_5" );
+ choice.name = TQString::tqfromLatin1( "iso8859_5" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_6" );
+ choice.name = TQString::tqfromLatin1( "iso8859_6" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_7" );
+ choice.name = TQString::tqfromLatin1( "iso8859_7" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_8" );
+ choice.name = TQString::tqfromLatin1( "iso8859_8" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_9" );
+ choice.name = TQString::tqfromLatin1( "iso8859_9" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_13" );
+ choice.name = TQString::tqfromLatin1( "iso8859_13" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_14" );
+ choice.name = TQString::tqfromLatin1( "iso8859_14" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "iso8859_15" );
+ choice.name = TQString::tqfromLatin1( "iso8859_15" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "utf8" );
+ choice.name = TQString::tqfromLatin1( "utf8" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "koi8_r" );
+ choice.name = TQString::tqfromLatin1( "koi8_r" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "koi8_u" );
+ choice.name = TQString::tqfromLatin1( "koi8_u" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "koi8_ru" );
+ choice.name = TQString::tqfromLatin1( "koi8_ru" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1251" );
+ choice.name = TQString::tqfromLatin1( "cp1251" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "gb2312" );
+ choice.name = TQString::tqfromLatin1( "gb2312" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "big5" );
+ choice.name = TQString::tqfromLatin1( "big5" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "euc_jp" );
+ choice.name = TQString::tqfromLatin1( "euc_jp" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "euc_kr" );
+ choice.name = TQString::tqfromLatin1( "euc_kr" );
valuesClientCharset.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "tis_620" );
+ choice.name = TQString::tqfromLatin1( "tis_620" );
valuesClientCharset.append( choice );
}
- mClientCharsetItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "ClientCharset" ), mClientCharset, valuesClientCharset, EnumClientCharset::default_charset );
+ mClientCharsetItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "ClientCharset" ), mClientCharset, valuesClientCharset, EnumClientCharset::default_charset );
mClientCharsetItem->setLabel( i18n("The charset used by the client") );
mClientCharsetItem->setWhatsThis( i18n("This is the charset that is used by the client side (i.e. your side) either to convert local path names to and from Unicode in case of the CIFS file system or for codepage to charset translations (NLS) in case of the SMBFS file system. If you keep the default setting, Smb4K will try to automatically determine the charset by looking up the \"unix charset\" option in the smb.conf.") );
- addItem( mClientCharsetItem, QString::fromLatin1( "ClientCharset" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesServerCodepage;
+ addItem( mClientCharsetItem, TQString::tqfromLatin1( "ClientCharset" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesServerCodepage;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "default_codepage" );
+ choice.name = TQString::tqfromLatin1( "default_codepage" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp437" );
+ choice.name = TQString::tqfromLatin1( "cp437" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp720" );
+ choice.name = TQString::tqfromLatin1( "cp720" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp737" );
+ choice.name = TQString::tqfromLatin1( "cp737" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp775" );
+ choice.name = TQString::tqfromLatin1( "cp775" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp850" );
+ choice.name = TQString::tqfromLatin1( "cp850" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp852" );
+ choice.name = TQString::tqfromLatin1( "cp852" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp855" );
+ choice.name = TQString::tqfromLatin1( "cp855" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp857" );
+ choice.name = TQString::tqfromLatin1( "cp857" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp858" );
+ choice.name = TQString::tqfromLatin1( "cp858" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp860" );
+ choice.name = TQString::tqfromLatin1( "cp860" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp861" );
+ choice.name = TQString::tqfromLatin1( "cp861" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp862" );
+ choice.name = TQString::tqfromLatin1( "cp862" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp863" );
+ choice.name = TQString::tqfromLatin1( "cp863" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp864" );
+ choice.name = TQString::tqfromLatin1( "cp864" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp865" );
+ choice.name = TQString::tqfromLatin1( "cp865" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp866" );
+ choice.name = TQString::tqfromLatin1( "cp866" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp869" );
+ choice.name = TQString::tqfromLatin1( "cp869" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp874" );
+ choice.name = TQString::tqfromLatin1( "cp874" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp932" );
+ choice.name = TQString::tqfromLatin1( "cp932" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp936" );
+ choice.name = TQString::tqfromLatin1( "cp936" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp949" );
+ choice.name = TQString::tqfromLatin1( "cp949" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp950" );
+ choice.name = TQString::tqfromLatin1( "cp950" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1250" );
+ choice.name = TQString::tqfromLatin1( "cp1250" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1251" );
+ choice.name = TQString::tqfromLatin1( "cp1251" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1252" );
+ choice.name = TQString::tqfromLatin1( "cp1252" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1253" );
+ choice.name = TQString::tqfromLatin1( "cp1253" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1254" );
+ choice.name = TQString::tqfromLatin1( "cp1254" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1255" );
+ choice.name = TQString::tqfromLatin1( "cp1255" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1256" );
+ choice.name = TQString::tqfromLatin1( "cp1256" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1257" );
+ choice.name = TQString::tqfromLatin1( "cp1257" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "cp1258" );
+ choice.name = TQString::tqfromLatin1( "cp1258" );
valuesServerCodepage.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "unicode" );
+ choice.name = TQString::tqfromLatin1( "tqunicode" );
valuesServerCodepage.append( choice );
}
- mServerCodepageItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "ServerCodepage" ), mServerCodepage, valuesServerCodepage, EnumServerCodepage::default_codepage );
+ mServerCodepageItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "ServerCodepage" ), mServerCodepage, valuesServerCodepage, EnumServerCodepage::default_codepage );
mServerCodepageItem->setLabel( i18n("The codepage used by the server") );
mServerCodepageItem->setWhatsThis( i18n("This is the codepage that is used by the server. The setting is only available with the SMBFS file system. If you keep the default setting, Smb4K will try to automatically determine the codepage by looking up the \"dos charset\" option in the smb.conf.") );
- addItem( mServerCodepageItem, QString::fromLatin1( "ServerCodepage" ) );
- mUserIDItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "UserID" ), mUserID, QString( "%1" ).arg( (int)getuid() ) );
+ addItem( mServerCodepageItem, TQString::tqfromLatin1( "ServerCodepage" ) );
+ mUserIDItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "UserID" ), mUserID, TQString( "%1" ).tqarg( (int)getuid() ) );
mUserIDItem->setLabel( i18n("The user ID that is to be used for mounting") );
mUserIDItem->setWhatsThis( i18n("Here you can enter the user ID (a number) that the files and directories of the mounted share will have. If you are using the CIFS file system and the remote server supports the CIFS Unix Extentions, this setting will be ignored.") );
- addItem( mUserIDItem, QString::fromLatin1( "UserID" ) );
- mGroupIDItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "GroupID" ), mGroupID, QString( "%1" ).arg( (int)getgid() ) );
+ addItem( mUserIDItem, TQString::tqfromLatin1( "UserID" ) );
+ mGroupIDItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "GroupID" ), mGroupID, TQString( "%1" ).tqarg( (int)getgid() ) );
mGroupIDItem->setLabel( i18n("The group ID that is to be used for mounting") );
mGroupIDItem->setWhatsThis( i18n("Here you can enter the group ID (a number) that the files and directories of the mounted share will have. If you are using the CIFS file system and the remote server supports the CIFS Unix Extentions, this setting will be ignored.") );
- addItem( mGroupIDItem, QString::fromLatin1( "GroupID" ) );
- mFileMaskItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "FileMask" ), mFileMask, QString::fromLatin1( "0755" ) );
- mFileMaskItem->setLabel( i18n("The file mask for a share") );
- mFileMaskItem->setWhatsThis( i18n("This is the mask that will be used for creating files. It must be defined in octal. In case the CIFS file system is used, this setting only takes effect if the server does not support the CIFS Unix Extensions.") );
- addItem( mFileMaskItem, QString::fromLatin1( "FileMask" ) );
- mDirectoryMaskItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "DirectoryMask" ), mDirectoryMask, QString::fromLatin1( "0755" ) );
- mDirectoryMaskItem->setLabel( i18n("The directory mask for a share") );
- mDirectoryMaskItem->setWhatsThis( i18n("This is the mask that will be used for creating directories. It must be defined in octal. In case the CIFS file system is used, this setting only takes effect if the server does not support the CIFS Unix Extensions.") );
- addItem( mDirectoryMaskItem, QString::fromLatin1( "DirectoryMask" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesWriteAccess;
- {
- KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "ReadWrite" );
+ addItem( mGroupIDItem, TQString::tqfromLatin1( "GroupID" ) );
+ mFileMaskItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "FileMask" ), mFileMask, TQString::tqfromLatin1( "0755" ) );
+ mFileMaskItem->setLabel( i18n("The file tqmask for a share") );
+ mFileMaskItem->setWhatsThis( i18n("This is the tqmask that will be used for creating files. It must be defined in octal. In case the CIFS file system is used, this setting only takes effect if the server does not support the CIFS Unix Extensions.") );
+ addItem( mFileMaskItem, TQString::tqfromLatin1( "FileMask" ) );
+ mDirectoryMaskItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "DirectoryMask" ), mDirectoryMask, TQString::tqfromLatin1( "0755" ) );
+ mDirectoryMaskItem->setLabel( i18n("The directory tqmask for a share") );
+ mDirectoryMaskItem->setWhatsThis( i18n("This is the tqmask that will be used for creating directories. It must be defined in octal. In case the CIFS file system is used, this setting only takes effect if the server does not support the CIFS Unix Extensions.") );
+ addItem( mDirectoryMaskItem, TQString::tqfromLatin1( "DirectoryMask" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesWriteAccess;
+ {
+ KConfigSkeleton::ItemEnum::Choice choice;
+ choice.name = TQString::tqfromLatin1( "ReadWrite" );
valuesWriteAccess.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "ReadOnly" );
+ choice.name = TQString::tqfromLatin1( "ReadOnly" );
valuesWriteAccess.append( choice );
}
- mWriteAccessItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "WriteAccess" ), mWriteAccess, valuesWriteAccess, EnumWriteAccess::ReadWrite );
+ mWriteAccessItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "WriteAccess" ), mWriteAccess, valuesWriteAccess, EnumWriteAccess::ReadWrite );
mWriteAccessItem->setLabel( i18n("The write access granted for the share") );
mWriteAccessItem->setWhatsThis( i18n("Here you can choose if the shares should be mounted in read and write mode or only read-only.") );
- addItem( mWriteAccessItem, QString::fromLatin1( "WriteAccess" ) );
- mPermissionChecksItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PermissionChecks" ), mPermissionChecks, true );
+ addItem( mWriteAccessItem, TQString::tqfromLatin1( "WriteAccess" ) );
+ mPermissionChecksItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PermissionChecks" ), mPermissionChecks, true );
mPermissionChecksItem->setLabel( i18n("Do permission checks") );
mPermissionChecksItem->setWhatsThis( i18n("The client side (i.e. your side) will check if you have the right UID/GID to manipulate a file or directory. You might want to switch this feature off if the server(s) support the CIFS Unix Extensions and you are not allowed to access the files and directories. This setting does not affect the normal ACL check.") );
- addItem( mPermissionChecksItem, QString::fromLatin1( "PermissionChecks" ) );
- mClientControlsIDsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ClientControlsIDs" ), mClientControlsIDs, false );
+ addItem( mPermissionChecksItem, TQString::tqfromLatin1( "PermissionChecks" ) );
+ mClientControlsIDsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ClientControlsIDs" ), mClientControlsIDs, false );
mClientControlsIDsItem->setLabel( i18n("Set UID and GID") );
mClientControlsIDsItem->setWhatsThis( i18n("In case the server supports the CIFS Unix Extensions, the client side (i.e. your side) attempts to set the effective UID and GID of the current process on newly created files, directories and devices. If this feature is turned off, the default UID and GID defined for the share will be used. It is recommended that you read the manual page of mount.cifs before you change this setting.") );
- addItem( mClientControlsIDsItem, QString::fromLatin1( "ClientControlsIDs" ) );
- mServerInodeNumbersItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ServerInodeNumbers" ), mServerInodeNumbers, false );
+ addItem( mClientControlsIDsItem, TQString::tqfromLatin1( "ClientControlsIDs" ) );
+ mServerInodeNumbersItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ServerInodeNumbers" ), mServerInodeNumbers, false );
mServerInodeNumbersItem->setLabel( i18n("Use server inode numbers") );
mServerInodeNumbersItem->setWhatsThis( i18n("Use inode numbers (unique persistent file identifiers) returned by the server instead of automatically generating temporary inode numbers on the client side.") );
- addItem( mServerInodeNumbersItem, QString::fromLatin1( "ServerInodeNumbers" ) );
- mInodeDataCachingItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "InodeDataCaching" ), mInodeDataCaching, false );
+ addItem( mServerInodeNumbersItem, TQString::tqfromLatin1( "ServerInodeNumbers" ) );
+ mInodeDataCachingItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "InodeDataCaching" ), mInodeDataCaching, false );
mInodeDataCachingItem->setLabel( i18n("Do not cache inode data") );
mInodeDataCachingItem->setWhatsThis( i18n("Directly read from and write to files opened on the share. In some cases this can provide better performance than the default behavior which caches reads and writes.") );
- addItem( mInodeDataCachingItem, QString::fromLatin1( "InodeDataCaching" ) );
- mTranslateReservedCharsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "TranslateReservedChars" ), mTranslateReservedChars, false );
+ addItem( mInodeDataCachingItem, TQString::tqfromLatin1( "InodeDataCaching" ) );
+ mTranslateReservedCharsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "TranslateReservedChars" ), mTranslateReservedChars, false );
mTranslateReservedCharsItem->setLabel( i18n("Translate reserved characters") );
mTranslateReservedCharsItem->setWhatsThis( i18n("Translate six of the seven reserved characters (including the colon, question mark, pipe, asterisk, greater than and less than characters but not the backslash) to remap range (above 0xF000). This allows you to open files that were created with such characters. This has no effect if the server does not support Unicode.") );
- addItem( mTranslateReservedCharsItem, QString::fromLatin1( "TranslateReservedChars" ) );
- mNoLockingItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "NoLocking" ), mNoLocking, false );
+ addItem( mTranslateReservedCharsItem, TQString::tqfromLatin1( "TranslateReservedChars" ) );
+ mNoLockingItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "NoLocking" ), mNoLocking, false );
mNoLockingItem->setLabel( i18n("Do not use locking") );
mNoLockingItem->setWhatsThis( i18n("Do not use locking. Do not start lockd.") );
- addItem( mNoLockingItem, QString::fromLatin1( "NoLocking" ) );
- mCustomCIFSOptionsItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "CustomCIFSOptions" ), mCustomCIFSOptions );
+ addItem( mNoLockingItem, TQString::tqfromLatin1( "NoLocking" ) );
+ mCustomCIFSOptionsItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "CustomCIFSOptions" ), mCustomCIFSOptions );
mCustomCIFSOptionsItem->setLabel( i18n("Advanced custom options for the CIFS file system") );
mCustomCIFSOptionsItem->setWhatsThis( i18n("Here you can enter advanced options for the CIFS file system in a comma-separated list (refer to the manual page of mount.cifs to learn more). The list will be added AS IS to the \"-o\" argument of mount.cifs. Please do not enter options that have already been defined in the configuration dialog.") );
- addItem( mCustomCIFSOptionsItem, QString::fromLatin1( "CustomCIFSOptions" ) );
- mCachingTimeItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "CachingTime" ), mCachingTime, 1000 );
+ addItem( mCustomCIFSOptionsItem, TQString::tqfromLatin1( "CustomCIFSOptions" ) );
+ mCachingTimeItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "CachingTime" ), mCachingTime, 1000 );
mCachingTimeItem->setLabel( i18n("Determines how long directory listings are cached") );
mCachingTimeItem->setWhatsThis( i18n("This setting determines how long a directory listing is cached in milliseconds. A high value means it takes longer until changes on the server are noticed on the client side (i.e. your side), but it can also give you an increase in performance on large directories, especially on long distances. You need Linux kernel 2.4.2 or later to take advantage of this setting.") );
- addItem( mCachingTimeItem, QString::fromLatin1( "CachingTime" ) );
- mUnicodeSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UnicodeSupport" ), mUnicodeSupport, false );
+ addItem( mCachingTimeItem, TQString::tqfromLatin1( "CachingTime" ) );
+ mUnicodeSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UnicodeSupport" ), mUnicodeSupport, false );
mUnicodeSupportItem->setLabel( i18n("Unicode support") );
mUnicodeSupportItem->setWhatsThis( i18n("Use Unicode when communicating with the server. This will give you better support for non-ASCII character sets with the SMBFS file system.") );
- addItem( mUnicodeSupportItem, QString::fromLatin1( "UnicodeSupport" ) );
- mLargeFileSystemSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "LargeFileSystemSupport" ), mLargeFileSystemSupport, false );
+ addItem( mUnicodeSupportItem, TQString::tqfromLatin1( "UnicodeSupport" ) );
+ mLargeFileSystemSupportItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "LargeFileSystemSupport" ), mLargeFileSystemSupport, false );
mLargeFileSystemSupportItem->setLabel( i18n("Long file support") );
mLargeFileSystemSupportItem->setWhatsThis( i18n("Large file support (LFS) enables you to read and write \n"
"files bigger than 2 GB on shares that were mounted with the SMBFS file system.") );
- addItem( mLargeFileSystemSupportItem, QString::fromLatin1( "LargeFileSystemSupport" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesProtocolHint;
+ addItem( mLargeFileSystemSupportItem, TQString::tqfromLatin1( "LargeFileSystemSupport" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesProtocolHint;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "Automatic" );
+ choice.name = TQString::tqfromLatin1( "Automatic" );
valuesProtocolHint.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "RPC" );
+ choice.name = TQString::tqfromLatin1( "RPC" );
valuesProtocolHint.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "RAP" );
+ choice.name = TQString::tqfromLatin1( "RAP" );
valuesProtocolHint.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "ADS" );
+ choice.name = TQString::tqfromLatin1( "ADS" );
valuesProtocolHint.append( choice );
}
- mProtocolHintItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "ProtocolHint" ), mProtocolHint, valuesProtocolHint, EnumProtocolHint::Automatic );
+ mProtocolHintItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "ProtocolHint" ), mProtocolHint, valuesProtocolHint, EnumProtocolHint::Automatic );
mProtocolHintItem->setLabel( i18n("The protocol that is used with the net command") );
mProtocolHintItem->setWhatsThis( i18n("Here you can choose the protocol that will be used by the net command for the communication with remote servers if appropriate. In most cases the automatic detection will work fine and you should not need to change the default setting. However, if you experience problems, use the RPC protocol for newer operating systems (Windows NT4 and above) and the RAP protocol for older ones (Windows 98/NT3 and below). Functions that need the ADS protocol (for Active Directory environments) have not been implemented yet, so you can ignore that one for now.") );
- addItem( mProtocolHintItem, QString::fromLatin1( "ProtocolHint" ) );
- mNameResolveOrderItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "NameResolveOrder" ), mNameResolveOrder );
+ addItem( mProtocolHintItem, TQString::tqfromLatin1( "ProtocolHint" ) );
+ mNameResolveOrderItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "NameResolveOrder" ), mNameResolveOrder );
mNameResolveOrderItem->setLabel( i18n("Name resolve order used by smbclient") );
mNameResolveOrderItem->setWhatsThis( i18n("This option is used to determine what naming services and in what order are used to resolve host names and IP addresses. It takes a space-separated list of up to four different name resolution options. Those are: lmhost, host, wins, bcast. See the manual page of smbclient for further information.") );
- addItem( mNameResolveOrderItem, QString::fromLatin1( "NameResolveOrder" ) );
- mBufferSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "BufferSize" ), mBufferSize, 65520 );
+ addItem( mNameResolveOrderItem, TQString::tqfromLatin1( "NameResolveOrder" ) );
+ mBufferSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "BufferSize" ), mBufferSize, 65520 );
mBufferSizeItem->setMinValue(0);
mBufferSizeItem->setLabel( i18n("Transmit/send buffer size used by smbclient") );
mBufferSizeItem->setWhatsThis( i18n("This option changes the transmit/send buffer size when getting or putting a file from/to the server. The default is 65520 bytes. Setting this value smaller has been observed to speed up file transfers to and from Windows 9x servers.") );
- addItem( mBufferSizeItem, QString::fromLatin1( "BufferSize" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesSigningState;
+ addItem( mBufferSizeItem, TQString::tqfromLatin1( "BufferSize" ) );
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesSigningState;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "None" );
+ choice.name = TQString::tqfromLatin1( "None" );
valuesSigningState.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "On" );
+ choice.name = TQString::tqfromLatin1( "On" );
valuesSigningState.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "Off" );
+ choice.name = TQString::tqfromLatin1( "Off" );
valuesSigningState.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "Required" );
+ choice.name = TQString::tqfromLatin1( "Required" );
valuesSigningState.append( choice );
}
- mSigningStateItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "SigningState" ), mSigningState, valuesSigningState, EnumSigningState::None );
+ mSigningStateItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "SigningState" ), mSigningState, valuesSigningState, EnumSigningState::None );
mSigningStateItem->setLabel( i18n("Signing state") );
mSigningStateItem->setWhatsThis( i18n("Set the signing state for smbclient.") );
- addItem( mSigningStateItem, QString::fromLatin1( "SigningState" ) );
- mBroadcastAddressItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "BroadcastAddress" ), mBroadcastAddress );
+ addItem( mSigningStateItem, TQString::tqfromLatin1( "SigningState" ) );
+ mBroadcastAddressItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "BroadcastAddress" ), mBroadcastAddress );
mBroadcastAddressItem->setLabel( i18n("The broadcast address used by nmblookup") );
mBroadcastAddressItem->setWhatsThis( i18n("Queries performed with nmblookup will be send to the given broadcast address. Without this option the default behavior is to send the queries to the broadcast address of the network interface that was either auto-detected or defined in the \"interfaces\" parameter of the smb.conf file.") );
- addItem( mBroadcastAddressItem, QString::fromLatin1( "BroadcastAddress" ) );
- mUsePort137Item = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UsePort137" ), mUsePort137, false );
+ addItem( mBroadcastAddressItem, TQString::tqfromLatin1( "BroadcastAddress" ) );
+ mUsePort137Item = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UsePort137" ), mUsePort137, false );
mUsePort137Item->setLabel( i18n("Use UDP port 137 with nmblookup") );
mUsePort137Item->setWhatsThis( i18n("Try and bind to UDP port 137 to send and receive UDP datagrams. The reason for this option is a bug in Windows 95 where it ignores the source port of the requesting packet and only replies to UDP port 137. Unfortunately, on most Unix systems super user privileges are needed to bind to this port. Please read the manual page of nmblookup for more information.") );
- addItem( mUsePort137Item, QString::fromLatin1( "UsePort137" ) );
+ addItem( mUsePort137Item, TQString::tqfromLatin1( "UsePort137" ) );
- setCurrentGroup( QString::fromLatin1( "Synchronization" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "Synchronization" ) );
- mRsyncPrefixItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "RsyncPrefix" ), mRsyncPrefix, QString::fromLatin1( "$HOME/smb4k_sync/" ) );
+ mRsyncPrefixItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "RsyncPrefix" ), mRsyncPrefix, TQString::tqfromLatin1( "$HOME/smb4k_sync/" ) );
mRsyncPrefixItem->setLabel( i18n("Prefix for synchronization") );
mRsyncPrefixItem->setWhatsThis( i18n("This is the path where Smb4K will store the files and directories during synchronization. If you plan to synchronize only with one remote share, then you can put the data directly in this directory. If you want to synchronize with several remote shares, then you should create a subdirectory for each share and choose the appropriate one in the synchronization dialog.") );
- addItem( mRsyncPrefixItem, QString::fromLatin1( "RsyncPrefix" ) );
- mArchiveModeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ArchiveMode" ), mArchiveMode, true );
+ addItem( mRsyncPrefixItem, TQString::tqfromLatin1( "RsyncPrefix" ) );
+ mArchiveModeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ArchiveMode" ), mArchiveMode, true );
mArchiveModeItem->setLabel( i18n("Use archive mode") );
mArchiveModeItem->setWhatsThis( i18n("Use archive mode (-a, --archive). This is a short form of -rlptgoD.") );
- addItem( mArchiveModeItem, QString::fromLatin1( "ArchiveMode" ) );
- mRecurseIntoDirectoriesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "RecurseIntoDirectories" ), mRecurseIntoDirectories, true );
+ addItem( mArchiveModeItem, TQString::tqfromLatin1( "ArchiveMode" ) );
+ mRecurseIntoDirectoriesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "RecurseIntoDirectories" ), mRecurseIntoDirectories, true );
mRecurseIntoDirectoriesItem->setLabel( i18n("Recurse into subdirectories") );
mRecurseIntoDirectoriesItem->setWhatsThis( i18n("Recurse into directories (-r, --recursive).") );
- addItem( mRecurseIntoDirectoriesItem, QString::fromLatin1( "RecurseIntoDirectories" ) );
- mUpdateTargetItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UpdateTarget" ), mUpdateTarget, true );
+ addItem( mRecurseIntoDirectoriesItem, TQString::tqfromLatin1( "RecurseIntoDirectories" ) );
+ mUpdateTargetItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UpdateTarget" ), mUpdateTarget, true );
mUpdateTargetItem->setLabel( i18n("Skip files that are newer in the target directory") );
mUpdateTargetItem->setWhatsThis( i18n("Update files in the destination directory that are older than in the source directory (-u, --update).") );
- addItem( mUpdateTargetItem, QString::fromLatin1( "UpdateTarget" ) );
- mUpdateInPlaceItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UpdateInPlace" ), mUpdateInPlace, false );
+ addItem( mUpdateTargetItem, TQString::tqfromLatin1( "UpdateTarget" ) );
+ mUpdateInPlaceItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UpdateInPlace" ), mUpdateInPlace, false );
mUpdateInPlaceItem->setLabel( i18n("Update destination files in place") );
mUpdateInPlaceItem->setWhatsThis( i18n("Update destination files in-place (--inplace). By default, rsync first creates a new copy of a file and moves it into place after its transfer finished. If you enable this feature, no copy will be created but the destination file will immediately be overwritten instead. An exception to this is if you combine this option with --backup.") );
- addItem( mUpdateInPlaceItem, QString::fromLatin1( "UpdateInPlace" ) );
- mRelativePathNamesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "RelativePathNames" ), mRelativePathNames, false );
+ addItem( mUpdateInPlaceItem, TQString::tqfromLatin1( "UpdateInPlace" ) );
+ mRelativePathNamesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "RelativePathNames" ), mRelativePathNames, false );
mRelativePathNamesItem->setLabel( i18n("Use relative path names") );
mRelativePathNamesItem->setWhatsThis( i18n("Use relative paths (-R, --relative). This means that the full path names specified on the command line are sent to the server rather than just the last parts of the file names.") );
- addItem( mRelativePathNamesItem, QString::fromLatin1( "RelativePathNames" ) );
- mNoImpliedDirectoriesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "NoImpliedDirectories" ), mNoImpliedDirectories, false );
+ addItem( mRelativePathNamesItem, TQString::tqfromLatin1( "RelativePathNames" ) );
+ mNoImpliedDirectoriesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "NoImpliedDirectories" ), mNoImpliedDirectories, false );
mNoImpliedDirectoriesItem->setLabel( i18n("Don't send implied directories with --relative") );
mNoImpliedDirectoriesItem->setWhatsThis( i18n("Don't send implied directories with --relative (--no-implied-dirs). This means that the corresponding path elements on the destination system are left unchanged if they exist, and any missing implied directories are created with default attributes. This even allows these implied path elements to have big differences, such as being a symlink to a directory on one side of the transfer, and a real directory on the other side.") );
- addItem( mNoImpliedDirectoriesItem, QString::fromLatin1( "NoImpliedDirectories" ) );
- mTransferDirectoriesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "TransferDirectories" ), mTransferDirectories, false );
+ addItem( mNoImpliedDirectoriesItem, TQString::tqfromLatin1( "NoImpliedDirectories" ) );
+ mTransferDirectoriesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "TransferDirectories" ), mTransferDirectories, false );
mTransferDirectoriesItem->setLabel( i18n("Transfer directories without recursing") );
mTransferDirectoriesItem->setWhatsThis( i18n("Transfer directories without recursing (-d, --dirs). This means that all top-level subdirectories are transferred but without their contents.") );
- addItem( mTransferDirectoriesItem, QString::fromLatin1( "TransferDirectories" ) );
- mCompressDataItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "CompressData" ), mCompressData, false );
+ addItem( mTransferDirectoriesItem, TQString::tqfromLatin1( "TransferDirectories" ) );
+ mCompressDataItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "CompressData" ), mCompressData, false );
mCompressDataItem->setLabel( i18n("Compress data during transfer") );
mCompressDataItem->setWhatsThis( i18n("Compress data during transfer (-z, --compress). This significantly reduces the amount of data that is being transferred. You may want to use this option, if you have a slow connection.") );
- addItem( mCompressDataItem, QString::fromLatin1( "CompressData" ) );
- mPreserveSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreserveSymlinks" ), mPreserveSymlinks, true );
+ addItem( mCompressDataItem, TQString::tqfromLatin1( "CompressData" ) );
+ mPreserveSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreserveSymlinks" ), mPreserveSymlinks, true );
mPreserveSymlinksItem->setLabel( i18n("Preserve symlinks") );
mPreserveSymlinksItem->setWhatsThis( i18n("Copy symlinks as symlinks (-l, --links).") );
- addItem( mPreserveSymlinksItem, QString::fromLatin1( "PreserveSymlinks" ) );
- mTransformSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "TransformSymlinks" ), mTransformSymlinks, false );
+ addItem( mPreserveSymlinksItem, TQString::tqfromLatin1( "PreserveSymlinks" ) );
+ mTransformSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "TransformSymlinks" ), mTransformSymlinks, false );
mTransformSymlinksItem->setLabel( i18n("Transform symlinks") );
mTransformSymlinksItem->setWhatsThis( i18n("Transform symlinks into the items they are pointing to (-L, --copy-links).") );
- addItem( mTransformSymlinksItem, QString::fromLatin1( "TransformSymlinks" ) );
- mTransformUnsafeSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "TransformUnsafeSymlinks" ), mTransformUnsafeSymlinks, false );
+ addItem( mTransformSymlinksItem, TQString::tqfromLatin1( "TransformSymlinks" ) );
+ mTransformUnsafeSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "TransformUnsafeSymlinks" ), mTransformUnsafeSymlinks, false );
mTransformUnsafeSymlinksItem->setLabel( i18n("Only transform unsafe symlinks") );
mTransformUnsafeSymlinksItem->setWhatsThis( i18n("Transform unsafe symlinks into the items they are pointing to (--copy-unsafe-links). This means that only those symlinks are transformed that point to items that are outside the copied tree. Absolute symlinks are treated the same way. This option has no additional effect if --copy-links has also been specified.") );
- addItem( mTransformUnsafeSymlinksItem, QString::fromLatin1( "TransformUnsafeSymlinks" ) );
- mIgnoreUnsafeSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "IgnoreUnsafeSymlinks" ), mIgnoreUnsafeSymlinks, false );
+ addItem( mTransformUnsafeSymlinksItem, TQString::tqfromLatin1( "TransformUnsafeSymlinks" ) );
+ mIgnoreUnsafeSymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "IgnoreUnsafeSymlinks" ), mIgnoreUnsafeSymlinks, false );
mIgnoreUnsafeSymlinksItem->setLabel( i18n("Ignore unsafe symlinks") );
mIgnoreUnsafeSymlinksItem->setWhatsThis( i18n("Ignore symlinks that point outside the copied tree (--safe-links). All absolute symlinks are also ignored. If you use this option in conjunction with --relative you might get unexpected results.") );
- addItem( mIgnoreUnsafeSymlinksItem, QString::fromLatin1( "IgnoreUnsafeSymlinks" ) );
- mPreserveHardLinksItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreserveHardLinks" ), mPreserveHardLinks, false );
+ addItem( mIgnoreUnsafeSymlinksItem, TQString::tqfromLatin1( "IgnoreUnsafeSymlinks" ) );
+ mPreserveHardLinksItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreserveHardLinks" ), mPreserveHardLinks, false );
mPreserveHardLinksItem->setLabel( i18n("Preserve hard links") );
mPreserveHardLinksItem->setWhatsThis( i18n("Preserve hard links (-H, --hard-links). This options causes rsync to preserve the hard links that are found during the transfer. Without it, hard links are treated as though they were separate files.") );
- addItem( mPreserveHardLinksItem, QString::fromLatin1( "PreserveHardLinks" ) );
- mKeepDirectorySymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "KeepDirectorySymlinks" ), mKeepDirectorySymlinks, false );
+ addItem( mPreserveHardLinksItem, TQString::tqfromLatin1( "PreserveHardLinks" ) );
+ mKeepDirectorySymlinksItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "KeepDirectorySymlinks" ), mKeepDirectorySymlinks, false );
mKeepDirectorySymlinksItem->setLabel( i18n("Keep directory symlinks") );
mKeepDirectorySymlinksItem->setWhatsThis( i18n("Treat symlinked directories on the receiving side as though they were real ones (-K, --keep-dirlinks). This only works if the symlink matches a real directory from the sending side. Without this option, the receiver's symlink will be deleted and replaced with a real directory.") );
- addItem( mKeepDirectorySymlinksItem, QString::fromLatin1( "KeepDirectorySymlinks" ) );
- mPreservePermissionsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreservePermissions" ), mPreservePermissions, true );
+ addItem( mKeepDirectorySymlinksItem, TQString::tqfromLatin1( "KeepDirectorySymlinks" ) );
+ mPreservePermissionsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreservePermissions" ), mPreservePermissions, true );
mPreservePermissionsItem->setLabel( i18n("Preserve permissions") );
mPreservePermissionsItem->setWhatsThis( i18n("Preserve permissions (-p, --perms). The permissions of the destination file will be same as the source file. For what happens if this option is switched off, please read rsync's manual page.") );
- addItem( mPreservePermissionsItem, QString::fromLatin1( "PreservePermissions" ) );
- mPreserveGroupItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreserveGroup" ), mPreserveGroup, true );
+ addItem( mPreservePermissionsItem, TQString::tqfromLatin1( "PreservePermissions" ) );
+ mPreserveGroupItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreserveGroup" ), mPreserveGroup, true );
mPreserveGroupItem->setLabel( i18n("Preserve group") );
mPreserveGroupItem->setWhatsThis( i18n("Preserve the group (-g, --group). The group of the destination file will be set to the same value as the source file.") );
- addItem( mPreserveGroupItem, QString::fromLatin1( "PreserveGroup" ) );
- mPreserveOwnerItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreserveOwner" ), mPreserveOwner, true );
+ addItem( mPreserveGroupItem, TQString::tqfromLatin1( "PreserveGroup" ) );
+ mPreserveOwnerItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreserveOwner" ), mPreserveOwner, true );
mPreserveOwnerItem->setLabel( i18n("Preserve owner (super user only)") );
mPreserveOwnerItem->setWhatsThis( i18n("Preserve the owner (-o, --owner). The owner of the destination file will be set to the same value as the source file, but only if the receiving rsync is run as the super user. Without this option, the owner is set to the invoking user on the receiving side.") );
- addItem( mPreserveOwnerItem, QString::fromLatin1( "PreserveOwner" ) );
- mPreserveDevicesAndSpecialsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreserveDevicesAndSpecials" ), mPreserveDevicesAndSpecials, true );
+ addItem( mPreserveOwnerItem, TQString::tqfromLatin1( "PreserveOwner" ) );
+ mPreserveDevicesAndSpecialsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreserveDevicesAndSpecials" ), mPreserveDevicesAndSpecials, true );
mPreserveDevicesAndSpecialsItem->setLabel( i18n("Preserve device and special files") );
mPreserveDevicesAndSpecialsItem->setWhatsThis( i18n("Preserve device and special files (-D, --devices --specials). This option causes rsync to transfer character and block devices as well as special files such as named sockets and fifos. It works only partially if rsync is not run as super user and the --super option is not specified.") );
- addItem( mPreserveDevicesAndSpecialsItem, QString::fromLatin1( "PreserveDevicesAndSpecials" ) );
- mPreserveTimesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "PreserveTimes" ), mPreserveTimes, true );
+ addItem( mPreserveDevicesAndSpecialsItem, TQString::tqfromLatin1( "PreserveDevicesAndSpecials" ) );
+ mPreserveTimesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "PreserveTimes" ), mPreserveTimes, true );
mPreserveTimesItem->setLabel( i18n("Preserve times") );
mPreserveTimesItem->setWhatsThis( i18n("Preserve times (-t, --times). The modification times are transferred along with the files. For what happens if this option is switched off, please read rsync's manual page.") );
- addItem( mPreserveTimesItem, QString::fromLatin1( "PreserveTimes" ) );
- mOmitDirectoryTimesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "OmitDirectoryTimes" ), mOmitDirectoryTimes, false );
+ addItem( mPreserveTimesItem, TQString::tqfromLatin1( "PreserveTimes" ) );
+ mOmitDirectoryTimesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "OmitDirectoryTimes" ), mOmitDirectoryTimes, false );
mOmitDirectoryTimesItem->setLabel( i18n("Omit directories when preserving times") );
mOmitDirectoryTimesItem->setWhatsThis( i18n("Omit directories when preserving times (-O, --omit-dir-times). This means that directories are omitted when modification times are being preserved. Thus, this feature only works in conjunction with --times.") );
- addItem( mOmitDirectoryTimesItem, QString::fromLatin1( "OmitDirectoryTimes" ) );
- mRemoveSourceFilesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "RemoveSourceFiles" ), mRemoveSourceFiles, false );
+ addItem( mOmitDirectoryTimesItem, TQString::tqfromLatin1( "OmitDirectoryTimes" ) );
+ mRemoveSourceFilesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "RemoveSourceFiles" ), mRemoveSourceFiles, false );
mRemoveSourceFilesItem->setLabel( i18n("Remove synchronized source files") );
mRemoveSourceFilesItem->setWhatsThis( i18n("Remove all synchronized source files (--remove-source-files). This tells rsync to remove from the sending side the non-directory items that are a part of the transfer and have been successfully duplicated on the receiving side.") );
- addItem( mRemoveSourceFilesItem, QString::fromLatin1( "RemoveSourceFiles" ) );
- mDeleteExtraneousItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "DeleteExtraneous" ), mDeleteExtraneous, false );
+ addItem( mRemoveSourceFilesItem, TQString::tqfromLatin1( "RemoveSourceFiles" ) );
+ mDeleteExtraneousItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "DeleteExtraneous" ), mDeleteExtraneous, false );
mDeleteExtraneousItem->setLabel( i18n("Delete extraneous files") );
mDeleteExtraneousItem->setWhatsThis( i18n("Delete extraneous files from destination (--delete). This tells rsync to delete all files from the receiving side that are not present on the sending side, but only for the directories that are being synchronized.") );
- addItem( mDeleteExtraneousItem, QString::fromLatin1( "DeleteExtraneous" ) );
- mDeleteBeforeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "DeleteBefore" ), mDeleteBefore, false );
+ addItem( mDeleteExtraneousItem, TQString::tqfromLatin1( "DeleteExtraneous" ) );
+ mDeleteBeforeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "DeleteBefore" ), mDeleteBefore, false );
mDeleteBeforeItem->setLabel( i18n("Delete files before transfer") );
mDeleteBeforeItem->setWhatsThis( i18n("Delete files on the receiving side before the transfer starts (--delete-before). This is the default behavior if --delete or --delete-excluded is specified without one of the --delete-WHEN options.") );
- addItem( mDeleteBeforeItem, QString::fromLatin1( "DeleteBefore" ) );
- mDeleteAfterItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "DeleteAfter" ), mDeleteAfter, false );
+ addItem( mDeleteBeforeItem, TQString::tqfromLatin1( "DeleteBefore" ) );
+ mDeleteAfterItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "DeleteAfter" ), mDeleteAfter, false );
mDeleteAfterItem->setLabel( i18n("Delete files after transfer") );
mDeleteAfterItem->setWhatsThis( i18n("Delete files on the receiving side after the transfer has completed (--delete-after, --del).") );
- addItem( mDeleteAfterItem, QString::fromLatin1( "DeleteAfter" ) );
- mDeleteDuringItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "DeleteDuring" ), mDeleteDuring, false );
+ addItem( mDeleteAfterItem, TQString::tqfromLatin1( "DeleteAfter" ) );
+ mDeleteDuringItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "DeleteDuring" ), mDeleteDuring, false );
mDeleteDuringItem->setLabel( i18n("Delete files during transfer") );
mDeleteDuringItem->setWhatsThis( i18n("Delete files on the receiving side during the transfer (--delete-during). This method is faster than --delete-before or --delete-after, but it is only supported with rsync 2.6.4 or later.") );
- addItem( mDeleteDuringItem, QString::fromLatin1( "DeleteDuring" ) );
- mDeleteExcludedItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "DeleteExcluded" ), mDeleteExcluded, false );
+ addItem( mDeleteDuringItem, TQString::tqfromLatin1( "DeleteDuring" ) );
+ mDeleteExcludedItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "DeleteExcluded" ), mDeleteExcluded, false );
mDeleteExcludedItem->setLabel( i18n("Also delete excluded files from destination directory") );
mDeleteExcludedItem->setWhatsThis( i18n("Also delete excluded files from destination directory (--delete-excluded). In addition to deleting the files on the receiving side that are not on the sending side, this tells rsync to also delete any files on the receiving side that are excluded. Refer to rsync's manual page for further information.") );
- addItem( mDeleteExcludedItem, QString::fromLatin1( "DeleteExcluded" ) );
- mIgnoreErrorsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "IgnoreErrors" ), mIgnoreErrors, false );
+ addItem( mDeleteExcludedItem, TQString::tqfromLatin1( "DeleteExcluded" ) );
+ mIgnoreErrorsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "IgnoreErrors" ), mIgnoreErrors, false );
mIgnoreErrorsItem->setLabel( i18n("Delete even if I/O errors occur") );
mIgnoreErrorsItem->setWhatsThis( i18n("Delete even if I/O errors occur (--ignore-errors). This option has to be specified in conjunction with --delete to take effect.") );
- addItem( mIgnoreErrorsItem, QString::fromLatin1( "IgnoreErrors" ) );
- mForceDirectoryDeletionItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "ForceDirectoryDeletion" ), mForceDirectoryDeletion, false );
+ addItem( mIgnoreErrorsItem, TQString::tqfromLatin1( "IgnoreErrors" ) );
+ mForceDirectoryDeletionItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "ForceDirectoryDeletion" ), mForceDirectoryDeletion, false );
mForceDirectoryDeletionItem->setLabel( i18n("Force deletion of non-void directories") );
mForceDirectoryDeletionItem->setWhatsThis( i18n("Force deletion of directories even if they are not empty (--force). This option tells rsync to delete a non-empty directory when it is to be replaced by a non-directory. This is only relevant if deletions are not active.") );
- addItem( mForceDirectoryDeletionItem, QString::fromLatin1( "ForceDirectoryDeletion" ) );
- mUseMaximumDeleteItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseMaximumDelete" ), mUseMaximumDelete, false );
+ addItem( mForceDirectoryDeletionItem, TQString::tqfromLatin1( "ForceDirectoryDeletion" ) );
+ mUseMaximumDeleteItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseMaximumDelete" ), mUseMaximumDelete, false );
mUseMaximumDeleteItem->setLabel( i18n("Only delete a maximum number of files") );
mUseMaximumDeleteItem->setWhatsThis( i18n("Only delete as many files as defined here (--max-delete=NUM). This tells rsync not to delete more than NUM files or directories (NUM must be non-zero). This is useful when mirroring very large trees to prevent disasters.") );
- addItem( mUseMaximumDeleteItem, QString::fromLatin1( "UseMaximumDelete" ) );
- mMaximumDeleteValueItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "MaximumDeleteValue" ), mMaximumDeleteValue, 0 );
+ addItem( mUseMaximumDeleteItem, TQString::tqfromLatin1( "UseMaximumDelete" ) );
+ mMaximumDeleteValueItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "MaximumDeleteValue" ), mMaximumDeleteValue, 0 );
mMaximumDeleteValueItem->setMinValue(0);
mMaximumDeleteValueItem->setLabel( i18n("Value for DeleteMaximum config entry") );
- addItem( mMaximumDeleteValueItem, QString::fromLatin1( "MaximumDeleteValue" ) );
- mUseMinimalTransferSizeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseMinimalTransferSize" ), mUseMinimalTransferSize, false );
+ addItem( mMaximumDeleteValueItem, TQString::tqfromLatin1( "MaximumDeleteValue" ) );
+ mUseMinimalTransferSizeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseMinimalTransferSize" ), mUseMinimalTransferSize, false );
mUseMinimalTransferSizeItem->setLabel( i18n("Don't transfer any file smaller than SIZE") );
mUseMinimalTransferSizeItem->setWhatsThis( i18n("This option causes rsync to not transfer any file that is smaller than the specified size (--min-size=SIZE).") );
- addItem( mUseMinimalTransferSizeItem, QString::fromLatin1( "UseMinimalTransferSize" ) );
- mMinimalTransferSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "MinimalTransferSize" ), mMinimalTransferSize, 0 );
+ addItem( mUseMinimalTransferSizeItem, TQString::tqfromLatin1( "UseMinimalTransferSize" ) );
+ mMinimalTransferSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "MinimalTransferSize" ), mMinimalTransferSize, 0 );
mMinimalTransferSizeItem->setMinValue(0);
mMinimalTransferSizeItem->setLabel( i18n("Value for MinimalTransferSize config entry") );
- addItem( mMinimalTransferSizeItem, QString::fromLatin1( "MinimalTransferSize" ) );
- mUseMaximalTransferSizeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseMaximalTransferSize" ), mUseMaximalTransferSize, false );
+ addItem( mMinimalTransferSizeItem, TQString::tqfromLatin1( "MinimalTransferSize" ) );
+ mUseMaximalTransferSizeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseMaximalTransferSize" ), mUseMaximalTransferSize, false );
mUseMaximalTransferSizeItem->setLabel( i18n("Don't transfer any file smaller than SIZE") );
mUseMaximalTransferSizeItem->setWhatsThis( i18n("This option causes rsync to not transfer any file that is larger than the specified size (--max-size=SIZE).") );
- addItem( mUseMaximalTransferSizeItem, QString::fromLatin1( "UseMaximalTransferSize" ) );
- mMaximalTransferSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "MaximalTransferSize" ), mMaximalTransferSize, 0 );
+ addItem( mUseMaximalTransferSizeItem, TQString::tqfromLatin1( "UseMaximalTransferSize" ) );
+ mMaximalTransferSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "MaximalTransferSize" ), mMaximalTransferSize, 0 );
mMaximalTransferSizeItem->setMinValue(0);
mMaximalTransferSizeItem->setLabel( i18n("Value for MamximalTransferSize config entry") );
- addItem( mMaximalTransferSizeItem, QString::fromLatin1( "MaximalTransferSize" ) );
- mKeepPartialItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "KeepPartial" ), mKeepPartial, false );
+ addItem( mMaximalTransferSizeItem, TQString::tqfromLatin1( "MaximalTransferSize" ) );
+ mKeepPartialItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "KeepPartial" ), mKeepPartial, false );
mKeepPartialItem->setLabel( i18n("Keep partially transferred files") );
mKeepPartialItem->setWhatsThis( i18n("Keep partially transferred files (--partial). The default behavor is that any partially transferred file is deleted if the transfer is interrupted.") );
- addItem( mKeepPartialItem, QString::fromLatin1( "KeepPartial" ) );
- mUsePartialDirectoryItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UsePartialDirectory" ), mUsePartialDirectory, false );
+ addItem( mKeepPartialItem, TQString::tqfromLatin1( "KeepPartial" ) );
+ mUsePartialDirectoryItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UsePartialDirectory" ), mUsePartialDirectory, false );
mUsePartialDirectoryItem->setLabel( i18n("The directory where to put a partially transferred file into.") );
mUsePartialDirectoryItem->setWhatsThis( i18n("Put a partially transferred file into this directory (--partial-dir=DIR). This is a better way than the --partial option to keep partial files, because the partially transferred file is kept in a different directory and the destination file is not overwritten.") );
- addItem( mUsePartialDirectoryItem, QString::fromLatin1( "UsePartialDirectory" ) );
- mPartialDirectoryItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "PartialDirectory" ), mPartialDirectory, QString::fromLatin1( "$HOME" ) );
+ addItem( mUsePartialDirectoryItem, TQString::tqfromLatin1( "UsePartialDirectory" ) );
+ mPartialDirectoryItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "PartialDirectory" ), mPartialDirectory, TQString::tqfromLatin1( "$HOME" ) );
mPartialDirectoryItem->setLabel( i18n("The data for the UsePartialDirectory option") );
- addItem( mPartialDirectoryItem, QString::fromLatin1( "PartialDirectory" ) );
- mUseCVSExcludeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseCVSExclude" ), mUseCVSExclude, false );
+ addItem( mPartialDirectoryItem, TQString::tqfromLatin1( "PartialDirectory" ) );
+ mUseCVSExcludeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseCVSExclude" ), mUseCVSExclude, false );
mUseCVSExcludeItem->setLabel( i18n("Auto-ignore files in the same way CVS does") );
mUseCVSExcludeItem->setWhatsThis( i18n("Auto-ignore files in the same way CVS does (-C, --cvs-exclude). This is a useful shorthand for excluding a broad range of files that you often do not want to transfer between systems. This option uses the same algorithm that CVS uses to determine if a file should be ignored.") );
- addItem( mUseCVSExcludeItem, QString::fromLatin1( "UseCVSExclude" ) );
- mUseExcludePatternItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseExcludePattern" ), mUseExcludePattern, false );
+ addItem( mUseCVSExcludeItem, TQString::tqfromLatin1( "UseCVSExclude" ) );
+ mUseExcludePatternItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseExcludePattern" ), mUseExcludePattern, false );
mUseExcludePatternItem->setLabel( i18n("Exclude files that match a certain pattern") );
mUseExcludePatternItem->setWhatsThis( i18n("Exclude files that match a certain pattern (--exclude=PATTERN). This is a special filter rule. For further information on filter rules see rsync's manual page.") );
- addItem( mUseExcludePatternItem, QString::fromLatin1( "UseExcludePattern" ) );
- mExcludePatternItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "ExcludePattern" ), mExcludePattern );
+ addItem( mUseExcludePatternItem, TQString::tqfromLatin1( "UseExcludePattern" ) );
+ mExcludePatternItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "ExcludePattern" ), mExcludePattern );
mExcludePatternItem->setLabel( i18n("Pattern that is used for file exclusion") );
- addItem( mExcludePatternItem, QString::fromLatin1( "ExcludePattern" ) );
- mUseExcludeFromItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseExcludeFrom" ), mUseExcludeFrom, false );
+ addItem( mExcludePatternItem, TQString::tqfromLatin1( "ExcludePattern" ) );
+ mUseExcludeFromItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseExcludeFrom" ), mUseExcludeFrom, false );
mUseExcludeFromItem->setLabel( i18n("Read exclude patterns from a file") );
mUseExcludeFromItem->setWhatsThis( i18n("Read exclude patterns from a file (--exclude-from=FILE). This option is similar to the --exclude=PATTERN option except that the exclude patterns are read from a file. This is a special filter rule. For further information on filter rules see rsync's manual page.") );
- addItem( mUseExcludeFromItem, QString::fromLatin1( "UseExcludeFrom" ) );
- mExcludeFromItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "ExcludeFrom" ), mExcludeFrom, QString::fromLatin1( "$HOME/exclude.txt" ) );
+ addItem( mUseExcludeFromItem, TQString::tqfromLatin1( "UseExcludeFrom" ) );
+ mExcludeFromItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "ExcludeFrom" ), mExcludeFrom, TQString::tqfromLatin1( "$HOME/exclude.txt" ) );
mExcludeFromItem->setLabel( i18n("The file from which the exclude patterns are read") );
- addItem( mExcludeFromItem, QString::fromLatin1( "ExcludeFrom" ) );
- mUseIncludePatternItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseIncludePattern" ), mUseIncludePattern, false );
+ addItem( mExcludeFromItem, TQString::tqfromLatin1( "ExcludeFrom" ) );
+ mUseIncludePatternItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseIncludePattern" ), mUseIncludePattern, false );
mUseIncludePatternItem->setLabel( i18n("Do not exclude files matching a certain pattern") );
mUseIncludePatternItem->setWhatsThis( i18n("Do not exclude files matching a certain pattern (--include=PATTERN). This is a special filter rule. For further information on filter rules see rsync's manual page.") );
- addItem( mUseIncludePatternItem, QString::fromLatin1( "UseIncludePattern" ) );
- mIncludePatternItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "IncludePattern" ), mIncludePattern );
+ addItem( mUseIncludePatternItem, TQString::tqfromLatin1( "UseIncludePattern" ) );
+ mIncludePatternItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "IncludePattern" ), mIncludePattern );
mIncludePatternItem->setLabel( i18n("Pattern that is used for file inclusion") );
- addItem( mIncludePatternItem, QString::fromLatin1( "IncludePattern" ) );
- mUseIncludeFromItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseIncludeFrom" ), mUseIncludeFrom, false );
+ addItem( mIncludePatternItem, TQString::tqfromLatin1( "IncludePattern" ) );
+ mUseIncludeFromItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseIncludeFrom" ), mUseIncludeFrom, false );
mUseIncludeFromItem->setLabel( i18n("Read include patterns from a file") );
mUseIncludeFromItem->setWhatsThis( i18n("Read include patterns from a file (--include-from=FILE). This option is similar to the --include=PATTERN option except that the include patterns are read from a file. This is a special filter rule. For further information on filter rules see rsync's manual page.") );
- addItem( mUseIncludeFromItem, QString::fromLatin1( "UseIncludeFrom" ) );
- mIncludeFromItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "IncludeFrom" ), mIncludeFrom, QString::fromLatin1( "$HOME/include.txt" ) );
+ addItem( mUseIncludeFromItem, TQString::tqfromLatin1( "UseIncludeFrom" ) );
+ mIncludeFromItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "IncludeFrom" ), mIncludeFrom, TQString::tqfromLatin1( "$HOME/include.txt" ) );
mIncludeFromItem->setLabel( i18n("The file from which the include patterns are read") );
- addItem( mIncludeFromItem, QString::fromLatin1( "IncludeFrom" ) );
- mCustomFilteringRulesItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "CustomFilteringRules" ), mCustomFilteringRules );
+ addItem( mIncludeFromItem, TQString::tqfromLatin1( "IncludeFrom" ) );
+ mCustomFilteringRulesItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "CustomFilteringRules" ), mCustomFilteringRules );
mCustomFilteringRulesItem->setLabel( i18n("Add custom file-filtering rules") );
mCustomFilteringRulesItem->setWhatsThis( i18n("Add custom file-filtering rules (-f, --filter=RULE). This option allows you to add rules to selectively exclude certain files from the list of files to be transferred.") );
- addItem( mCustomFilteringRulesItem, QString::fromLatin1( "CustomFilteringRules" ) );
- mUseFFilterRuleItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseFFilterRule" ), mUseFFilterRule, false );
+ addItem( mCustomFilteringRulesItem, TQString::tqfromLatin1( "CustomFilteringRules" ) );
+ mUseFFilterRuleItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseFFilterRule" ), mUseFFilterRule, false );
mUseFFilterRuleItem->setLabel( i18n("Use -F filter rule") );
mUseFFilterRuleItem->setWhatsThis( i18n("This filter rule tells rsync to look for per-directory .rsync-filter files that have been sprinkled through the hierarchy and use their rules to filter the files in the transfer. It has no effect, if you also choose to use the --filter='exclude .rsync-filter' rule.") );
- addItem( mUseFFilterRuleItem, QString::fromLatin1( "UseFFilterRule" ) );
- mUseFFFilterRuleItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseFFFilterRule" ), mUseFFFilterRule, false );
+ addItem( mUseFFilterRuleItem, TQString::tqfromLatin1( "UseFFilterRule" ) );
+ mUseFFFilterRuleItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseFFFilterRule" ), mUseFFFilterRule, false );
mUseFFFilterRuleItem->setLabel( i18n("Use -FF filter rule") );
mUseFFFilterRuleItem->setWhatsThis( i18n("This rule filters out the .rsync-filter files from the transfer. These files normally contain filter rules that can be activated by choosing the --filter='dir-merge /.rsync-filter' rule and deselecting this one.") );
- addItem( mUseFFFilterRuleItem, QString::fromLatin1( "UseFFFilterRule" ) );
- mEfficientSparseFileHandlingItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "EfficientSparseFileHandling" ), mEfficientSparseFileHandling, false );
+ addItem( mUseFFFilterRuleItem, TQString::tqfromLatin1( "UseFFFilterRule" ) );
+ mEfficientSparseFileHandlingItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "EfficientSparseFileHandling" ), mEfficientSparseFileHandling, false );
mEfficientSparseFileHandlingItem->setLabel( i18n("Handle sparse files efficiently") );
mEfficientSparseFileHandlingItem->setWhatsThis( i18n("Handle sparse files efficiently (-S, --sparse) so that they take up less space on the destination. This option conflicts with --inplace. For further information read rsync's manual page.") );
- addItem( mEfficientSparseFileHandlingItem, QString::fromLatin1( "EfficientSparseFileHandling" ) );
- mCopyFilesWholeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "CopyFilesWhole" ), mCopyFilesWhole, false );
+ addItem( mEfficientSparseFileHandlingItem, TQString::tqfromLatin1( "EfficientSparseFileHandling" ) );
+ mCopyFilesWholeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "CopyFilesWhole" ), mCopyFilesWhole, false );
mCopyFilesWholeItem->setLabel( i18n("Copy files whole (no rsync algorithm)") );
mCopyFilesWholeItem->setWhatsThis( i18n("Copy files whole (-W, --whole-file). With this option the incremental rsync algorithm is not used and the whole file is sent as-is instead.") );
- addItem( mCopyFilesWholeItem, QString::fromLatin1( "CopyFilesWhole" ) );
- mOneFileSystemItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "OneFileSystem" ), mOneFileSystem, false );
+ addItem( mCopyFilesWholeItem, TQString::tqfromLatin1( "CopyFilesWhole" ) );
+ mOneFileSystemItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "OneFileSystem" ), mOneFileSystem, false );
mOneFileSystemItem->setLabel( i18n("Do not cross file system boundaries") );
mOneFileSystemItem->setWhatsThis( i18n("Do not cross file system boundaries (-x, --one-file-system). This tells rsync to avoid crossing a filesystem boundary when recursing. For further information on this option, read the manual page.") );
- addItem( mOneFileSystemItem, QString::fromLatin1( "OneFileSystem" ) );
- mUpdateExistingItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UpdateExisting" ), mUpdateExisting, false );
+ addItem( mOneFileSystemItem, TQString::tqfromLatin1( "OneFileSystem" ) );
+ mUpdateExistingItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UpdateExisting" ), mUpdateExisting, false );
mUpdateExistingItem->setLabel( i18n("Skip creating new files on the receiving side") );
mUpdateExistingItem->setWhatsThis( i18n("Skip creating new files on the receiving side (--existing). This tells rsync to skip creating files (including directories) that do not exist yet on the destination. If this option is combined with the --ignore-existing option, no files will be updated (which can be useful if all you want to do is to delete extraneous files).") );
- addItem( mUpdateExistingItem, QString::fromLatin1( "UpdateExisting" ) );
- mIgnoreExistingItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "IgnoreExisting" ), mIgnoreExisting, false );
+ addItem( mUpdateExistingItem, TQString::tqfromLatin1( "UpdateExisting" ) );
+ mIgnoreExistingItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "IgnoreExisting" ), mIgnoreExisting, false );
mIgnoreExistingItem->setLabel( i18n("Skip updating files that exist on the receiving side") );
mIgnoreExistingItem->setWhatsThis( i18n("Skip updating files that already exist on the receiving side (--ignore-existing). Existing directories are not ignored.") );
- addItem( mIgnoreExistingItem, QString::fromLatin1( "IgnoreExisting" ) );
- mDelayUpdatesItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "DelayUpdates" ), mDelayUpdates, false );
+ addItem( mIgnoreExistingItem, TQString::tqfromLatin1( "IgnoreExisting" ) );
+ mDelayUpdatesItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "DelayUpdates" ), mDelayUpdates, false );
mDelayUpdatesItem->setLabel( i18n("Delay updates until the end of the transfer") );
mDelayUpdatesItem->setWhatsThis( i18n("Delay updates until the end of the transfer (--delay-updates). This option puts the temporary file from each updated file into a holding directory until the end of the transfer, at which time all the files are renamed and copied into place in rapid succession.") );
- addItem( mDelayUpdatesItem, QString::fromLatin1( "DelayUpdates" ) );
- mMakeBackupsItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "MakeBackups" ), mMakeBackups, false );
+ addItem( mDelayUpdatesItem, TQString::tqfromLatin1( "DelayUpdates" ) );
+ mMakeBackupsItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "MakeBackups" ), mMakeBackups, false );
mMakeBackupsItem->setLabel( i18n("Make backups") );
mMakeBackupsItem->setWhatsThis( i18n("Make backups (-b, --backup). With this option, preexisting destination files are renamed as each file is transferred or deleted. You can control where the backup file goes and what (if any) suffix gets appended using the --backup-dir=DIR and --suffix=SUFFIX options.") );
- addItem( mMakeBackupsItem, QString::fromLatin1( "MakeBackups" ) );
- mUseBackupSuffixItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseBackupSuffix" ), mUseBackupSuffix, false );
+ addItem( mMakeBackupsItem, TQString::tqfromLatin1( "MakeBackups" ) );
+ mUseBackupSuffixItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseBackupSuffix" ), mUseBackupSuffix, false );
mUseBackupSuffixItem->setLabel( i18n("Use a suffix for backups") );
mUseBackupSuffixItem->setWhatsThis( i18n("Use this suffix for backups (--suffix=SUFFIX).") );
- addItem( mUseBackupSuffixItem, QString::fromLatin1( "UseBackupSuffix" ) );
- mBackupSuffixItem = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "BackupSuffix" ), mBackupSuffix, QString::fromLatin1( "~" ) );
+ addItem( mUseBackupSuffixItem, TQString::tqfromLatin1( "UseBackupSuffix" ) );
+ mBackupSuffixItem = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "BackupSuffix" ), mBackupSuffix, TQString::tqfromLatin1( "~" ) );
mBackupSuffixItem->setLabel( i18n("Backup suffix") );
- addItem( mBackupSuffixItem, QString::fromLatin1( "BackupSuffix" ) );
- mUseBackupDirectoryItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseBackupDirectory" ), mUseBackupDirectory, false );
+ addItem( mBackupSuffixItem, TQString::tqfromLatin1( "BackupSuffix" ) );
+ mUseBackupDirectoryItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseBackupDirectory" ), mUseBackupDirectory, false );
mUseBackupDirectoryItem->setLabel( i18n("Put backups into a certain directory") );
mUseBackupDirectoryItem->setWhatsThis( i18n("Store backups in this directory (--backup-dir=DIR).") );
- addItem( mUseBackupDirectoryItem, QString::fromLatin1( "UseBackupDirectory" ) );
- mBackupDirectoryItem = new KConfigSkeleton::ItemPath( currentGroup(), QString::fromLatin1( "BackupDirectory" ), mBackupDirectory, QString::fromLatin1( "$HOME" ) );
+ addItem( mUseBackupDirectoryItem, TQString::tqfromLatin1( "UseBackupDirectory" ) );
+ mBackupDirectoryItem = new KConfigSkeleton::ItemPath( currentGroup(), TQString::tqfromLatin1( "BackupDirectory" ), mBackupDirectory, TQString::tqfromLatin1( "$HOME" ) );
mBackupDirectoryItem->setLabel( i18n("Backup directory") );
- addItem( mBackupDirectoryItem, QString::fromLatin1( "BackupDirectory" ) );
- mUseBlockSizeItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseBlockSize" ), mUseBlockSize, false );
+ addItem( mBackupDirectoryItem, TQString::tqfromLatin1( "BackupDirectory" ) );
+ mUseBlockSizeItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseBlockSize" ), mUseBlockSize, false );
mUseBlockSizeItem->setLabel( i18n("Force a fixed checksum block-size") );
mUseBlockSizeItem->setWhatsThis( i18n("Force a fixed checksum block-size (-B, --block-size=SIZE). This forces the block size used in the rsync algorithm to a fixed value.") );
- addItem( mUseBlockSizeItem, QString::fromLatin1( "UseBlockSize" ) );
- mBlockSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "BlockSize" ), mBlockSize, 0 );
+ addItem( mUseBlockSizeItem, TQString::tqfromLatin1( "UseBlockSize" ) );
+ mBlockSizeItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "BlockSize" ), mBlockSize, 0 );
mBlockSizeItem->setMinValue(0);
mBlockSizeItem->setLabel( i18n("The block size") );
- addItem( mBlockSizeItem, QString::fromLatin1( "BlockSize" ) );
- mUseChecksumSeedItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseChecksumSeed" ), mUseChecksumSeed, false );
+ addItem( mBlockSizeItem, TQString::tqfromLatin1( "BlockSize" ) );
+ mUseChecksumSeedItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseChecksumSeed" ), mUseChecksumSeed, false );
mUseChecksumSeedItem->setLabel( i18n("Set block/file checksum seed") );
mUseChecksumSeedItem->setWhatsThis( i18n("Set block/file checksum seed (--checksum-seed=NUM). Set the MD4 checksum seed to this integer. This 4 byte checksum seed is included in each block and file MD4 checksum calculation. By default the checksum seed is generated by the server and defaults to the current time.") );
- addItem( mUseChecksumSeedItem, QString::fromLatin1( "UseChecksumSeed" ) );
- mChecksumSeedItem = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "ChecksumSeed" ), mChecksumSeed, 0 );
+ addItem( mUseChecksumSeedItem, TQString::tqfromLatin1( "UseChecksumSeed" ) );
+ mChecksumSeedItem = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "ChecksumSeed" ), mChecksumSeed, 0 );
mChecksumSeedItem->setMinValue(0);
mChecksumSeedItem->setLabel( i18n("The checksum seed") );
- addItem( mChecksumSeedItem, QString::fromLatin1( "ChecksumSeed" ) );
- mUseChecksumItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseChecksum" ), mUseChecksum, false );
+ addItem( mChecksumSeedItem, TQString::tqfromLatin1( "ChecksumSeed" ) );
+ mUseChecksumItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseChecksum" ), mUseChecksum, false );
mUseChecksumItem->setLabel( i18n("Skip files based on a checksum") );
mUseChecksumItem->setWhatsThis( i18n("Skip files based on a checksum and not based on modification time and size (-c, --checksum). For further information on how this feature works read rsync's manual page.") );
- addItem( mUseChecksumItem, QString::fromLatin1( "UseChecksum" ) );
+ addItem( mUseChecksumItem, TQString::tqfromLatin1( "UseChecksum" ) );
- setCurrentGroup( QString::fromLatin1( "SuperUser" ) );
+ setCurrentGroup( TQString::tqfromLatin1( "SuperUser" ) );
- QValueList<KConfigSkeleton::ItemEnum::Choice> valuesSuperUserProgram;
+ TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesSuperUserProgram;
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "Sudo" );
+ choice.name = TQString::tqfromLatin1( "Sudo" );
valuesSuperUserProgram.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
- choice.name = QString::fromLatin1( "Super" );
+ choice.name = TQString::tqfromLatin1( "Super" );
valuesSuperUserProgram.append( choice );
}
- mSuperUserProgramItem = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "SuperUserProgram" ), mSuperUserProgram, valuesSuperUserProgram, EnumSuperUserProgram::Sudo );
+ mSuperUserProgramItem = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "SuperUserProgram" ), mSuperUserProgram, valuesSuperUserProgram, EnumSuperUserProgram::Sudo );
mSuperUserProgramItem->setLabel( i18n("The program that should be used to gain super user privileges") );
mSuperUserProgramItem->setWhatsThis( i18n("Choose the program that will grant you limited super user privileges for mounting and unmounting remote shares. You can either select sudo, the standard tool for this purpose on most distributions, or super.") );
- addItem( mSuperUserProgramItem, QString::fromLatin1( "SuperUserProgram" ) );
- mUseForceUnmountItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "UseForceUnmount" ), mUseForceUnmount, false );
+ addItem( mSuperUserProgramItem, TQString::tqfromLatin1( "SuperUserProgram" ) );
+ mUseForceUnmountItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "UseForceUnmount" ), mUseForceUnmount, false );
mUseForceUnmountItem->setLabel( i18n("Use super user privileges to unmount inaccessible shares") );
mUseForceUnmountItem->setWhatsThis( i18n("Unmount a share under Linux by force. This even works if the file system is \"busy\", because it is immediately detached from the file system hierarchy and all references to it are cleaned up later when it is not busy anymore. Linux kernel 2.4.11 or later is needed to take advantage of this feature. Use with case! Note, that you will need the root password to write the necessary changes to the configuration file.") );
- addItem( mUseForceUnmountItem, QString::fromLatin1( "UseForceUnmount" ) );
- mAlwaysUseSuperUserItem = new KConfigSkeleton::ItemBool( currentGroup(), QString::fromLatin1( "AlwaysUseSuperUser" ), mAlwaysUseSuperUser, false );
+ addItem( mUseForceUnmountItem, TQString::tqfromLatin1( "UseForceUnmount" ) );
+ mAlwaysUseSuperUserItem = new KConfigSkeleton::ItemBool( currentGroup(), TQString::tqfromLatin1( "AlwaysUseSuperUser" ), mAlwaysUseSuperUser, false );
mAlwaysUseSuperUserItem->setLabel( i18n("Use super user privileges to mount and unmount shares") );
mAlwaysUseSuperUserItem->setWhatsThis( i18n("Use super user privileges for mounting and unmounting remote shares. This feature is only needed, if you are not allowed to use smbmount, smbumount, mount.cifs and umount.cifs as normal user. Note, that you will need the root password to write the necessary changes to the configuration file.") );
- addItem( mAlwaysUseSuperUserItem, QString::fromLatin1( "AlwaysUseSuperUser" ) );
+ addItem( mAlwaysUseSuperUserItem, TQString::tqfromLatin1( "AlwaysUseSuperUser" ) );
}
Smb4KSettings::~Smb4KSettings()
diff --git a/smb4k/core/smb4kshare.cpp b/smb4k/core/smb4kshare.cpp
index 7877171..d1798de 100644
--- a/smb4k/core/smb4kshare.cpp
+++ b/smb4k/core/smb4kshare.cpp
@@ -26,8 +26,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qdir.h>
+// TQt includes
+#include <tqdir.h>
// KDE includes
#include <kdebug.h>
@@ -40,8 +40,8 @@
#include "smb4kshare.h"
-Smb4KShare::Smb4KShare( const QString &name, const QString &path, const QString &filesystem, const int uid, const int gid, bool broken ) :
-m_name(name), m_path( path.local8Bit() ), m_filesystem( filesystem ), m_user( uid ), m_group( gid ), m_cifs_login( QString::null ), m_broken( broken ), m_total( 0 ), m_free( 0 )
+Smb4KShare::Smb4KShare( const TQString &name, const TQString &path, const TQString &filesystem, const int uid, const int gid, bool broken ) :
+m_name(name), m_path( path.local8Bit() ), m_filesystem( filesystem ), m_user( uid ), m_group( gid ), m_cifs_login( TQString() ), m_broken( broken ), m_total( 0 ), m_free( 0 )
{
//FIXME should throw an exception if one of the param is empty
@@ -56,7 +56,7 @@ m_name(name), m_path( path.local8Bit() ), m_filesystem( filesystem ), m_user( ui
}
-Smb4KShare::Smb4KShare( const QString &name, const QString &path, const QString &filesystem, const QString &username, bool foreign, bool broken ) :
+Smb4KShare::Smb4KShare( const TQString &name, const TQString &path, const TQString &filesystem, const TQString &username, bool foreign, bool broken ) :
m_name( name ), m_path( path.local8Bit() ), m_filesystem( filesystem ), m_user( (int)getuid() ), m_group( (int)getgid() ), m_cifs_login( username ), m_foreign_mount( foreign ), m_broken( broken ), m_total( 0 ), m_free( 0 )
{
}
@@ -74,21 +74,21 @@ Smb4KShare::~Smb4KShare()
-const QString &Smb4KShare::name() const
+const TQString &Smb4KShare::name() const
{
return m_name;
}
-const QCString &Smb4KShare::path() const
+const TQCString &Smb4KShare::path() const
{
return m_path;
}
-const QCString Smb4KShare::canonicalPath() const
+const TQCString Smb4KShare::canonicalPath() const
{
- return m_broken ? m_path : QDir( m_path ).canonicalPath().local8Bit();
+ return m_broken ? m_path : TQDir( m_path ).canonicalPath().local8Bit();
}
@@ -116,25 +116,25 @@ void Smb4KShare::setGID( int gid )
}
-const QString Smb4KShare::user() const
+const TQString Smb4KShare::user() const
{
return m_user.loginName();
}
-const QString Smb4KShare::group() const
+const TQString Smb4KShare::group() const
{
return m_group.name();
}
-const QString &Smb4KShare::filesystem() const
+const TQString &Smb4KShare::filesystem() const
{
return m_filesystem;
}
-const QString &Smb4KShare::cifsLogin() const
+const TQString &Smb4KShare::cifsLogin() const
{
return m_cifs_login;
}
@@ -198,10 +198,10 @@ bool Smb4KShare::equals( const Smb4KShare &share )
{
bool equal = false;
- if ( QString::compare( m_name, share.name() ) == 0 &&
- QString::compare( m_path, share.path() ) == 0 &&
- QString::compare( m_filesystem, share.filesystem() ) == 0 &&
- QString::compare( m_cifs_login, share.cifsLogin() ) == 0 &&
+ if ( TQString::compare( m_name, share.name() ) == 0 &&
+ TQString::compare( m_path, share.path() ) == 0 &&
+ TQString::compare( m_filesystem, share.filesystem() ) == 0 &&
+ TQString::compare( m_cifs_login, share.cifsLogin() ) == 0 &&
(int)m_user.uid() == share.uid() &&
(int)m_group.gid() == share.gid() &&
m_broken == share.isBroken() &&
diff --git a/smb4k/core/smb4kshare.h b/smb4k/core/smb4kshare.h
index 40c8c47..2c8ee5b 100644
--- a/smb4k/core/smb4kshare.h
+++ b/smb4k/core/smb4kshare.h
@@ -33,9 +33,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qstring.h>
-#include <qcstring.h>
+// TQt includes
+#include <tqstring.h>
+#include <tqcstring.h>
// KDE includes
#include <kuser.h>
@@ -68,7 +68,7 @@ class Smb4KShare
*
* @param broken Determines whether the share is broken. "Broken" means that the share is unaccessible.
*/
- Smb4KShare( const QString &name, const QString &path, const QString &filesystem, const int uid = 0, const int gid = 0, bool broken = false );
+ Smb4KShare( const TQString &name, const TQString &path, const TQString &filesystem, const int uid = 0, const int gid = 0, bool broken = false );
/**
* The constructor for CIFS shares. It does not take the UID and GID, but the
@@ -86,7 +86,7 @@ class Smb4KShare
*
* @param broken Determines whether the share is broken. "Broken" means that the share is unaccessible.
*/
- Smb4KShare( const QString &name, const QString &path, const QString &filesystem, const QString &username, bool foreign = false, bool broken = false );
+ Smb4KShare( const TQString &name, const TQString &path, const TQString &filesystem, const TQString &username, bool foreign = false, bool broken = false );
/**
* Empty constructor.
@@ -110,7 +110,7 @@ class Smb4KShare
*
* @returns The name of the share.
*/
- const QString &name() const;
+ const TQString &name() const;
/**
* Returns the mount point aka path of the share as it has been gathered
@@ -118,7 +118,7 @@ class Smb4KShare
*
* @returns The path of the share.
*/
- const QCString &path() const;
+ const TQCString &path() const;
/**
* This function returns the canonical path of the share. In contrast to
@@ -128,7 +128,7 @@ class Smb4KShare
*
* @returns Returns the canonical path of the share.
*/
- const QCString canonicalPath() const;
+ const TQCString canonicalPath() const;
/**
* Returns the UID of the mounted share.
@@ -157,22 +157,22 @@ class Smb4KShare
/**
* Returns the name of the user of the share.
*/
- const QString user() const;
+ const TQString user() const;
/**
* Returns the name of the group of the share.
*/
- const QString group() const;
+ const TQString group() const;
/**
* Returns the file system of the share.
*/
- const QString &filesystem() const;
+ const TQString &filesystem() const;
/**
* Returns the CIFS login (user name).
*/
- const QString &cifsLogin() const;
+ const TQString &cifsLogin() const;
/**
* Is TRUE if the share is/seems to be mounted by another
@@ -256,17 +256,17 @@ class Smb4KShare
/**
* The name of the share.
*/
- QString m_name;
+ TQString m_name;
/**
* The mount point / path of the share
*/
- QCString m_path;
+ TQCString m_path;
/**
* The filesystem string
*/
- QString m_filesystem;
+ TQString m_filesystem;
/**
* The user ID of the share.
@@ -281,7 +281,7 @@ class Smb4KShare
/**
* The CIFS login name
*/
- QString m_cifs_login;
+ TQString m_cifs_login;
bool m_foreign_mount;
bool m_broken;
double m_total;
diff --git a/smb4k/core/smb4ksynchronizationinfo.cpp b/smb4k/core/smb4ksynchronizationinfo.cpp
index 072014f..0d5a230 100644
--- a/smb4k/core/smb4ksynchronizationinfo.cpp
+++ b/smb4k/core/smb4ksynchronizationinfo.cpp
@@ -28,9 +28,9 @@
#include "smb4ksynchronizationinfo.h"
-Smb4KSynchronizationInfo::Smb4KSynchronizationInfo() : m_text( QString::null ),
+Smb4KSynchronizationInfo::Smb4KSynchronizationInfo() : m_text( TQString() ),
m_individual_progress( -1 ), m_total_progress( -1 ), m_total_files( -1 ),
-m_processed_files( -1 ), m_rate( QString::null )
+m_processed_files( -1 ), m_rate( TQString() )
{
}
@@ -40,7 +40,7 @@ Smb4KSynchronizationInfo::~Smb4KSynchronizationInfo()
}
-void Smb4KSynchronizationInfo::setText( const QString &text )
+void Smb4KSynchronizationInfo::setText( const TQString &text )
{
m_text = text;
}
@@ -70,7 +70,7 @@ void Smb4KSynchronizationInfo::setProcessedFileNumber( int processed )
}
-void Smb4KSynchronizationInfo::setTransferRate( const QString &rate )
+void Smb4KSynchronizationInfo::setTransferRate( const TQString &rate )
{
m_rate = rate;
}
diff --git a/smb4k/core/smb4ksynchronizationinfo.h b/smb4k/core/smb4ksynchronizationinfo.h
index f254dd1..72f2ad9 100644
--- a/smb4k/core/smb4ksynchronizationinfo.h
+++ b/smb4k/core/smb4ksynchronizationinfo.h
@@ -27,8 +27,8 @@
#ifndef SMB4KSYNCHRONIZATIONINFO_H
#define SMB4KSYNCHRONIZATIONINFO_H
-// Qt includes
-#include <qstring.h>
+// TQt includes
+#include <tqstring.h>
class Smb4KSynchronizationInfo
{
@@ -50,7 +50,7 @@ class Smb4KSynchronizationInfo
*
* @param text The text
*/
- void setText( const QString &text );
+ void setText( const TQString &text );
/**
* Return the name of the file that is currently processed. This may
@@ -59,7 +59,7 @@ class Smb4KSynchronizationInfo
* @returns the name of the file that is currently processed or an empty
* string
*/
- const QString &text () const { return m_text; }
+ const TQString &text () const { return m_text; }
/**
* Set the progress of the file that's currently processed.
@@ -124,12 +124,12 @@ class Smb4KSynchronizationInfo
const int processedFileNumber() const { return m_processed_files; }
/**
- * Set the transfer rate. This should be a string that already contains
+ * Set the transfer rate. This should be a string that already tqcontains
* all information, i.e. the string should look like this: 100 kB/s.
*
* @param rate The rate string (e.g. 100 kB/s)
*/
- void setTransferRate( const QString &rate );
+ void setTransferRate( const TQString &rate );
/**
* Return the transfer rate. This is a string that already contains all
@@ -139,13 +139,13 @@ class Smb4KSynchronizationInfo
*
* @returns The rate or an empty string.
*/
- const QString &transferRate() const { return m_rate; }
+ const TQString &transferRate() const { return m_rate; }
private:
/**
* The text
*/
- QString m_text;
+ TQString m_text;
/**
* The individual progress
@@ -170,7 +170,7 @@ class Smb4KSynchronizationInfo
/**
* The rate string
*/
- QString m_rate;
+ TQString m_rate;
};
#endif
diff --git a/smb4k/core/smb4ksynchronizer.cpp b/smb4k/core/smb4ksynchronizer.cpp
index 21ac788..8333e0f 100644
--- a/smb4k/core/smb4ksynchronizer.cpp
+++ b/smb4k/core/smb4ksynchronizer.cpp
@@ -23,11 +23,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qdir.h>
-#include <qlabel.h>
-#include <qregexp.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqdir.h>
+#include <tqlabel.h>
+#include <tqregexp.h>
// KDE includes
#include <kmessagebox.h>
@@ -54,8 +54,8 @@ using namespace Smb4KGlobal;
bool cancel = false;
-Smb4KSynchronizer::Smb4KSynchronizer( QObject *parent, const char *name )
-: QObject( parent, name )
+Smb4KSynchronizer::Smb4KSynchronizer( TQObject *tqparent, const char *name )
+: TQObject( tqparent, name )
{
m_proc = new KProcess( this, "SynchronizerProcess" );
@@ -63,17 +63,17 @@ Smb4KSynchronizer::Smb4KSynchronizer( QObject *parent, const char *name )
m_working = false;
- connect( m_proc, SIGNAL( receivedStdout( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStdout( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStdout( KProcess *, char *, int ) ) );
- connect( m_proc, SIGNAL( processExited( KProcess* ) ),
- this, SLOT( slotProcessExited( KProcess * ) ) );
+ connect( m_proc, TQT_SIGNAL( processExited( KProcess* ) ),
+ this, TQT_SLOT( slotProcessExited( KProcess * ) ) );
- connect( m_proc, SIGNAL( receivedStderr( KProcess *, char *, int ) ),
- this, SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
+ connect( m_proc, TQT_SIGNAL( receivedStderr( KProcess *, char *, int ) ),
+ this, TQT_SLOT( slotReceivedStderr( KProcess *, char *, int ) ) );
- connect( kapp, SIGNAL( shutDown() ),
- this, SLOT( slotShutdown() ) );
+ connect( kapp, TQT_SIGNAL( shutDown() ),
+ this, TQT_SLOT( slotShutdown() ) );
}
@@ -86,7 +86,7 @@ Smb4KSynchronizer::~Smb4KSynchronizer()
Synchronizes a share with a local copy or vice versa.
****************************************************************************/
-void Smb4KSynchronizer::synchronize( const QString &source, const QString &destination )
+void Smb4KSynchronizer::synchronize( const TQString &source, const TQString &destination )
{
if ( Smb4KSettings::rsync().isEmpty() )
{
@@ -108,7 +108,7 @@ void Smb4KSynchronizer::synchronize( const QString &source, const QString &desti
// We will only define the stuff we urgently need
// here. The options that actually influence rsync's
// behavior will be retrieved by readRsyncOptions().
- QString command = "rsync --progress ";
+ TQString command = "rsync --progress ";
command.append( readRsyncOptions() );
command.append( " " );
@@ -129,9 +129,9 @@ void Smb4KSynchronizer::synchronize( const QString &source, const QString &desti
Reads the options that should be used with rsync
****************************************************************************/
-const QString Smb4KSynchronizer::readRsyncOptions()
+const TQString Smb4KSynchronizer::readRsyncOptions()
{
- QString options;
+ TQString options;
if ( Smb4KSettings::archiveMode() )
{
@@ -286,7 +286,7 @@ const QString Smb4KSynchronizer::readRsyncOptions()
}
options.append( Smb4KSettings::useMaximumDelete() ?
- " --max-delete="+QString( "%1" ).arg( Smb4KSettings::maximumDeleteValue() ) :
+ " --max-delete="+TQString( "%1" ).tqarg( Smb4KSettings::maximumDeleteValue() ) :
"" );
options.append( Smb4KSettings::useChecksum() ?
@@ -294,11 +294,11 @@ const QString Smb4KSynchronizer::readRsyncOptions()
"" );
options.append( Smb4KSettings::useBlockSize() ?
- " --block-size="+QString( "%1" ).arg( Smb4KSettings::blockSize() ) :
+ " --block-size="+TQString( "%1" ).tqarg( Smb4KSettings::blockSize() ) :
"" );
options.append( Smb4KSettings::useChecksumSeed() ?
- " --checksum-seed="+QString( "%1" ).arg( Smb4KSettings::checksumSeed() ) :
+ " --checksum-seed="+TQString( "%1" ).tqarg( Smb4KSettings::checksumSeed() ) :
"" );
if ( !Smb4KSettings::customFilteringRules().isEmpty() )
@@ -307,11 +307,11 @@ const QString Smb4KSynchronizer::readRsyncOptions()
}
options.append( Smb4KSettings::useMinimalTransferSize() ?
- " --min-size="+QString( "%1" ).arg( Smb4KSettings::minimalTransferSize() )+"K" :
+ " --min-size="+TQString( "%1" ).tqarg( Smb4KSettings::minimalTransferSize() )+"K" :
"" );
options.append( Smb4KSettings::useMaximalTransferSize() ?
- " --max-size="+QString( "%1" ).arg( Smb4KSettings::maximalTransferSize() )+"K" :
+ " --max-size="+TQString( "%1" ).tqarg( Smb4KSettings::maximalTransferSize() )+"K" :
"" );
if ( Smb4KSettings::keepPartial() )
@@ -356,7 +356,7 @@ const QString Smb4KSynchronizer::readRsyncOptions()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KSynchronizer::abort()
@@ -383,13 +383,13 @@ void Smb4KSynchronizer::slotProcessExited( KProcess * )
void Smb4KSynchronizer::slotReceivedStdout( KProcess *, char *buf, int len )
{
- m_buffer = QString::fromLocal8Bit( buf, len );
+ m_buffer = TQString::fromLocal8Bit( buf, len );
Smb4KSynchronizationInfo sync_info;
- QString partial, total, files, rate;
+ TQString partial, total, files, rate;
- if ( m_buffer[0].isSpace() && m_buffer.contains( "/s ", true ) > 0 )
+ if ( m_buffer[0].isSpace() && m_buffer.tqcontains( "/s ", true ) > 0 )
{
partial = m_buffer.section( "%", 0, 0 ).section( " ", -1, -1 ).stripWhiteSpace();
@@ -398,10 +398,10 @@ void Smb4KSynchronizer::slotReceivedStdout( KProcess *, char *buf, int len )
sync_info.setIndividualProgress( partial.toInt() );
}
- if ( m_buffer.contains( "to-check=" ) > 0 )
+ if ( m_buffer.tqcontains( "to-check=" ) > 0 )
{
// Newer versions of rsync:
- QString tmp = m_buffer.section( "to-check=", 1, 1 ).section( ")", 0, 0 ).stripWhiteSpace();
+ TQString tmp = m_buffer.section( "to-check=", 1, 1 ).section( ")", 0, 0 ).stripWhiteSpace();
if ( !tmp.isEmpty() )
{
@@ -409,7 +409,7 @@ void Smb4KSynchronizer::slotReceivedStdout( KProcess *, char *buf, int len )
double tmp_done = tmp.section( "/", 0, 0 ).stripWhiteSpace().toInt();
double tmp_percent = ((tmp_total-tmp_done)/tmp_total)*100;
- total = QString( "%1" ).arg( tmp_percent ).section( ".", 0, 0 ).stripWhiteSpace();
+ total = TQString( "%1" ).tqarg( tmp_percent ).section( ".", 0, 0 ).stripWhiteSpace();
}
}
else
@@ -423,7 +423,7 @@ void Smb4KSynchronizer::slotReceivedStdout( KProcess *, char *buf, int len )
sync_info.setTotalProgress( total.toInt() );
}
- if ( m_buffer.contains( "xfer#" ) > 0 )
+ if ( m_buffer.tqcontains( "xfer#" ) > 0 )
{
// Newer versions of rsync:
files = m_buffer.section( "xfer#", 1, 1 ).section( ",", 0, 0 ).stripWhiteSpace();
@@ -450,20 +450,20 @@ void Smb4KSynchronizer::slotReceivedStdout( KProcess *, char *buf, int len )
sync_info.setTransferRate( rate );
}
- m_buffer = QString::null;
+ m_buffer = TQString();
}
- else if ( !m_buffer[0].isSpace() && m_buffer.endsWith( "\n" ) && m_buffer.contains( "/s ", true ) == 0 )
+ else if ( !m_buffer[0].isSpace() && m_buffer.endsWith( "\n" ) && m_buffer.tqcontains( "/s ", true ) == 0 )
{
sync_info.setText( m_buffer.stripWhiteSpace() );
- if ( m_buffer.contains( "files to consider" ) != 0 )
+ if ( m_buffer.tqcontains( "files to consider" ) != 0 )
{
m_total_files = m_buffer.section( " files to consider", 0, 0 ).section( " ", -1, -1 ).stripWhiteSpace();
sync_info.setTotalFileNumber( m_total_files.toInt() );
}
- m_buffer = QString::null;
+ m_buffer = TQString();
}
emit progress( sync_info );
@@ -473,20 +473,20 @@ void Smb4KSynchronizer::slotReceivedStdout( KProcess *, char *buf, int len )
void Smb4KSynchronizer::slotReceivedStderr( KProcess *, char *buf, int len )
{
- QString error_message = QString::fromLocal8Bit( buf, len );
+ TQString error_message = TQString::fromLocal8Bit( buf, len );
// At least under Debian unstable (20051216), rsync emits an error
// when you kill the process (using SIGTERM). Pressing the cancel
// button will exactly do this. Thus, we need to exclude this occasion
// from here.
- if ( !cancel && error_message.contains( "rsync error:", true ) != 0 )
+ if ( !cancel && error_message.tqcontains( "rsync error:", true ) != 0 )
{
// Cancel the whole synchronization in case an error occurred.
// If we don't do it, the user might be flooded with error messages
// especially if you try to synchronize a local copy with a remote
// share that is mounted read-only.
abort();
- Smb4KError::error( ERROR_SYNCHRONIZING, QString::null, error_message );
+ Smb4KError::error( ERROR_SYNCHRONIZING, TQString(), error_message );
}
else
{
diff --git a/smb4k/core/smb4ksynchronizer.h b/smb4k/core/smb4ksynchronizer.h
index ecc279f..1bce096 100644
--- a/smb4k/core/smb4ksynchronizer.h
+++ b/smb4k/core/smb4ksynchronizer.h
@@ -34,9 +34,9 @@
#include <kprocess.h>
#include <kdialogbase.h>
-// Qt includes
-#include <qobject.h>
-#include <qstring.h>
+// TQt includes
+#include <tqobject.h>
+#include <tqstring.h>
// forward declarations
class Smb4KShare;
@@ -51,19 +51,20 @@ class Smb4KSynchronizationInfo;
*/
-class Smb4KSynchronizer : public QObject
+class Smb4KSynchronizer : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor of the synchronizer.
*
- * @param parent The parent of this object
+ * @param tqparent The tqparent of this object
*
* @param name The name of this object
*/
- Smb4KSynchronizer( QObject *parent = 0, const char *name = 0 );
+ Smb4KSynchronizer( TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -77,7 +78,7 @@ class Smb4KSynchronizer : public QObject
*
* @param destination The destination
*/
- void synchronize( const QString &source, const QString &destination );
+ void synchronize( const TQString &source, const TQString &destination );
/**
* This function reports if the synchronizer is running or not.
@@ -175,7 +176,7 @@ class Smb4KSynchronizer : public QObject
*
* @returns an option string
*/
- const QString readRsyncOptions();
+ const TQString readRsyncOptions();
/**
* The buffer for the output.
@@ -183,12 +184,12 @@ class Smb4KSynchronizer : public QObject
* NOTE: The buffer is not to contain error messages, that are received
* via slotReceivedStderr()!
*/
- QString m_buffer;
+ TQString m_buffer;
/**
* Total number of files to transfer
*/
- QString m_total_files;
+ TQString m_total_files;
};
#endif
diff --git a/smb4k/dialogs/smb4kbookmarkeditor.cpp b/smb4k/dialogs/smb4kbookmarkeditor.cpp
index b348e80..bec79e0 100644
--- a/smb4k/dialogs/smb4kbookmarkeditor.cpp
+++ b/smb4k/dialogs/smb4kbookmarkeditor.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qvaluelist.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqvaluelist.h>
// KDE includes
#include <klocale.h>
@@ -48,14 +48,14 @@
using namespace Smb4KGlobal;
-Smb4KBookmarkEditor::Smb4KBookmarkEditor( QWidget *parent, const char *name )
-: KDialogBase( Plain, i18n( "Bookmark Editor" ), Ok|Cancel, Ok, parent, name, true, true )
+Smb4KBookmarkEditor::Smb4KBookmarkEditor( TQWidget *tqparent, const char *name )
+: KDialogBase( Plain, i18n( "Bookmark Editor" ), Ok|Cancel, Ok, tqparent, name, true, true )
{
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
- QFrame *frame = plainPage();
- QGridLayout *layout = new QGridLayout( frame );
- layout->setSpacing( 5 );
+ TQFrame *frame = plainPage();
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
+ tqlayout->setSpacing( 5 );
m_view = new KListView( frame );
m_view->addColumn( i18n( "Bookmark" ), Bookmark );
@@ -71,31 +71,31 @@ Smb4KBookmarkEditor::Smb4KBookmarkEditor( QWidget *parent, const char *name )
m_collection = new KActionCollection( this, "BookmarkEditor_ActionCollection", KGlobal::instance() );
- (void) new KAction( i18n( "&Remove" ), "remove", Key_Delete, this, SLOT( slotRemoveClicked() ), m_collection, "remove_bookmark" );
+ (void) new KAction( i18n( "&Remove" ), "remove", Key_Delete, TQT_TQOBJECT(this), TQT_SLOT( slotRemoveClicked() ), m_collection, "remove_bookmark" );
- (void) new KAction( i18n( "Remove &All" ), "editdelete", CTRL+Key_X, this, SLOT( slotDeleteAllClicked() ), m_collection, "remove_all_bookmarks" );
+ (void) new KAction( i18n( "Remove &All" ), "editdelete", CTRL+Key_X, TQT_TQOBJECT(this), TQT_SLOT( slotDeleteAllClicked() ), m_collection, "remove_all_bookmarks" );
slotLoadBookmarks();
- layout->addWidget( m_view, 0, 0, 0 );
+ tqlayout->addWidget( m_view, 0, 0, 0 );
setInitialSize( configDialogSize( *(Smb4KSettings::self()->config()), "BookmarkEditor" ) );
- setMinimumSize( (sizeHint().width() > 350 ? sizeHint().width() : 350), sizeHint().height() );
+ setMinimumSize( (tqsizeHint().width() > 350 ? tqsizeHint().width() : 350), tqsizeHint().height() );
- connect( m_view, SIGNAL( rightButtonPressed( QListViewItem *, const QPoint &, int ) ),
- this, SLOT( slotRightButtonPressed( QListViewItem *, const QPoint &, int ) ) );
+ connect( m_view, TQT_SIGNAL( rightButtonPressed( TQListViewItem *, const TQPoint &, int ) ),
+ this, TQT_SLOT( slotRightButtonPressed( TQListViewItem *, const TQPoint &, int ) ) );
- connect( m_view, SIGNAL( itemRenamed( QListViewItem * ) ),
- this, SLOT( slotItemRenamed( QListViewItem * ) ) );
+ connect( m_view, TQT_SIGNAL( itemRenamed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemRenamed( TQListViewItem * ) ) );
- connect( this, SIGNAL( okClicked() ),
- this, SLOT( slotOkClicked() ) );
+ connect( this, TQT_SIGNAL( okClicked() ),
+ this, TQT_SLOT( slotOkClicked() ) );
- connect( this, SIGNAL( cancelClicked() ),
- this, SLOT( slotCancelClicked() ) );
+ connect( this, TQT_SIGNAL( cancelClicked() ),
+ this, TQT_SLOT( slotCancelClicked() ) );
- connect( Smb4KCore::bookmarkHandler(), SIGNAL( bookmarksUpdated() ),
- this, SLOT( slotLoadBookmarks() ) );
+ connect( Smb4KCore::bookmarkHandler(), TQT_SIGNAL( bookmarksUpdated() ),
+ this, TQT_SLOT( slotLoadBookmarks() ) );
}
@@ -113,10 +113,10 @@ Smb4KBookmarkEditor::~Smb4KBookmarkEditor()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
-void Smb4KBookmarkEditor::slotRightButtonPressed( QListViewItem *item, const QPoint &pos, int )
+void Smb4KBookmarkEditor::slotRightButtonPressed( TQListViewItem *item, const TQPoint &pos, int )
{
if ( !item )
{
@@ -140,7 +140,7 @@ void Smb4KBookmarkEditor::slotRightButtonPressed( QListViewItem *item, const QPo
if ( !menu )
{
- menu = new KActionMenu( this, "BookmarkEditorPopupMenu" );
+ menu = new KActionMenu( TQT_TQOBJECT(this), "BookmarkEditorPopupMenu" );
menu->insert( m_collection->action( "remove_bookmark" ) );
menu->insert( m_collection->action( "remove_all_bookmarks" ) );
}
@@ -185,11 +185,11 @@ void Smb4KBookmarkEditor::slotOkClicked()
delete *it;
}
- QValueList<Smb4KBookmark *> bookmarks;
+ TQValueList<Smb4KBookmark *> bookmarks;
if ( m_view->childCount() != 0 )
{
- QListViewItemIterator it( m_view );
+ TQListViewItemIterator it( m_view );
while( it.current() )
{
@@ -226,9 +226,9 @@ void Smb4KBookmarkEditor::slotLoadBookmarks()
{
m_view->clear();
- QValueList<Smb4KBookmark *> bookmarks = Smb4KCore::bookmarkHandler()->getBookmarks();
+ TQValueList<Smb4KBookmark *> bookmarks = Smb4KCore::bookmarkHandler()->getBookmarks();
- for ( QValueList<Smb4KBookmark *>::ConstIterator it = bookmarks.begin(); it != bookmarks.end(); ++it )
+ for ( TQValueList<Smb4KBookmark *>::ConstIterator it = bookmarks.begin(); it != bookmarks.end(); ++it )
{
KListViewItem *item = new KListViewItem( m_view );
item->setText( Bookmark, (*it)->bookmark() );
@@ -246,7 +246,7 @@ void Smb4KBookmarkEditor::slotLoadBookmarks()
}
-void Smb4KBookmarkEditor::slotItemRenamed( QListViewItem * )
+void Smb4KBookmarkEditor::slotItemRenamed( TQListViewItem * )
{
// Adjust the columns:
for ( int col = 0; col < m_view->columns(); col++ )
diff --git a/smb4k/dialogs/smb4kbookmarkeditor.h b/smb4k/dialogs/smb4kbookmarkeditor.h
index 8184c0c..5d0f59a 100644
--- a/smb4k/dialogs/smb4kbookmarkeditor.h
+++ b/smb4k/dialogs/smb4kbookmarkeditor.h
@@ -44,16 +44,17 @@
class Smb4KBookmarkEditor : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent of this dialog.
+ * @param tqparent The tqparent of this dialog.
*
* @param name The name of this dialog.
*/
- Smb4KBookmarkEditor( QWidget *parent = 0, const char *name = 0 );
+ Smb4KBookmarkEditor( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -82,7 +83,7 @@ class Smb4KBookmarkEditor : public KDialogBase
*
* @param col The column of the list view item.
*/
- void slotRightButtonPressed ( QListViewItem *item, const QPoint &pos, int col );
+ void slotRightButtonPressed ( TQListViewItem *item, const TQPoint &pos, int col );
/**
* This slot is activated whenever the remove button of the
@@ -116,7 +117,7 @@ class Smb4KBookmarkEditor : public KDialogBase
*
* @param item The item that was renamed.
*/
- void slotItemRenamed( QListViewItem *item );
+ void slotItemRenamed( TQListViewItem *item );
private:
/**
diff --git a/smb4k/dialogs/smb4kcustomoptionsdialog.cpp b/smb4k/dialogs/smb4kcustomoptionsdialog.cpp
index 6d8609b..aa8a9fc 100644
--- a/smb4k/dialogs/smb4kcustomoptionsdialog.cpp
+++ b/smb4k/dialogs/smb4kcustomoptionsdialog.cpp
@@ -24,10 +24,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qframe.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqframe.h>
// KDE includes
#include <klocale.h>
@@ -49,22 +49,22 @@ using namespace Smb4KGlobal;
// FIXME: Maybe introduce a private class here?
static int default_port = -1;
-static QString default_protocol = QString::null;
+static TQString default_protocol = TQString();
static bool default_kerberos = false;
-static QString default_uid = QString::null;
-static QString default_gid = QString::null;
+static TQString default_uid = TQString();
+static TQString default_gid = TQString();
#ifndef __FreeBSD__
-static QString default_filesystem = QString::null;
+static TQString default_filesystem = TQString();
static bool default_readwrite = true;
#endif
static int port_value = -1;
-static QString protocol_value = QString::null;
+static TQString protocol_value = TQString();
static bool kerberos_value = false;
-static QString uid_value = QString::null;
-static QString gid_value = QString::null;
+static TQString uid_value = TQString();
+static TQString gid_value = TQString();
#ifndef __FreeBSD__
-static QString filesystem_value = QString::null;
+static TQString filesystem_value = TQString();
static bool readwrite_value = true;
#endif
@@ -89,23 +89,23 @@ static bool readwrite_changed_default = false;
#endif
-Smb4KCustomOptionsDialog::Smb4KCustomOptionsDialog( Smb4KHostItem *host, QWidget *parent, const char *name )
-: KDialogBase( Plain, i18n( "Custom Options" ), User1|Ok|Cancel, Ok, parent, name, true, true ), m_type( Host ), m_host_item( host ), m_share_item( NULL ), m_homes_user( QString::null )
+Smb4KCustomOptionsDialog::Smb4KCustomOptionsDialog( Smb4KHostItem *host, TQWidget *tqparent, const char *name )
+: KDialogBase( Plain, i18n( "Custom Options" ), User1|Ok|Cancel, Ok, tqparent, name, true, true ), m_type( Host ), m_host_item( host ), m_share_item( NULL ), m_homes_user( TQString() )
{
m_initialized = true;
setButtonGuiItem( User1, KStdGuiItem::defaults() );
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
setupDialog();
}
-Smb4KCustomOptionsDialog::Smb4KCustomOptionsDialog( Smb4KShareItem *share, QWidget *parent, const char *name )
-: KDialogBase( Plain, i18n( "Custom Options" ), User1|Ok|Cancel, Ok, parent, name, true, true ), m_type( Share ), m_host_item( NULL ), m_share_item( share ), m_homes_user( QString::null )
+Smb4KCustomOptionsDialog::Smb4KCustomOptionsDialog( Smb4KShareItem *share, TQWidget *tqparent, const char *name )
+: KDialogBase( Plain, i18n( "Custom Options" ), User1|Ok|Cancel, Ok, tqparent, name, true, true ), m_type( Share ), m_host_item( NULL ), m_share_item( share ), m_homes_user( TQString() )
{
- if ( QString::compare( share->name(), "homes" ) != 0 )
+ if ( TQString::compare( share->name(), "homes" ) != 0 )
{
m_initialized = true;
}
@@ -117,7 +117,7 @@ Smb4KCustomOptionsDialog::Smb4KCustomOptionsDialog( Smb4KShareItem *share, QWidg
setButtonGuiItem( User1, KStdGuiItem::defaults() );
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
setupDialog();
}
@@ -149,32 +149,32 @@ void Smb4KCustomOptionsDialog::setupDialog()
#endif
// Set-up the widget:
- QFrame *frame = plainPage();
+ TQFrame *frame = plainPage();
- QGridLayout *grid = new QGridLayout( frame );
+ TQGridLayout *grid = new TQGridLayout( frame );
grid->setSpacing( 5 );
grid->setMargin( 0 );
// The following widgets are independent of the type of
// the network item:
- QLabel *location_label = new QLabel( m_type == Host ? i18n( "Host:" ) : i18n( "Share:" ), frame );
- KLineEdit *location = new KLineEdit( m_type == Host ? m_host_item->name() : "//"+m_share_item->host()+"/"+(QString::compare( m_share_item->name(), "homes" ) != 0 ? m_share_item->name() : m_homes_user), frame );
+ TQLabel *location_label = new TQLabel( m_type == Host ? i18n( "Host:" ) : i18n( "Share:" ), frame );
+ KLineEdit *location = new KLineEdit( m_type == Host ? m_host_item->name() : "//"+m_share_item->host()+"/"+(TQString::compare( m_share_item->name(), "homes" ) != 0 ? m_share_item->name() : m_homes_user), frame );
location->setReadOnly( true );
- QLabel *port_label = new QLabel( i18n( "Port:" ), frame );
+ TQLabel *port_label = new TQLabel( i18n( "Port:" ), frame );
m_port_input = new KIntNumInput( -1, frame );
m_port_input->setMinimumWidth( 200 );
m_port_input->setMinValue( -1 );
m_port_input->setMaxValue( 65535 );
- // The widgets will be put into the layout below.
+ // The widgets will be put into the tqlayout below.
// Here comes the item-dependent stuff:
switch ( m_type )
{
case Host:
{
- QLabel *protocol_label = new QLabel( i18n( "Protocol:" ), frame );
+ TQLabel *protocol_label = new TQLabel( i18n( "Protocol:" ), frame );
m_proto_input = new KComboBox( false, frame );
m_proto_input->setMinimumWidth( 200 );
m_proto_input->insertItem( i18n( "auto" ), -1 );
@@ -182,7 +182,7 @@ void Smb4KCustomOptionsDialog::setupDialog()
m_proto_input->insertItem( "RAP", -1 );
m_proto_input->insertItem( "ADS", -1 );
- m_kerberos = new QCheckBox( i18n( "Try to authenticate with Kerberos (Active Directory)" ), frame );
+ m_kerberos = new TQCheckBox( i18n( "Try to authenticate with Kerberos (Active Directory)" ), frame );
grid->addWidget( location_label, 0, 0, 0 );
grid->addWidget( location, 0, 1, 0 );
@@ -229,7 +229,7 @@ void Smb4KCustomOptionsDialog::setupDialog()
}
default:
{
- default_protocol = QString::null;
+ default_protocol = TQString();
break;
}
@@ -250,55 +250,55 @@ void Smb4KCustomOptionsDialog::setupDialog()
// Put the values in the widgets:
m_port_input->setValue( port_value );
- m_proto_input->setCurrentText( (QString::compare( protocol_value, "auto" ) == 0 ? i18n( "auto" ) : protocol_value.upper()) );
+ m_proto_input->setCurrentText( (TQString::compare( protocol_value, "auto" ) == 0 ? i18n( "auto" ) : protocol_value.upper()) );
m_kerberos->setChecked( kerberos_value );
// Does the 'Default' button need to be enabled?
if ( default_port != port_value ||
- QString::compare( default_protocol, protocol_value ) != 0 ||
+ TQString::compare( default_protocol, protocol_value ) != 0 ||
default_kerberos != kerberos_value )
{
enable_default_button = true;
}
// Connections:
- connect( m_port_input, SIGNAL( valueChanged( int ) ),
- this, SLOT( slotPortChanged( int ) ) );
+ connect( m_port_input, TQT_SIGNAL( valueChanged( int ) ),
+ this, TQT_SLOT( slotPortChanged( int ) ) );
- connect( m_kerberos, SIGNAL( toggled( bool ) ),
- this, SLOT( slotKerberosToggled( bool ) ) );
+ connect( m_kerberos, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotKerberosToggled( bool ) ) );
- connect( m_proto_input, SIGNAL( activated( const QString & ) ),
- this, SLOT( slotProtocolChanged( const QString & ) ) );
+ connect( m_proto_input, TQT_SIGNAL( activated( const TQString & ) ),
+ this, TQT_SLOT( slotProtocolChanged( const TQString & ) ) );
break;
}
case Share:
{
#ifndef __FreeBSD__
- QLabel *filesystem_label = new QLabel( i18n( "File system:" ), frame );
+ TQLabel *filesystem_label = new TQLabel( i18n( "File system:" ), frame );
m_fs_input = new KComboBox( false, frame );
m_fs_input->setMinimumWidth( 200 );
m_fs_input->insertItem( "SMBFS", -1 );
m_fs_input->insertItem( "CIFS", -1 );
m_fs_input->setCurrentItem( 0 );
- QLabel *permission_label = new QLabel( i18n( "Write access:" ), frame );
+ TQLabel *permission_label = new TQLabel( i18n( "Write access:" ), frame );
m_rw_input = new KComboBox( false, frame );
m_rw_input->setMinimumWidth( 200 );
m_rw_input->insertItem( i18n( "read-write" ) );
m_rw_input->insertItem( i18n( "read-only" ) );
- QLabel *uid_label = new QLabel( i18n( "User ID:" ), frame );
+ TQLabel *uid_label = new TQLabel( i18n( "User ID:" ), frame );
m_uid_input = new KLineEdit( frame );
m_uid_input->setMinimumWidth( 200 );
- m_uid_input->setAlignment( Qt::AlignRight );
- QLabel *gid_label = new QLabel( i18n( "Group ID:" ), frame );
+ m_uid_input->tqsetAlignment( TQt::AlignRight );
+ TQLabel *gid_label = new TQLabel( i18n( "Group ID:" ), frame );
m_gid_input = new KLineEdit( frame );
m_gid_input->setMinimumWidth( 200 );
- m_gid_input->setAlignment( Qt::AlignRight );
+ m_gid_input->tqsetAlignment( TQt::AlignRight );
- m_kerberos = new QCheckBox( i18n( "Try to authenticate with Kerberos (Active Directory)" ), frame );
+ m_kerberos = new TQCheckBox( i18n( "Try to authenticate with Kerberos (Active Directory)" ), frame );
grid->addWidget( location_label, 0, 0, 0 );
grid->addWidget( location, 0, 1, 0 );
@@ -314,14 +314,14 @@ void Smb4KCustomOptionsDialog::setupDialog()
grid->addWidget( m_rw_input, 5, 1, 0 );
grid->addMultiCellWidget( m_kerberos, 6, 6, 0, 1, 0 );
#else
- QLabel *uid_label = new QLabel( i18n( "User ID:" ), frame );
+ TQLabel *uid_label = new TQLabel( i18n( "User ID:" ), frame );
m_uid_input = new KLineEdit( frame );
m_uid_input->setMinimumWidth( 200 );
- m_uid_input->setAlignment( Qt::AlignRight );
- QLabel *gid_label = new QLabel( i18n( "Group ID:" ), frame );
+ m_uid_input->tqsetAlignment( TQt::AlignRight );
+ TQLabel *gid_label = new TQLabel( i18n( "Group ID:" ), frame );
m_gid_input = new KLineEdit( frame );
m_gid_input->setMinimumWidth( 200 );
- m_gid_input->setAlignment( Qt::AlignRight );
+ m_gid_input->tqsetAlignment( TQt::AlignRight );
grid->addWidget( location_label, 0, 0, 0 );
grid->addWidget( location, 0, 1, 0 );
@@ -333,7 +333,7 @@ void Smb4KCustomOptionsDialog::setupDialog()
grid->addWidget( m_gid_input, 3, 1, 0 );
#endif
- info = optionsHandler()->findItem( QString( "//%1/%2" ).arg( m_share_item->host(), m_share_item->name() ) );
+ info = optionsHandler()->findItem( TQString( "//%1/%2" ).tqarg( m_share_item->host(), m_share_item->name() ) );
// Get the default values from the config file:
default_port = Smb4KSettings::remotePort();
@@ -424,48 +424,48 @@ void Smb4KCustomOptionsDialog::setupDialog()
// Because we do not have Kerberos with CIFS, disable this button
// in that case:
- m_kerberos->setEnabled( !(QString::compare( filesystem_value, "cifs" ) == 0) );
+ m_kerberos->setEnabled( !(TQString::compare( filesystem_value, "cifs" ) == 0) );
#endif
// Does the 'Default' button need to be enabled?
#ifndef __FreeBSD__
if ( default_port != port_value ||
- QString::compare( default_filesystem, filesystem_value ) != 0 ||
+ TQString::compare( default_filesystem, filesystem_value ) != 0 ||
default_kerberos != kerberos_value ||
default_readwrite != readwrite_value ||
- QString::compare( default_uid, uid_value ) != 0 ||
- QString::compare( default_gid, gid_value ) != 0 )
+ TQString::compare( default_uid, uid_value ) != 0 ||
+ TQString::compare( default_gid, gid_value ) != 0 )
{
enable_default_button = true;
}
#else
if ( default_port != port_value ||
- QString::compare( default_uid, uid_value ) != 0 ||
- QString::compare( default_gid, gid_value ) != 0 )
+ TQString::compare( default_uid, uid_value ) != 0 ||
+ TQString::compare( default_gid, gid_value ) != 0 )
{
enable_default_button = true;
}
#endif
// Connections:
- connect( m_port_input, SIGNAL( valueChanged( int ) ),
- this, SLOT( slotPortChanged( int ) ) );
+ connect( m_port_input, TQT_SIGNAL( valueChanged( int ) ),
+ this, TQT_SLOT( slotPortChanged( int ) ) );
- connect( m_uid_input, SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotUIDChanged( const QString & ) ) );
+ connect( m_uid_input, TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotUIDChanged( const TQString & ) ) );
- connect( m_gid_input, SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotGIDChanged( const QString & ) ) );
+ connect( m_gid_input, TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotGIDChanged( const TQString & ) ) );
#ifndef __FreeBSD__
- connect( m_kerberos, SIGNAL( toggled( bool ) ),
- this, SLOT( slotKerberosToggled( bool ) ) );
+ connect( m_kerberos, TQT_SIGNAL( toggled( bool ) ),
+ this, TQT_SLOT( slotKerberosToggled( bool ) ) );
- connect( m_rw_input, SIGNAL( activated( const QString & ) ),
- this, SLOT( slotWriteAccessChanged( const QString & ) ) );
+ connect( m_rw_input, TQT_SIGNAL( activated( const TQString & ) ),
+ this, TQT_SLOT( slotWriteAccessChanged( const TQString & ) ) );
- connect( m_fs_input, SIGNAL( activated( const QString & ) ),
- this, SLOT( slotFilesystemChanged( const QString & ) ) );
+ connect( m_fs_input, TQT_SIGNAL( activated( const TQString & ) ),
+ this, TQT_SLOT( slotFilesystemChanged( const TQString & ) ) );
#endif
break;
@@ -482,17 +482,17 @@ void Smb4KCustomOptionsDialog::setupDialog()
enableButton( User1, enable_default_button );
// Connect the buttons:
- connect( this, SIGNAL( okClicked() ),
- this, SLOT( slotOKButtonClicked() ) );
+ connect( this, TQT_SIGNAL( okClicked() ),
+ this, TQT_SLOT( slotOKButtonClicked() ) );
- connect( this, SIGNAL( user1Clicked() ),
- this, SLOT( slotDefaultButtonClicked() ) );
+ connect( this, TQT_SIGNAL( user1Clicked() ),
+ this, TQT_SLOT( slotDefaultButtonClicked() ) );
- setFixedSize( (sizeHint().width() > 350 ? sizeHint().width() : 350), sizeHint().height() );
+ setFixedSize( (tqsizeHint().width() > 350 ? tqsizeHint().width() : 350), tqsizeHint().height() );
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KCustomOptionsDialog::slotPortChanged( int val )
@@ -544,14 +544,14 @@ void Smb4KCustomOptionsDialog::slotPortChanged( int val )
}
-void Smb4KCustomOptionsDialog::slotFilesystemChanged( const QString &text )
+void Smb4KCustomOptionsDialog::slotFilesystemChanged( const TQString &text )
{
#ifndef __FreeBSD__
- filesystem_changed_ok = (QString::compare( filesystem_value, text.lower() ) != 0);
- filesystem_changed_default = (QString::compare( default_filesystem, text.lower() ) != 0);
+ filesystem_changed_ok = (TQString::compare( filesystem_value, text.lower() ) != 0);
+ filesystem_changed_default = (TQString::compare( default_filesystem, text.lower() ) != 0);
// Authentication with Kerberos does not exist with mount.cifs:
- if ( QString::compare( text, "CIFS" ) == 0 )
+ if ( TQString::compare( text, "CIFS" ) == 0 )
{
m_kerberos->setEnabled( false );
}
@@ -600,10 +600,10 @@ void Smb4KCustomOptionsDialog::slotFilesystemChanged( const QString &text )
}
-void Smb4KCustomOptionsDialog::slotProtocolChanged( const QString &protocol )
+void Smb4KCustomOptionsDialog::slotProtocolChanged( const TQString &protocol )
{
- protocol_changed_ok = (QString::compare( protocol_value, protocol.lower() ) != 0);
- protocol_changed_default = (QString::compare( default_protocol, protocol.lower() ) != 0);
+ protocol_changed_ok = (TQString::compare( protocol_value, protocol.lower() ) != 0);
+ protocol_changed_default = (TQString::compare( default_protocol, protocol.lower() ) != 0);
switch ( m_type )
{
@@ -698,10 +698,10 @@ void Smb4KCustomOptionsDialog::slotKerberosToggled( bool on )
}
-void Smb4KCustomOptionsDialog::slotWriteAccessChanged( const QString &rw )
+void Smb4KCustomOptionsDialog::slotWriteAccessChanged( const TQString &rw )
{
#ifndef __FreeBSD__
- bool readwrite = (QString::compare( rw, i18n( "read-write" ) ) == 0);
+ bool readwrite = (TQString::compare( rw, i18n( "read-write" ) ) == 0);
readwrite_changed_ok = (readwrite_value != readwrite);
readwrite_changed_default = (default_readwrite != readwrite);
@@ -745,10 +745,10 @@ void Smb4KCustomOptionsDialog::slotWriteAccessChanged( const QString &rw )
}
-void Smb4KCustomOptionsDialog::slotUIDChanged( const QString &uid )
+void Smb4KCustomOptionsDialog::slotUIDChanged( const TQString &uid )
{
- uid_changed_ok = (QString::compare( uid_value, uid ) != 0);
- uid_changed_default = (QString::compare( default_uid, uid ) != 0);
+ uid_changed_ok = (TQString::compare( uid_value, uid ) != 0);
+ uid_changed_default = (TQString::compare( default_uid, uid ) != 0);
switch ( m_type )
{
@@ -794,10 +794,10 @@ void Smb4KCustomOptionsDialog::slotUIDChanged( const QString &uid )
}
-void Smb4KCustomOptionsDialog::slotGIDChanged( const QString &gid )
+void Smb4KCustomOptionsDialog::slotGIDChanged( const TQString &gid )
{
- gid_changed_ok = (QString::compare( gid_value, gid ) != 0);
- gid_changed_default = (QString::compare( default_gid, gid ) != 0);
+ gid_changed_ok = (TQString::compare( gid_value, gid ) != 0);
+ gid_changed_default = (TQString::compare( default_gid, gid ) != 0);
switch ( m_type )
{
@@ -851,7 +851,7 @@ void Smb4KCustomOptionsDialog::slotOKButtonClicked()
{
case Host:
{
- QString item_name = m_host_item->name();
+ TQString item_name = m_host_item->name();
// Check if we can remove the item:
if ( !port_changed_default && !protocol_changed_default && !kerberos_changed_default )
@@ -871,7 +871,7 @@ void Smb4KCustomOptionsDialog::slotOKButtonClicked()
// Put in the needed information:
info->setPort( m_port_input->value() );
- info->setProtocol( QString::compare( m_proto_input->currentText(), i18n( "auto" ) ) == 0 ?
+ info->setProtocol( TQString::compare( m_proto_input->currentText(), i18n( "auto" ) ) == 0 ?
"auto" :
m_proto_input->currentText().lower() );
@@ -885,8 +885,8 @@ void Smb4KCustomOptionsDialog::slotOKButtonClicked()
}
case Share:
{
- QString item_name = QString( "//%1/%2" ).arg( m_share_item->host(),
- QString::compare( m_share_item->name(), "homes" ) == 0 ?
+ TQString item_name = TQString( "//%1/%2" ).tqarg( m_share_item->host(),
+ TQString::compare( m_share_item->name(), "homes" ) == 0 ?
m_homes_user :
m_share_item->name() );
@@ -910,7 +910,7 @@ void Smb4KCustomOptionsDialog::slotOKButtonClicked()
// Put in the needed information:
info->setPort( m_port_input->value() );
info->setKerberos( m_kerberos->isChecked() );
- info->setWriteAccess( (QString::compare( m_rw_input->currentText(), i18n( "read-write" ) ) == 0) );
+ info->setWriteAccess( (TQString::compare( m_rw_input->currentText(), i18n( "read-write" ) ) == 0) );
info->setFilesystem( m_fs_input->currentText().lower() );
info->setUID( m_uid_input->text() );
info->setGID( m_gid_input->text() );
@@ -967,13 +967,13 @@ void Smb4KCustomOptionsDialog::slotDefaultButtonClicked()
{
m_port_input->setValue( default_port );
m_kerberos->setChecked( default_kerberos );
- QString protocol = (QString::compare( default_protocol, "auto" ) == 0 ? i18n( "auto" ) : protocol_value.upper());
+ TQString protocol = (TQString::compare( default_protocol, "auto" ) == 0 ? i18n( "auto" ) : protocol_value.upper());
m_proto_input->setCurrentText( protocol );
// Enable or disable the OK button:
enableButton( Ok, default_port != port_value ||
default_kerberos != kerberos_value ||
- QString::compare( default_protocol, protocol_value ) != 0 );
+ TQString::compare( default_protocol, protocol_value ) != 0 );
break;
}
@@ -985,13 +985,13 @@ void Smb4KCustomOptionsDialog::slotDefaultButtonClicked()
#ifndef __FreeBSD__
m_kerberos->setChecked( default_kerberos );
- QString write_access = (default_readwrite ? i18n( "read-write" ) : i18n( "read-only" ));
+ TQString write_access = (default_readwrite ? i18n( "read-write" ) : i18n( "read-only" ));
m_rw_input->setCurrentText( write_access );
m_fs_input->setCurrentText( default_filesystem.upper() );
// Enable or disable the Kerberos check box depending on
// the (default) file system:
- if ( QString::compare( default_filesystem, "cifs" ) == 0 )
+ if ( TQString::compare( default_filesystem, "cifs" ) == 0 )
{
m_kerberos->setEnabled( false );
}
@@ -1005,11 +1005,11 @@ void Smb4KCustomOptionsDialog::slotDefaultButtonClicked()
enableButton( Ok, default_port != port_value ||
#ifndef __FreeBSD__
default_kerberos != kerberos_value ||
- QString::compare( default_filesystem, filesystem_value ) != 0 ||
+ TQString::compare( default_filesystem, filesystem_value ) != 0 ||
default_readwrite != readwrite_value ||
#endif
- QString::compare( default_uid, uid_value ) != 0 ||
- QString::compare( default_gid, gid_value ) != 0 );
+ TQString::compare( default_uid, uid_value ) != 0 ||
+ TQString::compare( default_gid, gid_value ) != 0 );
break;
}
diff --git a/smb4k/dialogs/smb4kcustomoptionsdialog.h b/smb4k/dialogs/smb4kcustomoptionsdialog.h
index 10594a9..00c6123 100644
--- a/smb4k/dialogs/smb4kcustomoptionsdialog.h
+++ b/smb4k/dialogs/smb4kcustomoptionsdialog.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qcheckbox.h>
+// TQt includes
+#include <tqcheckbox.h>
// KDE includes
#include <kdialogbase.h>
@@ -47,6 +47,7 @@ class Smb4KShareItem;
class Smb4KCustomOptionsDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -54,22 +55,22 @@ class Smb4KCustomOptionsDialog : public KDialogBase
*
* @param host The host (server) for which the custom options should be defined.
*
- * @param parent The parent of this dialog
+ * @param tqparent The tqparent of this dialog
*
* @param name The name of this dialog
*/
- Smb4KCustomOptionsDialog( Smb4KHostItem *host, QWidget *parent = 0, const char *name = 0 );
+ Smb4KCustomOptionsDialog( Smb4KHostItem *host, TQWidget *tqparent = 0, const char *name = 0 );
/**
* Another constructor, similar to the one above.
*
* @param share The share for which the custom options should be defined.
*
- * @param parent The parent of this dialog
+ * @param tqparent The tqparent of this dialog
*
* @param name The name of this dialog
*/
- Smb4KCustomOptionsDialog( Smb4KShareItem *share, QWidget *parent = 0, const char *name = 0 );
+ Smb4KCustomOptionsDialog( Smb4KShareItem *share, TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -99,14 +100,14 @@ class Smb4KCustomOptionsDialog : public KDialogBase
*
* @param fs The file system
*/
- void slotFilesystemChanged( const QString &fs );
+ void slotFilesystemChanged( const TQString &fs );
/**
* Is invoked when the protocol value changed
*
* @param t The protocol
*/
- void slotProtocolChanged( const QString &p );
+ void slotProtocolChanged( const TQString &p );
/**
* Is invoked when the user clicked the 'Use Kerberos'
@@ -133,21 +134,21 @@ class Smb4KCustomOptionsDialog : public KDialogBase
*
* @param rw Either 'read-write' or 'read-only' (localized).
*/
- void slotWriteAccessChanged( const QString &rw );
+ void slotWriteAccessChanged( const TQString &rw );
/**
* This slot is invoked when the UID value changed.
*
* @param uid The UID value
*/
- void slotUIDChanged( const QString &uid );
+ void slotUIDChanged( const TQString &uid );
/**
* This slot is invoked when the GID value changed.
*
* @param gid The UID value
*/
- void slotGIDChanged( const QString &gid );
+ void slotGIDChanged( const TQString &gid );
private:
/**
@@ -207,14 +208,14 @@ class Smb4KCustomOptionsDialog : public KDialogBase
/**
* This will only be set if we are dealing with a 'homes' share.
*/
- QString m_homes_user;
+ TQString m_homes_user;
/**
* This check box will determine if the user wants to try to
* authenticate with Kerberos or not. This is needed for Active
* Directory stuff.
*/
- QCheckBox *m_kerberos;
+ TQCheckBox *m_kerberos;
/**
* This combo box holds the values of the UID that the user can
diff --git a/smb4k/dialogs/smb4kmountdialog.cpp b/smb4k/dialogs/smb4kmountdialog.cpp
index 7cafe35..6e7d7c4 100644
--- a/smb4k/dialogs/smb4kmountdialog.cpp
+++ b/smb4k/dialogs/smb4kmountdialog.cpp
@@ -24,11 +24,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qframe.h>
-#include <qgroupbox.h>
-#include <qlabel.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqframe.h>
+#include <tqgroupbox.h>
+#include <tqlabel.h>
// KDE includes
#include <klocale.h>
@@ -44,14 +44,14 @@
#include "../core/smb4kcore.h"
#include "../smb4k.h"
-Smb4KMountDialog::Smb4KMountDialog( QWidget *parent, const char *name ) :
-KDialogBase( Plain, i18n( "Mount Share" ), Ok|Cancel, Ok, parent, name, true, true )
+Smb4KMountDialog::Smb4KMountDialog( TQWidget *tqparent, const char *name ) :
+KDialogBase( Plain, i18n( "Mount Share" ), Ok|Cancel, Ok, tqparent, name, true, true )
{
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
setupView();
- setFixedSize( (sizeHint().width() > 350 ? sizeHint().width() : 350), sizeHint().height() );
+ setFixedSize( (tqsizeHint().width() > 350 ? tqsizeHint().width() : 350), tqsizeHint().height() );
}
@@ -62,46 +62,46 @@ Smb4KMountDialog::~Smb4KMountDialog()
void Smb4KMountDialog::setupView()
{
- QFrame *frame = plainPage();
- QGridLayout *layout = new QGridLayout( frame );
- layout->setSpacing( 5 );
- layout->setMargin( 0 );
+ TQFrame *frame = plainPage();
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
+ tqlayout->setSpacing( 5 );
+ tqlayout->setMargin( 0 );
- QLabel *shareLabel = new QLabel( i18n( "Share:" ), frame );
+ TQLabel *shareLabel = new TQLabel( i18n( "Share:" ), frame );
m_share_input = new KLineEdit( frame, "ShareInputLine" );
m_share_input->setMinimumWidth( 200 );
m_share_input->setFocus();
- QLabel *addressLabel = new QLabel( i18n( "IP Address:" ), frame );
+ TQLabel *addressLabel = new TQLabel( i18n( "IP Address:" ), frame );
m_ip_input = new KLineEdit( frame, "IPInputLine" );
m_ip_input->setMinimumWidth( 200 );
- QLabel *workgroupLabel = new QLabel( i18n( "Workgroup:" ), frame );
+ TQLabel *workgroupLabel = new TQLabel( i18n( "Workgroup:" ), frame );
m_workgroup_input = new KLineEdit( frame, "WorkgroupInputLine" );
m_workgroup_input->setMinimumWidth( 200 );
- m_bookmark = new QCheckBox( i18n( "Add this share to the bookmarks" ), frame, "BookmarkButton" );
+ m_bookmark = new TQCheckBox( i18n( "Add this share to the bookmarks" ), frame, "BookmarkButton" );
- layout->addWidget( shareLabel, 0, 0, 0 );
- layout->addWidget( m_share_input, 0, 1, 0 );
- layout->addWidget( addressLabel, 1, 0, 0 );
- layout->addWidget( m_ip_input, 1, 1, 0 );
- layout->addWidget( workgroupLabel, 2, 0, 0 );
- layout->addWidget( m_workgroup_input, 2, 1, 0 );
- layout->addMultiCellWidget( m_bookmark, 3, 3, 0, 1, 0 );
+ tqlayout->addWidget( shareLabel, 0, 0, 0 );
+ tqlayout->addWidget( m_share_input, 0, 1, 0 );
+ tqlayout->addWidget( addressLabel, 1, 0, 0 );
+ tqlayout->addWidget( m_ip_input, 1, 1, 0 );
+ tqlayout->addWidget( workgroupLabel, 2, 0, 0 );
+ tqlayout->addWidget( m_workgroup_input, 2, 1, 0 );
+ tqlayout->addMultiCellWidget( m_bookmark, 3, 3, 0, 1, 0 );
- connect( m_share_input, SIGNAL( textChanged ( const QString & ) ) ,
- this, SLOT( slotChangeInputValue( const QString & ) ) );
+ connect( m_share_input, TQT_SIGNAL( textChanged ( const TQString & ) ) ,
+ this, TQT_SLOT( slotChangeInputValue( const TQString & ) ) );
slotChangeInputValue( m_share_input->text() );
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
-void Smb4KMountDialog::slotChangeInputValue( const QString& _test)
+void Smb4KMountDialog::slotChangeInputValue( const TQString& _test)
{
enableButtonOK( !_test.isEmpty() );
}
@@ -115,25 +115,25 @@ void Smb4KMountDialog::slotOk()
if ( !m_share_input->text().stripWhiteSpace().isEmpty() )
{
#ifndef __FreeBSD__
- if ( m_share_input->text().contains( "/" ) == 3 )
+ if ( m_share_input->text().tqcontains( "/" ) == 3 )
#else
- if ( m_share_input->text().contains( "/" ) == 3
- && m_share_input->text().contains( '@' ) == 0 )
+ if ( m_share_input->text().tqcontains( "/" ) == 3
+ && m_share_input->text().tqcontains( '@' ) == 0 )
#endif
{
- QString host = m_share_input->text().stripWhiteSpace().section( "/", 2, 2 );
- QString share = m_share_input->text().stripWhiteSpace().section( "/", 3, 3 );
- QString ip = m_ip_input->text().stripWhiteSpace();
- QString workgroup = m_workgroup_input->text().stripWhiteSpace();
+ TQString host = m_share_input->text().stripWhiteSpace().section( "/", 2, 2 );
+ TQString share = m_share_input->text().stripWhiteSpace().section( "/", 3, 3 );
+ TQString ip = m_ip_input->text().stripWhiteSpace();
+ TQString workgroup = m_workgroup_input->text().stripWhiteSpace();
Smb4KCore::mounter()->mountShare( workgroup, host, ip, share );
if ( m_bookmark->isChecked() )
{
- Smb4KCore::bookmarkHandler()->addBookmark( new Smb4KBookmark( host, share, workgroup, ip, QString::null ) );
+ Smb4KCore::bookmarkHandler()->addBookmark( new Smb4KBookmark( host, share, workgroup, ip, TQString() ) );
}
- connect( Smb4KCore::mounter(), SIGNAL( state( int ) ), this, SLOT( slotMounterStateChanged( int ) ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( state( int ) ), this, TQT_SLOT( slotMounterStateChanged( int ) ) );
}
else
{
diff --git a/smb4k/dialogs/smb4kmountdialog.h b/smb4k/dialogs/smb4kmountdialog.h
index ff7ff5f..e9a07ef 100644
--- a/smb4k/dialogs/smb4kmountdialog.h
+++ b/smb4k/dialogs/smb4kmountdialog.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qcheckbox.h>
+// TQt includes
+#include <tqcheckbox.h>
// KDE includes
#include <kdialogbase.h>
@@ -47,12 +47,13 @@
class Smb4KMountDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*/
- Smb4KMountDialog( QWidget *parent = 0, const char *name = 0 );
+ Smb4KMountDialog( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
*/
@@ -74,7 +75,7 @@ class Smb4KMountDialog : public KDialogBase
*
* @param text The input text.
*/
- void slotChangeInputValue( const QString &text );
+ void slotChangeInputValue( const TQString &text );
/**
* This slot is connected to the Smb4KCore::mounter()::state() signal.
@@ -105,7 +106,7 @@ class Smb4KMountDialog : public KDialogBase
* This checkbox determines whether the share should be added to the
* bookmarks.
*/
- QCheckBox *m_bookmark;
+ TQCheckBox *m_bookmark;
};
#endif
diff --git a/smb4k/dialogs/smb4kpreviewdialog.cpp b/smb4k/dialogs/smb4kpreviewdialog.cpp
index 4a3f7b8..6c06919 100644
--- a/smb4k/dialogs/smb4kpreviewdialog.cpp
+++ b/smb4k/dialogs/smb4kpreviewdialog.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qtooltip.h>
-#include <qiconset.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqtooltip.h>
+#include <tqiconset.h>
// KDE includes
#include <klocale.h>
@@ -42,10 +42,10 @@
#include "../core/smb4ksettings.h"
-Smb4KPreviewDialog::Smb4KPreviewDialog( Smb4KShareItem *item, QWidget *parent, const char *name )
-: KDialogBase( Plain, i18n( "Preview" ), Close, Close, parent, name, false, true )
+Smb4KPreviewDialog::Smb4KPreviewDialog( Smb4KShareItem *item, TQWidget *tqparent, const char *name )
+: KDialogBase( Plain, i18n( "Preview" ), Close, Close, tqparent, name, false, true )
{
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
m_item = new Smb4KPreviewItem( item );
@@ -64,22 +64,22 @@ Smb4KPreviewDialog::Smb4KPreviewDialog( Smb4KShareItem *item, QWidget *parent, c
setInitialSize( configDialogSize( *(Smb4KSettings::self()->config()), "PreviewDialog" ) );
- connect( m_view, SIGNAL( executed( QIconViewItem * ) ),
- this, SLOT( slotItemExecuted( QIconViewItem * ) ) );
+ connect( m_view, TQT_SIGNAL( executed( TQIconViewItem * ) ),
+ this, TQT_SLOT( slotItemExecuted( TQIconViewItem * ) ) );
- connect( m_toolbar, SIGNAL( clicked( int ) ),
- this, SLOT( slotButtonClicked( int ) ) );
+ connect( m_toolbar, TQT_SIGNAL( clicked( int ) ),
+ this, TQT_SLOT( slotButtonClicked( int ) ) );
- connect( m_combo, SIGNAL( activated( const QString & ) ),
- this, SLOT( slotItemActivated( const QString & ) ) );
+ connect( m_combo, TQT_SIGNAL( activated( const TQString & ) ),
+ this, TQT_SLOT( slotItemActivated( const TQString & ) ) );
- connect( Smb4KCore::previewer(), SIGNAL( result( Smb4KPreviewItem * ) ),
- this, SLOT( slotReceivedData( Smb4KPreviewItem * ) ) );
+ connect( Smb4KCore::previewer(), TQT_SIGNAL( result( Smb4KPreviewItem * ) ),
+ this, TQT_SLOT( slotReceivedData( Smb4KPreviewItem * ) ) );
m_initialized = Smb4KCore::previewer()->preview( m_item );
}
- setMinimumSize( (sizeHint().width() > 350 ? sizeHint().width() : 350), sizeHint().height() );
+ setMinimumSize( (tqsizeHint().width() > 350 ? tqsizeHint().width() : 350), tqsizeHint().height() );
}
@@ -91,8 +91,8 @@ Smb4KPreviewDialog::~Smb4KPreviewDialog()
void Smb4KPreviewDialog::setupView()
{
- QFrame *frame = plainPage();
- QGridLayout *layout = new QGridLayout( frame );
+ TQFrame *frame = plainPage();
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
m_view = new KIconView( frame, 0, 0 );
m_view->setItemTextPos( KIconView::Right );
@@ -112,19 +112,19 @@ void Smb4KPreviewDialog::setupView()
m_toolbar->insertButton( "up", Up, false, i18n( "Up" ), 3 );
m_combo = new KComboBox( false, m_toolbar, 0 );
- m_combo->listBox()->setHScrollBarMode( QScrollView::Auto );
- m_combo->listBox()->setVScrollBarMode( QScrollView::Auto );
+ m_combo->listBox()->setHScrollBarMode( TQScrollView::Auto );
+ m_combo->listBox()->setVScrollBarMode( TQScrollView::Auto );
m_combo->listBox()->setMinimumHeight( 100 );
m_toolbar->insertWidget( Combo, 10, m_combo, 4 );
m_toolbar->setItemAutoSized( Combo, true );
- layout->addWidget( m_view, 0, 0, 0 );
- layout->addWidget( m_toolbar, 1, 0, 0 );
+ tqlayout->addWidget( m_view, 0, 0, 0 );
+ tqlayout->addWidget( m_toolbar, 1, 0, 0 );
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
@@ -170,9 +170,9 @@ void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
// current item:
m_combo->clear();
- for ( QStringList::Iterator it = m_history.begin(); it != m_history.end(); it++ )
+ for ( TQStringList::Iterator it = m_history.begin(); it != m_history.end(); it++ )
{
- if ( !m_combo->listBox()->findItem( *it, Qt::CaseSensitive|Qt::ExactMatch ) )
+ if ( !m_combo->listBox()->tqfindItem( *it, TQt::CaseSensitive|TQt::ExactMatch ) )
{
m_combo->insertItem( *it, -1 );
}
@@ -181,7 +181,7 @@ void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
m_combo->setCurrentText( *m_current_item );
// Now put the contents in the icon view:
- for ( QValueList<ContentsItem>::ConstIterator it = item->contents().begin();
+ for ( TQValueList<ContentsItem>::ConstIterator it = item->contents().begin();
it != item->contents().end(); ++it )
{
switch ( (*it).first )
@@ -189,17 +189,17 @@ void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
case Smb4KPreviewItem::File:
{
KIconViewItem *view_item = new KIconViewItem( m_view, (*it).second, SmallIcon( "file" ) );
- view_item->setKey( QString( "[file]_%1" ).arg( (*it).second ) );
+ view_item->setKey( TQString( "[file]_%1" ).tqarg( (*it).second ) );
break;
}
case Smb4KPreviewItem::Directory:
{
// We do not want to show the '.' and '..' directories.
- if ( QString::compare( (*it).second, "." ) != 0 && QString::compare( (*it).second, ".." ) != 0 )
+ if ( TQString::compare( (*it).second, "." ) != 0 && TQString::compare( (*it).second, ".." ) != 0 )
{
KIconViewItem *view_item = new KIconViewItem( m_view, (*it).second, SmallIcon( "folder" ) );
- view_item->setKey( QString( "[directory]_%1" ).arg( (*it).second ) );
+ view_item->setKey( TQString( "[directory]_%1" ).tqarg( (*it).second ) );
}
break;
@@ -209,7 +209,7 @@ void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
if ( Smb4KSettings::previewHiddenItems() )
{
KIconViewItem *view_item = new KIconViewItem( m_view, (*it).second, SmallIcon( "file" ) );
- view_item->setKey( QString( "[file]_%1" ).arg( (*it).second ) );
+ view_item->setKey( TQString( "[file]_%1" ).tqarg( (*it).second ) );
}
break;
@@ -217,10 +217,10 @@ void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
case Smb4KPreviewItem::HiddenDirectory:
{
if ( Smb4KSettings::previewHiddenItems() &&
- QString::compare( (*it).second, "." ) != 0 && QString::compare( (*it).second, ".." ) != 0 )
+ TQString::compare( (*it).second, "." ) != 0 && TQString::compare( (*it).second, ".." ) != 0 )
{
KIconViewItem *view_item = new KIconViewItem( m_view, (*it).second, SmallIcon( "folder" ) );
- view_item->setKey( QString( "[directory]_%1" ).arg( (*it).second ) );
+ view_item->setKey( TQString( "[directory]_%1" ).tqarg( (*it).second ) );
}
break;
@@ -236,7 +236,7 @@ void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
// Activate the 'Up' button if the current address is
// not equal to the base address.
- m_toolbar->setItemEnabled( Up, QString::compare( "//"+item->host()+"/"+item->share()+"/", item->location() ) != 0 );
+ m_toolbar->setItemEnabled( Up, TQString::compare( "//"+item->host()+"/"+item->share()+"/", item->location() ) != 0 );
// Activate/Deactivate 'Back' and 'Forward' buttons.
m_toolbar->setItemEnabled( Back, m_current_item != m_history.at( 0 ) );
@@ -249,7 +249,7 @@ void Smb4KPreviewDialog::slotReceivedData( Smb4KPreviewItem *item )
}
-void Smb4KPreviewDialog::slotItemExecuted( QIconViewItem *item )
+void Smb4KPreviewDialog::slotItemExecuted( TQIconViewItem *item )
{
if ( !item->key().startsWith( "[file]_" ) )
{
@@ -285,13 +285,13 @@ void Smb4KPreviewDialog::slotButtonClicked( int id )
return;
}
- if ( m_item->path().contains( "/" ) > 1 )
+ if ( m_item->path().tqcontains( "/" ) > 1 )
{
m_item->setPath( m_item->path().section( "/", 0, -3 ).append( "/" ) );
}
- else if ( m_item->path().contains( "/", true ) == 1 )
+ else if ( m_item->path().tqcontains( "/", true ) == 1 )
{
- m_item->setPath( QString::null );
+ m_item->setPath( TQString() );
}
Smb4KCore::previewer()->preview( m_item );
@@ -311,9 +311,9 @@ void Smb4KPreviewDialog::slotButtonClicked( int id )
}
// Get the path:
- if ( (*m_current_item).contains( "/", true ) == 3 )
+ if ( (*m_current_item).tqcontains( "/", true ) == 3 )
{
- m_item->setPath( QString::null );
+ m_item->setPath( TQString() );
}
else
{
@@ -346,9 +346,9 @@ void Smb4KPreviewDialog::slotButtonClicked( int id )
}
// Get the path:
- if ( (*m_current_item).contains( "/", true ) == 3 )
+ if ( (*m_current_item).tqcontains( "/", true ) == 3 )
{
- m_item->setPath( QString::null );
+ m_item->setPath( TQString() );
}
else
{
@@ -376,7 +376,7 @@ void Smb4KPreviewDialog::slotButtonClicked( int id )
}
-void Smb4KPreviewDialog::slotItemActivated( const QString &item )
+void Smb4KPreviewDialog::slotItemActivated( const TQString &item )
{
m_button_id = Combo;
diff --git a/smb4k/dialogs/smb4kpreviewdialog.h b/smb4k/dialogs/smb4kpreviewdialog.h
index 8c8fe15..9a7c48a 100644
--- a/smb4k/dialogs/smb4kpreviewdialog.h
+++ b/smb4k/dialogs/smb4kpreviewdialog.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qvaluelist.h>
+// TQt includes
+#include <tqvaluelist.h>
// KDE includes
#include <kdialogbase.h>
@@ -55,6 +55,7 @@ class Smb4KShareItem;
class Smb4KPreviewDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -62,11 +63,11 @@ class Smb4KPreviewDialog : public KDialogBase
*
* @param item The Smb4KShareItem object.
*
- * @param parent The parent of this widget
+ * @param tqparent The tqparent of this widget
*
* @param name The name of this widget
*/
- Smb4KPreviewDialog( Smb4KShareItem *item, QWidget *parent = 0, const char *name = 0 );
+ Smb4KPreviewDialog( Smb4KShareItem *item, TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -94,7 +95,7 @@ class Smb4KPreviewDialog : public KDialogBase
/**
* Is called, if one icon view item is clicked.
*/
- void slotItemExecuted( QIconViewItem *item );
+ void slotItemExecuted( TQIconViewItem *item );
/**
* Is called, if a tool bar button is clicked.
@@ -104,7 +105,7 @@ class Smb4KPreviewDialog : public KDialogBase
/**
* Is called, if an item in the combo box is activated.
*/
- void slotItemActivated( const QString &item );
+ void slotItemActivated( const TQString &item );
/**
* Reimplemented from KDialogBase. Saves the dialog size and
@@ -151,12 +152,12 @@ class Smb4KPreviewDialog : public KDialogBase
/**
* This list holds the history of the session.
*/
- QStringList m_history;
+ TQStringList m_history;
/**
* This iterator points to the current item in the history.
*/
- QStringList::Iterator m_current_item;
+ TQStringList::Iterator m_current_item;
/**
* TRUE if the dialog was successfully initilized and
diff --git a/smb4k/dialogs/smb4kprintdialog.cpp b/smb4k/dialogs/smb4kprintdialog.cpp
index 342d085..ab147ff 100644
--- a/smb4k/dialogs/smb4kprintdialog.cpp
+++ b/smb4k/dialogs/smb4kprintdialog.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qframe.h>
+// TQt includes
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqframe.h>
// KDE includes
#include <klocale.h>
@@ -42,11 +42,11 @@
#include "../core/smb4knetworkitems.h"
-Smb4KPrintDialog::Smb4KPrintDialog( Smb4KShareItem *item, QWidget *parent, const char *name )
-: KDialogBase( Plain, i18n( "Print File" ), Details|Filler|User1|Cancel, User1, parent, name, true, true ),
-m_item( item ), m_ip( QString::null ) /* will collect it in an instant */
+Smb4KPrintDialog::Smb4KPrintDialog( Smb4KShareItem *item, TQWidget *tqparent, const char *name )
+: KDialogBase( Plain, i18n( "Print File" ), Details|Filler|User1|Cancel, User1, tqparent, name, true, true ),
+m_item( item ), m_ip( TQString() ) /* will collect it in an instant */
{
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
if ( !m_item )
{
@@ -63,60 +63,60 @@ m_item( item ), m_ip( QString::null ) /* will collect it in an instant */
}
// Bild the view:
- QFrame *frame = plainPage();
+ TQFrame *frame = plainPage();
- QGridLayout *layout = new QGridLayout( frame );
- layout->setSpacing( 10 );
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
+ tqlayout->setSpacing( 10 );
- QGroupBox *p = new QGroupBox( 2, Qt::Horizontal, i18n( "Printer" ), frame );
+ TQGroupBox *p = new TQGroupBox( 2, Qt::Horizontal, i18n( "Printer" ), frame );
p->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "Name:" ), p );
- (void) new QLabel( m_item->name()+
+ (void) new TQLabel( i18n( "Name:" ), p );
+ (void) new TQLabel( m_item->name()+
(!m_item->comment().stripWhiteSpace().isEmpty() ?
" ("+m_item->comment()+")" :
""), p );
-// (void) new QLabel( i18n( "Comment:" ), p );
-// (void) new QLabel( m_item->comment(), p );
+// (void) new TQLabel( i18n( "Comment:" ), p );
+// (void) new TQLabel( m_item->comment(), p );
- (void) new QLabel( i18n( "Host:" ), p );
- (void) new QLabel( m_item->host(), p );
+ (void) new TQLabel( i18n( "Host:" ), p );
+ (void) new TQLabel( m_item->host(), p );
- (void) new QLabel( i18n( "IP address:" ), p );
- (void) new QLabel( m_ip.stripWhiteSpace().isEmpty() ?
+ (void) new TQLabel( i18n( "IP address:" ), p );
+ (void) new TQLabel( m_ip.stripWhiteSpace().isEmpty() ?
i18n( "Unknown" ) :
m_ip,
p );
- (void) new QLabel( i18n( "Workgroup:" ), p );
- (void) new QLabel( m_item->workgroup(), p );
+ (void) new TQLabel( i18n( "Workgroup:" ), p );
+ (void) new TQLabel( m_item->workgroup(), p );
- QGroupBox *f = new QGroupBox( 2, Qt::Horizontal, i18n( "File" ), frame );
+ TQGroupBox *f = new TQGroupBox( 2, Qt::Horizontal, i18n( "File" ), frame );
f->setInsideSpacing( 5 );
- (void) new QLabel( i18n( "File:" ), f );
- KURLRequester *requester = new KURLRequester( QString::null, f, "URL" );
+ (void) new TQLabel( i18n( "File:" ), f );
+ KURLRequester *requester = new KURLRequester( TQString(), f, "URL" );
requester->setMode( KFile::File | KFile::LocalOnly );
- QGroupBox *s = new QGroupBox( 2, Qt::Horizontal, i18n( "Options" ), frame );
+ TQGroupBox *s = new TQGroupBox( 2, Qt::Horizontal, i18n( "Options" ), frame );
s->setInsideSpacing( 5 );
setDetailsWidget( s );
- (void) new QLabel( i18n( "Copies:" ), s );
+ (void) new TQLabel( i18n( "Copies:" ), s );
KIntNumInput *cp = new KIntNumInput( 1, s, 10, "Copies" );
cp->setMinValue( 1 );
- layout->addWidget( p, 0, 0, 0 );
- layout->addWidget( f, 1, 0, 0 );
+ tqlayout->addWidget( p, 0, 0, 0 );
+ tqlayout->addWidget( f, 1, 0, 0 );
- setFixedSize( (sizeHint().width() > 350 ? sizeHint().width() : 350), sizeHint().height() );
+ setFixedSize( (tqsizeHint().width() > 350 ? tqsizeHint().width() : 350), tqsizeHint().height() );
enableButton( User1, false );
- connect( requester, SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotInputValueChanged( const QString & ) ) );
+ connect( requester, TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotInputValueChanged( const TQString & ) ) );
}
@@ -127,13 +127,13 @@ Smb4KPrintDialog::~ Smb4KPrintDialog()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KPrintDialog::slotUser1()
{
- KURLRequester *url = static_cast<KURLRequester *>( child( "URL", "KURLRequester", true ) );
- KIntNumInput *copies = static_cast<KIntNumInput *>( child( "Copies", "KIntNumInput", true ) );
+ KURLRequester *url = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "URL", "KURLRequester", true )) );
+ KIntNumInput *copies = static_cast<KIntNumInput *>( TQT_TQWIDGET(child( "Copies", "KIntNumInput", true )) );
if ( url && copies )
{
@@ -143,7 +143,7 @@ void Smb4KPrintDialog::slotUser1()
{
enableButton( User1, false );
- connect( Smb4KCore::print(), SIGNAL( state( int ) ), this, SLOT( slotPrintStateChanged( int ) ) );
+ connect( Smb4KCore::print(), TQT_SIGNAL( state( int ) ), this, TQT_SLOT( slotPrintStateChanged( int ) ) );
}
else
{
@@ -187,7 +187,7 @@ void Smb4KPrintDialog::slotPrintStateChanged( int state )
}
-void Smb4KPrintDialog::slotInputValueChanged( const QString &text )
+void Smb4KPrintDialog::slotInputValueChanged( const TQString &text )
{
enableButton( User1, !text.isEmpty() );
}
diff --git a/smb4k/dialogs/smb4kprintdialog.h b/smb4k/dialogs/smb4kprintdialog.h
index c7bff79..bd2294c 100644
--- a/smb4k/dialogs/smb4kprintdialog.h
+++ b/smb4k/dialogs/smb4kprintdialog.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qstring.h>
+// TQt includes
+#include <tqstring.h>
// KDE includes
#include <kdialogbase.h>
@@ -51,6 +51,7 @@ class Smb4KShareItem;
class Smb4KPrintDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -58,11 +59,11 @@ class Smb4KPrintDialog : public KDialogBase
*
* @param item The Smb4KShareItem of the printer.
*
- * @param parent The parent widget of this dialog.
+ * @param tqparent The tqparent widget of this dialog.
*
* @param name The name of this dialog.
*/
- Smb4KPrintDialog( Smb4KShareItem *item, QWidget *parent = 0, const char *name = 0 );
+ Smb4KPrintDialog( Smb4KShareItem *item, TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
*/
@@ -89,7 +90,7 @@ class Smb4KPrintDialog : public KDialogBase
*
* @param text The input text.
*/
- void slotInputValueChanged( const QString &text );
+ void slotInputValueChanged( const TQString &text );
private:
/**
@@ -99,7 +100,7 @@ class Smb4KPrintDialog : public KDialogBase
/**
* Holds the IP address.
*/
- QString m_ip;
+ TQString m_ip;
};
#endif
diff --git a/smb4k/dialogs/smb4ksynchronizationdialog.cpp b/smb4k/dialogs/smb4ksynchronizationdialog.cpp
index 5d72cce..fbe03a0 100644
--- a/smb4k/dialogs/smb4ksynchronizationdialog.cpp
+++ b/smb4k/dialogs/smb4ksynchronizationdialog.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qframe.h>
-#include <qlabel.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqframe.h>
+#include <tqlabel.h>
// KDE includes
#include <klocale.h>
@@ -43,31 +43,31 @@
#include "../core/smb4ksynchronizationinfo.h"
#include "../core/smb4ksettings.h"
-Smb4KSynchronizationDialog::Smb4KSynchronizationDialog( Smb4KShare *share, QWidget *parent, const char *name )
-: KDialogBase( Plain, i18n( "Synchronization" ), User2|User1|Cancel, User1, parent, name, false, true ),
+Smb4KSynchronizationDialog::Smb4KSynchronizationDialog( Smb4KShare *share, TQWidget *tqparent, const char *name )
+: KDialogBase( Plain, i18n( "Synchronization" ), User2|User1|Cancel, User1, tqparent, name, false, true ),
m_share( share )
{
- setWFlags( Qt::WDestructiveClose );
+ setWFlags( TQt::WDestructiveClose );
setButtonGuiItem( User1, KGuiItem( i18n( "Synchronize" ), "bottom", i18n( "Synchronize the destination with the source" ) ) );
- setButtonGuiItem( User2, KGuiItem( i18n( "Swap Paths" ), QString::null, i18n( "Swap source and destination" ) ) );
+ setButtonGuiItem( User2, KGuiItem( i18n( "Swap Paths" ), TQString(), i18n( "Swap source and destination" ) ) );
- QFrame *frame = plainPage();
- QGridLayout *layout = new QGridLayout( frame );
- layout->setSpacing( 5 );
- layout->setMargin( 0 );
+ TQFrame *frame = plainPage();
+ TQGridLayout *tqlayout = new TQGridLayout( frame );
+ tqlayout->setSpacing( 5 );
+ tqlayout->setMargin( 0 );
- QLabel *source_label = new QLabel( i18n( "Source:" ), frame, "SourceURLLabel" );
+ TQLabel *source_label = new TQLabel( i18n( "Source:" ), frame, "SourceURLLabel" );
KURLRequester *source = new KURLRequester( m_share->path()+"/", frame, "SourceURL" );
source->setShowLocalProtocol( false );
source->setMode( KFile::Directory | KFile::LocalOnly );
- QLabel *destination_label = new QLabel( i18n( "Destination:" ), frame, "DestinationURLLabel" );
+ TQLabel *destination_label = new TQLabel( i18n( "Destination:" ), frame, "DestinationURLLabel" );
KURLRequester *destination = new KURLRequester( Smb4KSettings::rsyncPrefix(), frame, "DestinationURL" );
destination->setShowLocalProtocol( false );
destination->setMode( KFile::Directory | KFile::LocalOnly );
- KLineEdit *current_file = new KLineEdit( QString::null, frame, "ProgressInfo" );
+ KLineEdit *current_file = new KLineEdit( TQString(), frame, "ProgressInfo" );
current_file->setEnableSqueezedText( true );
current_file->setReadOnly( true );
@@ -77,46 +77,46 @@ m_share( share )
KProgress *total = new KProgress( frame, "TotalProgress", 0 );
total->setEnabled( false );
- QWidget *transfer_widget = new QWidget( frame, "TransferInfoWidget" );
- QGridLayout *trans_layout = new QGridLayout( transfer_widget );
+ TQWidget *transfer_widget = new TQWidget( frame, "TransferInfoWidget" );
+ TQGridLayout *trans_layout = new TQGridLayout( transfer_widget );
trans_layout->setSpacing( 5 );
trans_layout->setMargin( 0 );
- QLabel *file_label = new QLabel( i18n( "Files transferred:" ), transfer_widget,
+ TQLabel *file_label = new TQLabel( i18n( "Files transferred:" ), transfer_widget,
"FilesTransferredLabel" );
- QLabel *file_trans_label = new QLabel( "0 / 0", transfer_widget,
+ TQLabel *file_trans_label = new TQLabel( "0 / 0", transfer_widget,
"FilesTransferred" );
- QLabel *rate_label = new QLabel( i18n( "Transfer rate:" ), transfer_widget,
+ TQLabel *rate_label = new TQLabel( i18n( "Transfer rate:" ), transfer_widget,
"TransferRateLabel" );
- QLabel *trans_rate_label = new QLabel( "0.00 kB/s", transfer_widget,
+ TQLabel *trans_rate_label = new TQLabel( "0.00 kB/s", transfer_widget,
"TransferRate" );
trans_layout->addWidget( file_label, 0, 0, 0 );
- trans_layout->addWidget( file_trans_label, 0, 1, Qt::AlignRight );
+ trans_layout->addWidget( file_trans_label, 0, 1, TQt::AlignRight );
trans_layout->addWidget( rate_label, 1, 0, 0 );
- trans_layout->addWidget( trans_rate_label, 1, 1, Qt::AlignRight );
+ trans_layout->addWidget( trans_rate_label, 1, 1, TQt::AlignRight );
transfer_widget->setEnabled( false );
- layout->addWidget( source_label, 0, 0, 0 );
- layout->addWidget( source, 0, 1, 0 );
- layout->addWidget( destination_label, 1, 0, 0 );
- layout->addWidget( destination, 1, 1, 0 );
- layout->addMultiCellWidget( current_file, 2, 2, 0, 1, 0 );
- layout->addMultiCellWidget( individual, 3, 3, 0, 1, 0 );
- layout->addMultiCellWidget( total, 4, 4, 0, 1, 0 );
- layout->addMultiCellWidget( transfer_widget, 5, 6, 0, 1, 0 );
+ tqlayout->addWidget( source_label, 0, 0, 0 );
+ tqlayout->addWidget( source, 0, 1, 0 );
+ tqlayout->addWidget( destination_label, 1, 0, 0 );
+ tqlayout->addWidget( destination, 1, 1, 0 );
+ tqlayout->addMultiCellWidget( current_file, 2, 2, 0, 1, 0 );
+ tqlayout->addMultiCellWidget( individual, 3, 3, 0, 1, 0 );
+ tqlayout->addMultiCellWidget( total, 4, 4, 0, 1, 0 );
+ tqlayout->addMultiCellWidget( transfer_widget, 5, 6, 0, 1, 0 );
// Connections
- connect( Smb4KCore::synchronizer(), SIGNAL( progress( const Smb4KSynchronizationInfo & ) ),
- this, SLOT( slotProgress( const Smb4KSynchronizationInfo & ) ) );
+ connect( Smb4KCore::synchronizer(), TQT_SIGNAL( progress( const Smb4KSynchronizationInfo & ) ),
+ this, TQT_SLOT( slotProgress( const Smb4KSynchronizationInfo & ) ) );
- connect( Smb4KCore::synchronizer(), SIGNAL( finished() ),
- this, SLOT( slotSynchronizationFinished() ) );
+ connect( Smb4KCore::synchronizer(), TQT_SIGNAL( finished() ),
+ this, TQT_SLOT( slotSynchronizationFinished() ) );
- setFixedSize( (sizeHint().width() > 350 ? sizeHint().width() : 350), sizeHint().height() );
+ setFixedSize( (tqsizeHint().width() > 350 ? tqsizeHint().width() : 350), tqsizeHint().height() );
}
@@ -127,7 +127,7 @@ Smb4KSynchronizationDialog::~Smb4KSynchronizationDialog()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
@@ -137,23 +137,23 @@ void Smb4KSynchronizationDialog::slotUser1()
// Disable the URL requesters but in a way, that the information
// proviced in them is still readable:
- KURLRequester *source = static_cast<KURLRequester *>( child( "SourceURL", "KURLRequester", true ) );
+ KURLRequester *source = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "SourceURL", "KURLRequester", true )) );
source->lineEdit()->setReadOnly( true );
source->button()->setEnabled( false );
- KURLRequester *destination = static_cast<KURLRequester *>( child( "DestinationURL", "KURLRequester", true ) );
+ KURLRequester *destination = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "DestinationURL", "KURLRequester", true )) );
destination->lineEdit()->setReadOnly( true );
destination->button()->setEnabled( false );
- QWidget *transfer_widget = static_cast<QWidget *>( child( "TransferInfoWidget", "QWidget", true ) );
+ TQWidget *transfer_widget = static_cast<TQWidget *>( TQT_TQWIDGET(child( "TransferInfoWidget", TQWIDGET_OBJECT_NAME_STRING, true )) );
transfer_widget->setEnabled( true );
enableButton( User1, false );
enableButton( User2, false );
// Enable the progress bars and the information widgets:
- static_cast<KProgress *>( child( "IndividualProgress", "KProgress", true ) )->setEnabled( true );
- static_cast<KProgress *>( child( "TotalProgress", "KProgress", true ) )->setEnabled( true );
+ static_cast<KProgress *>( TQT_TQWIDGET(child( "IndividualProgress", "KProgress", true )) )->setEnabled( true );
+ static_cast<KProgress *>( TQT_TQWIDGET(child( "TotalProgress", "KProgress", true )) )->setEnabled( true );
Smb4KCore::synchronizer()->synchronize( source->url(), destination->url() );
}
@@ -163,11 +163,11 @@ void Smb4KSynchronizationDialog::slotUser2()
{
// Swap URLs.
- KURLRequester *source = static_cast<KURLRequester *>( child( "SourceURL", "KURLRequester", true ) );
- KURLRequester *destination = static_cast<KURLRequester *>( child( "DestinationURL", "KURLRequester", true ) );
+ KURLRequester *source = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "SourceURL", "KURLRequester", true )) );
+ KURLRequester *destination = static_cast<KURLRequester *>( TQT_TQWIDGET(child( "DestinationURL", "KURLRequester", true )) );
- QString sourceURL = source->url();
- QString destinationURL = destination->url();
+ TQString sourceURL = source->url();
+ TQString destinationURL = destination->url();
source->setURL( destinationURL );
destination->setURL( sourceURL );
@@ -184,11 +184,11 @@ void Smb4KSynchronizationDialog::slotCancel()
void Smb4KSynchronizationDialog::slotProgress( const Smb4KSynchronizationInfo &info )
{
- KLineEdit *progress = static_cast<KLineEdit *>( child( "ProgressInfo", "KLineEdit", true ) );
- KProgress *individual = static_cast<KProgress *>( child( "IndividualProgress", "KProgress", true ) );
- KProgress *total = static_cast<KProgress *>( child( "TotalProgress", "KProgress", true ) );
- QLabel *transferred = static_cast<QLabel *>( child( "FilesTransferred", "QLabel", true ) );
- QLabel *rate = static_cast<QLabel *>( child( "TransferRate", "QLabel", true ) );
+ KLineEdit *progress = static_cast<KLineEdit *>( TQT_TQWIDGET(child( "ProgressInfo", "KLineEdit", true )) );
+ KProgress *individual = static_cast<KProgress *>( TQT_TQWIDGET(child( "IndividualProgress", "KProgress", true )) );
+ KProgress *total = static_cast<KProgress *>( TQT_TQWIDGET(child( "TotalProgress", "KProgress", true )) );
+ TQLabel *transferred = static_cast<TQLabel *>( TQT_TQWIDGET(child( "FilesTransferred", TQLABEL_OBJECT_NAME_STRING, true )) );
+ TQLabel *rate = static_cast<TQLabel *>( TQT_TQWIDGET(child( "TransferRate", TQLABEL_OBJECT_NAME_STRING, true )) );
if ( !info.text().isEmpty() )
{
@@ -207,7 +207,7 @@ void Smb4KSynchronizationDialog::slotProgress( const Smb4KSynchronizationInfo &i
if ( info.totalFileNumber() != -1 && info.processedFileNumber() != -1 )
{
- transferred->setText( QString( "%1 / %2" ).arg( info.processedFileNumber() ).arg( info.totalFileNumber() ) );
+ transferred->setText( TQString( "%1 / %2" ).tqarg( info.processedFileNumber() ).tqarg( info.totalFileNumber() ) );
}
if ( !info.transferRate().isEmpty() )
@@ -219,8 +219,8 @@ void Smb4KSynchronizationDialog::slotProgress( const Smb4KSynchronizationInfo &i
void Smb4KSynchronizationDialog::slotSynchronizationFinished()
{
- KProgress *individual = static_cast<KProgress *>( child( "IndividualProgress", "KProgress", true ) );
- KProgress *total = static_cast<KProgress *>( child( "TotalProgress", "KProgress", true ) );
+ KProgress *individual = static_cast<KProgress *>( TQT_TQWIDGET(child( "IndividualProgress", "KProgress", true )) );
+ KProgress *total = static_cast<KProgress *>( TQT_TQWIDGET(child( "TotalProgress", "KProgress", true )) );
if ( individual && individual->progress() != 100 )
{
diff --git a/smb4k/dialogs/smb4ksynchronizationdialog.h b/smb4k/dialogs/smb4ksynchronizationdialog.h
index c2c0c2d..00c121f 100644
--- a/smb4k/dialogs/smb4ksynchronizationdialog.h
+++ b/smb4k/dialogs/smb4ksynchronizationdialog.h
@@ -49,6 +49,7 @@ class Smb4KSynchronizationInfo;
class Smb4KSynchronizationDialog : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -56,11 +57,11 @@ class Smb4KSynchronizationDialog : public KDialogBase
*
* @param share The share item
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this dialog
*/
- Smb4KSynchronizationDialog( Smb4KShare *share, QWidget *parent = 0, const char *name = 0 );
+ Smb4KSynchronizationDialog( Smb4KShare *share, TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
diff --git a/smb4k/iconview/smb4ksharesiconview.cpp b/smb4k/iconview/smb4ksharesiconview.cpp
index bb669e1..ca8a289 100644
--- a/smb4k/iconview/smb4ksharesiconview.cpp
+++ b/smb4k/iconview/smb4ksharesiconview.cpp
@@ -38,8 +38,8 @@
#include "../core/smb4kcore.h"
-Smb4KSharesIconView::Smb4KSharesIconView( QWidget *parent, const char *name )
-: KIconView( parent, name )
+Smb4KSharesIconView::Smb4KSharesIconView( TQWidget *tqparent, const char *name )
+: KIconView( tqparent, name )
{
setSelectionMode( KIconView::Single ); // If this is changed, revise dragObject() function.
setResizeMode( KIconView::Adjust );
@@ -55,14 +55,14 @@ Smb4KSharesIconView::Smb4KSharesIconView( QWidget *parent, const char *name )
m_tooltip = NULL;
// Connections:
- connect( this, SIGNAL( pressed( QIconViewItem * ) ),
- this, SLOT( slotPressed( QIconViewItem * ) ) );
+ connect( this, TQT_SIGNAL( pressed( TQIconViewItem * ) ),
+ this, TQT_SLOT( slotPressed( TQIconViewItem * ) ) );
}
Smb4KSharesIconView::~Smb4KSharesIconView()
{
- // The tool tip's parent is 0 and not this icon view.
+ // The tool tip's tqparent is 0 and not this icon view.
if ( m_tooltip )
{
delete m_tooltip;
@@ -112,23 +112,23 @@ void Smb4KSharesIconView::startDrag()
}
-void Smb4KSharesIconView::contentsDragEnterEvent( QDragEnterEvent *e )
+void Smb4KSharesIconView::contentsDragEnterEvent( TQDragEnterEvent *e )
{
e->accept( Smb4KSettings::enableDropSupport() );
}
-void Smb4KSharesIconView::contentsDragMoveEvent( QDragMoveEvent *e )
+void Smb4KSharesIconView::contentsDragMoveEvent( TQDragMoveEvent *e )
{
- QIconViewItem *item = findItem( e->pos() );
+ TQIconViewItem *item = tqfindItem( e->pos() );
e->accept( Smb4KSettings::enableDropSupport() && item );
}
-void Smb4KSharesIconView::contentsDropEvent( QDropEvent *e )
+void Smb4KSharesIconView::contentsDropEvent( TQDropEvent *e )
{
- QIconViewItem *item = findItem( e->pos() );
+ TQIconViewItem *item = tqfindItem( e->pos() );
KURL::List src;
// Do we have to stop here?
@@ -150,7 +150,7 @@ void Smb4KSharesIconView::contentsDropEvent( QDropEvent *e )
{
if ( dest.equals( *it, true ) )
{
- if ( e->source() == this || e->source()->parent() == this )
+ if ( e->source() == this || TQT_BASE_OBJECT(e->source()->tqparent()) == TQT_BASE_OBJECT(this) )
{
e->ignore();
@@ -168,11 +168,11 @@ void Smb4KSharesIconView::contentsDropEvent( QDropEvent *e )
}
-void Smb4KSharesIconView::contentsMouseMoveEvent( QMouseEvent *e )
+void Smb4KSharesIconView::contentsMouseMoveEvent( TQMouseEvent *e )
{
m_pos = e->globalPos();
- Smb4KSharesIconViewItem *item = static_cast<Smb4KSharesIconViewItem *>( findItem( e->pos() ) );
+ Smb4KSharesIconViewItem *item = static_cast<Smb4KSharesIconViewItem *>( tqfindItem( e->pos() ) );
if ( item )
{
@@ -187,7 +187,7 @@ void Smb4KSharesIconView::contentsMouseMoveEvent( QMouseEvent *e )
{
m_tooltip = new Smb4KSharesIconViewToolTip( item );
- QTimer::singleShot( 2000, this, SLOT( slotShowToolTip() ) );
+ TQTimer::singleShot( 2000, this, TQT_SLOT( slotShowToolTip() ) );
}
else
{
@@ -207,7 +207,7 @@ void Smb4KSharesIconView::contentsMouseMoveEvent( QMouseEvent *e )
{
m_tooltip = new Smb4KSharesIconViewToolTip( item );
- QTimer::singleShot( 2000, this, SLOT( slotShowToolTip() ) );
+ TQTimer::singleShot( 2000, this, TQT_SLOT( slotShowToolTip() ) );
}
else
{
@@ -229,10 +229,10 @@ void Smb4KSharesIconView::contentsMouseMoveEvent( QMouseEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
-void Smb4KSharesIconView::slotPressed( QIconViewItem *item )
+void Smb4KSharesIconView::slotPressed( TQIconViewItem *item )
{
if ( m_tooltip )
{
@@ -256,7 +256,7 @@ void Smb4KSharesIconView::slotPressed( QIconViewItem *item )
void Smb4KSharesIconView::slotShowToolTip()
{
if ( m_tooltip && hasMouse() && Smb4KSettings::showShareToolTip() &&
- (m_tooltip->item() == static_cast<Smb4KSharesIconViewItem *>( findItem( viewport()->mapFromGlobal( m_pos ) ) )) )
+ (m_tooltip->item() == static_cast<Smb4KSharesIconViewItem *>( tqfindItem( viewport()->mapFromGlobal( m_pos ) ) )) )
{
m_tooltip->showTip( m_pos );
}
diff --git a/smb4k/iconview/smb4ksharesiconview.h b/smb4k/iconview/smb4ksharesiconview.h
index 048e23d..cecf441 100644
--- a/smb4k/iconview/smb4ksharesiconview.h
+++ b/smb4k/iconview/smb4ksharesiconview.h
@@ -30,8 +30,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qvaluelist.h>
+// TQt includes
+#include <tqvaluelist.h>
// KDE includes
#include <kiconview.h>
@@ -51,16 +51,17 @@ class Smb4KSharesIconViewToolTip;
class Smb4KSharesIconView : public KIconView
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of the widget
*/
- Smb4KSharesIconView( QWidget *parent = 0, const char *name = 0 );
+ Smb4KSharesIconView( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -75,7 +76,7 @@ class Smb4KSharesIconView : public KIconView
protected:
/**
- * Reimplemented (sort of) from QIconView to enable dragging. As QDragObject
+ * Reimplemented (sort of) from TQIconView to enable dragging. As TQDragObject
* a KURLDrag will be returned.
*
* @returns a KURLDrag object.
@@ -83,41 +84,41 @@ class Smb4KSharesIconView : public KIconView
KURLDrag *dragObject();
/**
- * Reimplemented from QIconView to allow some actions to be carried
+ * Reimplemented from TQIconView to allow some actions to be carried
* out before the drag begins.
*/
void startDrag();
/**
- * Reimplemented from QIconView.
+ * Reimplemented from TQIconView.
*/
- void contentsDragEnterEvent( QDragEnterEvent * );
+ void contentsDragEnterEvent( TQDragEnterEvent * );
/**
- * Reimplemented from QIconView.
+ * Reimplemented from TQIconView.
*/
- void contentsDragMoveEvent( QDragMoveEvent *e );
+ void contentsDragMoveEvent( TQDragMoveEvent *e );
/**
- * Reimplemented from QIconView.
+ * Reimplemented from TQIconView.
*/
- void contentsDropEvent( QDropEvent *e );
+ void contentsDropEvent( TQDropEvent *e );
/**
- * Reimplemented from QIconView. This function is used to
+ * Reimplemented from TQIconView. This function is used to
* show the tooltips.
*/
- void contentsMouseMoveEvent( QMouseEvent *e );
+ void contentsMouseMoveEvent( TQMouseEvent *e );
protected slots:
/**
* This slot is connected to KIconView::pressed() and clears the selection
* if the user clicked on the viewport.
*
- * @param item The QIconViewItem that the user clicked or NULL
+ * @param item The TQIconViewItem that the user clicked or NULL
* if he/she pressed a mouse button on the viewport.
*/
- void slotPressed( QIconViewItem *item );
+ void slotPressed( TQIconViewItem *item );
/**
* This slot shows the tool tip for an icon view item.
@@ -128,7 +129,7 @@ class Smb4KSharesIconView : public KIconView
/**
* The current global mouse position
*/
- QPoint m_pos;
+ TQPoint m_pos;
/**
* The tool tip
diff --git a/smb4k/iconview/smb4ksharesiconview_part.cpp b/smb4k/iconview/smb4ksharesiconview_part.cpp
index 0f47631..ab46025 100644
--- a/smb4k/iconview/smb4ksharesiconview_part.cpp
+++ b/smb4k/iconview/smb4ksharesiconview_part.cpp
@@ -51,9 +51,9 @@ KInstance *Smb4KSharesIconViewPartFactory::m_instance = 0L;
KAboutData *Smb4KSharesIconViewPartFactory::m_about = 0L;
-Smb4KSharesIconViewPart::Smb4KSharesIconViewPart( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name )
-: KParts::Part( parent, name )
+Smb4KSharesIconViewPart::Smb4KSharesIconViewPart( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name )
+: KParts::Part( tqparent, name )
{
// First of all We need an instance:
setInstance( Smb4KSharesIconViewPartFactory::instance() );
@@ -62,7 +62,7 @@ Smb4KSharesIconViewPart::Smb4KSharesIconViewPart( QWidget *parentWidget, const c
setXMLFile( "smb4ksharesiconview_part.rc" );
// Set the widget of this part:
- m_widget = new Smb4KSharesIconView( parentWidget, widgetName );
+ m_widget = new Smb4KSharesIconView( tqparentWidget, widgetName );
setWidget( m_widget );
// Set up the actions.
@@ -77,23 +77,23 @@ Smb4KSharesIconViewPart::Smb4KSharesIconViewPart( QWidget *parentWidget, const c
loadSettings();
// Add some connections:
- connect( Smb4KCore::mounter(), SIGNAL( updated() ),
- this, SLOT( slotMountedShares() ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( updated() ),
+ this, TQT_SLOT( slotMountedShares() ) );
- connect( Smb4KCore::synchronizer(), SIGNAL( state( int ) ),
- this, SLOT( slotSynchronizationState( int ) ) );
+ connect( Smb4KCore::synchronizer(), TQT_SIGNAL( state( int ) ),
+ this, TQT_SLOT( slotSynchronizationState( int ) ) );
- connect( m_widget, SIGNAL( contextMenuRequested( QIconViewItem *, const QPoint & ) ),
- this, SLOT( slotContextMenuRequested( QIconViewItem *, const QPoint & ) ) );
+ connect( m_widget, TQT_SIGNAL( contextMenuRequested( TQIconViewItem *, const TQPoint & ) ),
+ this, TQT_SLOT( slotContextMenuRequested( TQIconViewItem *, const TQPoint & ) ) );
- connect( m_widget, SIGNAL( selectionChanged( QIconViewItem * ) ),
- this, SLOT( slotSelectionChanged( QIconViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( selectionChanged( TQIconViewItem * ) ),
+ this, TQT_SLOT( slotSelectionChanged( TQIconViewItem * ) ) );
- connect( m_widget, SIGNAL( pressed( QIconViewItem * ) ),
- this, SLOT( slotMouseButtonPressed( QIconViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( pressed( TQIconViewItem * ) ),
+ this, TQT_SLOT( slotMouseButtonPressed( TQIconViewItem * ) ) );
- connect( m_widget, SIGNAL( executed( QIconViewItem * ) ),
- this, SLOT( slotFilemanager() ) );
+ connect( m_widget, TQT_SIGNAL( executed( TQIconViewItem * ) ),
+ this, TQT_SLOT( slotFilemanager() ) );
}
@@ -106,24 +106,24 @@ void Smb4KSharesIconViewPart::setupActions()
{
// Create the actions:
KAction *unmount = new KAction( i18n( "&Unmount" ), "hdd_unmount", KShortcut( CTRL+Key_U ),
- this, SLOT( slotUnmountShare() ),
+ this, TQT_SLOT( slotUnmountShare() ),
actionCollection(), "unmount_action" );
#ifdef __linux__
KAction *force = new KAction( i18n( "&Force Unmounting" ), "hdd_unmount", KShortcut( CTRL+Key_F ),
- this, SLOT( slotForceUnmountShare() ),
+ this, TQT_SLOT( slotForceUnmountShare() ),
actionCollection(), "force_unmount_action" );
#endif
KAction *all = new KAction( i18n( "U&nmount All" ), "gear", KShortcut( CTRL+Key_N ),
- this, SLOT( slotUnmountAllShares() ),
+ this, TQT_SLOT( slotUnmountAllShares() ),
actionCollection(), "unmount_all_action" );
KAction *sync = new KAction( i18n( "S&ynchronize" ), "bottom", KShortcut( CTRL+Key_Y ),
- this, SLOT( slotSynchronize() ),
+ this, TQT_SLOT( slotSynchronize() ),
actionCollection(), "synchronize_action" );
KAction *konsole = new KAction( i18n( "Open with Konso&le" ), "terminal", KShortcut( CTRL+Key_L ),
- this, SLOT( slotKonsole() ),
+ this, TQT_SLOT( slotKonsole() ),
actionCollection(), "konsole_action" );
KAction *konq = new KAction( i18n( "Open with &Konqueror" ), "kfm_home", KShortcut( CTRL+Key_K ),
- this, SLOT( slotFilemanager() ),
+ this, TQT_SLOT( slotFilemanager() ),
actionCollection(), "filemanager_action" );
// Disable all actions for now:
@@ -159,7 +159,7 @@ void Smb4KSharesIconViewPart::loadSettings()
#endif
// Change the text of the share:
- for ( QIconViewItem *it = m_widget->firstItem(); it; it = it->nextItem() )
+ for ( TQIconViewItem *it = m_widget->firstItem(); it; it = it->nextItem() )
{
Smb4KSharesIconViewItem *item = static_cast<Smb4KSharesIconViewItem *>( it );
@@ -180,7 +180,7 @@ void Smb4KSharesIconViewPart::loadSettings()
}
-void Smb4KSharesIconViewPart::customEvent( QCustomEvent *e )
+void Smb4KSharesIconViewPart::customEvent( TQCustomEvent *e )
{
switch ( e->type() )
{
@@ -217,10 +217,10 @@ void Smb4KSharesIconViewPart::customEvent( QCustomEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS (Smb4KSharesIconViewPart)
+// TQT_SLOT IMPLEMENTATIONS (Smb4KSharesIconViewPart)
/////////////////////////////////////////////////////////////////////////////
-void Smb4KSharesIconViewPart::slotContextMenuRequested( QIconViewItem *item, const QPoint &pos )
+void Smb4KSharesIconViewPart::slotContextMenuRequested( TQIconViewItem *item, const TQPoint &pos )
{
if ( item )
{
@@ -236,7 +236,7 @@ void Smb4KSharesIconViewPart::slotContextMenuRequested( QIconViewItem *item, con
}
-void Smb4KSharesIconViewPart::slotSelectionChanged( QIconViewItem *item )
+void Smb4KSharesIconViewPart::slotSelectionChanged( TQIconViewItem *item )
{
// NOTE: Here we only enable or disable the KActions. All other things
// are done in the Smb4KSharesIconView class.
@@ -275,7 +275,7 @@ void Smb4KSharesIconViewPart::slotSelectionChanged( QIconViewItem *item )
}
-void Smb4KSharesIconViewPart::slotMouseButtonPressed( QIconViewItem *item )
+void Smb4KSharesIconViewPart::slotMouseButtonPressed( TQIconViewItem *item )
{
// NOTE: Here we only enable or disable the KActions. All other things
// are done in the Smb4KSharesIconView class.
@@ -303,7 +303,7 @@ void Smb4KSharesIconViewPart::slotMouseButtonPressed( QIconViewItem *item )
void Smb4KSharesIconViewPart::slotMountedShares()
{
// Get the list of shares:
- QValueList<Smb4KShare *> list = Smb4KCore::mounter()->getShares();
+ TQValueList<Smb4KShare *> list = Smb4KCore::mounter()->getShares();
// Update the view:
if ( !list.isEmpty() )
@@ -329,15 +329,15 @@ void Smb4KSharesIconViewPart::slotMountedShares()
// Now process the entries in the list:
bool already_in_view = false;
- for ( QValueListConstIterator<Smb4KShare *> it = list.begin(); it != list.end(); ++it )
+ for ( TQValueListConstIterator<Smb4KShare *> it = list.begin(); it != list.end(); ++it )
{
// Check, whether the share is already in the list. Look for the
// mount point.
for ( Smb4KSharesIconViewItem *item = static_cast<Smb4KSharesIconViewItem *>( m_widget->firstItem() );
item; item = static_cast<Smb4KSharesIconViewItem *>( item->nextItem() ) )
{
- if ( QString::compare( item->shareObject()->path(), (*it)->path() ) == 0 ||
- QString::compare( item->shareObject()->canonicalPath(), (*it)->canonicalPath() ) == 0 )
+ if ( TQString::compare( item->shareObject()->path(), (*it)->path() ) == 0 ||
+ TQString::compare( item->shareObject()->canonicalPath(), (*it)->canonicalPath() ) == 0 )
{
// Replace the share object if something changed:
if ( !item->sameShareObject( *it ) )
@@ -389,7 +389,7 @@ void Smb4KSharesIconViewPart::slotMountedShares()
}
// Enable/disable the actions:
- QIconViewItem *item = m_widget->currentItem();
+ TQIconViewItem *item = m_widget->currentItem();
bool have_selected_item = (item && item->isSelected());
actionCollection()->action( "unmount_action" )->setEnabled( have_selected_item );
@@ -444,7 +444,7 @@ void Smb4KSharesIconViewPart::slotUnmountAllShares()
void Smb4KSharesIconViewPart::slotSynchronize()
{
Smb4KSharesIconViewItem *item = static_cast<Smb4KSharesIconViewItem *>( m_widget->currentItem() );
- Smb4KSynchronizationDialog *dlg = static_cast<Smb4KSynchronizationDialog *>( m_widget->child( "SynchronizationDialog", "Smb4KSynchronizationDialog", true ) );
+ Smb4KSynchronizationDialog *dlg = static_cast<Smb4KSynchronizationDialog *>( TQT_TQWIDGET(m_widget->child( "SynchronizationDialog", "Smb4KSynchronizationDialog", true )) );
if ( item && !item->shareObject()->isBroken() && !dlg )
{
@@ -527,13 +527,13 @@ Smb4KSharesIconViewPartFactory::~Smb4KSharesIconViewPartFactory()
}
-KParts::Part *Smb4KSharesIconViewPartFactory::createPartObject( QWidget *parentWidget, const char *widgetName,
-QObject *parent, const char *name, const char *, const QStringList & )
+KParts::Part *Smb4KSharesIconViewPartFactory::createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+TQObject *tqparent, const char *name, const char *, const TQStringList & )
{
- Smb4KSharesIconViewPart *obj = new Smb4KSharesIconViewPart( parentWidget, widgetName, parent, name );
+ Smb4KSharesIconViewPart *obj = new Smb4KSharesIconViewPart( tqparentWidget, widgetName, tqparent, name );
// See if we are to be read-write or not
-// if (QCString(classname) == "KParts::ReadOnlyPart")
+// if (TQCString(classname) == "KParts::ReadOnlyPart")
// {
// obj->setReadWrite(false);
// }
diff --git a/smb4k/iconview/smb4ksharesiconview_part.h b/smb4k/iconview/smb4ksharesiconview_part.h
index f9d482b..1df5547 100644
--- a/smb4k/iconview/smb4ksharesiconview_part.h
+++ b/smb4k/iconview/smb4ksharesiconview_part.h
@@ -48,21 +48,22 @@
class Smb4KSharesIconViewPart : public KParts::Part
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parentWidget The parent widget
+ * @param tqparentWidget The tqparent widget
*
* @param widgetName The name the widget should have
*
- * @param parent The parent object
+ * @param tqparent The tqparent object
*
* @param name The name this object should have
*/
- Smb4KSharesIconViewPart( QWidget *parentWidget = 0, const char *widgetName = 0,
- QObject *parent = 0, const char *name = 0 );
+ Smb4KSharesIconViewPart( TQWidget *tqparentWidget = 0, const char *widgetName = 0,
+ TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -73,7 +74,7 @@ class Smb4KSharesIconViewPart : public KParts::Part
/**
* Reimplemented from KParts::Part.
*/
- void customEvent( QCustomEvent *e );
+ void customEvent( TQCustomEvent *e );
protected slots:
/**
@@ -85,7 +86,7 @@ class Smb4KSharesIconViewPart : public KParts::Part
*
* @param pos The position where the user clicked.
*/
- void slotContextMenuRequested( QIconViewItem *item, const QPoint & pos );
+ void slotContextMenuRequested( TQIconViewItem *item, const TQPoint & pos );
/**
* This slot is called when the selection in the icon view changed. It
@@ -95,7 +96,7 @@ class Smb4KSharesIconViewPart : public KParts::Part
*
* @param item The icon view item that was selected
*/
- void slotSelectionChanged( QIconViewItem *item );
+ void slotSelectionChanged( TQIconViewItem *item );
/**
* This slot is called when the user presses any mouse button somewhere
@@ -105,7 +106,7 @@ class Smb4KSharesIconViewPart : public KParts::Part
* @param item The icon view item that was clicked or NULL if the
* user clicked onto the viewport.
*/
- void slotMouseButtonPressed( QIconViewItem *item );
+ void slotMouseButtonPressed( TQIconViewItem *item );
/**
* This slot is called by the Smb4KMounter::updated() signal and updates
@@ -192,6 +193,7 @@ class KAboutData;
class Smb4KSharesIconViewPartFactory : public KParts::Factory
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -207,9 +209,9 @@ class Smb4KSharesIconViewPartFactory : public KParts::Factory
/**
* Reimplemented from KParts::Factory
*/
- virtual KParts::Part *createPartObject( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
- const char *classname, const QStringList &args );
+ virtual KParts::Part *createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name,
+ const char *classname, const TQStringList &args );
/**
* The instance
diff --git a/smb4k/iconview/smb4ksharesiconviewitem.cpp b/smb4k/iconview/smb4ksharesiconviewitem.cpp
index c54a734..7ac94a3 100644
--- a/smb4k/iconview/smb4ksharesiconviewitem.cpp
+++ b/smb4k/iconview/smb4ksharesiconviewitem.cpp
@@ -23,8 +23,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qpixmap.h>
+// TQt includes
+#include <tqpixmap.h>
// KDE includes
#include <kiconeffect.h>
@@ -35,8 +35,8 @@
#include "smb4ksharesiconview.h"
Smb4KSharesIconViewItem::Smb4KSharesIconViewItem( Smb4KShare *share, bool mountpoint,
- Smb4KSharesIconView *parent )
-: KIconViewItem( parent, QString::null ), m_share( *share ), m_mountpoint( mountpoint ),
+ Smb4KSharesIconView *tqparent )
+: KIconViewItem( tqparent, TQString() ), m_share( *share ), m_mountpoint( mountpoint ),
m_initial_setup( false )
{
setDropEnabled( true );
@@ -55,21 +55,21 @@ Smb4KSharesIconViewItem::~Smb4KSharesIconViewItem()
}
-void Smb4KSharesIconViewItem::paintItem( QPainter *p, const QColorGroup &cg )
+void Smb4KSharesIconViewItem::paintItem( TQPainter *p, const TQColorGroup &cg )
{
// Set the color of the item text:
- QColorGroup colorgrp( cg );
+ TQColorGroup colorgrp( cg );
if ( m_share.isForeign() )
{
- colorgrp.setColor( QColorGroup::Text, Qt::gray );
+ colorgrp.setColor( TQColorGroup::Text, TQt::gray );
}
- QIconViewItem::paintItem( p, colorgrp );
+ TQIconViewItem::paintItem( p, colorgrp );
}
-bool Smb4KSharesIconViewItem::acceptDrop( const QMimeSource *source ) const
+bool Smb4KSharesIconViewItem::acceptDrop( const TQMimeSource *source ) const
{
if ( source->provides( "text/plain" ) )
{
@@ -92,16 +92,16 @@ void Smb4KSharesIconViewItem::setupItem( const Smb4KShare &share, bool mountpoin
if ( m_share.isBroken() )
{
- QImage over = m_loader->loadIcon( "button_cancel", KIcon::Desktop,
+ TQImage over = m_loader->loadIcon( "button_cancel", KIcon::Desktop,
0, icon_state, 0L, false ).convertToImage();
- QImage src = m_loader->loadIcon( "hdd_mount", KIcon::Desktop,
+ TQImage src = m_loader->loadIcon( "hdd_mount", KIcon::Desktop,
0, icon_state, 0L, false ).convertToImage();
KIconEffect e;
e.semiTransparent( over );
e.overlay( src, over );
- m_pixmap = QPixmap( src );
+ m_pixmap = TQPixmap( src );
}
else
{
diff --git a/smb4k/iconview/smb4ksharesiconviewitem.h b/smb4k/iconview/smb4ksharesiconviewitem.h
index c18360f..eba33d6 100644
--- a/smb4k/iconview/smb4ksharesiconviewitem.h
+++ b/smb4k/iconview/smb4ksharesiconviewitem.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qpainter.h>
-#include <qpalette.h>
+// TQt includes
+#include <tqpainter.h>
+#include <tqpalette.h>
// KDE includes
#include <kiconview.h>
@@ -62,11 +62,11 @@ class Smb4KSharesIconViewItem : public KIconViewItem
* @param mountpoint Tells the item if the mount point instead of the
* share name should be shown. Default is FALSE.
*
- * @param parent The parent widget of this item.
+ * @param tqparent The tqparent widget of this item.
*/
Smb4KSharesIconViewItem( Smb4KShare *share,
bool mountpoint = false,
- Smb4KSharesIconView *parent = 0 );
+ Smb4KSharesIconView *tqparent = 0 );
/**
* The destructor
@@ -105,11 +105,11 @@ class Smb4KSharesIconViewItem : public KIconViewItem
*
* @returns the destop pixmap of this item.
*/
- const QPixmap &desktopPixmap() { return m_pixmap; }
+ const TQPixmap &desktopPixmap() { return m_pixmap; }
protected:
/**
- * Reimplemented from QIconViewItem.
+ * Reimplemented from TQIconViewItem.
*
* This function paints the icon text and uses Smb4KShare::isForeign() to
* determine the color (TRUE: gray, FALSE: the default color).
@@ -118,17 +118,17 @@ class Smb4KSharesIconViewItem : public KIconViewItem
*
* @param cg The color group
*/
- void paintItem( QPainter *p,
- const QColorGroup &cg );
+ void paintItem( TQPainter *p,
+ const TQColorGroup &cg );
/**
- * Reimplemented from QIconViewItem.
+ * Reimplemented from TQIconViewItem.
*
* This function accepts or denies drops according to the contents of @p source.
*
* @param source The mime source
*/
- bool acceptDrop( const QMimeSource *source ) const;
+ bool acceptDrop( const TQMimeSource *source ) const;
private:
/**
@@ -166,7 +166,7 @@ class Smb4KSharesIconViewItem : public KIconViewItem
/**
* The desktop pixmap
*/
- QPixmap m_pixmap;
+ TQPixmap m_pixmap;
};
#endif
diff --git a/smb4k/iconview/smb4ksharesiconviewtooltip.cpp b/smb4k/iconview/smb4ksharesiconviewtooltip.cpp
index 7f33fce..0fc29a6 100644
--- a/smb4k/iconview/smb4ksharesiconviewtooltip.cpp
+++ b/smb4k/iconview/smb4ksharesiconviewtooltip.cpp
@@ -23,11 +23,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qtooltip.h>
-#include <qapplication.h>
-#include <qdesktopwidget.h>
-#include <qtimer.h>
+// TQt includes
+#include <tqtooltip.h>
+#include <tqapplication.h>
+#include <tqdesktopwidget.h>
+#include <tqtimer.h>
// KDE includes
#include <klocale.h>
@@ -39,17 +39,17 @@
Smb4KSharesIconViewToolTip::Smb4KSharesIconViewToolTip( Smb4KSharesIconViewItem *item )
-: QLabel( 0, "SharesIconViewToolTip", WStyle_StaysOnTop | WStyle_Customize |
+: TQLabel( 0, "SharesIconViewToolTip", WStyle_StaysOnTop | WStyle_Customize |
WStyle_NoBorder | WStyle_Tool | WX11BypassWM | WDestructiveClose ), m_item( item )
{
- setPalette( QToolTip::palette() );
+ setPalette( TQToolTip::palette() );
setLineWidth( 1 );
setMidLineWidth( 1 );
setFrameShape( Box );
setFrameShadow( Plain );
setMouseTracking( true );
- m_layout = new QGridLayout( this );
+ m_layout = new TQGridLayout( this );
m_layout->setMargin( 10 );
m_layout->setSpacing( 3 );
@@ -71,7 +71,7 @@ Smb4KSharesIconViewToolTip::~Smb4KSharesIconViewToolTip()
}
-void Smb4KSharesIconViewToolTip::showTip( const QPoint &pos )
+void Smb4KSharesIconViewToolTip::showTip( const TQPoint &pos )
{
if ( !m_item || isShown() )
{
@@ -82,8 +82,8 @@ void Smb4KSharesIconViewToolTip::showTip( const QPoint &pos )
adjustSize();
- QDesktopWidget *d = QApplication::desktop();
- QPoint p( pos );
+ TQDesktopWidget *d = TQApplication::desktop();
+ TQPoint p( pos );
if ( p.x() + width() > d->width() )
{
@@ -106,7 +106,7 @@ void Smb4KSharesIconViewToolTip::showTip( const QPoint &pos )
setGeometry( p.x(), p.y(), width(), height() );
polish();
show();
- QTimer::singleShot( 10000, this, SLOT( slotHideToolTip() ) );
+ TQTimer::singleShot( 10000, this, TQT_SLOT( slotHideToolTip() ) );
}
@@ -117,38 +117,38 @@ void Smb4KSharesIconViewToolTip::setupTip()
return;
}
- m_layout->addWidget( new QLabel( i18n( "Share:" ), this ), 0, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->name(), this ), 0, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Mount point:" ), this ), 1, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->path(), this ), 1, 2, 0 );
+ m_layout->addWidget( new TQLabel( i18n( "Share:" ), this ), 0, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->name(), this ), 0, 2, 0 );
+ m_layout->addWidget( new TQLabel( i18n( "Mount point:" ), this ), 1, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->path(), this ), 1, 2, 0 );
- if ( QString::compare( m_item->shareObject()->filesystem(), "smbfs" ) == 0 )
+ if ( TQString::compare( m_item->shareObject()->filesystem(), "smbfs" ) == 0 )
{
- m_layout->addWidget( new QLabel( "Owner:", this ), 2, 1, 0 );
- m_layout->addWidget( new QLabel( QString( "%1 - %2" ).arg( m_item->shareObject()->user(), m_item->shareObject()->group() ), this ), 2, 2, 0 );
+ m_layout->addWidget( new TQLabel( "Owner:", this ), 2, 1, 0 );
+ m_layout->addWidget( new TQLabel( TQString( "%1 - %2" ).tqarg( m_item->shareObject()->user(), m_item->shareObject()->group() ), this ), 2, 2, 0 );
}
else
{
- m_layout->addWidget( new QLabel( "Login:", this ), 2, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->cifsLogin(), this ), 2, 2, 0 );
+ m_layout->addWidget( new TQLabel( "Login:", this ), 2, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->cifsLogin(), this ), 2, 2, 0 );
}
- m_layout->addWidget( new QLabel( i18n( "File system:" ), this ), 3, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->filesystem().upper(), this ), 3, 2, 0 );
+ m_layout->addWidget( new TQLabel( i18n( "File system:" ), this ), 3, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->filesystem().upper(), this ), 3, 2, 0 );
- QFrame *line = new QFrame( this );
+ TQFrame *line = new TQFrame( this );
line->setLineWidth( 1 );
line->setMidLineWidth( 0 );
line->setFixedWidth( 100 );
- line->setFrameShape( QFrame::HLine );
- line->setFrameShadow( QFrame::Plain );
+ line->setFrameShape( TQFrame::HLine );
+ line->setFrameShadow( TQFrame::Plain );
- m_layout->addMultiCellWidget( line, 4, 4, 1, 2, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( line, 4, 4, 1, 2, TQt::AlignCenter );
// Prepare the disk usage stuff.
if ( !m_item->shareObject()->isBroken() )
{
- QString total, free, used, total_dim, free_dim, used_dim;
+ TQString total, free, used, total_dim, free_dim, used_dim;
if ( m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace() > 1024 )
{
@@ -161,13 +161,13 @@ void Smb4KSharesIconViewToolTip::setupTip()
used_dim = "GB";
}
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
else
{
used_dim = "kB";
double tmp_used = m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace();
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
if ( m_item->shareObject()->freeDiskSpace() >= 1024 )
@@ -181,12 +181,12 @@ void Smb4KSharesIconViewToolTip::setupTip()
free_dim = "GB";
}
- free = QString( "%1" ).arg( tmp_free, 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( tmp_free, 0, 'f', 1 );
}
else
{
free_dim = "kB";
- free = QString( "%1" ).arg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
}
if ( m_item->shareObject()->totalDiskSpace() >= 1024 )
@@ -200,46 +200,46 @@ void Smb4KSharesIconViewToolTip::setupTip()
total_dim = "GB";
}
- total = QString( "%1" ).arg( tmp_total, 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( tmp_total, 0, 'f', 1 );
}
else
{
total_dim = "kB";
- total = QString( "%1" ).arg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
}
- m_layout->addWidget( new QLabel( i18n( "Free:" ), this, "FreeLabel" ), 5, 1, 0 );
- m_free = new QLabel( QString( "%1 %2" ).arg( free, free_dim ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Free:" ), this, "FreeLabel" ), 5, 1, 0 );
+ m_free = new TQLabel( TQString( "%1 %2" ).tqarg( free, free_dim ), this );
m_layout->addWidget( m_free, 5, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Used:" ), this, "UsedLabel" ), 6, 1, 0 );
- m_used = new QLabel( QString( "%1 %2" ).arg( used, used_dim ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Used:" ), this, "UsedLabel" ), 6, 1, 0 );
+ m_used = new TQLabel( TQString( "%1 %2" ).tqarg( used, used_dim ), this );
m_layout->addWidget( m_used, 6, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Total:" ), this, "TotalLabel" ), 7, 1, 0 );
- m_total = new QLabel( QString( "%1 %2" ).arg( total, total_dim ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Total:" ), this, "TotalLabel" ), 7, 1, 0 );
+ m_total = new TQLabel( TQString( "%1 %2" ).tqarg( total, total_dim ), this );
m_layout->addWidget( m_total, 7, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Usage:" ), this, "UsageLabel" ), 8, 1, 0 );
- m_usage = new QLabel( QString( "%1 %" ).arg( m_item->shareObject()->percentage(), 0, 'f', 1 ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Usage:" ), this, "UsageLabel" ), 8, 1, 0 );
+ m_usage = new TQLabel( TQString( "%1 %" ).tqarg( m_item->shareObject()->percentage(), 0, 'f', 1 ), this );
m_layout->addWidget( m_usage, 8, 2, 0 );
}
else
{
- QLabel *error = new QLabel( i18n( "This share is inaccessible." ), this );
+ TQLabel *error = new TQLabel( i18n( "This share is inaccessible." ), this );
- QFont font;
+ TQFont font;
font.setItalic( true );
error->setFont( font );
- m_layout->addMultiCellWidget( error, 5, 5, 1, 2, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( error, 5, 5, 1, 2, TQt::AlignCenter );
}
- m_pixmap = new QLabel( this );
+ m_pixmap = new TQLabel( this );
m_pixmap->setPixmap( m_item->desktopPixmap() );
- m_layout->addMultiCellWidget( m_pixmap, 0, m_layout->numRows(), 0, 0, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( m_pixmap, 0, m_layout->numRows(), 0, 0, TQt::AlignCenter );
m_is_set_up = true;
}
@@ -255,7 +255,7 @@ void Smb4KSharesIconViewToolTip::update()
// Only change the variable entries:
if ( !m_item->shareObject()->isBroken() )
{
- QString total, free, used, total_dim, free_dim, used_dim;
+ TQString total, free, used, total_dim, free_dim, used_dim;
if ( m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace() > 1024 )
{
@@ -268,13 +268,13 @@ void Smb4KSharesIconViewToolTip::update()
used_dim = "GB";
}
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
else
{
used_dim = "kB";
double tmp_used = m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace();
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
if ( m_item->shareObject()->freeDiskSpace() >= 1024 )
@@ -288,12 +288,12 @@ void Smb4KSharesIconViewToolTip::update()
free_dim = "GB";
}
- free = QString( "%1" ).arg( tmp_free, 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( tmp_free, 0, 'f', 1 );
}
else
{
free_dim = "kB";
- free = QString( "%1" ).arg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
}
if ( m_item->shareObject()->totalDiskSpace() >= 1024 )
@@ -307,22 +307,22 @@ void Smb4KSharesIconViewToolTip::update()
total_dim = "GB";
}
- total = QString( "%1" ).arg( tmp_total, 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( tmp_total, 0, 'f', 1 );
}
else
{
total_dim = "kB";
- total = QString( "%1" ).arg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
}
- m_free->setText( QString( "%1 %2" ).arg( free, free_dim ) );
- m_used->setText( QString( "%1 %2" ).arg( used, used_dim ) );
- m_total->setText( QString( "%1 %2" ).arg( total, total_dim ) );
- m_usage->setText( QString( "%1 %" ).arg( m_item->shareObject()->percentage(), 0, 'f', 1 ) );
+ m_free->setText( TQString( "%1 %2" ).tqarg( free, free_dim ) );
+ m_used->setText( TQString( "%1 %2" ).tqarg( used, used_dim ) );
+ m_total->setText( TQString( "%1 %2" ).tqarg( total, total_dim ) );
+ m_usage->setText( TQString( "%1 %" ).tqarg( m_item->shareObject()->percentage(), 0, 'f', 1 ) );
}
else
{
- QLabel *free_label = static_cast<QLabel *>( child( "FreeLabel", "QLabel" ) );
+ TQLabel *free_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "FreeLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( free_label )
{
@@ -337,7 +337,7 @@ void Smb4KSharesIconViewToolTip::update()
m_free = NULL;
}
- QLabel *used_label = static_cast<QLabel *>( child( "UsedLabel", "QLabel" ) );
+ TQLabel *used_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "UsedLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( used_label )
{
@@ -352,7 +352,7 @@ void Smb4KSharesIconViewToolTip::update()
m_used = NULL;
}
- QLabel *total_label = static_cast<QLabel *>( child( "TotalLabel", "QLabel" ) );
+ TQLabel *total_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "TotalLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( total_label )
{
@@ -367,7 +367,7 @@ void Smb4KSharesIconViewToolTip::update()
m_total = NULL;
}
- QLabel *usage_label = static_cast<QLabel *>( child( "UsageLabel", "QLabel" ) );
+ TQLabel *usage_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "UsageLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( usage_label )
{
@@ -382,40 +382,40 @@ void Smb4KSharesIconViewToolTip::update()
m_usage = NULL;
}
- QFont font;
+ TQFont font;
font.setItalic( true );
- QLabel *error = new QLabel( i18n( "This share is inaccessible." ), this );
+ TQLabel *error = new TQLabel( i18n( "This share is inaccessible." ), this );
error->setFont( font );
error->show();
m_layout->remove( m_pixmap );
m_pixmap->setPixmap( m_item->desktopPixmap() );
- m_layout->addMultiCellWidget( error, 5, 5, 1, 2, Qt::AlignCenter );
- m_layout->addMultiCellWidget( m_pixmap, 0, 5, 0, 0, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( error, 5, 5, 1, 2, TQt::AlignCenter );
+ m_layout->addMultiCellWidget( m_pixmap, 0, 5, 0, 0, TQt::AlignCenter );
}
adjustSize();
}
-void Smb4KSharesIconViewToolTip::mousePressEvent( QMouseEvent *e )
+void Smb4KSharesIconViewToolTip::mousePressEvent( TQMouseEvent *e )
{
hide();
- QLabel::mousePressEvent( e );
+ TQLabel::mousePressEvent( e );
}
-void Smb4KSharesIconViewToolTip::leaveEvent( QEvent *e )
+void Smb4KSharesIconViewToolTip::leaveEvent( TQEvent *e )
{
hide();
- QLabel::leaveEvent( e );
+ TQLabel::leaveEvent( e );
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KSharesIconViewToolTip::slotHideToolTip()
diff --git a/smb4k/iconview/smb4ksharesiconviewtooltip.h b/smb4k/iconview/smb4ksharesiconviewtooltip.h
index f8b1c99..48761e0 100644
--- a/smb4k/iconview/smb4ksharesiconviewtooltip.h
+++ b/smb4k/iconview/smb4ksharesiconviewtooltip.h
@@ -30,10 +30,10 @@
#include <config.h>
#endif
-// Qt includes
-#include <qlabel.h>
-#include <qpoint.h>
-#include <qlayout.h>
+// TQt includes
+#include <tqlabel.h>
+#include <tqpoint.h>
+#include <tqlayout.h>
// Forward declarations:
class Smb4KSharesIconViewItem;
@@ -45,17 +45,18 @@ class Smb4KSharesIconViewItem;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KSharesIconViewToolTip : public QLabel
+class Smb4KSharesIconViewToolTip : public TQLabel
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * Please note that the parent of the tool tip will be '0' and
- * not the parent widget of @p item. Thus, you have to delete the
- * tool tip object in the destructor of the parent widget.
+ * Please note that the tqparent of the tool tip will be '0' and
+ * not the tqparent widget of @p item. Thus, you have to delete the
+ * tool tip object in the destructor of the tqparent widget.
*
* @param item The item for which the tool tip should be shown.
*/
@@ -73,7 +74,7 @@ class Smb4KSharesIconViewToolTip : public QLabel
*
* @param pos The global position of the mouse pointer.
*/
- void showTip( const QPoint &pos );
+ void showTip( const TQPoint &pos );
/**
* The shares icon view item for which the tool tip should be shown.
@@ -92,14 +93,14 @@ class Smb4KSharesIconViewToolTip : public QLabel
protected:
/**
- * Reimplemented from QLabel.
+ * Reimplemented from TQLabel.
*/
- void mousePressEvent( QMouseEvent *e );
+ void mousePressEvent( TQMouseEvent *e );
/**
- * Reimplemented from QLabel.
+ * Reimplemented from TQLabel.
*/
- void leaveEvent( QEvent *e );
+ void leaveEvent( TQEvent *e );
protected slots:
/**
@@ -114,9 +115,9 @@ class Smb4KSharesIconViewToolTip : public QLabel
Smb4KSharesIconViewItem *m_item;
/**
- * The layout of the tool tip.
+ * The tqlayout of the tool tip.
*/
- QGridLayout *m_layout;
+ TQGridLayout *m_layout;
/**
* This function sets up the tool tip.
@@ -132,29 +133,29 @@ class Smb4KSharesIconViewToolTip : public QLabel
* This label holds the variable value of the free
* space left on the share.
*/
- QLabel *m_free;
+ TQLabel *m_free;
/**
* This label holds the variable value of the used
* space on the share.
*/
- QLabel *m_used;
+ TQLabel *m_used;
/**
* This label holds the value of the total space
* available on the share.
*/
- QLabel *m_total;
+ TQLabel *m_total;
/**
* This label holds the variable value of the usage
*/
- QLabel *m_usage;
+ TQLabel *m_usage;
/**
* This label holds the pixmap.
*/
- QLabel *m_pixmap;
+ TQLabel *m_pixmap;
};
#endif
diff --git a/smb4k/listview/smb4kshareslistview.cpp b/smb4k/listview/smb4kshareslistview.cpp
index 8efc550..75112e0 100644
--- a/smb4k/listview/smb4kshareslistview.cpp
+++ b/smb4k/listview/smb4kshareslistview.cpp
@@ -23,8 +23,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qtimer.h>
+// TQt includes
+#include <tqtimer.h>
// KDE includes
#include <klocale.h>
@@ -39,8 +39,8 @@
#include "smb4kshareslistviewtooltip.h"
#include "../core/smb4ksettings.h"
-Smb4KSharesListView::Smb4KSharesListView( QWidget *parent, const char *name )
-: KListView( parent, name )
+Smb4KSharesListView::Smb4KSharesListView( TQWidget *tqparent, const char *name )
+: KListView( tqparent, name )
{
setSelectionModeExt( KListView::Single );
setAllColumnsShowFocus( false );
@@ -59,17 +59,17 @@ Smb4KSharesListView::Smb4KSharesListView( QWidget *parent, const char *name )
addColumn( i18n( "Total" ) );
addColumn( i18n( "Usage" ) );
- // Set alignment
- setColumnAlignment( Free, Qt::AlignRight );
- setColumnAlignment( Used, Qt::AlignRight );
- setColumnAlignment( Total, Qt::AlignRight );
- setColumnAlignment( Usage, Qt::AlignRight );
+ // Set tqalignment
+ setColumnAlignment( Free, TQt::AlignRight );
+ setColumnAlignment( Used, TQt::AlignRight );
+ setColumnAlignment( Total, TQt::AlignRight );
+ setColumnAlignment( Usage, TQt::AlignRight );
m_tooltip = NULL;
// Connections:
- connect( this, SIGNAL( pressed( QListViewItem * ) ),
- this, SLOT( slotPressed( QListViewItem * ) ) );
+ connect( this, TQT_SIGNAL( pressed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotPressed( TQListViewItem * ) ) );
}
@@ -117,23 +117,23 @@ void Smb4KSharesListView::startDrag()
}
-void Smb4KSharesListView::contentsDragEnterEvent( QDragEnterEvent *e )
+void Smb4KSharesListView::contentsDragEnterEvent( TQDragEnterEvent *e )
{
e->accept( Smb4KSettings::enableDropSupport() );
}
-void Smb4KSharesListView::contentsDragMoveEvent( QDragMoveEvent *e )
+void Smb4KSharesListView::contentsDragMoveEvent( TQDragMoveEvent *e )
{
- QListViewItem *item = itemAt( contentsToViewport( e->pos() ) );
+ TQListViewItem *item = itemAt( contentsToViewport( e->pos() ) );
e->accept( Smb4KSettings::enableDropSupport() && item );
}
-void Smb4KSharesListView::contentsDropEvent( QDropEvent *e )
+void Smb4KSharesListView::contentsDropEvent( TQDropEvent *e )
{
- QListViewItem *item = itemAt( contentsToViewport( e->pos() ) );
+ TQListViewItem *item = itemAt( contentsToViewport( e->pos() ) );
KURL::List src;
// Do we have to stop here?
@@ -155,7 +155,7 @@ void Smb4KSharesListView::contentsDropEvent( QDropEvent *e )
{
if ( dest.equals( *it, true ) )
{
- if ( e->source() == this || e->source()->parent() == this )
+ if ( e->source() == this || TQT_BASE_OBJECT(e->source()->tqparent()) == TQT_BASE_OBJECT(this) )
{
e->ignore();
@@ -173,7 +173,7 @@ void Smb4KSharesListView::contentsDropEvent( QDropEvent *e )
}
-void Smb4KSharesListView::contentsMouseMoveEvent( QMouseEvent *e )
+void Smb4KSharesListView::contentsMouseMoveEvent( TQMouseEvent *e )
{
m_pos = e->globalPos();
@@ -192,7 +192,7 @@ void Smb4KSharesListView::contentsMouseMoveEvent( QMouseEvent *e )
{
m_tooltip = new Smb4KSharesListViewToolTip( item );
- QTimer::singleShot( 2000, this, SLOT( slotShowToolTip() ) );
+ TQTimer::singleShot( 2000, this, TQT_SLOT( slotShowToolTip() ) );
}
else
{
@@ -212,7 +212,7 @@ void Smb4KSharesListView::contentsMouseMoveEvent( QMouseEvent *e )
{
m_tooltip = new Smb4KSharesListViewToolTip( item );
- QTimer::singleShot( 2000, this, SLOT( slotShowToolTip() ) );
+ TQTimer::singleShot( 2000, this, TQT_SLOT( slotShowToolTip() ) );
}
else
{
@@ -234,10 +234,10 @@ void Smb4KSharesListView::contentsMouseMoveEvent( QMouseEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
-void Smb4KSharesListView::slotPressed( QListViewItem *item )
+void Smb4KSharesListView::slotPressed( TQListViewItem *item )
{
if ( m_tooltip )
{
diff --git a/smb4k/listview/smb4kshareslistview.h b/smb4k/listview/smb4kshareslistview.h
index df1c265..ecd1d11 100644
--- a/smb4k/listview/smb4kshareslistview.h
+++ b/smb4k/listview/smb4kshareslistview.h
@@ -46,16 +46,17 @@ class Smb4KSharesListViewToolTip;
class Smb4KSharesListView : public KListView
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this object
*/
- Smb4KSharesListView( QWidget *parent = 0, const char *name = 0 );
+ Smb4KSharesListView( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor
@@ -92,7 +93,7 @@ class Smb4KSharesListView : public KListView
protected:
/**
- * Reimplemented (sort of) from QListView to enable dragging. As QDragObject
+ * Reimplemented (sort of) from TQListView to enable dragging. As TQDragObject
* a KURLDrag will be returned.
*
* @returns a KURLDrag object.
@@ -100,41 +101,41 @@ class Smb4KSharesListView : public KListView
KURLDrag *dragObject();
/**
- * Reimplemented from QListView to allow some actions to be carried
+ * Reimplemented from TQListView to allow some actions to be carried
* out before the drag begins.
*/
void startDrag();
/**
- * Reimplemented from QListView.
+ * Reimplemented from TQListView.
*/
- void contentsDragEnterEvent( QDragEnterEvent * );
+ void contentsDragEnterEvent( TQDragEnterEvent * );
/**
- * Reimplemented from QListView.
+ * Reimplemented from TQListView.
*/
- void contentsDragMoveEvent( QDragMoveEvent *e );
+ void contentsDragMoveEvent( TQDragMoveEvent *e );
/**
- * Reimplemented from QListView.
+ * Reimplemented from TQListView.
*/
- void contentsDropEvent( QDropEvent *e );
+ void contentsDropEvent( TQDropEvent *e );
/**
- * Reimplemented from QListView. This function is used to
+ * Reimplemented from TQListView. This function is used to
* show the tooltips.
*/
- void contentsMouseMoveEvent( QMouseEvent *e );
+ void contentsMouseMoveEvent( TQMouseEvent *e );
protected slots:
/**
* This slot is connected to KListView::pressed() and clears the selection
* if the user clicked on the viewport.
*
- * @param item The QIconViewItem that the user clicked or NULL
+ * @param item The TQIconViewItem that the user clicked or NULL
* if he/she pressed a mouse button on the viewport.
*/
- void slotPressed( QListViewItem *item );
+ void slotPressed( TQListViewItem *item );
/**
* This slot shows the tool tip for an icon view item.
@@ -145,7 +146,7 @@ class Smb4KSharesListView : public KListView
/**
* The current global mouse position
*/
- QPoint m_pos;
+ TQPoint m_pos;
/**
* The tool tip
diff --git a/smb4k/listview/smb4kshareslistview_part.cpp b/smb4k/listview/smb4kshareslistview_part.cpp
index 723042a..60cd5e2 100644
--- a/smb4k/listview/smb4kshareslistview_part.cpp
+++ b/smb4k/listview/smb4kshareslistview_part.cpp
@@ -24,8 +24,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qheader.h>
+// TQt includes
+#include <tqheader.h>
// KDE includes
#include <kglobal.h>
@@ -54,9 +54,9 @@ KInstance *Smb4KSharesListViewPartFactory::m_instance = 0L;
KAboutData *Smb4KSharesListViewPartFactory::m_about = 0L;
-Smb4KSharesListViewPart::Smb4KSharesListViewPart( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name )
-: KParts::Part( parent, name )
+Smb4KSharesListViewPart::Smb4KSharesListViewPart( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name )
+: KParts::Part( tqparent, name )
{
// First of all We need an instance:
setInstance( Smb4KSharesListViewPartFactory::instance() );
@@ -65,7 +65,7 @@ Smb4KSharesListViewPart::Smb4KSharesListViewPart( QWidget *parentWidget, const c
setXMLFile( "smb4kshareslistview_part.rc" );
// Set the widget of this part:
- m_widget = new Smb4KSharesListView( parentWidget, widgetName );
+ m_widget = new Smb4KSharesListView( tqparentWidget, widgetName );
setWidget( m_widget );
// Set up the actions.
@@ -80,23 +80,23 @@ Smb4KSharesListViewPart::Smb4KSharesListViewPart( QWidget *parentWidget, const c
loadSettings();
// Add some connections:
- connect( Smb4KCore::mounter(), SIGNAL( updated() ),
- this, SLOT( slotMountedShares() ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( updated() ),
+ this, TQT_SLOT( slotMountedShares() ) );
- connect( Smb4KCore::synchronizer(), SIGNAL( state( int ) ),
- this, SLOT( slotSynchronizationState( int ) ) );
+ connect( Smb4KCore::synchronizer(), TQT_SIGNAL( state( int ) ),
+ this, TQT_SLOT( slotSynchronizationState( int ) ) );
- connect( m_widget, SIGNAL( contextMenuRequested( QListViewItem *, const QPoint & , int) ),
- this, SLOT( slotContextMenuRequested( QListViewItem *, const QPoint &, int ) ) );
+ connect( m_widget, TQT_SIGNAL( contextMenuRequested( TQListViewItem *, const TQPoint & , int) ),
+ this, TQT_SLOT( slotContextMenuRequested( TQListViewItem *, const TQPoint &, int ) ) );
- connect( m_widget, SIGNAL( selectionChanged( QListViewItem * ) ),
- this, SLOT( slotSelectionChanged( QListViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( selectionChanged( TQListViewItem * ) ),
+ this, TQT_SLOT( slotSelectionChanged( TQListViewItem * ) ) );
- connect( m_widget, SIGNAL( pressed( QListViewItem * ) ),
- this, SLOT( slotMouseButtonPressed( QListViewItem * ) ) );
+ connect( m_widget, TQT_SIGNAL( pressed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotMouseButtonPressed( TQListViewItem * ) ) );
- connect( m_widget, SIGNAL( executed( QListViewItem * ) ),
- this, SLOT( slotFilemanager() ) );
+ connect( m_widget, TQT_SIGNAL( executed( TQListViewItem * ) ),
+ this, TQT_SLOT( slotFilemanager() ) );
}
@@ -109,24 +109,24 @@ void Smb4KSharesListViewPart::setupActions()
{
// Create the actions:
KAction *unmount = new KAction( i18n( "&Unmount" ), "hdd_unmount", KShortcut( CTRL+Key_U ),
- this, SLOT( slotUnmountShare() ),
+ this, TQT_SLOT( slotUnmountShare() ),
actionCollection(), "unmount_action" );
#ifdef __linux__
KAction *force = new KAction( i18n( "&Force Unmounting" ), "hdd_unmount", KShortcut( CTRL+Key_F ),
- this, SLOT( slotForceUnmountShare() ),
+ this, TQT_SLOT( slotForceUnmountShare() ),
actionCollection(), "force_unmount_action" );
#endif
KAction *all = new KAction( i18n( "U&nmount All" ), "gear", KShortcut( CTRL+Key_N ),
- this, SLOT( slotUnmountAllShares() ),
+ this, TQT_SLOT( slotUnmountAllShares() ),
actionCollection(), "unmount_all_action" );
KAction *sync = new KAction( i18n( "S&ynchronize" ), "bottom", KShortcut( CTRL+Key_Y ),
- this, SLOT( slotSynchronize() ),
+ this, TQT_SLOT( slotSynchronize() ),
actionCollection(), "synchronize_action" );
KAction *konsole = new KAction( i18n( "Open with Konso&le" ), "terminal", KShortcut( CTRL+Key_L ),
- this, SLOT( slotKonsole() ),
+ this, TQT_SLOT( slotKonsole() ),
actionCollection(), "konsole_action" );
KAction *konq = new KAction( i18n( "Open with &Konqueror" ), "kfm_home", KShortcut( CTRL+Key_K ),
- this, SLOT( slotFilemanager() ),
+ this, TQT_SLOT( slotFilemanager() ),
actionCollection(), "filemanager_action" );
// Disable all actions for now:
@@ -162,19 +162,19 @@ void Smb4KSharesListViewPart::loadSettings()
#endif
m_widget->setColumnWidth( Smb4KSharesListView::Item, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Item, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Item, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::Item );
if ( Smb4KSettings::showOwner() )
{
m_widget->setColumnWidth( Smb4KSharesListView::Owner, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Owner, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Owner, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::Owner );
}
else
{
m_widget->setColumnWidth( Smb4KSharesListView::Owner, 0 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Owner, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Owner, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KSharesListView::Owner );
}
@@ -182,13 +182,13 @@ void Smb4KSharesListViewPart::loadSettings()
if ( Smb4KSettings::showLogin() )
{
m_widget->setColumnWidth( Smb4KSharesListView::Login, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Login, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Login, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::Login );
}
else
{
m_widget->setColumnWidth( Smb4KSharesListView::Login, 0 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Login, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Login, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KSharesListView::Login );
}
#endif
@@ -196,70 +196,70 @@ void Smb4KSharesListViewPart::loadSettings()
if ( Smb4KSettings::showFileSystem() )
{
m_widget->setColumnWidth( Smb4KSharesListView::FileSystem, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::FileSystem, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::FileSystem, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::FileSystem );
}
else
{
m_widget->setColumnWidth( Smb4KSharesListView::FileSystem, 0 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::FileSystem, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::FileSystem, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KSharesListView::FileSystem );
}
if ( Smb4KSettings::showFreeDiskSpace() )
{
m_widget->setColumnWidth( Smb4KSharesListView::Free, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Free, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Free, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::Free );
}
else
{
m_widget->setColumnWidth( Smb4KSharesListView::Free, 0 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Free, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Free, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KSharesListView::Free );
}
if ( Smb4KSettings::showUsedDiskSpace() )
{
m_widget->setColumnWidth( Smb4KSharesListView::Used, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Used, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Used, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::Used );
}
else
{
m_widget->setColumnWidth( Smb4KSharesListView::Used, 0 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Used, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Used, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KSharesListView::Used );
}
if ( Smb4KSettings::showTotalDiskSpace() )
{
m_widget->setColumnWidth( Smb4KSharesListView::Total, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Total, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Total, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::Total );
}
else
{
m_widget->setColumnWidth( Smb4KSharesListView::Total, 0 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Total, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Total, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KSharesListView::Total );
}
if ( Smb4KSettings::showDiskUsage() )
{
m_widget->setColumnWidth( Smb4KSharesListView::Usage, 10 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Usage, QListView::Maximum );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Usage, TQListView::Maximum );
m_widget->header()->setResizeEnabled( true, Smb4KSharesListView::Usage );
}
else
{
m_widget->setColumnWidth( Smb4KSharesListView::Usage, 0 );
- m_widget->setColumnWidthMode( Smb4KSharesListView::Usage, QListView::Manual );
+ m_widget->setColumnWidthMode( Smb4KSharesListView::Usage, TQListView::Manual );
m_widget->header()->setResizeEnabled( false, Smb4KSharesListView::Usage );
}
// Change the text of the share (first column):
- QListViewItemIterator it( m_widget );
+ TQListViewItemIterator it( m_widget );
Smb4KSharesListViewItem *item = NULL;
while( it.current() )
@@ -294,7 +294,7 @@ void Smb4KSharesListViewPart::loadSettings()
}
-void Smb4KSharesListViewPart::customEvent( QCustomEvent *e )
+void Smb4KSharesListViewPart::customEvent( TQCustomEvent *e )
{
switch ( e->type() )
{
@@ -331,10 +331,10 @@ void Smb4KSharesListViewPart::customEvent( QCustomEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS (Smb4KSharesListViewPart)
+// TQT_SLOT IMPLEMENTATIONS (Smb4KSharesListViewPart)
/////////////////////////////////////////////////////////////////////////////
-void Smb4KSharesListViewPart::slotContextMenuRequested( QListViewItem *item, const QPoint &pos, int /*col*/ )
+void Smb4KSharesListViewPart::slotContextMenuRequested( TQListViewItem *item, const TQPoint &pos, int /*col*/ )
{
if ( item )
{
@@ -350,7 +350,7 @@ void Smb4KSharesListViewPart::slotContextMenuRequested( QListViewItem *item, con
}
-void Smb4KSharesListViewPart::slotSelectionChanged( QListViewItem *item )
+void Smb4KSharesListViewPart::slotSelectionChanged( TQListViewItem *item )
{
// NOTE: Here we only enable or disable the KActions. All other things
// are done in the Smb4KSharesListView class.
@@ -389,7 +389,7 @@ void Smb4KSharesListViewPart::slotSelectionChanged( QListViewItem *item )
}
-void Smb4KSharesListViewPart::slotMouseButtonPressed( QListViewItem *item )
+void Smb4KSharesListViewPart::slotMouseButtonPressed( TQListViewItem *item )
{
// NOTE: Here we only enable or disable the KActions. All other things
// are done in the Smb4KSharesListView class.
@@ -417,13 +417,13 @@ void Smb4KSharesListViewPart::slotMouseButtonPressed( QListViewItem *item )
void Smb4KSharesListViewPart::slotMountedShares()
{
// Get the list of shares:
- QValueList<Smb4KShare *> list = Smb4KCore::mounter()->getShares();
+ TQValueList<Smb4KShare *> list = Smb4KCore::mounter()->getShares();
// Update the view:
if ( !list.isEmpty() )
{
// Remove all obsolete items:
- QListViewItemIterator it( m_widget );
+ TQListViewItemIterator it( m_widget );
Smb4KSharesListViewItem *item = NULL;
while ( it.current() )
@@ -443,15 +443,15 @@ void Smb4KSharesListViewPart::slotMountedShares()
// Now process the entries in the list:
bool already_in_view = false;
- for ( QValueListConstIterator<Smb4KShare *> it = list.begin(); it != list.end(); ++it )
+ for ( TQValueListConstIterator<Smb4KShare *> it = list.begin(); it != list.end(); ++it )
{
// Check, whether the share is already in the list. Look for the
// mount point.
for ( Smb4KSharesListViewItem *item = static_cast<Smb4KSharesListViewItem *>( m_widget->firstChild() );
item; item = static_cast<Smb4KSharesListViewItem *>( item->nextSibling() ) )
{
- if ( QString::compare( item->shareObject()->path(), (*it)->path() ) == 0 ||
- QString::compare( item->shareObject()->canonicalPath(), (*it)->canonicalPath() ) == 0 )
+ if ( TQString::compare( item->shareObject()->path(), (*it)->path() ) == 0 ||
+ TQString::compare( item->shareObject()->canonicalPath(), (*it)->canonicalPath() ) == 0 )
{
// Replace the share object if something changed:
if ( !item->sameShareObject( *it ) )
@@ -524,7 +524,7 @@ void Smb4KSharesListViewPart::slotMountedShares()
}
// Enable/disable the actions:
- QListViewItem *item = m_widget->currentItem();
+ TQListViewItem *item = m_widget->currentItem();
bool have_selected_item = (item && item->isSelected());
actionCollection()->action( "unmount_action" )->setEnabled( have_selected_item );
@@ -578,7 +578,7 @@ void Smb4KSharesListViewPart::slotUnmountAllShares()
void Smb4KSharesListViewPart::slotSynchronize()
{
Smb4KSharesListViewItem *item = static_cast<Smb4KSharesListViewItem *>( m_widget->currentItem() );
- Smb4KSynchronizationDialog *dlg = static_cast<Smb4KSynchronizationDialog *>( m_widget->child( "SynchronizationDialog", "Smb4KSynchronizationDialog", true ) );
+ Smb4KSynchronizationDialog *dlg = static_cast<Smb4KSynchronizationDialog *>( TQT_TQWIDGET(m_widget->child( "SynchronizationDialog", "Smb4KSynchronizationDialog", true )) );
if ( item && !item->shareObject()->isBroken() && !dlg )
{
@@ -654,13 +654,13 @@ Smb4KSharesListViewPartFactory::~Smb4KSharesListViewPartFactory()
}
-KParts::Part *Smb4KSharesListViewPartFactory::createPartObject( QWidget *parentWidget, const char *widgetName,
-QObject *parent, const char *name, const char *, const QStringList & )
+KParts::Part *Smb4KSharesListViewPartFactory::createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+TQObject *tqparent, const char *name, const char *, const TQStringList & )
{
- Smb4KSharesListViewPart *obj = new Smb4KSharesListViewPart( parentWidget, widgetName, parent, name );
+ Smb4KSharesListViewPart *obj = new Smb4KSharesListViewPart( tqparentWidget, widgetName, tqparent, name );
// See if we are to be read-write or not
-// if (QCString(classname) == "KParts::ReadOnlyPart")
+// if (TQCString(classname) == "KParts::ReadOnlyPart")
// {
// obj->setReadWrite(false);
// }
diff --git a/smb4k/listview/smb4kshareslistview_part.h b/smb4k/listview/smb4kshareslistview_part.h
index 858193e..213f41e 100644
--- a/smb4k/listview/smb4kshareslistview_part.h
+++ b/smb4k/listview/smb4kshareslistview_part.h
@@ -48,21 +48,22 @@
class Smb4KSharesListViewPart : public KParts::Part
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parentWidget The parent widget
+ * @param tqparentWidget The tqparent widget
*
* @param widgetName The name the widget should have
*
- * @param parent The parent object
+ * @param tqparent The tqparent object
*
* @param name The name this object should have
*/
- Smb4KSharesListViewPart( QWidget *parentWidget = 0, const char *widgetName = 0,
- QObject *parent = 0, const char *name = 0 );
+ Smb4KSharesListViewPart( TQWidget *tqparentWidget = 0, const char *widgetName = 0,
+ TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -73,7 +74,7 @@ class Smb4KSharesListViewPart : public KParts::Part
/**
* Reimplemented from KParts::Part.
*/
- void customEvent( QCustomEvent *e );
+ void customEvent( TQCustomEvent *e );
protected slots:
/**
@@ -87,7 +88,7 @@ class Smb4KSharesListViewPart : public KParts::Part
*
* @param col The column where the context menu should be show.
*/
- void slotContextMenuRequested( QListViewItem *item, const QPoint & pos, int col );
+ void slotContextMenuRequested( TQListViewItem *item, const TQPoint & pos, int col );
/**
* This slot is called when the selection in the list view changed. It
@@ -97,7 +98,7 @@ class Smb4KSharesListViewPart : public KParts::Part
*
* @param item The list view item that was selected
*/
- void slotSelectionChanged( QListViewItem *item );
+ void slotSelectionChanged( TQListViewItem *item );
/**
* This slot is called when the user presses any mouse button somewhere
@@ -107,7 +108,7 @@ class Smb4KSharesListViewPart : public KParts::Part
* @param item The icon view item that was clicked or NULL if the
* user clicked onto the viewport.
*/
- void slotMouseButtonPressed( QListViewItem *item );
+ void slotMouseButtonPressed( TQListViewItem *item );
/**
* This slot is called by the Smb4KMounter::updated() signal and updates
@@ -194,6 +195,7 @@ class KAboutData;
class Smb4KSharesListViewPartFactory : public KParts::Factory
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -209,9 +211,9 @@ class Smb4KSharesListViewPartFactory : public KParts::Factory
/**
* Reimplemented from KParts::Factory
*/
- virtual KParts::Part *createPartObject( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
- const char *classname, const QStringList &args );
+ virtual KParts::Part *createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name,
+ const char *classname, const TQStringList &args );
/**
* The instance
diff --git a/smb4k/listview/smb4kshareslistviewitem.cpp b/smb4k/listview/smb4kshareslistviewitem.cpp
index 327f9fb..ef94e0f 100644
--- a/smb4k/listview/smb4kshareslistviewitem.cpp
+++ b/smb4k/listview/smb4kshareslistviewitem.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qpixmap.h>
-#include <qcolor.h>
+// TQt includes
+#include <tqpixmap.h>
+#include <tqcolor.h>
// KDE includes
#include <kiconeffect.h>
@@ -37,8 +37,8 @@
Smb4KSharesListViewItem::Smb4KSharesListViewItem( Smb4KShare *share, bool mountpoint,
- Smb4KSharesListView *parent )
-: KListViewItem( parent ), m_share( *share ), m_mountpoint( mountpoint ),
+ Smb4KSharesListView *tqparent )
+: KListViewItem( tqparent ), m_share( *share ), m_mountpoint( mountpoint ),
m_initial_setup( true )
{
setDropEnabled( true );
@@ -65,20 +65,20 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
{
if ( m_initial_setup || m_share.isBroken() != share.isBroken() )
{
- QPixmap pix;
+ TQPixmap pix;
int icon_state = m_share.isForeign() ? KIcon::DisabledState : KIcon::DefaultState;
if ( m_share.isBroken() )
{
- QImage over = m_loader->loadIcon( "button_cancel", KIcon::Small,
+ TQImage over = m_loader->loadIcon( "button_cancel", KIcon::Small,
0, icon_state, 0L, false ).convertToImage();
- QImage src = m_loader->loadIcon( "hdd_mount", KIcon::Small,
+ TQImage src = m_loader->loadIcon( "hdd_mount", KIcon::Small,
0, icon_state, 0L, false ).convertToImage();
- QImage over_desk = m_loader->loadIcon( "button_cancel", KIcon::Desktop,
+ TQImage over_desk = m_loader->loadIcon( "button_cancel", KIcon::Desktop,
0, icon_state, 0L, false ).convertToImage();
- QImage src_desk = m_loader->loadIcon( "hdd_mount", KIcon::Desktop,
+ TQImage src_desk = m_loader->loadIcon( "hdd_mount", KIcon::Desktop,
0, icon_state, 0L, false ).convertToImage();
KIconEffect e;
@@ -87,8 +87,8 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
e.semiTransparent( over_desk );
e.overlay( src_desk, over_desk );
- pix = QPixmap( src );
- m_desktop_pixmap = QPixmap( src_desk );
+ pix = TQPixmap( src );
+ m_desktop_pixmap = TQPixmap( src_desk );
}
else
{
@@ -115,7 +115,7 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
// The file system, owner and login won't change
- QString total, free, used, total_dim, free_dim, used_dim;
+ TQString total, free, used, total_dim, free_dim, used_dim;
if ( shareObject()->totalDiskSpace() - shareObject()->freeDiskSpace() > 1024 )
{
@@ -128,13 +128,13 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
used_dim = "GB";
}
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
else
{
used_dim = "kB";
double tmp_used = shareObject()->totalDiskSpace() - shareObject()->freeDiskSpace();
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
if ( shareObject()->freeDiskSpace() >= 1024 )
@@ -148,12 +148,12 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
free_dim = "GB";
}
- free = QString( "%1" ).arg( tmp_free, 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( tmp_free, 0, 'f', 1 );
}
else
{
free_dim = "kB";
- free = QString( "%1" ).arg( shareObject()->freeDiskSpace(), 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( shareObject()->freeDiskSpace(), 0, 'f', 1 );
}
if ( shareObject()->totalDiskSpace() >= 1024 )
@@ -167,33 +167,33 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
total_dim = "GB";
}
- total = QString( "%1" ).arg( tmp_total, 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( tmp_total, 0, 'f', 1 );
}
else
{
total_dim = "kB";
- total = QString( "%1" ).arg( shareObject()->totalDiskSpace(), 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( shareObject()->totalDiskSpace(), 0, 'f', 1 );
}
- setText( Free, QString( "%1 %2" ).arg( free, free_dim ) );
- setText( Used, QString( "%1 %2" ).arg( used, used_dim ) );
- setText( Total, QString( "%1 %2" ).arg( total, total_dim ) );
+ setText( Free, TQString( "%1 %2" ).tqarg( free, free_dim ) );
+ setText( Used, TQString( "%1 %2" ).tqarg( used, used_dim ) );
+ setText( Total, TQString( "%1 %2" ).tqarg( total, total_dim ) );
}
else
{
setText( Item, (m_mountpoint ? m_share.path() : m_share.name()) );
- setText( Owner, QString::compare( m_share.filesystem(), "smbfs" ) == 0 ?
- QString( "%1 - %2" ).arg( m_share.user() ).arg( m_share.group() ) :
- QString::null );
+ setText( Owner, TQString::compare( m_share.filesystem(), "smbfs" ) == 0 ?
+ TQString( "%1 - %2" ).tqarg( m_share.user() ).tqarg( m_share.group() ) :
+ TQString() );
#ifndef __FreeBSD__
- setText( Login, QString::compare( m_share.filesystem(), "cifs" ) == 0 ?
+ setText( Login, TQString::compare( m_share.filesystem(), "cifs" ) == 0 ?
m_share.cifsLogin() :
- QString::null );
+ TQString() );
#endif
setText( FileSystem, m_share.filesystem().upper() );
- QString total, free, used, total_dim, free_dim, used_dim;
+ TQString total, free, used, total_dim, free_dim, used_dim;
if ( shareObject()->totalDiskSpace() - shareObject()->freeDiskSpace() > 1024 )
{
@@ -206,13 +206,13 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
used_dim = "GB";
}
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
else
{
used_dim = "kB";
double tmp_used = shareObject()->totalDiskSpace() - shareObject()->freeDiskSpace();
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
if ( shareObject()->freeDiskSpace() >= 1024 )
@@ -226,12 +226,12 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
free_dim = "GB";
}
- free = QString( "%1" ).arg( tmp_free, 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( tmp_free, 0, 'f', 1 );
}
else
{
free_dim = "kB";
- free = QString( "%1" ).arg( shareObject()->freeDiskSpace(), 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( shareObject()->freeDiskSpace(), 0, 'f', 1 );
}
if ( shareObject()->totalDiskSpace() >= 1024 )
@@ -245,17 +245,17 @@ void Smb4KSharesListViewItem::setupItem( const Smb4KShare &share, bool mountpoin
total_dim = "GB";
}
- total = QString( "%1" ).arg( tmp_total, 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( tmp_total, 0, 'f', 1 );
}
else
{
total_dim = "kB";
- total = QString( "%1" ).arg( shareObject()->totalDiskSpace(), 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( shareObject()->totalDiskSpace(), 0, 'f', 1 );
}
- setText( Free, QString( "%1 %2" ).arg( free, free_dim ) );
- setText( Used, QString( "%1 %2" ).arg( used, used_dim ) );
- setText( Total, QString( "%1 %2" ).arg( total, total_dim ) );
+ setText( Free, TQString( "%1 %2" ).tqarg( free, free_dim ) );
+ setText( Used, TQString( "%1 %2" ).tqarg( used, used_dim ) );
+ setText( Total, TQString( "%1 %2" ).tqarg( total, total_dim ) );
}
m_initial_setup = false;
@@ -281,14 +281,14 @@ void Smb4KSharesListViewItem::replaceShareObject( Smb4KShare *share )
}
-void Smb4KSharesListViewItem::paintCell( QPainter *p, const QColorGroup &cg, int col, int width, int align )
+void Smb4KSharesListViewItem::paintCell( TQPainter *p, const TQColorGroup &cg, int col, int width, int align )
{
// Set the color of the item text:
- QColorGroup colorgrp( cg );
+ TQColorGroup colorgrp( cg );
if ( m_share.isForeign() )
{
- colorgrp.setColor( QColorGroup::Text, Qt::gray );
+ colorgrp.setColor( TQColorGroup::Text, TQt::gray );
}
if ( col != Usage )
@@ -316,10 +316,10 @@ void Smb4KSharesListViewItem::paintCell( QPainter *p, const QColorGroup &cg, int
{
int percent = (int)(((double)(width-2)) * (m_share.percentage()/100));
- p->fillRect( 1, 1, percent, height()-2, !m_share.isForeign() ? Qt::red : Qt::red.light( 175 ) );
- p->fillRect( percent+1, 1, width-percent-2, height()-2, !m_share.isForeign() ? Qt::green : Qt::green.light( 175 ) );
+ p->fillRect( 1, 1, percent, height()-2, !m_share.isForeign() ? TQt::red : TQColor(TQt::red.light( 175 )) );
+ p->fillRect( percent+1, 1, width-percent-2, height()-2, !m_share.isForeign() ? TQt::green : TQColor(TQt::green.light( 175 )) );
- p->setPen( !m_share.isForeign() ? colorgrp.foreground() : Qt::gray );
+ p->setPen( !m_share.isForeign() ? colorgrp.foreground() : TQt::gray );
p->drawRect( 1, 1, width-2, height()-2 );
// Show the text:
@@ -330,19 +330,19 @@ void Smb4KSharesListViewItem::paintCell( QPainter *p, const QColorGroup &cg, int
// p->setPen( colorgrp.highlightedText() );
// }
- p->drawText( 0, 0, width-1, height()-1, Qt::AlignCenter, QString( "%1 \%" ).arg( m_share.percentage(), 0, 'f', 1 ) );
+ p->drawText( 0, 0, width-1, height()-1, TQt::AlignCenter, TQString( "%1 \%" ).tqarg( m_share.percentage(), 0, 'f', 1 ) );
}
else
{
p->fillRect( 1, 1, width-2, height()-2, colorgrp.base() );
- p->setPen( !m_share.isForeign() ? colorgrp.foreground() : Qt::gray );
+ p->setPen( !m_share.isForeign() ? colorgrp.foreground() : TQt::gray );
p->drawRect( 1, 1, width-2, height()-2 );
}
}
-bool Smb4KSharesListViewItem::acceptDrop( const QMimeSource *source ) const
+bool Smb4KSharesListViewItem::acceptDrop( const TQMimeSource *source ) const
{
if ( source->provides( "text/plain" ) )
{
diff --git a/smb4k/listview/smb4kshareslistviewitem.h b/smb4k/listview/smb4kshareslistviewitem.h
index 4b5ddc3..052c37b 100644
--- a/smb4k/listview/smb4kshareslistviewitem.h
+++ b/smb4k/listview/smb4kshareslistviewitem.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qpainter.h>
-#include <qpalette.h>
+// TQt includes
+#include <tqpainter.h>
+#include <tqpalette.h>
// KDE includes
#include <klistview.h>
@@ -62,11 +62,11 @@ class Smb4KSharesListViewItem : public KListViewItem
* @param mountpoint Tells the item if the mount point instead of the
* share name should be shown. Default is FALSE.
*
- * @param parent The parent widget of this item.
+ * @param tqparent The tqparent widget of this item.
*/
Smb4KSharesListViewItem( Smb4KShare *share,
bool mountpoint = false,
- Smb4KSharesListView *parent = 0 );
+ Smb4KSharesListView *tqparent = 0 );
/**
* The destructor
@@ -127,7 +127,7 @@ class Smb4KSharesListViewItem : public KListViewItem
*
* @returns the destop pixmap of this item.
*/
- const QPixmap &desktopPixmap() { return m_desktop_pixmap; }
+ const TQPixmap &desktopPixmap() { return m_desktop_pixmap; }
protected:
/**
@@ -144,13 +144,13 @@ class Smb4KSharesListViewItem : public KListViewItem
*
* @param width The width of the area that will be painted.
*
- * @param alignment The alignment of the column that will be used.
+ * @param tqalignment The tqalignment of the column that will be used.
*/
- void paintCell( QPainter *p,
- const QColorGroup &cg,
+ void paintCell( TQPainter *p,
+ const TQColorGroup &cg,
int column,
int width,
- int alignment );
+ int tqalignment );
/**
* Reimplemented from KListViewItem.
@@ -159,7 +159,7 @@ class Smb4KSharesListViewItem : public KListViewItem
*
* @param source The mime source
*/
- bool acceptDrop( const QMimeSource *source ) const;
+ bool acceptDrop( const TQMimeSource *source ) const;
private:
/**
@@ -197,7 +197,7 @@ class Smb4KSharesListViewItem : public KListViewItem
/**
* The desktop pixmap
*/
- QPixmap m_desktop_pixmap;
+ TQPixmap m_desktop_pixmap;
};
#endif
diff --git a/smb4k/listview/smb4kshareslistviewtooltip.cpp b/smb4k/listview/smb4kshareslistviewtooltip.cpp
index 110f412..a2c49cc 100644
--- a/smb4k/listview/smb4kshareslistviewtooltip.cpp
+++ b/smb4k/listview/smb4kshareslistviewtooltip.cpp
@@ -23,11 +23,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qtooltip.h>
-#include <qapplication.h>
-#include <qdesktopwidget.h>
-#include <qtimer.h>
+// TQt includes
+#include <tqtooltip.h>
+#include <tqapplication.h>
+#include <tqdesktopwidget.h>
+#include <tqtimer.h>
// KDE includes
#include <klocale.h>
@@ -39,17 +39,17 @@
Smb4KSharesListViewToolTip::Smb4KSharesListViewToolTip( Smb4KSharesListViewItem *item )
-: QLabel( 0, "SharesListViewToolTip", WStyle_StaysOnTop | WStyle_Customize |
+: TQLabel( 0, "SharesListViewToolTip", WStyle_StaysOnTop | WStyle_Customize |
WStyle_NoBorder | WStyle_Tool | WX11BypassWM | WDestructiveClose ), m_item( item )
{
- setPalette( QToolTip::palette() );
+ setPalette( TQToolTip::palette() );
setLineWidth( 1 );
setMidLineWidth( 1 );
setFrameShape( Box );
setFrameShadow( Plain );
setMouseTracking( true );
- m_layout = new QGridLayout( this );
+ m_layout = new TQGridLayout( this );
m_layout->setMargin( 10 );
m_layout->setSpacing( 3 );
@@ -71,7 +71,7 @@ Smb4KSharesListViewToolTip::~Smb4KSharesListViewToolTip()
}
-void Smb4KSharesListViewToolTip::showTip( const QPoint &pos )
+void Smb4KSharesListViewToolTip::showTip( const TQPoint &pos )
{
if ( !m_item || isShown() )
{
@@ -82,8 +82,8 @@ void Smb4KSharesListViewToolTip::showTip( const QPoint &pos )
adjustSize();
- QDesktopWidget *d = QApplication::desktop();
- QPoint p( pos );
+ TQDesktopWidget *d = TQApplication::desktop();
+ TQPoint p( pos );
if ( p.x() + width() > d->width() )
{
@@ -106,7 +106,7 @@ void Smb4KSharesListViewToolTip::showTip( const QPoint &pos )
setGeometry( p.x(), p.y(), width(), height() );
polish();
show();
- QTimer::singleShot( 10000, this, SLOT( slotHideToolTip() ) );
+ TQTimer::singleShot( 10000, this, TQT_SLOT( slotHideToolTip() ) );
}
@@ -117,38 +117,38 @@ void Smb4KSharesListViewToolTip::setupTip()
return;
}
- m_layout->addWidget( new QLabel( i18n( "Share:" ), this ), 0, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->name(), this ), 0, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Mount point:" ), this ), 1, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->path(), this ), 1, 2, 0 );
+ m_layout->addWidget( new TQLabel( i18n( "Share:" ), this ), 0, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->name(), this ), 0, 2, 0 );
+ m_layout->addWidget( new TQLabel( i18n( "Mount point:" ), this ), 1, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->path(), this ), 1, 2, 0 );
- if ( QString::compare( m_item->shareObject()->filesystem(), "smbfs" ) == 0 )
+ if ( TQString::compare( m_item->shareObject()->filesystem(), "smbfs" ) == 0 )
{
- m_layout->addWidget( new QLabel( "Owner:", this ), 2, 1, 0 );
- m_layout->addWidget( new QLabel( QString( "%1 - %2" ).arg( m_item->shareObject()->user(), m_item->shareObject()->group() ), this ), 2, 2, 0 );
+ m_layout->addWidget( new TQLabel( "Owner:", this ), 2, 1, 0 );
+ m_layout->addWidget( new TQLabel( TQString( "%1 - %2" ).tqarg( m_item->shareObject()->user(), m_item->shareObject()->group() ), this ), 2, 2, 0 );
}
else
{
- m_layout->addWidget( new QLabel( "Login:", this ), 2, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->cifsLogin(), this ), 2, 2, 0 );
+ m_layout->addWidget( new TQLabel( "Login:", this ), 2, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->cifsLogin(), this ), 2, 2, 0 );
}
- m_layout->addWidget( new QLabel( i18n( "File system:" ), this ), 3, 1, 0 );
- m_layout->addWidget( new QLabel( m_item->shareObject()->filesystem().upper(), this ), 3, 2, 0 );
+ m_layout->addWidget( new TQLabel( i18n( "File system:" ), this ), 3, 1, 0 );
+ m_layout->addWidget( new TQLabel( m_item->shareObject()->filesystem().upper(), this ), 3, 2, 0 );
- QFrame *line = new QFrame( this );
+ TQFrame *line = new TQFrame( this );
line->setLineWidth( 1 );
line->setMidLineWidth( 0 );
line->setFixedWidth( 100 );
- line->setFrameShape( QFrame::HLine );
- line->setFrameShadow( QFrame::Plain );
+ line->setFrameShape( TQFrame::HLine );
+ line->setFrameShadow( TQFrame::Plain );
- m_layout->addMultiCellWidget( line, 4, 4, 1, 2, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( line, 4, 4, 1, 2, TQt::AlignCenter );
// Prepare the disk usage stuff.
if ( !m_item->shareObject()->isBroken() )
{
- QString total, free, used, total_dim, free_dim, used_dim;
+ TQString total, free, used, total_dim, free_dim, used_dim;
if ( m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace() > 1024 )
{
@@ -161,13 +161,13 @@ void Smb4KSharesListViewToolTip::setupTip()
used_dim = "GB";
}
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
else
{
used_dim = "kB";
double tmp_used = m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace();
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
if ( m_item->shareObject()->freeDiskSpace() >= 1024 )
@@ -181,12 +181,12 @@ void Smb4KSharesListViewToolTip::setupTip()
free_dim = "GB";
}
- free = QString( "%1" ).arg( tmp_free, 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( tmp_free, 0, 'f', 1 );
}
else
{
free_dim = "kB";
- free = QString( "%1" ).arg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
}
if ( m_item->shareObject()->totalDiskSpace() >= 1024 )
@@ -200,46 +200,46 @@ void Smb4KSharesListViewToolTip::setupTip()
total_dim = "GB";
}
- total = QString( "%1" ).arg( tmp_total, 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( tmp_total, 0, 'f', 1 );
}
else
{
total_dim = "kB";
- total = QString( "%1" ).arg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
}
- m_layout->addWidget( new QLabel( i18n( "Free:" ), this, "FreeLabel" ), 5, 1, 0 );
- m_free = new QLabel( QString( "%1 %2" ).arg( free, free_dim ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Free:" ), this, "FreeLabel" ), 5, 1, 0 );
+ m_free = new TQLabel( TQString( "%1 %2" ).tqarg( free, free_dim ), this );
m_layout->addWidget( m_free, 5, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Used:" ), this, "UsedLabel" ), 6, 1, 0 );
- m_used = new QLabel( QString( "%1 %2" ).arg( used, used_dim ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Used:" ), this, "UsedLabel" ), 6, 1, 0 );
+ m_used = new TQLabel( TQString( "%1 %2" ).tqarg( used, used_dim ), this );
m_layout->addWidget( m_used, 6, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Total:" ), this, "TotalLabel" ), 7, 1, 0 );
- m_total = new QLabel( QString( "%1 %2" ).arg( total, total_dim ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Total:" ), this, "TotalLabel" ), 7, 1, 0 );
+ m_total = new TQLabel( TQString( "%1 %2" ).tqarg( total, total_dim ), this );
m_layout->addWidget( m_total, 7, 2, 0 );
- m_layout->addWidget( new QLabel( i18n( "Usage:" ), this, "UsageLabel" ), 8, 1, 0 );
- m_usage = new QLabel( QString( "%1 %" ).arg( m_item->shareObject()->percentage(), 0, 'f', 1 ), this );
+ m_layout->addWidget( new TQLabel( i18n( "Usage:" ), this, "UsageLabel" ), 8, 1, 0 );
+ m_usage = new TQLabel( TQString( "%1 %" ).tqarg( m_item->shareObject()->percentage(), 0, 'f', 1 ), this );
m_layout->addWidget( m_usage, 8, 2, 0 );
}
else
{
- QLabel *error = new QLabel( i18n( "This share is inaccessible." ), this );
+ TQLabel *error = new TQLabel( i18n( "This share is inaccessible." ), this );
- QFont font;
+ TQFont font;
font.setItalic( true );
error->setFont( font );
- m_layout->addMultiCellWidget( error, 5, 5, 1, 2, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( error, 5, 5, 1, 2, TQt::AlignCenter );
}
- m_pixmap = new QLabel( this );
+ m_pixmap = new TQLabel( this );
m_pixmap->setPixmap( m_item->desktopPixmap() );
- m_layout->addMultiCellWidget( m_pixmap, 0, m_layout->numRows(), 0, 0, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( m_pixmap, 0, m_layout->numRows(), 0, 0, TQt::AlignCenter );
m_is_set_up = true;
}
@@ -255,7 +255,7 @@ void Smb4KSharesListViewToolTip::update()
// Only change the variable entries:
if ( !m_item->shareObject()->isBroken() )
{
- QString total, free, used, total_dim, free_dim, used_dim;
+ TQString total, free, used, total_dim, free_dim, used_dim;
if ( m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace() > 1024 )
{
@@ -268,13 +268,13 @@ void Smb4KSharesListViewToolTip::update()
used_dim = "GB";
}
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
else
{
used_dim = "kB";
double tmp_used = m_item->shareObject()->totalDiskSpace() - m_item->shareObject()->freeDiskSpace();
- used = QString( "%1" ).arg( tmp_used, 0, 'f', 1 );
+ used = TQString( "%1" ).tqarg( tmp_used, 0, 'f', 1 );
}
if ( m_item->shareObject()->freeDiskSpace() >= 1024 )
@@ -288,12 +288,12 @@ void Smb4KSharesListViewToolTip::update()
free_dim = "GB";
}
- free = QString( "%1" ).arg( tmp_free, 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( tmp_free, 0, 'f', 1 );
}
else
{
free_dim = "kB";
- free = QString( "%1" ).arg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
+ free = TQString( "%1" ).tqarg( m_item->shareObject()->freeDiskSpace(), 0, 'f', 1 );
}
if ( m_item->shareObject()->totalDiskSpace() >= 1024 )
@@ -307,22 +307,22 @@ void Smb4KSharesListViewToolTip::update()
total_dim = "GB";
}
- total = QString( "%1" ).arg( tmp_total, 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( tmp_total, 0, 'f', 1 );
}
else
{
total_dim = "kB";
- total = QString( "%1" ).arg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
+ total = TQString( "%1" ).tqarg( m_item->shareObject()->totalDiskSpace(), 0, 'f', 1 );
}
- m_free->setText( QString( "%1 %2" ).arg( free, free_dim ) );
- m_used->setText( QString( "%1 %2" ).arg( used, used_dim ) );
- m_total->setText( QString( "%1 %2" ).arg( total, total_dim ) );
- m_usage->setText( QString( "%1 %" ).arg( m_item->shareObject()->percentage(), 0, 'f', 1 ) );
+ m_free->setText( TQString( "%1 %2" ).tqarg( free, free_dim ) );
+ m_used->setText( TQString( "%1 %2" ).tqarg( used, used_dim ) );
+ m_total->setText( TQString( "%1 %2" ).tqarg( total, total_dim ) );
+ m_usage->setText( TQString( "%1 %" ).tqarg( m_item->shareObject()->percentage(), 0, 'f', 1 ) );
}
else
{
- QLabel *free_label = static_cast<QLabel *>( child( "FreeLabel", "QLabel" ) );
+ TQLabel *free_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "FreeLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( free_label )
{
@@ -337,7 +337,7 @@ void Smb4KSharesListViewToolTip::update()
m_free = NULL;
}
- QLabel *used_label = static_cast<QLabel *>( child( "UsedLabel", "QLabel" ) );
+ TQLabel *used_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "UsedLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( used_label )
{
@@ -352,7 +352,7 @@ void Smb4KSharesListViewToolTip::update()
m_used = NULL;
}
- QLabel *total_label = static_cast<QLabel *>( child( "TotalLabel", "QLabel" ) );
+ TQLabel *total_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "TotalLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( total_label )
{
@@ -367,7 +367,7 @@ void Smb4KSharesListViewToolTip::update()
m_total = NULL;
}
- QLabel *usage_label = static_cast<QLabel *>( child( "UsageLabel", "QLabel" ) );
+ TQLabel *usage_label = static_cast<TQLabel *>( TQT_TQWIDGET(child( "UsageLabel", TQLABEL_OBJECT_NAME_STRING )) );
if ( usage_label )
{
@@ -382,40 +382,40 @@ void Smb4KSharesListViewToolTip::update()
m_usage = NULL;
}
- QFont font;
+ TQFont font;
font.setItalic( true );
- QLabel *error = new QLabel( i18n( "This share is inaccessible." ), this );
+ TQLabel *error = new TQLabel( i18n( "This share is inaccessible." ), this );
error->setFont( font );
error->show();
m_layout->remove( m_pixmap );
m_pixmap->setPixmap( m_item->desktopPixmap() );
- m_layout->addMultiCellWidget( error, 5, 5, 1, 2, Qt::AlignCenter );
- m_layout->addMultiCellWidget( m_pixmap, 0, 5, 0, 0, Qt::AlignCenter );
+ m_layout->addMultiCellWidget( error, 5, 5, 1, 2, TQt::AlignCenter );
+ m_layout->addMultiCellWidget( m_pixmap, 0, 5, 0, 0, TQt::AlignCenter );
}
adjustSize();
}
-void Smb4KSharesListViewToolTip::mousePressEvent( QMouseEvent *e )
+void Smb4KSharesListViewToolTip::mousePressEvent( TQMouseEvent *e )
{
hide();
- QLabel::mousePressEvent( e );
+ TQLabel::mousePressEvent( e );
}
-void Smb4KSharesListViewToolTip::leaveEvent( QEvent *e )
+void Smb4KSharesListViewToolTip::leaveEvent( TQEvent *e )
{
hide();
- QLabel::leaveEvent( e );
+ TQLabel::leaveEvent( e );
}
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KSharesListViewToolTip::slotHideToolTip()
diff --git a/smb4k/listview/smb4kshareslistviewtooltip.h b/smb4k/listview/smb4kshareslistviewtooltip.h
index d15a68e..a41623e 100644
--- a/smb4k/listview/smb4kshareslistviewtooltip.h
+++ b/smb4k/listview/smb4kshareslistviewtooltip.h
@@ -30,10 +30,10 @@
#include <config.h>
#endif
-// Qt includes
-#include <qlabel.h>
-#include <qpoint.h>
-#include <qlayout.h>
+// TQt includes
+#include <tqlabel.h>
+#include <tqpoint.h>
+#include <tqlayout.h>
// Forward declarations:
class Smb4KSharesListViewItem;
@@ -45,17 +45,18 @@ class Smb4KSharesListViewItem;
* @author Alexander Reinholdt <dustpuppy@users.berlios.de>
*/
-class Smb4KSharesListViewToolTip : public QLabel
+class Smb4KSharesListViewToolTip : public TQLabel
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * Please note that the parent of the tool tip will be '0' and
- * not the parent widget of @p item. Thus, you have to delete the
- * tool tip object in the destructor of the parent widget.
+ * Please note that the tqparent of the tool tip will be '0' and
+ * not the tqparent widget of @p item. Thus, you have to delete the
+ * tool tip object in the destructor of the tqparent widget.
*
* @param item The item for which the tool tip should be shown.
*/
@@ -73,7 +74,7 @@ class Smb4KSharesListViewToolTip : public QLabel
*
* @param pos The global position of the mouse pointer.
*/
- void showTip( const QPoint &pos );
+ void showTip( const TQPoint &pos );
/**
* The shares list view item for which the tool tip should be shown.
@@ -92,14 +93,14 @@ class Smb4KSharesListViewToolTip : public QLabel
protected:
/**
- * Reimplemented from QLabel.
+ * Reimplemented from TQLabel.
*/
- void mousePressEvent( QMouseEvent *e );
+ void mousePressEvent( TQMouseEvent *e );
/**
- * Reimplemented from QLabel.
+ * Reimplemented from TQLabel.
*/
- void leaveEvent( QEvent *e );
+ void leaveEvent( TQEvent *e );
protected slots:
/**
@@ -114,9 +115,9 @@ class Smb4KSharesListViewToolTip : public QLabel
Smb4KSharesListViewItem *m_item;
/**
- * The layout of the tool tip.
+ * The tqlayout of the tool tip.
*/
- QGridLayout *m_layout;
+ TQGridLayout *m_layout;
/**
* This function sets up the tool tip.
@@ -132,29 +133,29 @@ class Smb4KSharesListViewToolTip : public QLabel
* This label holds the variable value of the free
* space left on the share.
*/
- QLabel *m_free;
+ TQLabel *m_free;
/**
* This label holds the variable value of the used
* space on the share.
*/
- QLabel *m_used;
+ TQLabel *m_used;
/**
* This label holds the value of the total space
* available on the share.
*/
- QLabel *m_total;
+ TQLabel *m_total;
/**
* This label holds the variable value of the usage
*/
- QLabel *m_usage;
+ TQLabel *m_usage;
/**
* This label holds the pixmap.
*/
- QLabel *m_pixmap;
+ TQLabel *m_pixmap;
};
#endif
diff --git a/smb4k/main.cpp b/smb4k/main.cpp
index e3907a6..7ebaa97 100644
--- a/smb4k/main.cpp
+++ b/smb4k/main.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qstringlist.h>
-#include <qfile.h>
+// TQt includes
+#include <tqstringlist.h>
+#include <tqfile.h>
// KDE includes
#include <kcmdlineargs.h>
@@ -67,7 +67,7 @@ int main( int argc, char *argv[] )
// Authors:
aboutData.addAuthor( "Alexander Reinholdt", I18N_NOOP( "Developer" ), "dustpuppy@users.berlios.de" );
- aboutData.addAuthor( "Massimo Callegari", I18N_NOOP( "Developer" ), "massimocallegari@yahoo.it" );
+ aboutData.addAuthor( "Massimo Callegari", I18N_NOOP( "Developer" ), "massitqmocallegari@yahoo.it" );
aboutData.addAuthor( "Franck Babin", I18N_NOOP( "Developer" ), "babinfranck@yahoo.ca" );
// All our credits:
@@ -119,22 +119,22 @@ int main( int argc, char *argv[] )
KConfig config( "smb4krc", false, false, "config" );
if ( !config.groupList().isEmpty() &&
- (config.groupList().contains( "Browse Options" ) != 0 ||
- config.groupList().contains( "Mount Options" ) != 0 ||
- config.groupList().contains( "Rsync" ) != 0 ||
- config.groupList().contains( "Super User Privileges") != 0 ||
- config.groupList().contains( "User Interface" ) != 0 ||
- config.groupList().contains( "System" ) != 0) )
+ (config.groupList().tqcontains( "Browse Options" ) != 0 ||
+ config.groupList().tqcontains( "Mount Options" ) != 0 ||
+ config.groupList().tqcontains( "Rsync" ) != 0 ||
+ config.groupList().tqcontains( "Super User Privileges") != 0 ||
+ config.groupList().tqcontains( "User Interface" ) != 0 ||
+ config.groupList().tqcontains( "System" ) != 0) )
{
int return_value = KMessageBox::warningContinueCancel( 0, i18n( "Smb4K now uses a different configuration system. Thus, your old settings are obsolete and you have to reconfigure the application.\nTo assure a clean transition, the current configuration file will be removed." ) );
if ( return_value == KMessageBox::Continue )
{
- QString file_name = locateLocal( "config", "smb4krc", false );
+ TQString file_name = locateLocal( "config", "smb4krc", false );
- if ( !file_name.isEmpty() && QFile::exists( file_name ) )
+ if ( !file_name.isEmpty() && TQFile::exists( file_name ) )
{
- QFile::remove( file_name );
+ TQFile::remove( file_name );
}
}
else
diff --git a/smb4k/searchdlg/smb4ksearchdialog.cpp b/smb4k/searchdlg/smb4ksearchdialog.cpp
index bce09bb..0feda21 100644
--- a/smb4k/searchdlg/smb4ksearchdialog.cpp
+++ b/smb4k/searchdlg/smb4ksearchdialog.cpp
@@ -23,10 +23,10 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qlayout.h>
-#include <qstringlist.h>
-#include <qheader.h>
+// TQt includes
+#include <tqlayout.h>
+#include <tqstringlist.h>
+#include <tqheader.h>
// KDE includes
#include <klocale.h>
@@ -38,23 +38,23 @@
#include "smb4ksearchdialogitem.h"
#include "../core/smb4knetworkitems.h"
-Smb4KSearchDialog::Smb4KSearchDialog( QWidget *parent, const char *name )
-: QWidget( parent, name )
+Smb4KSearchDialog::Smb4KSearchDialog( TQWidget *tqparent, const char *name )
+: TQWidget( tqparent, name )
{
- QGridLayout *layout = new QGridLayout( this );
- layout->setSpacing( 5 );
+ TQGridLayout *tqlayout = new TQGridLayout( this );
+ tqlayout->setSpacing( 5 );
// Tool bar
m_tool_bar = new KToolBar( this, "SearchDialogToolBar", true, true );
- m_tool_bar->insertCombo( QStringList(), Combo, true, SIGNAL( returnPressed() ),
- this, SLOT( slotReturnPressed() ), true,
+ m_tool_bar->insertCombo( TQStringList(), Combo, true, TQT_SIGNAL( returnPressed() ),
+ TQT_TQOBJECT(this), TQT_SLOT( slotReturnPressed() ), true,
i18n( "Enter the search string here." ), -1, Combo );
m_tool_bar->setItemAutoSized( Combo, true );
m_tool_bar->insertSeparator();
- m_tool_bar->insertButton( "find", Search, false, i18n( "Search" ) );
+ m_tool_bar->insertButton( "tqfind", Search, false, i18n( "Search" ) );
m_tool_bar->insertButton( "editdelete", Clear, false, i18n( "Clear" ) );
m_tool_bar->insertButton( "button_ok", Add, false, i18n( "Add" ) );
@@ -62,25 +62,25 @@ Smb4KSearchDialog::Smb4KSearchDialog( QWidget *parent, const char *name )
m_list_view = new KListView( this, "SearchDialogListView" );
m_list_view->addColumn( i18n( "Search Results" ), -1 );
m_list_view->header()->hide();
- m_list_view->setSelectionMode( QListView::Single );
+ m_list_view->setSelectionMode( TQListView::Single );
- layout->addWidget( m_tool_bar, 0, 0, 0 );
- layout->addWidget( m_list_view, 1, 0, 0 );
+ tqlayout->addWidget( m_tool_bar, 0, 0, 0 );
+ tqlayout->addWidget( m_list_view, 1, 0, 0 );
- m_search_string = QString::null;
+ m_search_string = TQString();
// Connections:
- connect( m_tool_bar->getCombo( Combo ), SIGNAL( textChanged( const QString & ) ),
- this, SLOT( slotTextChanged( const QString & ) ) );
+ connect( m_tool_bar->getCombo( Combo ), TQT_SIGNAL( textChanged( const TQString & ) ),
+ this, TQT_SLOT( slotTextChanged( const TQString & ) ) );
- connect( m_tool_bar, SIGNAL( pressed( int ) ),
- this, SLOT( slotButtonPressed( int ) ) );
+ connect( m_tool_bar, TQT_SIGNAL( pressed( int ) ),
+ this, TQT_SLOT( slotButtonPressed( int ) ) );
- connect( m_list_view, SIGNAL( clicked( QListViewItem * ) ),
- this, SLOT( slotItemClicked( QListViewItem * ) ) );
+ connect( m_list_view, TQT_SIGNAL( clicked( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemClicked( TQListViewItem * ) ) );
- connect( m_list_view, SIGNAL( selectionChanged( QListViewItem * ) ),
- this, SLOT( slotSelectionChanged( QListViewItem * ) ) );
+ connect( m_list_view, TQT_SIGNAL( selectionChanged( TQListViewItem * ) ),
+ this, TQT_SLOT( slotSelectionChanged( TQListViewItem * ) ) );
}
@@ -89,7 +89,7 @@ Smb4KSearchDialog::~Smb4KSearchDialog()
}
-const QString &Smb4KSearchDialog::searchString()
+const TQString &Smb4KSearchDialog::searchString()
{
m_search_string = m_tool_bar->getCombo( Combo )->currentText();
@@ -98,7 +98,7 @@ const QString &Smb4KSearchDialog::searchString()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KSearchDialog::slotReturnPressed()
@@ -107,7 +107,7 @@ void Smb4KSearchDialog::slotReturnPressed()
}
-void Smb4KSearchDialog::slotTextChanged( const QString &text )
+void Smb4KSearchDialog::slotTextChanged( const TQString &text )
{
m_tool_bar->setItemEnabled( Search, !text.isEmpty() );
m_tool_bar->setItemEnabled( Clear, !text.isEmpty() );
@@ -151,7 +151,7 @@ void Smb4KSearchDialog::slotButtonPressed( int button_id )
}
-void Smb4KSearchDialog::slotItemClicked( QListViewItem *item )
+void Smb4KSearchDialog::slotItemClicked( TQListViewItem *item )
{
if ( !item )
{
@@ -169,7 +169,7 @@ void Smb4KSearchDialog::slotItemClicked( QListViewItem *item )
}
-void Smb4KSearchDialog::slotSelectionChanged( QListViewItem *item )
+void Smb4KSearchDialog::slotSelectionChanged( TQListViewItem *item )
{
if ( item )
{
diff --git a/smb4k/searchdlg/smb4ksearchdialog.h b/smb4k/searchdlg/smb4ksearchdialog.h
index 2b0f2eb..19d2526 100644
--- a/smb4k/searchdlg/smb4ksearchdialog.h
+++ b/smb4k/searchdlg/smb4ksearchdialog.h
@@ -30,9 +30,9 @@
#include <config.h>
#endif
-// Qt includes
-#include <qwidget.h>
-#include <qstring.h>
+// TQt includes
+#include <tqwidget.h>
+#include <tqstring.h>
// KDE includes
#include <klistview.h>
@@ -50,19 +50,20 @@ class Smb4KHostItem;
*/
-class Smb4KSearchDialog : public QWidget
+class Smb4KSearchDialog : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent widget
+ * @param tqparent The tqparent widget
*
* @param name The name of this widget
*/
- Smb4KSearchDialog( QWidget *parent = 0, const char *name = 0 );
+ Smb4KSearchDialog( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -81,7 +82,7 @@ class Smb4KSearchDialog : public QWidget
*
* @returns the search string.
*/
- const QString &searchString();
+ const TQString &searchString();
/**
* This function returns a pointer to the list view of this widget.
@@ -120,7 +121,7 @@ class Smb4KSearchDialog : public QWidget
*
* @param text The text input
*/
- void slotTextChanged( const QString &text );
+ void slotTextChanged( const TQString &text );
/**
* This slot is activated when a button in the tool bar is pressed.
@@ -143,7 +144,7 @@ class Smb4KSearchDialog : public QWidget
* @param item The list box item that the user clicked or NULL if
* he clicked onto the viewport.
*/
- void slotItemClicked( QListViewItem *item );
+ void slotItemClicked( TQListViewItem *item );
/**
* This slot is activated when the selection changed in the list view.
@@ -151,13 +152,13 @@ class Smb4KSearchDialog : public QWidget
*
* @param item The list box item that's currently selected
*/
- void slotSelectionChanged( QListViewItem *item );
+ void slotSelectionChanged( TQListViewItem *item );
private:
/**
* The current search string
*/
- QString m_search_string;
+ TQString m_search_string;
/**
* The list box of this widget
diff --git a/smb4k/searchdlg/smb4ksearchdialog_part.cpp b/smb4k/searchdlg/smb4ksearchdialog_part.cpp
index 6a23df6..fd44ab8 100644
--- a/smb4k/searchdlg/smb4ksearchdialog_part.cpp
+++ b/smb4k/searchdlg/smb4ksearchdialog_part.cpp
@@ -24,9 +24,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qimage.h>
-#include <qpixmap.h>
+// TQt includes
+#include <tqimage.h>
+#include <tqpixmap.h>
// KDE includes
#include <kaboutdata.h>
@@ -48,9 +48,9 @@ KInstance *Smb4KSearchDialogPartFactory::m_instance = 0L;
KAboutData *Smb4KSearchDialogPartFactory::m_about = 0L;
-Smb4KSearchDialogPart::Smb4KSearchDialogPart( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name )
-: KParts::Part( parent, name )
+Smb4KSearchDialogPart::Smb4KSearchDialogPart( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name )
+: KParts::Part( tqparent, name )
{
// First of all we need an instance:
setInstance( Smb4KSearchDialogPartFactory::instance() );
@@ -59,23 +59,23 @@ Smb4KSearchDialogPart::Smb4KSearchDialogPart( QWidget *parentWidget, const char
// setXMLFile( "smb4ksearchdialog_part.rc" );
// Set the widget of this part:
- m_widget = new Smb4KSearchDialog( parentWidget, widgetName );
+ m_widget = new Smb4KSearchDialog( tqparentWidget, widgetName );
setWidget( m_widget );
m_serial_number = 0;
// Connections:
- connect( m_widget, SIGNAL( buttonPressed( int ) ),
- this, SLOT( slotButtonPressed( int ) ) );
+ connect( m_widget, TQT_SIGNAL( buttonPressed( int ) ),
+ this, TQT_SLOT( slotButtonPressed( int ) ) );
- connect( m_widget->listView(), SIGNAL( doubleClicked( QListViewItem * ) ),
- this, SLOT( slotItemDoubleClicked( QListViewItem * ) ) );
+ connect( m_widget->listView(), TQT_SIGNAL( doubleClicked( TQListViewItem * ) ),
+ this, TQT_SLOT( slotItemDoubleClicked( TQListViewItem * ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( searchResult( Smb4KHostItem * ) ),
- this, SLOT( slotReceivedSearchResult( Smb4KHostItem * ) ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( searchResult( Smb4KHostItem * ) ),
+ this, TQT_SLOT( slotReceivedSearchResult( Smb4KHostItem * ) ) );
- connect( Smb4KCore::scanner(), SIGNAL( hostListChanged() ),
- this, SLOT( slotCheckItemIsKnown() ) );
+ connect( Smb4KCore::scanner(), TQT_SIGNAL( hostListChanged() ),
+ this, TQT_SLOT( slotCheckItemIsKnown() ) );
}
@@ -84,7 +84,7 @@ Smb4KSearchDialogPart::~Smb4KSearchDialogPart()
}
-void Smb4KSearchDialogPart::customEvent( QCustomEvent *e )
+void Smb4KSearchDialogPart::customEvent( TQCustomEvent *e )
{
switch ( e->type() )
{
@@ -111,7 +111,7 @@ void Smb4KSearchDialogPart::customEvent( QCustomEvent *e )
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS (Smb4KSearchDialogPart)
+// TQT_SLOT IMPLEMENTATIONS (Smb4KSearchDialogPart)
/////////////////////////////////////////////////////////////////////////////
void Smb4KSearchDialogPart::slotButtonPressed( int button_id )
@@ -171,7 +171,7 @@ void Smb4KSearchDialogPart::slotReceivedSearchResult( Smb4KHostItem *item )
void Smb4KSearchDialogPart::slotCheckItemIsKnown()
{
- QListViewItemIterator it( m_widget->listView() );
+ TQListViewItemIterator it( m_widget->listView() );
while ( it.current() )
{
@@ -193,7 +193,7 @@ void Smb4KSearchDialogPart::slotCheckItemIsKnown()
}
-void Smb4KSearchDialogPart::slotItemDoubleClicked( QListViewItem *item )
+void Smb4KSearchDialogPart::slotItemDoubleClicked( TQListViewItem *item )
{
if ( item )
{
@@ -232,13 +232,13 @@ Smb4KSearchDialogPartFactory::~Smb4KSearchDialogPartFactory()
}
-KParts::Part *Smb4KSearchDialogPartFactory::createPartObject( QWidget *parentWidget, const char *widgetName,
-QObject *parent, const char *name, const char *, const QStringList & )
+KParts::Part *Smb4KSearchDialogPartFactory::createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+TQObject *tqparent, const char *name, const char *, const TQStringList & )
{
- Smb4KSearchDialogPart *obj = new Smb4KSearchDialogPart( parentWidget, widgetName, parent, name );
+ Smb4KSearchDialogPart *obj = new Smb4KSearchDialogPart( tqparentWidget, widgetName, tqparent, name );
// See if we are to be read-write or not
-// if (QCString(classname) == "KParts::ReadOnlyPart")
+// if (TQCString(classname) == "KParts::ReadOnlyPart")
// {
// obj->setReadWrite(false);
// }
diff --git a/smb4k/searchdlg/smb4ksearchdialog_part.h b/smb4k/searchdlg/smb4ksearchdialog_part.h
index 0638a1b..38e97b9 100644
--- a/smb4k/searchdlg/smb4ksearchdialog_part.h
+++ b/smb4k/searchdlg/smb4ksearchdialog_part.h
@@ -31,8 +31,8 @@
#include <config.h>
#endif
-// Qt includes
-#include <qlistview.h>
+// TQt includes
+#include <tqlistview.h>
// KDE includes
#include <kparts/part.h>
@@ -52,21 +52,22 @@ class Smb4KHostItem;
class Smb4KSearchDialogPart : public KParts::Part
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parentWidget The parent widget
+ * @param tqparentWidget The tqparent widget
*
* @param widgetName The name the widget should have
*
- * @param parent The parent object
+ * @param tqparent The tqparent object
*
* @param name The name this object should have
*/
- Smb4KSearchDialogPart( QWidget *parentWidget = 0, const char *widgetName = 0,
- QObject *parent = 0, const char *name = 0 );
+ Smb4KSearchDialogPart( TQWidget *tqparentWidget = 0, const char *widgetName = 0,
+ TQObject *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -77,7 +78,7 @@ class Smb4KSearchDialogPart : public KParts::Part
/**
* Reimplemented from KParts::Part.
*/
- void customEvent( QCustomEvent *e );
+ void customEvent( TQCustomEvent *e );
protected slots:
/**
@@ -111,7 +112,7 @@ class Smb4KSearchDialogPart : public KParts::Part
*
* @param item The item that has been double clicked.
*/
- void slotItemDoubleClicked( QListViewItem *item );
+ void slotItemDoubleClicked( TQListViewItem *item );
private:
/**
@@ -132,6 +133,7 @@ class KAboutData;
class Smb4KSearchDialogPartFactory : public KParts::Factory
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
@@ -147,9 +149,9 @@ class Smb4KSearchDialogPartFactory : public KParts::Factory
/**
* Reimplemented from KParts::Factory
*/
- virtual KParts::Part *createPartObject( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
- const char *classname, const QStringList &args );
+ virtual KParts::Part *createPartObject( TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name,
+ const char *classname, const TQStringList &args );
/**
* The instance
diff --git a/smb4k/searchdlg/smb4ksearchdialogitem.cpp b/smb4k/searchdlg/smb4ksearchdialogitem.cpp
index 525072e..9b18496 100644
--- a/smb4k/searchdlg/smb4ksearchdialogitem.cpp
+++ b/smb4k/searchdlg/smb4ksearchdialogitem.cpp
@@ -24,8 +24,8 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qimage.h>
+// TQt includes
+#include <tqimage.h>
// KDE includes
#include <kiconloader.h>
@@ -47,7 +47,7 @@ Smb4KSearchDialogItem::Smb4KSearchDialogItem( KListView *listView, Smb4KHostItem
{
m_is_regular = true;
- QString item_text = m_item.name();
+ TQString item_text = m_item.name();
if ( !m_item.workgroup().isEmpty() && !m_item.ip().isEmpty() )
{
@@ -95,12 +95,12 @@ void Smb4KSearchDialogItem::setIcon()
if ( m_is_known )
{
KIconEffect e;
- QImage over = SmallIcon( "button_ok" ).convertToImage();
- QImage src = SmallIcon( "server" ).convertToImage();
+ TQImage over = SmallIcon( "button_ok" ).convertToImage();
+ TQImage src = SmallIcon( "server" ).convertToImage();
e.semiTransparent( over );
e.overlay( src, over );
- QPixmap pix( src );
+ TQPixmap pix( src );
setPixmap( 0, pix );
}
@@ -124,7 +124,7 @@ void Smb4KSearchDialogItem::setKnown( bool known )
}
-int Smb4KSearchDialogItem::compare( QListViewItem *i, int, bool ascending ) const
+int Smb4KSearchDialogItem::compare( TQListViewItem *i, int, bool ascending ) const
{
Smb4KSearchDialogItem *item = static_cast<Smb4KSearchDialogItem *>( i );
diff --git a/smb4k/searchdlg/smb4ksearchdialogitem.h b/smb4k/searchdlg/smb4ksearchdialogitem.h
index 97dbbc9..9b070b9 100644
--- a/smb4k/searchdlg/smb4ksearchdialogitem.h
+++ b/smb4k/searchdlg/smb4ksearchdialogitem.h
@@ -32,7 +32,7 @@
#include <config.h>
#endif
-// Qt includes
+// TQt includes
#include <klistview.h>
// application specific includes
@@ -56,7 +56,7 @@ class Smb4KSearchDialogItem : public KListViewItem
* text according to the contents of @p item. If the search failed
* and @p item is empty, an error message will be displayed.
*
- * @param listBox The parent list box.
+ * @param listBox The tqparent list box.
*
* @param item The host item that represents the search
* result.
@@ -76,7 +76,7 @@ class Smb4KSearchDialogItem : public KListViewItem
* here.
*
* Make sure you copy the contents to a new item, because the pointer
- * will be invalidated if this Smb4KSearchDialogItem is deleted.
+ * will be tqinvalidated if this Smb4KSearchDialogItem is deleted.
*
* @returns the encapsulated Smb4KHostItem object.
*/
@@ -115,7 +115,7 @@ class Smb4KSearchDialogItem : public KListViewItem
int serialNumber() const { return m_serial; }
/**
- * Reimplemented from QListViewItem. It is used for sorting and compares the
+ * Reimplemented from TQListViewItem. It is used for sorting and compares the
* serial numbers of this item and @p item. If @p ascending is TRUE and the
* serial number of this item is greater than that of @p item, it will be inserted
* before @p item and else it will be inserted after. In this implementation,
@@ -132,7 +132,7 @@ class Smb4KSearchDialogItem : public KListViewItem
* they are not. Which value and especially which algebraic sign is returned depends
* on the values that are returned by of both serialNumber() functions and on @p ascending.
*/
- int compare( QListViewItem *item, int col, bool ascending ) const;
+ int compare( TQListViewItem *item, int col, bool ascending ) const;
private:
/**
diff --git a/smb4k/smb4k.cpp b/smb4k/smb4k.cpp
index a2877ae..549bcef 100644
--- a/smb4k/smb4k.cpp
+++ b/smb4k/smb4k.cpp
@@ -23,9 +23,9 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qvaluelist.h>
-#include <qpopupmenu.h>
+// TQt includes
+#include <tqvaluelist.h>
+#include <tqpopupmenu.h>
// KDE includes
#include <kstatusbar.h>
@@ -54,8 +54,8 @@
using namespace Smb4KGlobal;
-Smb4KApp::Smb4KApp( QWidget *parent, const char *name )
-: KParts::DockMainWindow( parent, name )
+Smb4KApp::Smb4KApp( TQWidget *tqparent, const char *name )
+: KParts::DockMainWindow( tqparent, name )
{
m_system_tray = NULL;
@@ -77,7 +77,7 @@ Smb4KApp::Smb4KApp( QWidget *parent, const char *name )
// Setup all things that need to be done *after* createGUI()
// was run:
- QPopupMenu *settings = static_cast<QPopupMenu *>( child( "settings", "QPopupMenu", true ) );
+ TQPopupMenu *settings = static_cast<TQPopupMenu *>( TQT_TQWIDGET(child( "settings", TQPOPUPMENU_OBJECT_NAME_STRING, true )) );
if ( settings )
{
@@ -101,15 +101,15 @@ Smb4KApp::Smb4KApp( QWidget *parent, const char *name )
// because the first labels will be saved and then loaded again
// and again.
KDockWidget *dock = NULL;
- KDockTabGroup *parent_group = NULL;
+ KDockTabGroup *tqparent_group = NULL;
if ( (dock = manager()->getDockWidgetFromName( "NetworkBrowser" )) != NULL )
{
dock->setTabPageLabel( i18n( "Network Browser" ) );
- if ( (parent_group = dock->parentDockTabGroup()) != NULL )
+ if ( (tqparent_group = dock->parentDockTabGroup()) != NULL )
{
- parent_group->changeTab( dock, i18n( "Network Browser" ) );
+ tqparent_group->changeTab( dock, i18n( "Network Browser" ) );
}
}
@@ -117,24 +117,24 @@ Smb4KApp::Smb4KApp( QWidget *parent, const char *name )
{
dock->setTabPageLabel( i18n( "Search Dialog" ) );
- if ( (parent_group = dock->parentDockTabGroup()) != NULL )
+ if ( (tqparent_group = dock->parentDockTabGroup()) != NULL )
{
- parent_group->changeTab( dock, i18n( "Search Dialog" ) );
+ tqparent_group->changeTab( dock, i18n( "Search Dialog" ) );
}
}
// Connections
- connect( actionCollection(), SIGNAL( actionHighlighted( KAction * ) ),
- this, SLOT( slotActionHighlighted( KAction * ) ) );
+ connect( actionCollection(), TQT_SIGNAL( actionHighlighted( KAction * ) ),
+ this, TQT_SLOT( slotActionHighlighted( KAction * ) ) );
- connect( Smb4KCore::self(), SIGNAL( runStateChanged() ),
- this, SLOT( slotRunStateChanged() ) );
+ connect( Smb4KCore::self(), TQT_SIGNAL( runStateChanged() ),
+ this, TQT_SLOT( slotRunStateChanged() ) );
- connect( Smb4KCore::bookmarkHandler(), SIGNAL( bookmarksUpdated() ),
- this, SLOT( slotSetupBookmarksMenu() ) );
+ connect( Smb4KCore::bookmarkHandler(), TQT_SIGNAL( bookmarksUpdated() ),
+ this, TQT_SLOT( slotSetupBookmarksMenu() ) );
- connect( Smb4KCore::mounter(), SIGNAL( updated() ),
- this, SLOT( slotShareListUpdated() ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( updated() ),
+ this, TQT_SLOT( slotShareListUpdated() ) );
}
@@ -147,7 +147,7 @@ void Smb4KApp::setupActions()
{
actionCollection()->setHighlightingEnabled( true );
- (void) KStdAction::quit( this, SLOT( slotQuit() ), actionCollection(), "quit_action" );
+ (void) KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( slotQuit() ), actionCollection(), "quit_action" );
// Set up the "Settings" menu:
setStandardToolBarMenuEnabled( true );
@@ -157,11 +157,11 @@ void Smb4KApp::setupActions()
actionCollection(), "view_modes_menu" );
KRadioAction *icon_view = new KRadioAction( i18n( "&Icon View" ), "view_icon", CTRL+Key_I,
- this, SLOT( slotChangeSharesView() ), actionCollection(), "icon_view_action" );
+ TQT_TQOBJECT(this), TQT_SLOT( slotChangeSharesView() ), actionCollection(), "icon_view_action" );
icon_view->setExclusiveGroup( "SharesViewActions" );
KRadioAction *list_view = new KRadioAction( i18n( "List Vie&w" ), "view_detailed", CTRL+Key_W,
- this, SLOT( slotChangeSharesView() ), actionCollection(), "list_view_action" );
+ TQT_TQOBJECT(this), TQT_SLOT( slotChangeSharesView() ), actionCollection(), "list_view_action" );
list_view->setExclusiveGroup( "SharesViewActions" );
switch ( Smb4KSettings::sharesView() )
@@ -187,7 +187,7 @@ void Smb4KApp::setupActions()
view_modes->insert( icon_view, -1 );
view_modes->insert( list_view, -1 );
- (void) KStdAction::preferences( this, SLOT( slotConfigDialog() ), actionCollection(), "configure_action" );
+ (void) KStdAction::preferences( TQT_TQOBJECT(this), TQT_SLOT( slotConfigDialog() ), actionCollection(), "configure_action" );
// Notes:
// (1) Actions from the parts will be included by setupView().
@@ -208,7 +208,7 @@ void Smb4KApp::setupStatusBar()
progress->setPercentageVisible( false );
statusBar()->addWidget( progress, 0, true );
- statusBar()->insertFixedItem( QString( "Smb4K %1" ).arg( VERSION ), Version, true );
+ statusBar()->insertFixedItem( TQString( "Smb4K %1" ).tqarg( VERSION ), Version, true );
// Align the items:
statusBar()->setItemAlignment( Message, AlignAuto );
@@ -248,7 +248,7 @@ void Smb4KApp::setupView()
if ( shares_factory )
{
- m_shares_part = static_cast<KParts::Part *>( shares_factory->create( this, "SharesPart", "KParts::Part" ) );
+ m_shares_part = static_cast<KParts::Part *>( shares_factory->create( TQT_TQOBJECT(this), "SharesPart", "KParts::Part" ) );
if ( m_shares_part )
{
@@ -261,7 +261,7 @@ void Smb4KApp::setupView()
createGUI( m_shares_part );
- accel()->insert( i18n( "Jump to shares view" ), CTRL+Key_3, this, SLOT( slotJumpToSharesView() ), false, true );
+ accel()->insert( i18n( "Jump to shares view" ), CTRL+Key_3, TQT_TQOBJECT(this), TQT_SLOT( slotJumpToSharesView() ), false, true );
}
}
else
@@ -280,7 +280,7 @@ void Smb4KApp::setupView()
if ( browser_factory )
{
- m_browser_part = static_cast<KParts::Part *>( browser_factory->create( this, "BrowserPart", "KParts::Part" ) );
+ m_browser_part = static_cast<KParts::Part *>( browser_factory->create( TQT_TQOBJECT(this), "BrowserPart", "KParts::Part" ) );
if ( m_browser_part )
{
@@ -290,7 +290,7 @@ void Smb4KApp::setupView()
factory()->addClient( m_browser_part );
- accel()->insert( i18n( "Jump to network browser" ), CTRL+Key_1, this, SLOT( slotJumpToNetworkBrowser() ), false, true );
+ accel()->insert( i18n( "Jump to network browser" ), CTRL+Key_1, TQT_TQOBJECT(this), TQT_SLOT( slotJumpToNetworkBrowser() ), false, true );
}
}
else
@@ -309,11 +309,11 @@ void Smb4KApp::setupView()
if ( search_factory )
{
- m_search_part = static_cast<KParts::Part *>( search_factory->create( this, "SearchDialogPart", "KParts::Part" ) );
+ m_search_part = static_cast<KParts::Part *>( search_factory->create( TQT_TQOBJECT(this), "SearchDialogPart", "KParts::Part" ) );
if ( m_search_part )
{
- KDockWidget *search = createDockWidget( "SearchDialog", SmallIcon( "find" ), 0L, i18n( "Search Dialog" ) );
+ KDockWidget *search = createDockWidget( "SearchDialog", SmallIcon( "tqfind" ), 0L, i18n( "Search Dialog" ) );
search->setWidget( m_search_part->widget() );
KDockWidget *network = manager()->getDockWidgetFromName( "NetworkBrowser" );
@@ -329,7 +329,7 @@ void Smb4KApp::setupView()
factory()->addClient( m_search_part );
- accel()->insert( i18n( "Jump to search dialog" ), CTRL+Key_2, this, SLOT( slotJumpToSearchDialog() ), false, true );
+ accel()->insert( i18n( "Jump to search dialog" ), CTRL+Key_2, TQT_TQOBJECT(this), TQT_SLOT( slotJumpToSearchDialog() ), false, true );
}
}
else
@@ -350,11 +350,11 @@ void Smb4KApp::setupSystemTray()
m_system_tray = new Smb4KSystemTray( this, "SystemTray" );
}
- connect( m_system_tray, SIGNAL( quitSelected() ),
- this, SLOT( slotQuit() ) );
+ connect( m_system_tray, TQT_SIGNAL( quitSelected() ),
+ this, TQT_SLOT( slotQuit() ) );
- connect( m_system_tray, SIGNAL( settingsChanged() ),
- this, SLOT( slotSettingsChanged() ) );
+ connect( m_system_tray, TQT_SIGNAL( settingsChanged() ),
+ this, TQT_SLOT( slotSettingsChanged() ) );
m_system_tray->embed( Smb4KSettings::embedIntoSystemTray() );
}
@@ -403,7 +403,7 @@ void Smb4KApp::changeSharesView()
if ( shares_factory )
{
- m_shares_part = static_cast<KParts::Part *>( shares_factory->create( this, "SharesPart", "KParts::Part" ) );
+ m_shares_part = static_cast<KParts::Part *>( shares_factory->create( TQT_TQOBJECT(this), "SharesPart", "KParts::Part" ) );
if ( m_shares_part )
{
@@ -476,9 +476,9 @@ bool Smb4KApp::queryClose()
}
-void Smb4KApp::timerEvent( QTimerEvent * )
+void Smb4KApp::timerEvent( TQTimerEvent * )
{
- KProgress *progress_bar = static_cast<KProgress *>( child( "StatusBarProgressBar", "KProgress", true ) );
+ KProgress *progress_bar = static_cast<KProgress *>( TQT_TQWIDGET(child( "StatusBarProgressBar", "KProgress", true )) );
if ( progress_bar )
{
@@ -488,7 +488,7 @@ void Smb4KApp::timerEvent( QTimerEvent * )
/////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////
void Smb4KApp::slotQuit()
@@ -508,14 +508,14 @@ void Smb4KApp::slotChangeSharesView()
{
// Let's be sure that the last action that was highlighted is
// indeed an action that changes the shares view:
- QString action_name;
+ TQString action_name;
if ( m_action )
{
- action_name = QString( m_action->name() );
+ action_name = TQString( m_action->name() );
- if ( QString::compare( action_name, "icon_view_action" ) != 0 &&
- QString::compare( action_name, "list_view_action" ) != 0 )
+ if ( TQString::compare( action_name, "icon_view_action" ) != 0 &&
+ TQString::compare( action_name, "list_view_action" ) != 0 )
{
return;
}
@@ -538,11 +538,11 @@ void Smb4KApp::slotChangeSharesView()
}
// Change the shares view setting and save it:
- if ( QString::compare( action_name, "icon_view_action" ) == 0 )
+ if ( TQString::compare( action_name, "icon_view_action" ) == 0 )
{
Smb4KSettings::setSharesView( Smb4KSettings::EnumSharesView::IconView );
}
- else if ( QString::compare( action_name, "list_view_action" ) == 0 )
+ else if ( TQString::compare( action_name, "list_view_action" ) == 0 )
{
Smb4KSettings::setSharesView( Smb4KSettings::EnumSharesView::ListView );
}
@@ -571,11 +571,11 @@ void Smb4KApp::slotConfigDialog()
if ( config_factory )
{
- KConfigDialog *dlg = static_cast<KConfigDialog *>( config_factory->create( this, "ConfigDialog", "KConfigDialog" ) );
+ KConfigDialog *dlg = static_cast<KConfigDialog *>( TQT_TQWIDGET(config_factory->create( TQT_TQOBJECT(this), "ConfigDialog", "KConfigDialog" )) );
if ( dlg )
{
- connect( dlg, SIGNAL( settingsChanged() ), this, SLOT( slotSettingsChanged() ) );
+ connect( dlg, TQT_SIGNAL( settingsChanged() ), TQT_TQOBJECT(this), TQT_SLOT( slotSettingsChanged() ) );
dlg->show();
}
@@ -609,16 +609,16 @@ void Smb4KApp::slotSettingsChanged()
}
// Notify the parts to reload the settings.
- // Note: QApplication::postEvent() will delete the QCustomEvent pointers.
- QApplication::postEvent( m_browser_part, new QCustomEvent( EVENT_LOAD_SETTINGS ) );
- QApplication::postEvent( m_search_part, new QCustomEvent( EVENT_LOAD_SETTINGS ) );
- QApplication::postEvent( m_shares_part, new QCustomEvent( EVENT_LOAD_SETTINGS ) );
+ // Note: TQApplication::postEvent() will delete the TQCustomEvent pointers.
+ TQApplication::postEvent( m_browser_part, new TQCustomEvent( EVENT_LOAD_SETTINGS ) );
+ TQApplication::postEvent( m_search_part, new TQCustomEvent( EVENT_LOAD_SETTINGS ) );
+ TQApplication::postEvent( m_shares_part, new TQCustomEvent( EVENT_LOAD_SETTINGS ) );
}
void Smb4KApp::slotBookmarkEditor()
{
- Smb4KBookmarkEditor *dlg = static_cast<Smb4KBookmarkEditor *>( child( "BookmarkEditor", "Smb4KBookmarkEditor", true ) );
+ Smb4KBookmarkEditor *dlg = static_cast<Smb4KBookmarkEditor *>( TQT_TQWIDGET(child( "BookmarkEditor", "Smb4KBookmarkEditor", true )) );
if ( !dlg )
{
@@ -632,7 +632,7 @@ void Smb4KApp::slotBookmarkEditor()
void Smb4KApp::slotRunStateChanged()
{
// Get the progress bar:
- KProgress *progress_bar = static_cast<KProgress *>( child( "StatusBarProgressBar", "KProgress", true ) );
+ KProgress *progress_bar = static_cast<KProgress *>( TQT_TQWIDGET(child( "StatusBarProgressBar", "KProgress", true )) );
// Clear the status bar:
statusBar()->clear();
@@ -658,7 +658,7 @@ void Smb4KApp::slotRunStateChanged()
}
case Smb4KSettings::EnumBrowseList::QueryCustomMaster:
{
- statusBar()->changeItem( i18n( "Querying master browser %1..." ).arg( Smb4KSettings::customMasterBrowser().upper() ), Message );
+ statusBar()->changeItem( i18n( "Querying master browser %1..." ).tqarg( Smb4KSettings::customMasterBrowser().upper() ), Message );
break;
}
@@ -807,23 +807,23 @@ void Smb4KApp::slotRunStateChanged()
void Smb4KApp::slotSetupBookmarksMenu()
{
// Set up bookmark related actions:
- QValueList<Smb4KBookmark *> bookmarks = Smb4KCore::bookmarkHandler()->getBookmarks();
+ TQValueList<Smb4KBookmark *> bookmarks = Smb4KCore::bookmarkHandler()->getBookmarks();
if ( !actionCollection()->action( "edit_bookmarks_action" ) )
{
unplugActionList( "bookmark_actions" );
- QPtrList<KAction> bookmark_actions;
+ TQPtrList<KAction> bookmark_actions;
// Create the "Edit Bookmarks" action:
bookmark_actions.append( new KAction( i18n( "&Edit Bookmarks" ), "bookmark", CTRL+Key_E,
- this, SLOT( slotBookmarkEditor() ), actionCollection(),
+ TQT_TQOBJECT(this), TQT_SLOT( slotBookmarkEditor() ), actionCollection(),
"edit_bookmarks_action" ) );
// Get the "Add Bookmark" action from the browser:
- QPtrList<KXMLGUIClient> clients_list = factory()->clients();
+ TQPtrList<KXMLGUIClient> clients_list = factory()->clients();
- for ( QPtrList<KXMLGUIClient>::Iterator it = clients_list.begin(); it != clients_list.end(); ++it )
+ for ( TQPtrList<KXMLGUIClient>::Iterator it = clients_list.begin(); it != clients_list.end(); ++it )
{
if ( (*it)->action( "bookmark_action" ) )
{
@@ -865,9 +865,9 @@ void Smb4KApp::slotSetupBookmarksMenu()
actionCollection()->action( "edit_bookmarks_action" )->setEnabled( true );
// Work around sorting problems:
- QStringList display_strings;
+ TQStringList display_strings;
- for ( QValueListIterator<Smb4KBookmark *> it = bookmarks.begin(); it != bookmarks.end(); ++it )
+ for ( TQValueListIterator<Smb4KBookmark *> it = bookmarks.begin(); it != bookmarks.end(); ++it )
{
if ( !(*it)->label().isEmpty() && Smb4KSettings::showCustomBookmarkLabel() )
{
@@ -882,13 +882,13 @@ void Smb4KApp::slotSetupBookmarksMenu()
display_strings.sort();
// Create the bookmark list and plug it into the menu:
- QPtrList<KAction> bookmark_list;
+ TQPtrList<KAction> bookmark_list;
- for ( QStringList::ConstIterator it = display_strings.begin(); it != display_strings.end(); ++it )
+ for ( TQStringList::ConstIterator it = display_strings.begin(); it != display_strings.end(); ++it )
{
KAction *a = new KAction( *it, "folder", KShortcut::null(), 0, 0, actionCollection(), *it );
a->setGroup( "Bookmarks" );
- connect( a, SIGNAL( activated() ), this, SLOT( slotBookmarkActivated() ) );
+ connect( a, TQT_SIGNAL( activated() ), TQT_TQOBJECT(this), TQT_SLOT( slotBookmarkActivated() ) );
bookmark_list.append( a );
}
@@ -899,7 +899,7 @@ void Smb4KApp::slotSetupBookmarksMenu()
void Smb4KApp::slotBookmarkActivated()
{
- if ( m_action && QString::compare( m_action->group(), "Bookmarks" ) == 0 )
+ if ( m_action && TQString::compare( m_action->group(), "Bookmarks" ) == 0 )
{
Smb4KBookmark *bookmark = NULL;
@@ -931,7 +931,7 @@ void Smb4KApp::slotShareListUpdated()
if ( !list.isEmpty() )
{
- QString name;
+ TQString name;
for ( KActionPtrList::ConstIterator it = list.begin(); it != list.end(); ++it )
{
@@ -946,11 +946,11 @@ void Smb4KApp::slotShareListUpdated()
name = (*it)->plainText();
}
- QValueList<Smb4KShare> share_list = Smb4KCore::mounter()->findShareByName( name );
+ TQValueList<Smb4KShare> share_list = Smb4KCore::mounter()->findShareByName( name );
bool enable = true;
- for ( QValueList<Smb4KShare>::ConstIterator i = share_list.begin(); i != share_list.end(); ++i )
+ for ( TQValueList<Smb4KShare>::ConstIterator i = share_list.begin(); i != share_list.end(); ++i )
{
if ( !(*i).isForeign() )
{
@@ -988,7 +988,7 @@ void Smb4KApp::slotJumpToNetworkBrowser()
// Send a custom focus event to the browser, that tells it to set
// the focus to the list view widget.
- QApplication::postEvent( m_browser_part, new QCustomEvent( EVENT_SET_FOCUS ) );
+ TQApplication::postEvent( m_browser_part, new TQCustomEvent( EVENT_SET_FOCUS ) );
}
@@ -1004,7 +1004,7 @@ void Smb4KApp::slotJumpToSearchDialog()
// Send a custom focus event to the search dialog, that tells it
// to set the focus to the combo box in the tool bar.
- QApplication::postEvent( m_search_part, new QCustomEvent( EVENT_SET_FOCUS ) );
+ TQApplication::postEvent( m_search_part, new TQCustomEvent( EVENT_SET_FOCUS ) );
}
@@ -1012,7 +1012,7 @@ void Smb4KApp::slotJumpToSharesView()
{
// Send a custom focus event to the shares view, that tells it
// to set the focus to its main widget.
- QApplication::postEvent( m_shares_part, new QCustomEvent( EVENT_SET_FOCUS ) );
+ TQApplication::postEvent( m_shares_part, new TQCustomEvent( EVENT_SET_FOCUS ) );
}
#include "smb4k.moc"
diff --git a/smb4k/smb4k.h b/smb4k/smb4k.h
index 2021a47..1282285 100644
--- a/smb4k/smb4k.h
+++ b/smb4k/smb4k.h
@@ -46,16 +46,17 @@ class Smb4KSystemTray;
class Smb4KApp : public KParts::DockMainWindow
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent of this widget
+ * @param tqparent The tqparent of this widget
*
* @param name The name of this widget
*/
- Smb4KApp( QWidget *parent = 0, const char *name = 0 );
+ Smb4KApp( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
@@ -74,9 +75,9 @@ class Smb4KApp : public KParts::DockMainWindow
bool queryClose();
/**
- * Reimplemented from QObject
+ * Reimplemented from TQObject
*/
- void timerEvent( QTimerEvent *e );
+ void timerEvent( TQTimerEvent *e );
protected slots:
/**
diff --git a/smb4k/smb4ksystemtray.cpp b/smb4k/smb4ksystemtray.cpp
index 336f0ec..2b21b85 100644
--- a/smb4k/smb4ksystemtray.cpp
+++ b/smb4k/smb4ksystemtray.cpp
@@ -23,11 +23,11 @@
* MA 02110-1301 USA *
***************************************************************************/
-// Qt includes
-#include <qtooltip.h>
-#include <qiconset.h>
-#include <qpixmap.h>
-#include <qimage.h>
+// TQt includes
+#include <tqtooltip.h>
+#include <tqiconset.h>
+#include <tqpixmap.h>
+#include <tqimage.h>
// KDE specific includes
#include <kiconloader.h>
@@ -51,12 +51,12 @@
#include "core/smb4ksettings.h"
-Smb4KSystemTray::Smb4KSystemTray( QWidget *parent, const char *name )
-: KSystemTray( parent, name )
+Smb4KSystemTray::Smb4KSystemTray( TQWidget *tqparent, const char *name )
+: KSystemTray( tqparent, name )
{
setPixmap( loadIcon( "smb4k" ) );
- QToolTip::add( this, i18n( "Smb4K" ) );
+ TQToolTip::add( this, i18n( "Smb4K" ) );
m_action = NULL;
@@ -68,11 +68,11 @@ Smb4KSystemTray::Smb4KSystemTray( QWidget *parent, const char *name )
actionCollection(), "st_mounted_shares_action_menu" );
m_bookmarks_menu = new KActionMenu( i18n( "Bookmarks" ), "bookmark_folder",
actionCollection(), "st_bookmark_action_menu" );
- KActionSeparator *sep = new KActionSeparator( this );
+ KActionSeparator *sep = new KActionSeparator( TQT_TQOBJECT(this) );
KAction *manual_mount = new KAction( i18n( "M&ount Manually" ), "connect_creating",
- 0, this, SLOT( slotMountManually() ),
+ 0, TQT_TQOBJECT(this), TQT_SLOT( slotMountManually() ),
actionCollection(), "st_mount_manually_action" );
- KAction *configure = KStdAction::preferences( this, SLOT( slotConfigDialog() ),
+ KAction *configure = KStdAction::preferences( TQT_TQOBJECT(this), TQT_SLOT( slotConfigDialog() ),
actionCollection(), "st_configure_action" );
m_shares_menu->plug( contextMenu() );
@@ -86,19 +86,19 @@ Smb4KSystemTray::Smb4KSystemTray( QWidget *parent, const char *name )
slotSetupSharesMenu();
// Connections:
- connect( actionCollection(), SIGNAL( actionHighlighted( KAction * ) ),
- this, SLOT( slotActionHighlighted( KAction * ) ) );
+ connect( actionCollection(), TQT_SIGNAL( actionHighlighted( KAction * ) ),
+ this, TQT_SLOT( slotActionHighlighted( KAction * ) ) );
- connect( Smb4KCore::bookmarkHandler(), SIGNAL( bookmarksUpdated() ),
- this, SLOT( slotSetupBookmarksMenu() ) );
+ connect( Smb4KCore::bookmarkHandler(), TQT_SIGNAL( bookmarksUpdated() ),
+ this, TQT_SLOT( slotSetupBookmarksMenu() ) );
- connect( Smb4KCore::mounter(), SIGNAL( updated() ),
- this, SLOT( slotEnableBookmarks() ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( updated() ),
+ this, TQT_SLOT( slotEnableBookmarks() ) );
- connect( Smb4KCore::mounter(), SIGNAL( updated() ),
- this, SLOT( slotSetupSharesMenu() ) );
+ connect( Smb4KCore::mounter(), TQT_SIGNAL( updated() ),
+ this, TQT_SLOT( slotSetupSharesMenu() ) );
- // Connection to quitSelected() signal must be done in parent widget.
+ // Connection to quitSelected() signal must be done in tqparent widget.
}
@@ -134,27 +134,27 @@ void Smb4KSystemTray::loadSettings()
/////////////////////////////////////////////////////////////////////////////
-// SLOT IMPLEMENTATIONS
+// TQT_SLOT IMPLEMENTATIONS
/////////////////////////////////////////////////////////////////////////////
void Smb4KSystemTray::slotMountManually()
{
Smb4KMountDialog *dlg = NULL;
- if ( parentWidget() )
+ if ( tqparentWidget() )
{
- dlg = static_cast<Smb4KMountDialog *>( parentWidget()->child( "MountDialog", "Smb4KMountDialog", true ) );
+ dlg = static_cast<Smb4KMountDialog *>( TQT_TQWIDGET(tqparentWidget()->child( "MountDialog", "Smb4KMountDialog", true )) );
}
else
{
- dlg = static_cast<Smb4KMountDialog *>( child( "MountDialog", "Smb4KMountDialog", true ) );
+ dlg = static_cast<Smb4KMountDialog *>( TQT_TQWIDGET(child( "MountDialog", "Smb4KMountDialog", true )) );
}
if ( !dlg )
{
- if ( parentWidget() && parentWidget()->isShown() )
+ if ( tqparentWidget() && tqparentWidget()->isShown() )
{
- dlg = new Smb4KMountDialog( parentWidget(), "MountDialog" );
+ dlg = new Smb4KMountDialog( tqparentWidget(), "MountDialog" );
}
else
{
@@ -181,8 +181,8 @@ void Smb4KSystemTray::slotConfigDialog()
// To make sure we do not connect the config dialog several times
// to slotSettingsChanged(), we break the connection first and re-
// establish it afterwards:
- disconnect( dlg, SIGNAL( settingsChanged() ), this, SLOT( slotSettingsChanged() ) );
- connect( dlg, SIGNAL( settingsChanged() ), this, SLOT( slotSettingsChanged() ) );
+ disconnect( dlg, TQT_SIGNAL( settingsChanged() ), TQT_TQOBJECT(this), TQT_SLOT( slotSettingsChanged() ) );
+ connect( dlg, TQT_SIGNAL( settingsChanged() ), TQT_TQOBJECT(this), TQT_SLOT( slotSettingsChanged() ) );
return;
}
@@ -192,19 +192,19 @@ void Smb4KSystemTray::slotConfigDialog()
if ( config_factory )
{
- if ( parentWidget() && parentWidget()->isShown() )
+ if ( tqparentWidget() && tqparentWidget()->isShown() )
{
- dlg = static_cast<KConfigDialog *>( config_factory->create( parentWidget(), "ConfigDialog", "KConfigDialog" ) );
+ dlg = static_cast<KConfigDialog *>( TQT_TQWIDGET(config_factory->create( TQT_TQOBJECT(tqparentWidget()), "ConfigDialog", "KConfigDialog" )) );
}
else
{
- dlg = static_cast<KConfigDialog *>( config_factory->create( this, "ConfigDialog", "KConfigDialog" ) );
+ dlg = static_cast<KConfigDialog *>( TQT_TQWIDGET(config_factory->create( TQT_TQOBJECT(this), "ConfigDialog", "KConfigDialog" )) );
}
// ... and show it.
if ( dlg )
{
- connect( dlg, SIGNAL( settingsChanged() ), this, SLOT( slotSettingsChanged() ) );
+ connect( dlg, TQT_SIGNAL( settingsChanged() ), TQT_TQOBJECT(this), TQT_SLOT( slotSettingsChanged() ) );
dlg->show();
}
@@ -219,7 +219,7 @@ void Smb4KSystemTray::slotConfigDialog()
void Smb4KSystemTray::slotSettingsChanged()
{
- // Notify the parent that the settings changed:
+ // Notify the tqparent that the settings changed:
emit settingsChanged();
// Execute loadSettings():
@@ -234,7 +234,7 @@ void Smb4KSystemTray::slotSetupBookmarksMenu()
{
// OK, build the menu from ground up:
KAction *edit_bookmarks = new KAction( i18n( "&Edit Bookmarks" ), "bookmark", 0,
- this, SLOT( slotBookmarkEditor() ), actionCollection(),
+ TQT_TQOBJECT(this), TQT_SLOT( slotBookmarkEditor() ), actionCollection(),
"st_edit_bookmarks_action" );
edit_bookmarks->setGroup( "BookmarkActions" );
edit_bookmarks->plug( m_bookmarks_menu->popupMenu() );
@@ -256,8 +256,8 @@ void Smb4KSystemTray::slotSetupBookmarksMenu()
}
// Get the list of bookmarks:
- QValueList<Smb4KBookmark *> bookmarks = Smb4KCore::bookmarkHandler()->getBookmarks();
- QStringList display_strings;
+ TQValueList<Smb4KBookmark *> bookmarks = Smb4KCore::bookmarkHandler()->getBookmarks();
+ TQStringList display_strings;
// Prepare the list of bookmarks for display:
if ( !bookmarks.isEmpty() )
@@ -266,7 +266,7 @@ void Smb4KSystemTray::slotSetupBookmarksMenu()
actionCollection()->action( "st_edit_bookmarks_action" )->setEnabled( true );
// Work around sorting problems:
- for ( QValueListIterator<Smb4KBookmark *> it = bookmarks.begin(); it != bookmarks.end(); ++it )
+ for ( TQValueListIterator<Smb4KBookmark *> it = bookmarks.begin(); it != bookmarks.end(); ++it )
{
if ( !(*it)->label().isEmpty() && Smb4KSettings::showCustomBookmarkLabel() )
{
@@ -286,15 +286,15 @@ void Smb4KSystemTray::slotSetupBookmarksMenu()
actionCollection()->action( "st_edit_bookmarks_action" )->setEnabled( false );
}
- for ( QStringList::ConstIterator it = display_strings.begin(); it != display_strings.end(); ++it )
+ for ( TQStringList::ConstIterator it = display_strings.begin(); it != display_strings.end(); ++it )
{
// Create the bookmark action:
KAction *a = new KAction( *it, "folder", KShortcut::null(), 0, 0, actionCollection(), "st_"+*it );
a->setGroup( "Bookmarks" );
- connect( a, SIGNAL( activated() ), this, SLOT( slotBookmarkActivated() ) );
+ connect( a, TQT_SIGNAL( activated() ), TQT_TQOBJECT(this), TQT_SLOT( slotBookmarkActivated() ) );
// Let's have a look if the bookmark action has to be enabled or disabled:
- QString name;
+ TQString name;
if ( !(*it).startsWith( "//" ) )
{
@@ -307,11 +307,11 @@ void Smb4KSystemTray::slotSetupBookmarksMenu()
name = *it;
}
- QValueList<Smb4KShare> share_list = Smb4KCore::mounter()->findShareByName( name );
+ TQValueList<Smb4KShare> share_list = Smb4KCore::mounter()->findShareByName( name );
bool enable = true;
- for ( QValueList<Smb4KShare>::ConstIterator i = share_list.begin(); i != share_list.end(); ++i )
+ for ( TQValueList<Smb4KShare>::ConstIterator i = share_list.begin(); i != share_list.end(); ++i )
{
if ( !(*i).isForeign() )
{
@@ -337,20 +337,20 @@ void Smb4KSystemTray::slotBookmarkEditor()
{
Smb4KBookmarkEditor *dlg = NULL;
- if ( parentWidget() )
+ if ( tqparentWidget() )
{
- dlg = static_cast<Smb4KBookmarkEditor *>( parentWidget()->child( "BookmarkEditor", "Smb4KBookmarkEditor", true ) );
+ dlg = static_cast<Smb4KBookmarkEditor *>( TQT_TQWIDGET(tqparentWidget()->child( "BookmarkEditor", "Smb4KBookmarkEditor", true )) );
}
else
{
- dlg = static_cast<Smb4KBookmarkEditor *>( child( "BookmarkEditor", "Smb4KBookmarkEditor", true ) );
+ dlg = static_cast<Smb4KBookmarkEditor *>( TQT_TQWIDGET(child( "BookmarkEditor", "Smb4KBookmarkEditor", true )) );
}
if ( !dlg )
{
- if ( parentWidget() && parentWidget()->isShown() )
+ if ( tqparentWidget() && tqparentWidget()->isShown() )
{
- dlg = new Smb4KBookmarkEditor( parentWidget(), "BookmarkEditor" );
+ dlg = new Smb4KBookmarkEditor( tqparentWidget(), "BookmarkEditor" );
}
else
{
@@ -367,7 +367,7 @@ void Smb4KSystemTray::slotBookmarkEditor()
void Smb4KSystemTray::slotBookmarkActivated()
{
- if ( m_action && QString::compare( m_action->group(), "Bookmarks" ) == 0 )
+ if ( m_action && TQString::compare( m_action->group(), "Bookmarks" ) == 0 )
{
Smb4KBookmark *bookmark = NULL;
@@ -401,7 +401,7 @@ void Smb4KSystemTray::slotEnableBookmarks()
// Enable/diable the bookmark actions:
for ( KActionPtrList::Iterator it = list.begin(); it != list.end(); ++it )
{
- QString name;
+ TQString name;
if ( !(*it)->plainText().startsWith( "//" ) )
{
@@ -414,11 +414,11 @@ void Smb4KSystemTray::slotEnableBookmarks()
name = (*it)->plainText();
}
- QValueList<Smb4KShare> share_list = Smb4KCore::mounter()->findShareByName( name );
+ TQValueList<Smb4KShare> share_list = Smb4KCore::mounter()->findShareByName( name );
bool enable = true;
- for ( QValueList<Smb4KShare>::ConstIterator i = share_list.begin(); i != share_list.end(); ++i )
+ for ( TQValueList<Smb4KShare>::ConstIterator i = share_list.begin(); i != share_list.end(); ++i )
{
if ( !(*i).isForeign() )
{
@@ -444,7 +444,7 @@ void Smb4KSystemTray::slotSetupSharesMenu()
{
// OK, build the menu from ground up:
KAction *unmount_all = new KAction( i18n( "U&nmount All" ), "gear", KShortcut::null(),
- this, SLOT( slotUnmountAllShares() ), actionCollection(),
+ TQT_TQOBJECT(this), TQT_SLOT( slotUnmountAllShares() ), actionCollection(),
"st_unmount_all_action" );
unmount_all->setGroup( "ShareActions" );
unmount_all->plug( m_shares_menu->popupMenu(), 0 );
@@ -461,7 +461,7 @@ void Smb4KSystemTray::slotSetupSharesMenu()
KActionPtrList actions_list = actionCollection()->actions( "ShareMenus" );
// Get the list of mounted shares:
- QValueList<Smb4KShare *> shares_list = Smb4KCore::mounter()->getShares();
+ TQValueList<Smb4KShare *> shares_list = Smb4KCore::mounter()->getShares();
if ( !shares_list.isEmpty() )
{
@@ -472,8 +472,8 @@ void Smb4KSystemTray::slotSetupSharesMenu()
for ( KActionPtrList::Iterator it = actions_list.begin(); it != actions_list.end(); ++it )
{
// Get the canonical path of the share action:
- QString action_name = (*it)->name();
- QString canonical_path = action_name.section( "st_[share_menu]_", 1, -1 );
+ TQString action_name = (*it)->name();
+ TQString canonical_path = action_name.section( "st_[share_menu]_", 1, -1 );
// Check if the share is still present:
Smb4KShare *share = Smb4KCore::mounter()->findShareByPath( canonical_path );
@@ -488,9 +488,9 @@ void Smb4KSystemTray::slotSetupSharesMenu()
// To avoid sorting problems later, we remove *all* actions that
// have *displayed texts* that do not match the current criterions.
if ( (!Smb4KSettings::showMountPoint() &&
- QString::compare( (*it)->plainText(), share->name() ) == 0) ||
+ TQString::compare( (*it)->plainText(), share->name() ) == 0) ||
(Smb4KSettings::showMountPoint() &&
- QString::compare( (*it)->plainText(), share->canonicalPath() ) == 0) )
+ TQString::compare( (*it)->plainText(), share->canonicalPath() ) == 0) )
{
// Find the "Force Unmount" action and decide if it needs to be
// enabled/disabled:
@@ -695,9 +695,9 @@ void Smb4KSystemTray::slotSetupSharesMenu()
// Since we cannot sort the Smb4kShare items appropriately, we have to
// work around this problem. For that, let's create a string list:
- QStringList strings;
+ TQStringList strings;
- for ( QValueList<Smb4KShare *>::ConstIterator it = shares_list.begin(); it != shares_list.end(); ++it )
+ for ( TQValueList<Smb4KShare *>::ConstIterator it = shares_list.begin(); it != shares_list.end(); ++it )
{
if ( !(*it)->isForeign() || Smb4KSettings::showAllShares() )
{
@@ -709,7 +709,7 @@ void Smb4KSystemTray::slotSetupSharesMenu()
{
// _::_ is the devider between share name and the canonical path of
// the share.
- QString item = QString( "%1_::_%2" ).arg( (*it)->name(), (*it)->canonicalPath() );
+ TQString item = TQString( "%1_::_%2" ).tqarg( TQString((*it)->name()), TQString((*it)->canonicalPath()) );
strings.append( item );
}
@@ -727,7 +727,7 @@ void Smb4KSystemTray::slotSetupSharesMenu()
// We loop through the list of mounted shares and check if the
// single shares are already in the menu. If not, we plug them
// there:
- for ( QValueList<Smb4KShare *>::ConstIterator it = shares_list.begin(); it != shares_list.end(); ++it )
+ for ( TQValueList<Smb4KShare *>::ConstIterator it = shares_list.begin(); it != shares_list.end(); ++it )
{
KActionMenu *action_menu = NULL;
@@ -736,9 +736,9 @@ void Smb4KSystemTray::slotSetupSharesMenu()
for ( KActionPtrList::ConstIterator i = new_actions_list.begin(); i != new_actions_list.end(); ++i )
{
- QString item = QString( "st_[share_menu]_%1" ).arg( (*it)->canonicalPath() );
+ TQString item = TQString( "st_[share_menu]_%1" ).tqarg( TQString((*it)->canonicalPath()) );
- if ( QString::compare( (*i)->name(), item ) == 0 )
+ if ( TQString::compare( (*i)->name(), item ) == 0 )
{
action_menu = static_cast<KActionMenu *>( *i );
@@ -753,24 +753,24 @@ void Smb4KSystemTray::slotSetupSharesMenu()
if ( !action_menu )
{
// Create a new KAction menu:
- QIconSet set;
- QPixmap pix;
+ TQIconSet set;
+ TQPixmap pix;
KIconLoader loader;
int icon_state = (*it)->isForeign() ? KIcon::DisabledState : KIcon::DefaultState;
if ( (*it)->isBroken() )
{
- QImage over = loader.loadIcon( "button_cancel", KIcon::Small,
+ TQImage over = loader.loadIcon( "button_cancel", KIcon::Small,
0, icon_state, 0L, false ).convertToImage();
- QImage src = loader.loadIcon( "hdd_mount", KIcon::Small,
+ TQImage src = loader.loadIcon( "hdd_mount", KIcon::Small,
0, icon_state, 0L, false ).convertToImage();
KIconEffect e;
e.semiTransparent( over );
e.overlay( src, over );
- pix = QPixmap( src );
+ pix = TQPixmap( src );
}
else
{
@@ -778,7 +778,7 @@ void Smb4KSystemTray::slotSetupSharesMenu()
0, icon_state, 0L, false );
}
- set.reset( pix, QIconSet::Automatic );
+ set.reset( pix, TQIconSet::Automatic );
action_menu = new KActionMenu( Smb4KSettings::showMountPoint() ? (*it)->path() : (*it)->name(),
set, actionCollection(), "st_[share_menu]_"+(*it)->canonicalPath() );
@@ -787,27 +787,27 @@ void Smb4KSystemTray::slotSetupSharesMenu()
// Define the actions that can be performed on a share from within
// the system tray widget:
- KAction *umount = new KAction( i18n( "&Unmount" ), "hdd_unmount", KShortcut::null(), this,
- SLOT( slotUnmountShare() ), actionCollection(), "st_[unmount]_"+(*it)->canonicalPath() );
+ KAction *umount = new KAction( i18n( "&Unmount" ), "hdd_unmount", KShortcut::null(), TQT_TQOBJECT(this),
+ TQT_SLOT( slotUnmountShare() ), actionCollection(), "st_[unmount]_"+(*it)->canonicalPath() );
umount->setGroup( "ShareActions" );
#ifdef __linux__
- KAction *force_umount = new KAction( i18n( "&Force Unmounting" ), "hdd_unmount", KShortcut::null(), this,
- SLOT( slotForceUnmountShare() ), actionCollection(), "st_[force]_"+(*it)->canonicalPath() );
+ KAction *force_umount = new KAction( i18n( "&Force Unmounting" ), "hdd_unmount", KShortcut::null(), TQT_TQOBJECT(this),
+ TQT_SLOT( slotForceUnmountShare() ), actionCollection(), "st_[force]_"+(*it)->canonicalPath() );
force_umount->setGroup( "ShareActions" );
force_umount->setEnabled( Smb4KSettings::useForceUnmount() );
#endif
- KAction *synchronize = new KAction( i18n( "S&ynchronize" ), "bottom", KShortcut::null(), this,
- SLOT( slotSynchronize() ), actionCollection(), "st_[synchronize]_"+(*it)->canonicalPath() );
+ KAction *synchronize = new KAction( i18n( "S&ynchronize" ), "bottom", KShortcut::null(), TQT_TQOBJECT(this),
+ TQT_SLOT( slotSynchronize() ), actionCollection(), "st_[synchronize]_"+(*it)->canonicalPath() );
synchronize->setGroup( "ShareActions" );
synchronize->setEnabled( !Smb4KSettings::rsync().isEmpty() );
- KAction *konsole = new KAction( i18n( "Open with Konso&le" ), "terminal", KShortcut::null(), this,
- SLOT( slotKonsole() ), actionCollection(), "st_[konsole]_"+(*it)->canonicalPath() );
+ KAction *konsole = new KAction( i18n( "Open with Konso&le" ), "terminal", KShortcut::null(), TQT_TQOBJECT(this),
+ TQT_SLOT( slotKonsole() ), actionCollection(), "st_[konsole]_"+(*it)->canonicalPath() );
konsole->setGroup( "ShareActions" );
konsole->setEnabled( !Smb4KSettings::konsole().isEmpty() );
- KAction *konqueror = new KAction( i18n( "Open with &Konqueror" ), "kfm_home", KShortcut::null(), this,
- SLOT( slotFilemanager() ), actionCollection(), "st_[filemanager]_"+(*it)->canonicalPath() );
+ KAction *konqueror = new KAction( i18n( "Open with &Konqueror" ), "kfm_home", KShortcut::null(), TQT_TQOBJECT(this),
+ TQT_SLOT( slotFilemanager() ), actionCollection(), "st_[filemanager]_"+(*it)->canonicalPath() );
konqueror->setGroup( "ShareActions" );
// Set up the action submenu:
@@ -826,13 +826,13 @@ void Smb4KSystemTray::slotSetupSharesMenu()
if ( !Smb4KSettings::showMountPoint() )
{
- QString item = QString( "%1_::_%2" ).arg( (*it)->name(), (*it)->canonicalPath() );
+ TQString item = TQString( "%1_::_%2" ).tqarg( TQString((*it)->name()), TQString((*it)->canonicalPath()) );
- index = strings.findIndex( item );
+ index = strings.tqfindIndex( item );
}
else
{
- index = strings.findIndex( (*it)->canonicalPath() );
+ index = strings.tqfindIndex( (*it)->canonicalPath() );
}
m_shares_menu->insert( action_menu, index + 2 ); // +2 due to "Unmount All" and separator
@@ -843,42 +843,42 @@ void Smb4KSystemTray::slotSetupSharesMenu()
// in the meantime:
if ( (*it)->isBroken() )
{
- QIconSet set;
- QPixmap pix;
+ TQIconSet set;
+ TQPixmap pix;
KIconLoader loader;
int icon_state = (*it)->isForeign() ? KIcon::DisabledState : KIcon::DefaultState;
- QImage over = loader.loadIcon( "button_cancel", KIcon::Small,
+ TQImage over = loader.loadIcon( "button_cancel", KIcon::Small,
0, icon_state, 0L, false ).convertToImage();
- QImage src = loader.loadIcon( "hdd_mount", KIcon::Small,
+ TQImage src = loader.loadIcon( "hdd_mount", KIcon::Small,
0, icon_state, 0L, false ).convertToImage();
KIconEffect e;
e.semiTransparent( over );
e.overlay( src, over );
- pix = QPixmap( src );
+ pix = TQPixmap( src );
- set.reset( pix, QIconSet::Automatic );
+ set.reset( pix, TQIconSet::Automatic );
action_menu->setIconSet( set );
// Disable actions that should not be performed on an inaccessible
// share:
- actionCollection()->action( "st_[synchronize]_"+(*it)->canonicalPath() )->setEnabled( false );
- actionCollection()->action( "st_[konsole]_"+(*it)->canonicalPath() )->setEnabled( false );
- actionCollection()->action( "st_[filemanager]_"+(*it)->canonicalPath() )->setEnabled( false );
+ actionCollection()->action( TQString("st_[synchronize]_"+(*it)->canonicalPath()) )->setEnabled( false );
+ actionCollection()->action( TQString("st_[konsole]_"+(*it)->canonicalPath()) )->setEnabled( false );
+ actionCollection()->action( TQString("st_[filemanager]_"+(*it)->canonicalPath()) )->setEnabled( false );
}
// Change the text if necessary:
if ( !Smb4KSettings::showMountPoint() &&
- QString::compare( action_menu->plainText(), (*it)->name() ) != 0 )
+ TQString::compare( action_menu->plainText(), (*it)->name() ) != 0 )
{
action_menu->setText( (*it)->name() );
}
else if ( Smb4KSettings::showMountPoint() &&
- QString::compare( action_menu->plainText(), (*it)->path() ) != 0 )
+ TQString::compare( action_menu->plainText(), (*it)->path() ) != 0 )
{
action_menu->setText( (*it)->path() );
}
@@ -897,10 +897,10 @@ void Smb4KSystemTray::slotSetupSharesMenu()
KActionMenu *action_menu = static_cast<KActionMenu *>( *it );
// Get the canonical path of the share action:
- QString action_name = action_menu->name();
- QString canonical_path = action_name.section( "st_[share_menu]_", 1, -1 );
+ TQString action_name = action_menu->name();
+ TQString canonical_path = action_name.section( "st_[share_menu]_", 1, -1 );
- // Remove all children of the share action menus:
+ // Remove all tqchildren of the share action menus:
KAction *action = NULL;
// Unmount action
@@ -969,9 +969,9 @@ void Smb4KSystemTray::slotUnmountAllShares()
void Smb4KSystemTray::slotUnmountShare()
{
- if ( m_action && QString( m_action->name() ).startsWith( "st_[unmount]_" ) )
+ if ( m_action && TQString( m_action->name() ).startsWith( "st_[unmount]_" ) )
{
- QString canonical_path = QString( m_action->name() ).section( "st_[unmount]_", 1, 1 );
+ TQString canonical_path = TQString( m_action->name() ).section( "st_[unmount]_", 1, 1 );
Smb4KShare *share = Smb4KCore::mounter()->findShareByPath( canonical_path );
@@ -985,9 +985,9 @@ void Smb4KSystemTray::slotUnmountShare()
void Smb4KSystemTray::slotForceUnmountShare()
{
- if ( m_action && QString( m_action->name() ).startsWith( "st_[force]_" ) )
+ if ( m_action && TQString( m_action->name() ).startsWith( "st_[force]_" ) )
{
- QString canonical_path = QString( m_action->name() ).section( "st_[force]_", 1, 1 );
+ TQString canonical_path = TQString( m_action->name() ).section( "st_[force]_", 1, 1 );
Smb4KShare *share = Smb4KCore::mounter()->findShareByPath( canonical_path );
@@ -1003,9 +1003,9 @@ void Smb4KSystemTray::slotSynchronize()
{
// Since we want to allow the possibility to open several instances
// of the synchronization dialog, we do not checks like in slotConfigDialog()
- if ( m_action && QString( m_action->name() ).startsWith( "st_[synchronize]_" ) )
+ if ( m_action && TQString( m_action->name() ).startsWith( "st_[synchronize]_" ) )
{
- QString canonical_path = QString( m_action->name() ).section( "st_[synchronize]_", 1, 1 );
+ TQString canonical_path = TQString( m_action->name() ).section( "st_[synchronize]_", 1, 1 );
Smb4KShare *share = Smb4KCore::mounter()->findShareByPath( canonical_path );
@@ -1013,9 +1013,9 @@ void Smb4KSystemTray::slotSynchronize()
{
Smb4KSynchronizationDialog *dlg = NULL;
- if ( parentWidget() && parentWidget()->isShown() )
+ if ( tqparentWidget() && tqparentWidget()->isShown() )
{
- dlg = new Smb4KSynchronizationDialog( share, parentWidget(), "SynchronizationDialog" );
+ dlg = new Smb4KSynchronizationDialog( share, tqparentWidget(), "SynchronizationDialog" );
}
else
{
@@ -1030,9 +1030,9 @@ void Smb4KSystemTray::slotSynchronize()
void Smb4KSystemTray::slotKonsole()
{
- if ( m_action && QString( m_action->name() ).startsWith( "st_[konsole]_" ) )
+ if ( m_action && TQString( m_action->name() ).startsWith( "st_[konsole]_" ) )
{
- QString canonical_path = QString( m_action->name() ).section( "st_[konsole]_", 1, 1 );
+ TQString canonical_path = TQString( m_action->name() ).section( "st_[konsole]_", 1, 1 );
Smb4KShare *share = Smb4KCore::mounter()->findShareByPath( canonical_path );
@@ -1046,9 +1046,9 @@ void Smb4KSystemTray::slotKonsole()
void Smb4KSystemTray::slotFilemanager()
{
- if ( m_action && QString( m_action->name() ).startsWith( "st_[filemanager]_" ) )
+ if ( m_action && TQString( m_action->name() ).startsWith( "st_[filemanager]_" ) )
{
- QString canonical_path = QString( m_action->name() ).section( "st_[filemanager]_", 1, 1 );
+ TQString canonical_path = TQString( m_action->name() ).section( "st_[filemanager]_", 1, 1 );
Smb4KShare *share = Smb4KCore::mounter()->findShareByPath( canonical_path );
diff --git a/smb4k/smb4ksystemtray.h b/smb4k/smb4ksystemtray.h
index c3d4d6b..2ecc7bf 100644
--- a/smb4k/smb4ksystemtray.h
+++ b/smb4k/smb4ksystemtray.h
@@ -37,16 +37,17 @@
class Smb4KSystemTray : public KSystemTray
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* The constructor.
*
- * @param parent The parent widget of the system tray window
+ * @param tqparent The tqparent widget of the system tray window
*
* @param name The name of the system tray window
*/
- Smb4KSystemTray( QWidget *parent = 0, const char *name = 0 );
+ Smb4KSystemTray( TQWidget *tqparent = 0, const char *name = 0 );
/**
* The destructor.
diff --git a/utilities/smb4k_kill.cpp b/utilities/smb4k_kill.cpp
index 7c31bfd..546a4bb 100644
--- a/utilities/smb4k_kill.cpp
+++ b/utilities/smb4k_kill.cpp
@@ -82,7 +82,7 @@ bool find_program( const char *name, char *path )
if ( !strcmp( file.c_str(), "" ) )
{
- cerr << "smb4k_kill: Could not find " << name << " binary" << endl;
+ cerr << "smb4k_kill: Could not tqfind " << name << " binary" << endl;
return false;
}
diff --git a/utilities/smb4k_mount.cpp b/utilities/smb4k_mount.cpp
index 2e82f28..2ae1318 100644
--- a/utilities/smb4k_mount.cpp
+++ b/utilities/smb4k_mount.cpp
@@ -109,7 +109,7 @@ bool find_program( const char *name, char *path )
if ( !strcmp( file.c_str(), "" ) )
{
- cerr << "smb4k_mount: Could not find " << name << " binary" << endl;
+ cerr << "smb4k_mount: Could not tqfind " << name << " binary" << endl;
return false;
}
diff --git a/utilities/smb4k_mv.cpp b/utilities/smb4k_mv.cpp
index 7949722..119916f 100644
--- a/utilities/smb4k_mv.cpp
+++ b/utilities/smb4k_mv.cpp
@@ -93,7 +93,7 @@ bool find_program( const char *name, char *path )
if ( !strcmp( file.c_str(), "" ) )
{
- cerr << "smb4k_mv: Could not find " << name << " binary" << endl;
+ cerr << "smb4k_mv: Could not tqfind " << name << " binary" << endl;
return false;
}
diff --git a/utilities/smb4k_umount.cpp b/utilities/smb4k_umount.cpp
index 23eb266..fb82039 100644
--- a/utilities/smb4k_umount.cpp
+++ b/utilities/smb4k_umount.cpp
@@ -121,7 +121,7 @@ bool find_program( const char *name, char *path )
if ( !strcmp( file.c_str(), "" ) )
{
- cerr << "smb4k_umount: Could not find " << name << " binary" << endl;
+ cerr << "smb4k_umount: Could not tqfind " << name << " binary" << endl;
return false;
}