author | ulf69 <ulf69> | 2004-09-24 22:21:25 (UTC) |
---|---|---|
committer | ulf69 <ulf69> | 2004-09-24 22:21:25 (UTC) |
commit | e695903cc49b33e63505b651b13d830e318fc29a (patch) (side-by-side diff) | |
tree | fd210e2defbdcb3f3d9d739d0b00e6853705af29 /pwmanager | |
parent | a884dac6f756b3702a10ae97aa8782e4d2a84b20 (diff) | |
download | kdepimpi-e695903cc49b33e63505b651b13d830e318fc29a.zip kdepimpi-e695903cc49b33e63505b651b13d830e318fc29a.tar.gz kdepimpi-e695903cc49b33e63505b651b13d830e318fc29a.tar.bz2 |
fixed bug with QDomDocument handling, plus some GUI enhancements
-rw-r--r-- | pwmanager/pwmanager/pwmdocui.cpp | 8 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmexception.cpp | 7 | ||||
-rw-r--r-- | pwmanager/pwmanager/serializer.cpp | 12 |
3 files changed, 23 insertions, 4 deletions
diff --git a/pwmanager/pwmanager/pwmdocui.cpp b/pwmanager/pwmanager/pwmdocui.cpp index e42dd9d..5e675fc 100644 --- a/pwmanager/pwmanager/pwmdocui.cpp +++ b/pwmanager/pwmanager/pwmdocui.cpp @@ -439,12 +439,12 @@ QString PwMDocUi::string_deepLockedShort() QString PwMDocUi::string_deepLockedLong() { return i18n("This file is DEEP-LOCKED!\n" - "That means all data has been encrypted " - "and written out to the file. If you want " - "to see the entries, please UNLOCK the file. " - "While unlocking, you will be prompted for the " + "That means all data has been encrypted\n" + "and written out to the file. If you want\n" + "to see the entries, please UNLOCK the file.\n" + "While unlocking, you will be prompted for the\n" "master-password or the key-card."); } QString PwMDocUi::string_defaultTitle() diff --git a/pwmanager/pwmanager/pwmexception.cpp b/pwmanager/pwmanager/pwmexception.cpp index 4c00b04..c0dbb39 100644 --- a/pwmanager/pwmanager/pwmexception.cpp +++ b/pwmanager/pwmanager/pwmexception.cpp @@ -42,17 +42,24 @@ void __printError(const string &msg) void __printInfo(const string &msg) { cout << PROG_NAME " INFO: " << msg << endl; +#ifdef PWM_DEBUG + qDebug("%s INFO: %s", PROG_NAME, msg.c_str()) ; +#endif } void __printWarn(const string &msg) { cerr << PROG_NAME " WARNING: " << msg << endl; +#ifdef PWM_DEBUG + qDebug("%s WARNING: %s", PROG_NAME, msg.c_str()) ; +#endif } #ifdef PWM_DEBUG void __printDebug(const string &msg) { cout << PROG_NAME " DEBUG: " << msg << endl; + qDebug("%s DEBUG: %s", PROG_NAME, msg.c_str()) ; } #endif // PWM_DEBUG diff --git a/pwmanager/pwmanager/serializer.cpp b/pwmanager/pwmanager/serializer.cpp index 2810b48..fcdcec3 100644 --- a/pwmanager/pwmanager/serializer.cpp +++ b/pwmanager/pwmanager/serializer.cpp @@ -119,15 +119,26 @@ Serializer::Serializer() { defaultLockStat = true; +//US BUG: I needed to specify a document name. Otherwise impl will not be created for serializing +#ifndef PWM_EMBEDDED domDoc = new QDomDocument; +#else + domDoc = new QDomDocument("mydoc"); +#endif } Serializer::Serializer(const QCString &buffer) { defaultLockStat = true; +//US BUG: I needed to specify a document name. Otherwise impl will not be created for serializing +#ifndef PWM_EMBEDDED domDoc = new QDomDocument; +#else + domDoc = new QDomDocument("mydoc"); +#endif + if (!parseXml(buffer)) { delete domDoc; #ifndef PWM_EMBEDDED throw PwMException(PwMException::EX_PARSE); @@ -182,8 +193,9 @@ QCString Serializer::getXml() #if defined(PWM_DEBUG) && SERIALIZER_DEBUG != 0 QCString tmp(" " + domDoc->toCString()); printDebug("<BEGIN Serializer::getXml() dump>\n"); + qDebug(tmp); cout << tmp << endl; printDebug("<END Serializer::getXml() dump>"); #endif // DEBUG |