author | zautrix <zautrix> | 2004-12-05 12:12:10 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-12-05 12:12:10 (UTC) |
commit | 5ab47964d8b52897bb0662ef4a5fcf9604acaf6c (patch) (unidiff) | |
tree | 0f80433206ddd6b4ef901cb346d0f06caf76b20f | |
parent | 196365e533c6fd1a8f47aa9579763ef5afcebcda (diff) | |
download | kdepimpi-5ab47964d8b52897bb0662ef4a5fcf9604acaf6c.zip kdepimpi-5ab47964d8b52897bb0662ef4a5fcf9604acaf6c.tar.gz kdepimpi-5ab47964d8b52897bb0662ef4a5fcf9604acaf6c.tar.bz2 |
fixed kapi toolbar repaint problem
-rw-r--r-- | kaddressbook/kabcore.cpp | 10 | ||||
-rw-r--r-- | microkde/kdeui/ktoolbar.cpp | 6 | ||||
-rw-r--r-- | microkde/kdeui/ktoolbar.h | 3 |
3 files changed, 15 insertions, 4 deletions
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp index 76f9ab6..15cab73 100644 --- a/kaddressbook/kabcore.cpp +++ b/kaddressbook/kabcore.cpp | |||
@@ -360,12 +360,16 @@ KABCore::KABCore( KXMLGUIClient *client, bool readWrite, QWidget *parent, const | |||
360 | #endif | 360 | #endif |
361 | //toggleBeamReceive( ); | 361 | //toggleBeamReceive( ); |
362 | 362 | //mMainWindow->toolBar()->show(); | |
363 | // we have a toolbar repainting error on the Zaurus when starting KA/Pi | 363 | // we have a toolbar repainting error on the Zaurus when starting KA/Pi |
364 | QTimer::singleShot( 10000, this , SLOT ( updateToolBar())); | 364 | QTimer::singleShot( 10, this , SLOT ( updateToolBar())); |
365 | } | 365 | } |
366 | 366 | ||
367 | void KABCore::updateToolBar() | 367 | void KABCore::updateToolBar() |
368 | { | 368 | { |
369 | mMainWindow->toolBar()->update(); | 369 | static int iii = 0; |
370 | ++iii; | ||
371 | mMainWindow->toolBar()->repaintMe(); | ||
372 | if ( iii < 5 ) | ||
373 | QTimer::singleShot( 10, this , SLOT ( updateToolBar())); | ||
370 | } | 374 | } |
371 | KABCore::~KABCore() | 375 | KABCore::~KABCore() |
diff --git a/microkde/kdeui/ktoolbar.cpp b/microkde/kdeui/ktoolbar.cpp index 79b0f9d..e9226c0 100644 --- a/microkde/kdeui/ktoolbar.cpp +++ b/microkde/kdeui/ktoolbar.cpp | |||
@@ -1411,4 +1411,10 @@ void KToolBar::insertWidgetInternal( QWidget *w, int &index, int id ) | |||
1411 | widget2id.insert( w, id ); | 1411 | widget2id.insert( w, id ); |
1412 | } | 1412 | } |
1413 | void KToolBar::repaintMe() | ||
1414 | { | ||
1415 | setUpdatesEnabled( true ); | ||
1416 | QToolBar::repaint( true ); | ||
1417 | qDebug(" KToolBar::repaintMe() "); | ||
1418 | } | ||
1413 | 1419 | ||
1414 | void KToolBar::showEvent( QShowEvent *e ) | 1420 | void KToolBar::showEvent( QShowEvent *e ) |
diff --git a/microkde/kdeui/ktoolbar.h b/microkde/kdeui/ktoolbar.h index 2c061b5..61b5ea3 100644 --- a/microkde/kdeui/ktoolbar.h +++ b/microkde/kdeui/ktoolbar.h | |||
@@ -1046,4 +1046,5 @@ public: | |||
1046 | * @return global setting for "Highlight buttons under mouse" | 1046 | * @return global setting for "Highlight buttons under mouse" |
1047 | */ | 1047 | */ |
1048 | void repaintMe(); | ||
1048 | static bool highlightSetting(); | 1049 | static bool highlightSetting(); |
1049 | 1050 | ||
@@ -1061,4 +1062,5 @@ public slots: | |||
1061 | virtual void setIconText( const QString &txt ) | 1062 | virtual void setIconText( const QString &txt ) |
1062 | { QToolBar::setIconText( txt ); } | 1063 | { QToolBar::setIconText( txt ); } |
1064 | void slotRepaint(); | ||
1063 | 1065 | ||
1064 | protected: | 1066 | protected: |
@@ -1076,5 +1078,4 @@ private slots: | |||
1076 | void slotAppearanceChanged(); | 1078 | void slotAppearanceChanged(); |
1077 | void slotIconChanged(int); | 1079 | void slotIconChanged(int); |
1078 | void slotRepaint(); | ||
1079 | void toolBarPosChanged( QToolBar *tb ); | 1080 | void toolBarPosChanged( QToolBar *tb ); |
1080 | void slotContextAboutToShow(); | 1081 | void slotContextAboutToShow(); |