7 // Note: this file has been copied from the Qt source.
8 // Those classes are normally used internally in Qt
9 // but we need them for immitate the roll-over effect of QComboBox.
11 // Some class definitions have been moved from qeffects.cpp to this file.
12 // They are framed with the comment "MOVED FROM qeffect.cpp"
14 /****************************************************************************
15 ** $Id: qt/qeffects_p.h 3.3.4 edited May 27 2003 $
17 ** Definition of QEffects functions
21 ** Copyright (C) 2000 Trolltech AS. All rights reserved.
23 ** This file is part of the widgets module of the Qt GUI Toolkit.
25 ** This file may be distributed under the terms of the Q Public License
26 ** as defined by Trolltech AS of Norway and appearing in the file
27 ** LICENSE.QPL included in the packaging of this file.
29 ** This file may be distributed and/or modified under the terms of the
30 ** GNU General Public License version 2 as published by the Free Software
31 ** Foundation and appearing in the file LICENSE.GPL included in the
32 ** packaging of this file.
34 ** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition
35 ** licenses may use this file in accordance with the Qt Commercial License
36 ** Agreement provided with the Software.
38 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
39 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
41 ** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for
42 ** information about Qt Commercial License Agreements.
43 ** See http://www.trolltech.com/qpl/ for QPL licensing information.
44 ** See http://www.trolltech.com/gpl/ for GPL licensing information.
46 ** Contact info@trolltech.com if any conditions of this licensing are
49 **********************************************************************/
59 // This file is not part of the Qt API. It exists for the convenience
60 // of qeffects.cpp, qcombobox.cpp, qpopupmenu.cpp and qtooltip.cpp.
61 // This header file may change from version to version without notice,
62 // or even be removed.
69 #include "qnamespace.h"
84 typedef uint DirFlags
;
87 extern void Q_EXPORT
qScrollEffect( QWidget
*, QEffects::DirFlags dir
= QEffects::DownScroll
, int time
= -1 );
88 extern void Q_EXPORT
qFadeEffect( QWidget
*, int time
= -1 );
91 /******************* MOVED FROM qeffect.cpp: */
94 #include "qdatetime.h"
100 Internal class to get access to protected QWidget-members
103 class QAccessWidget
: public QWidget
105 friend class QAlphaWidget
;
106 friend class QRollEffect
;
108 QAccessWidget( QWidget
* parent
=0, const char* name
=0, WFlags f
= 0 )
109 : QWidget( parent
, name
, f
) {}
113 Internal class QAlphaWidget.
115 The QAlphaWidget is shown while the animation lasts
116 and displays the pixmap resulting from the alpha blending.
119 class QAlphaWidget
: public QWidget
, private QEffects
123 QAlphaWidget( QWidget
* w
, WFlags f
= 0 );
125 void run( int time
);
128 void paintEvent( QPaintEvent
* e
);
129 void closeEvent( QCloseEvent
* );
130 bool eventFilter( QObject
* o
, QEvent
* e
);
142 QPointer
<QAccessWidget
> widget
;
151 Internal class QRollEffect
153 The QRollEffect widget is shown while the animation lasts
154 and displays a scrolling pixmap.
157 class QRollEffect
: public QWidget
, private QEffects
161 QRollEffect( QWidget
* w
, WFlags f
, DirFlags orient
);
163 void run( int time
);
166 void paintEvent( QPaintEvent
* );
167 bool eventFilter( QObject
*, QEvent
* );
168 void closeEvent( QCloseEvent
* );
174 QPointer
<QAccessWidget
> widget
;
193 /******************************/
195 #endif // QT_NO_EFFECTS
197 #endif // QEFFECTS_P_H