summaryrefslogtreecommitdiff
path: root/desktop/source/migration/migration_impl.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'desktop/source/migration/migration_impl.hxx')
-rw-r--r--desktop/source/migration/migration_impl.hxx16
1 files changed, 12 insertions, 4 deletions
diff --git a/desktop/source/migration/migration_impl.hxx b/desktop/source/migration/migration_impl.hxx
index bffba28a546d..dc7d48ebf99c 100644
--- a/desktop/source/migration/migration_impl.hxx
+++ b/desktop/source/migration/migration_impl.hxx
@@ -114,12 +114,20 @@ struct MigrationItem
return *this;
}
+ bool areBothOpenFrom(OUString const & cmd1, OUString const & cmd2)
+ {
+ return cmd1 == ".uno:Open" && cmd2.startsWith(".uno:OpenFrom");
+ }
+
+
bool operator==(const MigrationItem& aMigrationItem)
{
- return ( aMigrationItem.m_sParentNodeName == m_sParentNodeName &&
- aMigrationItem.m_sPrevSibling == m_sPrevSibling &&
- aMigrationItem.m_sCommandURL == m_sCommandURL &&
- aMigrationItem.m_xPopupMenu.is() == m_xPopupMenu.is() );
+ return ((aMigrationItem.m_sCommandURL == m_sCommandURL
+ || (areBothOpenFrom(aMigrationItem.m_sCommandURL, m_sCommandURL)
+ || areBothOpenFrom(m_sCommandURL, aMigrationItem.m_sCommandURL)))
+ && aMigrationItem.m_sParentNodeName == m_sParentNodeName
+ && aMigrationItem.m_sPrevSibling == m_sPrevSibling
+ && aMigrationItem.m_xPopupMenu.is() == m_xPopupMenu.is() );
}
};