diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-17 08:20:48 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-17 08:20:48 +0000 |
commit | aa0726b20f398264f0a2abc60215be044b106f9c (patch) | |
tree | 070fdbc19a1106cfdd7f651a8ce76bb1b89a513d /src/kicondialog.h | |
parent | d3cf5b3e75aadc3b02d0b56f030d4c3f8c2c749d (diff) | |
download | basket-aa0726b20f398264f0a2abc60215be044b106f9c.tar.gz basket-aa0726b20f398264f0a2abc60215be044b106f9c.zip |
TQt4 port basket
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/basket@1232416 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/kicondialog.h')
-rw-r--r-- | src/kicondialog.h | 82 |
1 files changed, 42 insertions, 40 deletions
diff --git a/src/kicondialog.h b/src/kicondialog.h index 6b03bd4..3cd4866 100644 --- a/src/kicondialog.h +++ b/src/kicondialog.h @@ -16,9 +16,9 @@ #ifndef __KIconDialog_h__ #define __KIconDialog_h__ -#include <qstring.h> -#include <qstringlist.h> -#include <qpushbutton.h> +#include <tqstring.h> +#include <tqstringlist.h> +#include <tqpushbutton.h> #include <kicontheme.h> #include <kdialogbase.h> @@ -28,10 +28,10 @@ class KIconDialogUI; -class QComboBox; -class QTimer; -class QKeyEvent; -class QRadioButton; +class TQComboBox; +class TQTimer; +class TQKeyEvent; +class TQRadioButton; class KProgress; class KIconLoader; @@ -44,16 +44,17 @@ class KIconLoader; class KIO_EXPORT KIconDialog: public KDialogBase { Q_OBJECT + TQ_OBJECT public: /** * Constructs an icon selection dialog using the global iconloader. */ - KIconDialog(QWidget *parent=0L, const char *name=0L); + KIconDialog(TQWidget *tqparent=0L, const char *name=0L); /** * Constructs an icon selection dialog using a specific iconloader. */ - KIconDialog(KIconLoader *loader, QWidget *parent=0, + KIconDialog(KIconLoader *loader, TQWidget *tqparent=0, const char *name=0); /** * Destructs the dialog. @@ -75,13 +76,13 @@ public: /** * gets the custom icon directory */ - const QString & customLocation() const; + const TQString & customLocation() const; /** * sets a custom icon directory * @since 3.1 */ - void setCustomLocation( const QString& location ); + void setCustomLocation( const TQString& location ); /** * Sets the size of the icons to be shown / selected. @@ -100,7 +101,7 @@ public: /** * @deprecated in KDE 3.0, use the static method getIcon instead. */ - QString selectIcon(KIcon::Group group=KIcon::Desktop, KIcon::Context + TQString selectIcon(KIcon::Group group=KIcon::Desktop, KIcon::Context context=KIcon::Application, bool user=false); #endif @@ -130,15 +131,15 @@ public: /** * exec()utes this modal dialog and returns the name of the selected icon, - * or QString::null if the dialog was aborted. + * or TQString() if the dialog was aborted. * @returns the name of the icon, suitable for loading with KIconLoader. * @see getIcon */ - QString openDialog(); + TQString openDialog(); /** - * show()es this dialog and emits a newIcon(const QString&) signal when - * successful. QString::null will be emitted if the dialog was aborted. + * show()es this dialog and emits a newIcon(const TQString&) signal when + * successful. TQString() will be emitted if the dialog was aborted. */ void showDialog(); @@ -156,19 +157,19 @@ public: * @param iconSize the size of the icons -- the default of the icongroup * if set to 0 * @param user Begin with the "user icons" instead of "system icons". - * @param parent The parent widget of the dialog. + * @param tqparent The tqparent widget of the dialog. * @param caption The caption to use for the dialog. * @return The name of the icon, suitable for loading with KIconLoader. * @version New in 3.0 */ - static QString getIcon(KIcon::Group group=KIcon::Desktop, + static TQString getIcon(KIcon::Group group=KIcon::Desktop, KIcon::Context context=KIcon::Application, bool strictIconSize=false, int iconSize = 0, - bool user=false, QWidget *parent=0, - const QString &caption=QString::null); + bool user=false, TQWidget *tqparent=0, + const TQString &caption=TQString()); signals: - void newIconName(const QString&); + void newIconName(const TQString&); protected slots: void slotOk(); @@ -188,12 +189,12 @@ private: KIcon::Context mContext; int mType; - QStringList mFileList; + TQStringList mFileList; // FIXME: the following fields are obsolete, remove in KDE4 - QComboBox *mpCombo; - QPushButton *mpBrowseBut; - QRadioButton *mpRb1, *mpRb2; + TQComboBox *mpCombo; + TQPushButton *mpBrowseBut; + TQRadioButton *mpRb1, *mpRb2; KProgress *mpProgress; KIconLoader *mpLoader; @@ -215,24 +216,25 @@ private: * @see KIconDialog * @short A push button that allows selection of an icon. */ -class KIO_EXPORT KIconButton: public QPushButton +class KIO_EXPORT KIconButton: public TQPushButton { Q_OBJECT - Q_PROPERTY( QString icon READ icon WRITE setIcon RESET resetIcon ) - Q_PROPERTY( int iconSize READ iconSize WRITE setIconSize) - Q_PROPERTY( bool strictIconSize READ strictIconSize WRITE setStrictIconSize ) - Q_PROPERTY( QString customLocation READ customLocation WRITE setCustomLocation ) + TQ_OBJECT + TQ_PROPERTY( TQString icon READ icon WRITE setIcon RESET resetIcon ) + TQ_PROPERTY( int iconSize READ iconSize WRITE setIconSize) + TQ_PROPERTY( bool strictIconSize READ strictIconSize WRITE setStrictIconSize ) + TQ_PROPERTY( TQString customLocation READ customLocation WRITE setCustomLocation ) public: /** * Constructs a KIconButton using the global iconloader. */ - KIconButton(QWidget *parent=0L, const char *name=0L); + KIconButton(TQWidget *tqparent=0L, const char *name=0L); /** * Constructs a KIconButton using a specific KIconLoader. */ - KIconButton(KIconLoader *loader, QWidget *parent, const char *name=0L); + KIconButton(KIconLoader *loader, TQWidget *tqparent, const char *name=0L); /** * Destructs the button. */ @@ -265,17 +267,17 @@ public: /** * sets a custom icon directory */ - void setCustomLocation(const QString &custom); + void setCustomLocation(const TQString &custom); /** * get the custom icon directory */ - const QString & customLocation() const; + const TQString & customLocation() const; /** * Sets the button's initial icon. */ - void setIcon(const QString& icon); + void setIcon(const TQString& icon); /** * Resets the icon (reverts to an empty button). @@ -285,7 +287,7 @@ public: /** * Returns the name of the selected icon. */ - QString icon() const { return mIcon; } + TQString icon() const { return mIcon; } /** * Sets the size of the icon to be shown / selected. @@ -304,12 +306,12 @@ signals: /** * Emitted when the icon has changed. */ - void iconChanged(QString icon); - /* FIXME: KDE4: Make it const QString & */ + void iconChanged(TQString icon); + /* FIXME: KDE4: Make it const TQString & */ private slots: void slotChangeIcon(); - void newIconName(const QString& name); + void newIconName(const TQString& name); private: void init( KIconLoader *loader ); @@ -318,7 +320,7 @@ private: KIcon::Group mGroup; KIcon::Context mContext; - QString mIcon; + TQString mIcon; KIconDialog *mpDialog; KIconLoader *mpLoader; class KIconButtonPrivate; |