diff options
Diffstat (limited to 'kdevdesigner/designer/actiondnd.h')
-rw-r--r-- | kdevdesigner/designer/actiondnd.h | 71 |
1 files changed, 39 insertions, 32 deletions
diff --git a/kdevdesigner/designer/actiondnd.h b/kdevdesigner/designer/actiondnd.h index 23c461aa..560bcca4 100644 --- a/kdevdesigner/designer/actiondnd.h +++ b/kdevdesigner/designer/actiondnd.h @@ -1,15 +1,15 @@ /********************************************************************** ** Copyright (C) 2000-2002 Trolltech AS. All rights reserved. ** -** This file is part of Qt Designer. +** This file is part of TQt Designer. ** ** This file may be distributed and/or modified under the terms of the ** GNU General Public License version 2 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. ** -** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition -** licenses may use this file in accordance with the Qt Commercial License +** Licensees holding valid TQt Enterprise Edition or TQt Professional Edition +** licenses may use this file in accordance with the TQt Commercial License ** Agreement provided with the Software. ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE @@ -17,7 +17,7 @@ ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** See http://www.trolltech.com/pricing.html or email [email protected] for -** information about Qt Commercial License Agreements. +** information about TQt Commercial License Agreements. ** ** Contact [email protected] if any conditions of this licensing are ** not clear to you. @@ -38,26 +38,28 @@ #include <tqguardedptr.h> #include "../shared/widgetdatabase.h" -//class QDesignerPopupMenu; -class QDesignerIndicatorWidget; +//class TQDesignerPopupMenu; +class TQDesignerIndicatorWidget; class FormWindow; class TQPopupMenu; -class QDesignerIndicatorWidget : public QWidget +class TQDesignerIndicatorWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - QDesignerIndicatorWidget( TQWidget *p ) + TQDesignerIndicatorWidget( TQWidget *p ) : TQWidget( p, "qt_dockwidget_internal" ) { setBackgroundColor( red ); } }; -class ActionDrag : public QStoredDrag +class ActionDrag : public TQStoredDrag { Q_OBJECT + TQ_OBJECT public: ActionDrag(const TQString &type, TQAction *action, TQWidget *source); @@ -77,22 +79,23 @@ private: static TQAction *the_action; }; -class QDesignerActionGroup : public QActionGroup +class TQDesignerActionGroup : public TQActionGroup { Q_OBJECT + TQ_OBJECT public: - QDesignerActionGroup( TQObject *parent ) - : TQActionGroup( ::qt_cast<TQActionGroup*>(parent) ? parent : 0 ), wid( 0 ), idx( -1 ) { init(); } + TQDesignerActionGroup( TQObject *tqparent ) + : TQActionGroup( ::tqqt_cast<TQActionGroup*>(tqparent) ? tqparent : 0 ), wid( 0 ), idx( -1 ) { init(); } void init(); TQWidget *widget() const { return wid; } - TQWidget *widget( TQAction *a ) const { return *widgets.find( a ); } + TQWidget *widget( TQAction *a ) const { return *widgets.tqfind( a ); } int index() const { return idx; } protected: -#if !defined(Q_NO_USING_KEYWORD) +#if !defined(TQ_NO_USING_KEYWORD) using TQActionGroup::addedTo; #endif void addedTo( TQWidget *w, TQWidget * ) { @@ -112,15 +115,16 @@ private: }; -class QDesignerAction : public QAction +class TQDesignerAction : public TQAction { Q_OBJECT + TQ_OBJECT public: - QDesignerAction( TQObject *parent ) - : TQAction( ::qt_cast<TQActionGroup*>(parent) ? parent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( 0 ) { init(); } - QDesignerAction( TQWidget *w, TQObject *parent ) - : TQAction( ::qt_cast<TQActionGroup*>(parent) ? parent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( w ) { init(); } + TQDesignerAction( TQObject *tqparent ) + : TQAction( ::tqqt_cast<TQActionGroup*>(tqparent) ? tqparent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( 0 ) { init(); } + TQDesignerAction( TQWidget *w, TQObject *tqparent ) + : TQAction( ::tqqt_cast<TQActionGroup*>(tqparent) ? tqparent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( w ) { init(); } void init(); @@ -148,31 +152,33 @@ private: }; -class QDesignerToolBarSeparator : public QWidget +class TQDesignerToolBarSeparator : public TQWidget { Q_OBJECT + TQ_OBJECT public: - QDesignerToolBarSeparator( Orientation, TQToolBar *parent, const char* name=0 ); + TQDesignerToolBarSeparator( Qt::Orientation, TQToolBar *tqparent, const char* name=0 ); - TQSize sizeHint() const; - Orientation orientation() const { return orient; } + TQSize tqsizeHint() const; + Qt::Orientation orientation() const { return orient; } public slots: - void setOrientation( Orientation ); + void setOrientation( Qt::Orientation ); protected: void styleChange( TQStyle& ); void paintEvent( TQPaintEvent * ); private: - Orientation orient; + Qt::Orientation orient; }; -class QSeparatorAction : public QAction +class TQSeparatorAction : public TQAction { Q_OBJECT + TQ_OBJECT public: - QSeparatorAction( TQObject *parent ); + TQSeparatorAction( TQObject *tqparent ); bool addTo( TQWidget *w ); bool removeFrom( TQWidget *w ); @@ -186,13 +192,14 @@ private: }; -class QDesignerToolBar : public QToolBar +class TQDesignerToolBar : public TQToolBar { Q_OBJECT + TQ_OBJECT public: - QDesignerToolBar( TQMainWindow *mw ); - QDesignerToolBar( TQMainWindow *mw, Dock dock ); + TQDesignerToolBar( TQMainWindow *mw ); + TQDesignerToolBar( TQMainWindow *mw, Dock dock ); TQPtrList<TQAction> insertedActions() const { return actionList; } void addAction( TQAction *a ); @@ -208,7 +215,7 @@ public: protected: bool eventFilter( TQObject *, TQEvent * ); void paintEvent( TQPaintEvent * ); -#ifndef QT_NO_DRAGANDDROP +#ifndef TQT_NO_DRAGANDDROP void dragEnterEvent( TQDragEnterEvent * ); void dragMoveEvent( TQDragMoveEvent * ); void dragLeaveEvent( TQDragLeaveEvent * ); @@ -238,7 +245,7 @@ private: TQPtrList<TQAction> actionList; TQMap<TQWidget*, TQAction*> actionMap; TQPoint dragStartPos; - QDesignerIndicatorWidget *indicator; + TQDesignerIndicatorWidget *indicator; bool widgetInserting; FormWindow *formWindow; |