From: Frederik Gladhorn Date: Sat, 1 Sep 2007 23:41:21 +0000 (+0000) Subject: cleanup, improve identifier copy constructor X-Git-Tag: v3.94.0~89 X-Git-Url: https://git.rmz.fi/?a=commitdiff_plain;h=50bc1d6113b44d2989298fe09d821c3f56789c19;p=libqmvoc.git cleanup, improve identifier copy constructor svn path=/trunk/KDE/kdeedu/libkdeedu/; revision=707488 --- diff --git a/keduvocdocument/keduvocexpression.cpp b/keduvocdocument/keduvocexpression.cpp index ef3b8fb..69ed6a3 100644 --- a/keduvocdocument/keduvocexpression.cpp +++ b/keduvocdocument/keduvocexpression.cpp @@ -131,16 +131,10 @@ void KEduVocExpression::setTranslation( int index, const QString & expr ) if ( index < 0 ) return; -///@todo get rid of this nonsense: - /* not needed with qmap but for now all translations <= index are expected to exist - // extend translations with empty strings if necessary - for (int i = d->m_translations.count(); i < index + 1; i++) { - d->m_translations.append(""); - } - */ - for ( int i = d->m_translations.count(); i <= index; i++ ) { - d->m_translations[i] = KEduVocTranslation( "" ); - } +// extend translations with empty strings if necessary +// for ( int i = d->m_translations.count(); i <= index; i++ ) { +// d->m_translations[i] = KEduVocTranslation( "" ); +// } // if (index <= translations.count()) d->m_translations[index] = expr.simplified(); diff --git a/keduvocdocument/keduvocidentifier.cpp b/keduvocdocument/keduvocidentifier.cpp index ce50db0..cb05910 100644 --- a/keduvocdocument/keduvocidentifier.cpp +++ b/keduvocdocument/keduvocidentifier.cpp @@ -73,11 +73,14 @@ KEduVocIdentifier::~KEduVocIdentifier() KEduVocIdentifier::KEduVocIdentifier( const KEduVocIdentifier &other ) : d( new Private ) { -///@todo d->m_locale = other.d->m_locale; d->m_name = other.d->m_name; d->m_articles = other.d->m_articles; d->m_personalPronouns = other.d->m_personalPronouns; + d->m_comment = other.d->m_comment; + d->m_sizeHint = other.d->m_sizeHint; + d->m_tenses = other.d->m_tenses; + d->m_type = other.d->m_type; } diff --git a/keduvocdocument/keduvockvtmlreader.cpp b/keduvocdocument/keduvockvtmlreader.cpp index 66bffb0..fb5d4c0 100644 --- a/keduvocdocument/keduvockvtmlreader.cpp +++ b/keduvocdocument/keduvockvtmlreader.cpp @@ -132,7 +132,6 @@ bool KEduVocKvtmlReader::readBody( QDomElement &domElementParent ) currentElement = domElementParent.firstChildElement( KV_CONJUG_GRP ); if ( !currentElement.isNull() ) { -///@todo conjugations int count = 0; QDomElement domElementConjugChild = currentElement.firstChildElement(KV_CON_ENTRY); diff --git a/keduvocdocument/keduvockvtmlwriter.cpp b/keduvocdocument/keduvockvtmlwriter.cpp index 7bb16c0..3b24cbd 100644 --- a/keduvocdocument/keduvockvtmlwriter.cpp +++ b/keduvocdocument/keduvockvtmlwriter.cpp @@ -138,7 +138,7 @@ bool KEduVocKvtmlWriter::writeDoc( KEduVocDocument *doc, const QString &generato if ( !entry->translation( 0 ).example().isEmpty() ) domElementOriginal.setAttribute( KV_EXAMPLE, entry->translation( 0 ).example() ); -///@todo enable writing of usages +///@todo enable writing of usages in old format /* if (!entry->translation(0).usageLabel().isEmpty() ) domElementOriginal.setAttribute(KV_USAGE, entry->translation(0).usageLabel());