diff options
author | Juergen Funk <juergen.funk_ml@cib.de> | 2015-01-20 13:32:11 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-01-20 14:38:37 +0100 |
commit | 282baa9012a4f43931be12fd429d15c081e7bf28 (patch) | |
tree | a9a25b7d10d207d07cf6260eb65b50bb7007f90d /desktop | |
parent | 6cf58a33676cebc9f2c1d26163793ba7dce46262 (diff) |
Remove unused code
- a inline function not use
- a variable will be set but not use
Change-Id: I67674a6cd05ddb058d11d46188d5c9d039ed40fb
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/source/migration/migration.cxx | 33 | ||||
-rw-r--r-- | desktop/source/migration/migration_impl.hxx | 3 |
2 files changed, 1 insertions, 35 deletions
diff --git a/desktop/source/migration/migration.cxx b/desktop/source/migration/migration.cxx index 553138e922d9..15d3b5b6ca0e 100644 --- a/desktop/source/migration/migration.cxx +++ b/desktop/source/migration/migration.cxx @@ -302,7 +302,6 @@ bool MigrationImpl::doMigration() } m_aOldVersionItemsHashMap.clear(); - m_aNewVersionItemsHashMap.clear(); } // execute the migration items from Setup.xcu @@ -1151,36 +1150,6 @@ void MigrationImpl::compareOldAndNewConfig(const OUString& sParent, sSibling = it->m_sCommandURL; } - - uno::Reference< container::XIndexContainer > xPopup; - for (it = vNewItems.begin(); it!=vNewItems.end(); ++it) - { - ::std::vector< MigrationItem >::iterator pFound = ::std::find(vOldItems.begin(), vOldItems.end(), *it); - if (pFound != vOldItems.end() && it->m_xPopupMenu.is()) - { - OUString sName; - if (!sParent.isEmpty()) - sName = sParent + MENU_SEPARATOR + it->m_sCommandURL; - else - sName = it->m_sCommandURL; - compareOldAndNewConfig(sName, pFound->m_xPopupMenu, it->m_xPopupMenu, sResourceURL); - } - else if (::std::find(vOldItems.begin(), vOldItems.end(), *it) == vOldItems.end()) - { - MigrationItem aMigrationItem(sParent, sSibling, it->m_sCommandURL, it->m_xPopupMenu); - if (m_aNewVersionItemsHashMap.find(sResourceURL)==m_aNewVersionItemsHashMap.end()) - { - ::std::vector< MigrationItem > vMigrationItems; - m_aNewVersionItemsHashMap.insert(MigrationHashMap::value_type(sResourceURL, vMigrationItems)); - m_aNewVersionItemsHashMap[sResourceURL].push_back(aMigrationItem); - } - else - { - if (::std::find(m_aNewVersionItemsHashMap[sResourceURL].begin(), m_aNewVersionItemsHashMap[sResourceURL].end(), aMigrationItem)==m_aNewVersionItemsHashMap[sResourceURL].end()) - m_aNewVersionItemsHashMap[sResourceURL].push_back(aMigrationItem); - } - } - } } void MigrationImpl::mergeOldToNewVersion(const uno::Reference< ui::XUIConfigurationManager >& xCfgManager, @@ -1247,7 +1216,7 @@ void MigrationImpl::mergeOldToNewVersion(const uno::Reference< ui::XUIConfigurat if (it->m_sPrevSibling.isEmpty()) xTemp->insertByIndex(0, uno::makeAny(aPropSeq)); - else if (!it->m_sPrevSibling.isEmpty()) + else { sal_Int32 nCount = xTemp->getCount(); sal_Int32 i = 0; diff --git a/desktop/source/migration/migration_impl.hxx b/desktop/source/migration/migration_impl.hxx index 4f304fbb305e..bffba28a546d 100644 --- a/desktop/source/migration/migration_impl.hxx +++ b/desktop/source/migration/migration_impl.hxx @@ -121,8 +121,6 @@ struct MigrationItem aMigrationItem.m_sCommandURL == m_sCommandURL && aMigrationItem.m_xPopupMenu.is() == m_xPopupMenu.is() ); } - - OUString GetPrevSibling() const { return m_sPrevSibling; } }; typedef std::unordered_map< OUString, std::vector< MigrationItem >, @@ -185,7 +183,6 @@ private: install_info m_aInfo; // info about the version being migrated strings_vr m_vrFileList; // final list of files to be copied MigrationHashMap m_aOldVersionItemsHashMap; - MigrationHashMap m_aNewVersionItemsHashMap; OUString m_sModuleIdentifier; // functions to control the migration process |