summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/kaddressbook/germantranslation.txt2
-rw-r--r--kabc/stdaddressbook.cpp5
-rw-r--r--kabc/stdaddressbook.h2
-rw-r--r--kaddressbook/kabcore.cpp28
-rw-r--r--kaddressbook/kabcore.h4
-rw-r--r--kaddressbook/kaddressbookmain.cpp4
-rw-r--r--kaddressbook/mainembedded.cpp5
7 files changed, 38 insertions, 12 deletions
diff --git a/bin/kdepim/kaddressbook/germantranslation.txt b/bin/kdepim/kaddressbook/germantranslation.txt
index 293aaea..ece26d2 100644
--- a/bin/kdepim/kaddressbook/germantranslation.txt
+++ b/bin/kdepim/kaddressbook/germantranslation.txt
@@ -814,3 +814,3 @@
{ "Import all!","Importiere alle!" },
-{ "","" },
+{ "Loading addressbook data ... please wait","Lade Adressbuchdaten ... bitte warten" },
{ "","" },
diff --git a/kabc/stdaddressbook.cpp b/kabc/stdaddressbook.cpp
index f17f366..a14ae20 100644
--- a/kabc/stdaddressbook.cpp
+++ b/kabc/stdaddressbook.cpp
@@ -115,3 +115,3 @@ StdAddressBook::StdAddressBook()
- init( false );
+ //init( false );
}
@@ -122,3 +122,4 @@ StdAddressBook::StdAddressBook( bool onlyFastResources )
- init( onlyFastResources );
+ if ( onlyFastResources )
+ init( onlyFastResources );
}
diff --git a/kabc/stdaddressbook.h b/kabc/stdaddressbook.h
index 9ec53b0..cf130b3 100644
--- a/kabc/stdaddressbook.h
+++ b/kabc/stdaddressbook.h
@@ -136,2 +136,3 @@ class StdAddressBook : public AddressBook
void setWhoAmI( const Addressee &addr );
+ void init( bool onlyFastResources );
@@ -141,3 +142,2 @@ class StdAddressBook : public AddressBook
- void init( bool onlyFastResources );
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp
index b9830b1..c670b1f 100644
--- a/kaddressbook/kabcore.cpp
+++ b/kaddressbook/kabcore.cpp
@@ -405,5 +405,28 @@ KABCore::KABCore( KXMLGUIClient *client, bool readWrite, QWidget *parent, const
// we have a toolbar repainting error on the Zaurus when starting KA/Pi
- QTimer::singleShot( 10, this , SLOT ( updateToolBar()));
+ //QTimer::singleShot( 10, this , SLOT ( updateToolBar()));
+ QTimer::singleShot( 100, this, SLOT ( loadDataAfterStart() ));
+}
+void KABCore::receiveStart( const QCString& cmsg, const QByteArray& data )
+{
+ qDebug("KO: QCOP start message received: %s ", cmsg.data() );
+ mCStringMess = cmsg;
+ mByteData = data;
}
+void KABCore::loadDataAfterStart()
+{
+ qDebug("KABCore::loadDataAfterStart() ");
+ ((StdAddressBook*)mAddressBook)->init( true );
+ mViewManager->refreshView();
+
+#ifndef DESKTOP_VERSION
+ disconnect(qApp, SIGNAL (appMessage ( const QCString &, const QByteArray & )), this, SLOT (receiveStart ( const QCString &, const QByteArray & )));
+
+ QObject::connect(qApp, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & )));
+ if ( !mCStringMess.isEmpty() )
+ ExternalAppHandler::instance()->appMessage( mCStringMess, mByteData );
+#endif
+ QTimer::singleShot( 10, this , SLOT ( updateToolBar()));
+ setCaptionBack();
+}
void KABCore::updateToolBar()
@@ -2447,3 +2470,2 @@ void KABCore::removeVoice()
message(i18n("Refreshing view...") );
- qApp->processEvents();
mViewManager->refreshView( "" );
@@ -2479,3 +2501,2 @@ void KABCore::setFormattedName()
message(i18n("Changing contact #%1").arg( count ) );
- qApp->processEvents();
QString fName;
@@ -2499,3 +2520,2 @@ void KABCore::setFormattedName()
message(i18n("Refreshing view...") );
- qApp->processEvents();
if ( modified )
diff --git a/kaddressbook/kabcore.h b/kaddressbook/kabcore.h
index ceeeda7..42b7709 100644
--- a/kaddressbook/kabcore.h
+++ b/kaddressbook/kabcore.h
@@ -356,2 +356,3 @@ class KABCore : public QWidget, public KSyncInterface
public slots:
+ void loadDataAfterStart();
void recieve(QString cmsg );
@@ -368,2 +369,3 @@ class KABCore : public QWidget, public KSyncInterface
void receive( const QCString& cmsg, const QByteArray& data );
+ void receiveStart( const QCString& cmsg, const QByteArray& data );
void toggleBeamReceive( );
@@ -394,2 +396,4 @@ class KABCore : public QWidget, public KSyncInterface
private:
+ QCString mCStringMess;
+ QByteArray mByteData;
QString mEmailSourceChannel;
diff --git a/kaddressbook/kaddressbookmain.cpp b/kaddressbook/kaddressbookmain.cpp
index 519dc92..8fe3ee0 100644
--- a/kaddressbook/kaddressbookmain.cpp
+++ b/kaddressbook/kaddressbookmain.cpp
@@ -85,4 +85,6 @@ KAddressBookMain::KAddressBookMain() : DCOPObject( "KAddressBookIface" ), KMainW
setAutoSaveSettings();
- qApp->processEvents();
mCore->restoreSettings();
+#ifndef DESKTOP_VERSION
+ QObject::connect(qApp, SIGNAL (appMessage ( const QCString &, const QByteArray & )), mCore, SLOT (receiveStart ( const QCString &, const QByteArray & )));
+#endif
}
diff --git a/kaddressbook/mainembedded.cpp b/kaddressbook/mainembedded.cpp
index 93ba53c..2f3531d 100644
--- a/kaddressbook/mainembedded.cpp
+++ b/kaddressbook/mainembedded.cpp
@@ -81,5 +81,3 @@ int main( int argc, char **argv )
//US MainWindow m;
-#ifndef DESKTOP_VERSION
- QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & )));
-#endif
+
@@ -93,2 +91,3 @@ int main( int argc, char **argv )
#endif
+ m.setCaption(i18n("Loading addressbook data ... please wait" ));
a.exec();