diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2019-06-01 15:56:13 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2019-06-01 15:56:13 +0900 |
commit | b1e66b339befa7bdf222f7bb80a431236a3ff689 (patch) | |
tree | 3ae72987233dbeddeb7fe370ee36dbe36077663c /parts | |
parent | 5fcb1d91b4f52ab609864968a7320eb276f6c068 (diff) | |
download | tdevelop-b1e66b339befa7bdf222f7bb80a431236a3ff689.tar.gz tdevelop-b1e66b339befa7bdf222f7bb80a431236a3ff689.zip |
Adjusted to use new TQStringVariantMap type.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'parts')
-rw-r--r-- | parts/astyle/astyle_adaptor.cpp | 4 | ||||
-rw-r--r-- | parts/astyle/astyle_adaptor.h | 2 | ||||
-rw-r--r-- | parts/astyle/astyle_part.cpp | 16 | ||||
-rw-r--r-- | parts/astyle/astyle_part.h | 10 | ||||
-rw-r--r-- | parts/astyle/astyle_widget.cpp | 12 |
5 files changed, 22 insertions, 22 deletions
diff --git a/parts/astyle/astyle_adaptor.cpp b/parts/astyle/astyle_adaptor.cpp index 05fb0901..49ff81a8 100644 --- a/parts/astyle/astyle_adaptor.cpp +++ b/parts/astyle/astyle_adaptor.cpp @@ -38,9 +38,9 @@ string ASStringIterator::nextLine() } -KDevFormatter::KDevFormatter(const TQMap<TQString, TQVariant>& options) +KDevFormatter::KDevFormatter(const TQStringVariantMap& options) { -// for ( TQMap<TQString, TQVariant>::ConstIterator iter = options.begin();iter != options.end();iter++ ) +// for ( TQStringVariantMap::ConstIterator iter = options.begin();iter != options.end();iter++ ) // { // kdDebug ( 9009 ) << "format: " << iter.key() << "=" << iter.data() << endl; // } diff --git a/parts/astyle/astyle_adaptor.h b/parts/astyle/astyle_adaptor.h index 21398fbb..d1cb4e61 100644 --- a/parts/astyle/astyle_adaptor.h +++ b/parts/astyle/astyle_adaptor.h @@ -37,7 +37,7 @@ class KDevFormatter : public astyle::ASFormatter { public: - KDevFormatter(const TQMap<TQString, TQVariant>& options); + KDevFormatter(const TQStringVariantMap& options); KDevFormatter( AStyleWidget * widget ); TQString indentString() const { diff --git a/parts/astyle/astyle_part.cpp b/parts/astyle/astyle_part.cpp index 16d590ab..f5b5e2e7 100644 --- a/parts/astyle/astyle_part.cpp +++ b/parts/astyle/astyle_part.cpp @@ -101,7 +101,7 @@ void AStylePart::loadGlobal() } -// for (TQMap<TQString, TQVariant>::iterator iter = m_global.begin();iter != m_global.end();iter++) +// for (TQStringVariantMap::iterator iter = m_global.begin();iter != m_global.end();iter++) // { // kdDebug(9009) << "load: " <<iter.key() << "="<< iter.data() << endl; // } @@ -110,7 +110,7 @@ void AStylePart::loadGlobal() void AStylePart::saveGlobal() { TQString options; - for (TQMap<TQString, TQVariant>::iterator iter = m_global.begin();iter != m_global.end();iter++) + for (TQStringVariantMap::iterator iter = m_global.begin();iter != m_global.end();iter++) { // kdDebug(9009) <<"saveGlobal" <<iter.key() << "="<< iter.data() << endl; options += iter.key(); @@ -118,7 +118,7 @@ void AStylePart::saveGlobal() options += iter.data().toString(); options += ","; } -// for (TQMap<TQString, TQVariant>::iterator iter = m_project.begin();iter != m_project.end();iter++) +// for (TQStringVariantMap::iterator iter = m_project.begin();iter != m_project.end();iter++) // { // kdDebug(9009) << "project before: " <<iter.key() << "="<< iter.data() << endl; // } @@ -129,11 +129,11 @@ void AStylePart::saveGlobal() config->writeEntry("Extensions",m_globalExtensions.join(",")); config->sync(); -// for (TQMap<TQString, TQVariant>::iterator iter = m_global.begin();iter != m_global.end();iter++) +// for (TQStringVariantMap::iterator iter = m_global.begin();iter != m_global.end();iter++) // { // kdDebug(9009) << "global after: " <<iter.key() << "="<< iter.data() << endl; // } -// for (TQMap<TQString, TQVariant>::iterator iter = m_project.begin();iter != m_project.end();iter++) +// for (TQStringVariantMap::iterator iter = m_project.begin();iter != m_project.end();iter++) // { // kdDebug(9009) << "project after: " <<iter.key() << "="<< iter.data() << endl; // } @@ -343,7 +343,7 @@ void AStylePart::activePartChanged ( KParts::Part *part ) formatTextAction->setEnabled ( enabled ); } -TQString AStylePart::formatSource( const TQString text, AStyleWidget * widget, const TQMap<TQString, TQVariant>& options ) +TQString AStylePart::formatSource( const TQString text, AStyleWidget * widget, const TQStringVariantMap& options ) { ASStringIterator is(text); KDevFormatter * formatter = ( widget)? new KDevFormatter( widget ) : new KDevFormatter(options); @@ -426,7 +426,7 @@ void AStylePart::restorePartialProjectSession(const TQDomElement * el) } else { - for (TQMap<TQString, TQVariant>::iterator iter = m_global.begin();iter != m_global.end();iter++) + for (TQStringVariantMap::iterator iter = m_global.begin();iter != m_global.end();iter++) { m_project[iter.key()] = style.attribute(iter.key(),iter.data().toString()); } @@ -451,7 +451,7 @@ void AStylePart::savePartialProjectSession(TQDomElement * el) style.setAttribute("FStyle", m_project["FStyle"].toString()); if (m_project["FStyle"] != "GLOBAL") { - for (TQMap<TQString, TQVariant>::iterator iter = m_project.begin();iter != m_project.end();iter++) + for (TQStringVariantMap::iterator iter = m_project.begin();iter != m_project.end();iter++) { style.setAttribute(iter.key(),iter.data().toString()); } diff --git a/parts/astyle/astyle_part.h b/parts/astyle/astyle_part.h index 61b5a382..f5a79485 100644 --- a/parts/astyle/astyle_part.h +++ b/parts/astyle/astyle_part.h @@ -30,7 +30,7 @@ public: AStylePart(TQObject *parent, const char *name, const TQStringList &); ~AStylePart(); - TQString formatSource(const TQString text, AStyleWidget * widget, const TQMap<TQString, TQVariant>& options); + TQString formatSource(const TQString text, AStyleWidget * widget, const TQStringVariantMap& options); virtual TQString formatSource(const TQString text); TQString indentString() const; void saveGlobal(); @@ -40,8 +40,8 @@ public: void restorePartialProjectSession(const TQDomElement * el); void savePartialProjectSession(TQDomElement * el); - TQMap<TQString, TQVariant>& getProjectOptions(){return m_project;} - TQMap<TQString, TQVariant>& getGlobalOptions(){return m_global;} + TQStringVariantMap& getProjectOptions(){return m_project;} + TQStringVariantMap& getGlobalOptions(){return m_global;} private slots: @@ -65,8 +65,8 @@ private: TDEAction *formatFileAction; // the configurable options. - TQMap<TQString, TQVariant> m_project; - TQMap<TQString, TQVariant> m_global; + TQStringVariantMap m_project; + TQStringVariantMap m_global; TQStringList m_projectExtensions; TQStringList m_globalExtensions; TQMap<TQString, TQString> m_searchExtensions; diff --git a/parts/astyle/astyle_widget.cpp b/parts/astyle/astyle_widget.cpp index a70c6771..6959fe7b 100644 --- a/parts/astyle/astyle_widget.cpp +++ b/parts/astyle/astyle_widget.cpp @@ -53,7 +53,7 @@ AStyleWidget::AStyleWidget(AStylePart * part, bool global, TQWidget *parent, con connect(Keep_Blocks, TQT_SIGNAL(clicked()), this, TQT_SLOT(styleChanged())); - TQMap<TQString, TQVariant> option; + TQStringVariantMap option; if ( isGlobalWidget){ Style_Global->hide(); option = m_part->getGlobalOptions(); @@ -172,7 +172,7 @@ AStyleWidget::~AStyleWidget() void AStyleWidget::accept() { - TQMap<TQString, TQVariant>* m_option; + TQStringVariantMap* m_option; if ( isGlobalWidget){ m_option = &(m_part->getGlobalOptions()); m_part->setExtensions(GeneralExtension->text(),true); @@ -195,8 +195,8 @@ void AStyleWidget::accept() else if (Style_JAVA->isChecked()) (*m_option)["FStyle"] = "JAVA"; else if (Style_Global->isChecked()){ - TQMap<TQString,TQVariant>& global = m_part->getGlobalOptions(); - TQMap<TQString,TQVariant>& project = m_part->getProjectOptions(); + TQStringVariantMap& global = m_part->getGlobalOptions(); + TQStringVariantMap& project = m_part->getProjectOptions(); project=global; project["FStyle"]="GLOBAL"; } @@ -264,7 +264,7 @@ void AStyleWidget::accept() } if ( isGlobalWidget){ - TQMap<TQString, TQVariant>& project = m_part->getProjectOptions(); + TQStringVariantMap& project = m_part->getProjectOptions(); if ( project["FStyle"] == "GLOBAL"){ project = m_part->getGlobalOptions(); project["FStyle"] = "GLOBAL"; @@ -272,7 +272,7 @@ void AStyleWidget::accept() m_part->saveGlobal(); } -// for ( TQMap<TQString, TQVariant>::ConstIterator iter = m_option->begin();iter != m_option->end();iter++ ) +// for ( TQStringVariantMap::ConstIterator iter = m_option->begin();iter != m_option->end();iter++ ) // { // kdDebug ( 9009 ) << "widget: " << iter.key() << "=" << iter.data() << endl; // } |