summaryrefslogtreecommitdiffabout
path: root/microkde/kdeui/ktoolbar.h
Side-by-side diff
Diffstat (limited to 'microkde/kdeui/ktoolbar.h') (more/less context) (ignore whitespace changes)
-rw-r--r--microkde/kdeui/ktoolbar.h68
1 files changed, 38 insertions, 30 deletions
diff --git a/microkde/kdeui/ktoolbar.h b/microkde/kdeui/ktoolbar.h
index 3319fa8..4e00abd 100644
--- a/microkde/kdeui/ktoolbar.h
+++ b/microkde/kdeui/ktoolbar.h
@@ -26,27 +26,35 @@
#ifndef DESKTOP_VERSION
#define private public
-#include <qtoolbar.h>
+#include <q3toolbar.h>
#undef private
#include <qpe/qpetoolbar.h>
#else
-#include <qtoolbar.h>
+#include <q3toolbar.h>
#endif
-#include <qmainwindow.h>
+#include <q3mainwindow.h>
#include <qcombobox.h>
#include <qmap.h>
-#include <qptrlist.h>
+#include <q3ptrlist.h>
+//Added by qt3to4:
+#include <QPixmap>
+#include <QResizeEvent>
+#include <Q3PopupMenu>
+#include <QMouseEvent>
+#include <QChildEvent>
+#include <QEvent>
+#include <QShowEvent>
#include <kglobal.h>
-#include <qguardedptr.h>
-#include <qframe.h>
-#include <qiconset.h>
+#include <qpointer.h>
+#include <q3frame.h>
+#include <qicon.h>
class QDomElement;
class QSize;
class QPixmap;
-class QPopupMenu;
+class Q3PopupMenu;
class QStringList;
class QDomDocument;
class QTimer;
@@ -63,22 +71,22 @@ class KXMLGUIClient;
class KToolBarPrivate;
-class KToolBarSeparator : public QFrame
+class KToolBarSeparator : public Q3Frame
{
Q_OBJECT
public:
- KToolBarSeparator( Orientation, bool l, QToolBar *parent, const char* name=0 );
+ KToolBarSeparator( Qt::Orientation, bool l, Q3ToolBar *parent, const char* name=0 );
QSize sizeHint() const;
- Orientation orientation() const { return orient; }
+ Qt::Orientation orientation() const { return orient; }
QSizePolicy sizePolicy() const;
bool showLine() const { return line; }
public slots:
- void setOrientation( Orientation );
+ void setOrientation( Qt::Orientation );
protected:
void styleChange( QStyle& );
private:
- Orientation orient;
+ Qt::Orientation orient;
bool line;
};
@@ -111,10 +119,10 @@ private:
// porting KToolBar back to Qt2 really needs some strange hacks
#ifndef DESKTOP_VERSION
-#define QToolBar QPEToolBar
+#define Q3ToolBar QPEToolBar
#endif
- class KToolBar : public QToolBar
+ class KToolBar : public Q3ToolBar
{
Q_OBJECT
@@ -127,7 +135,7 @@ private:
Q_PROPERTY( int iconSize READ iconSize WRITE setIconSize )
Q_PROPERTY( QString text READ text WRITE setText )
#ifndef DESKTOP_VERSION
-#undef QToolBar
+#undef Q3ToolBar
#endif
public:
enum IconText{IconOnly = 0, IconTextRight, TextOnly, IconTextBottom};
@@ -175,7 +183,7 @@ public:
* @param honor_style If true, then global settings for IconSize and IconText will be honored
* @param readConfig whether to apply the configuration (global and application-specific)
*/
- KToolBar( QMainWindow *parentWindow, QMainWindow::ToolBarDock dock /*= QMainWindow::Top*/, bool newLine = false,
+ KToolBar( Q3MainWindow *parentWindow, Qt::ToolBarDock dock /*= QMainWindow::Top*/, bool newLine = false,
const char *name = 0, bool honor_style = FALSE, bool readConfig = TRUE );
/**
@@ -193,7 +201,7 @@ public:
* @param honor_style If true, then global settings for IconSize and IconText will be honored
* @param readConfig whether to apply the configuration (global and application-specific)
*/
- KToolBar( QMainWindow *parentWindow, QWidget *dock, bool newLine = false,
+ KToolBar( Q3MainWindow *parentWindow, QWidget *dock, bool newLine = false,
const char *name = 0, bool honor_style = FALSE, bool readConfig = TRUE );
virtual ~KToolBar();
@@ -303,7 +311,7 @@ public:
* You can add custom popups which inherit @ref QPopupMenu to get popups
* with tables, drawings etc. Just don't fiddle with events there.
*/
- int insertButton(const QString& icon, int id, QPopupMenu *popup,
+ int insertButton(const QString& icon, int id, Q3PopupMenu *popup,
bool enabled, const QString&_text, int index=-1);
/**
@@ -318,7 +326,7 @@ public:
* You can add custom popups which inherit @ref QPopupMenu to get popups
* with tables, drawings etc. Just don't fiddle with events there.
*/
- int insertButton(const QPixmap& pixmap, int id, QPopupMenu *popup,
+ int insertButton(const QPixmap& pixmap, int id, Q3PopupMenu *popup,
bool enabled, const QString&_text, int index=-1);
/**
@@ -359,7 +367,7 @@ public:
const char *slot, bool enabled=true,
const QString& tooltiptext=QString::null,
int size=70, int index=-1,
- QComboBox::Policy policy = QComboBox::AtBottom);
+ QComboBox::Policy policy = QComboBox::InsertAtBottom);
/**
* Insert a @ref KComboBox with text.
@@ -375,7 +383,7 @@ public:
const char *slot, bool enabled=true,
const QString& tooltiptext=QString::null,
int size=70, int index=-1,
- QComboBox::Policy policy = QComboBox::AtBottom);
+ QComboBox::Policy policy = QComboBox::InsertAtBottom);
/**
* Inserts a separator into the toolbar with the given id.
@@ -465,7 +473,7 @@ public:
*
* Can be used while button is visible.
*/
- void setButtonIconSet( int id, const QIconSet& iconset );
+ void setButtonIconSet( int id, const QIcon& iconset );
/**
* Sets a delayed popup for a button.
@@ -491,7 +499,7 @@ public:
* add popups that are already in the menu bar or are submenus of
* other popups.
*/
- void setDelayedPopup (int id , QPopupMenu *_popup, bool toggle = false);
+ void setDelayedPopup (int id , Q3PopupMenu *_popup, bool toggle = false);
/**
* Turns a button into an autorepeat button.
@@ -1060,7 +1068,7 @@ public:
public slots:
virtual void setIconText( const QString &txt )
- { QToolBar::setIconText( txt ); }
+ { Q3ToolBar::setIconText( txt ); }
void slotRepaint();
protected:
@@ -1077,7 +1085,7 @@ private slots:
void slotReadConfig ();
void slotAppearanceChanged();
void slotIconChanged(int);
- void toolBarPosChanged( QToolBar *tb );
+ void toolBarPosChanged( Q3ToolBar *tb );
void slotContextAboutToShow();
void widgetDestroyed();
@@ -1090,16 +1098,16 @@ private:
void removeWidgetInternal( QWidget *w );
void getAttributes( QString &position, QString &icontext, int &index );
//US KPopupMenu *contextMenu();
- QPopupMenu *contextMenu();
+ Q3PopupMenu *contextMenu();
QMap<QWidget*, int > widget2id;
typedef QMap<int, QWidget* > Id2WidgetMap;
Id2WidgetMap id2widget;
//US KPopupMenu *context;
- QPopupMenu *context;
- QPtrList<QWidget> widgets;
+ Q3PopupMenu *context;
+ Q3PtrList<QWidget> widgets;
QTimer *layoutTimer;
- QGuardedPtr<QWidget> stretchableWidget, rightAligned;
+ QPointer<QWidget> stretchableWidget, rightAligned;
protected:
virtual void virtual_hook( int id, void* data );
private: