summaryrefslogtreecommitdiffstats
path: root/smb4k/dialogs
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-01 22:30:35 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-01 22:30:35 +0000
commited6e59662040eb15573dae9c323450e9a720ac01 (patch)
treebe17632b1c7c05f3d669eb26b5634edbcb772bb7 /smb4k/dialogs
parentc0875805b54444a0740d98a6d2c8fa05cd672fef (diff)
downloadsmb4k-ed6e59662040eb15573dae9c323450e9a720ac01.tar.gz
smb4k-ed6e59662040eb15573dae9c323450e9a720ac01.zip
TQt4 port smb4k
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/smb4k@1239034 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'smb4k/dialogs')
-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
12 files changed, 344 insertions, 338 deletions
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