summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorMartin Gallwey <mtg@openoffice.org>2001-02-23 13:31:41 +0000
committerMartin Gallwey <mtg@openoffice.org>2001-02-23 13:31:41 +0000
commit920f6969c4b8687c67b955b2fe01f0255a7f7caf (patch)
treea200844290ccd936af1c4db6a8a49ee37aab7af6 /sw/source
parent5fb0f7396c6780f77b9782f9c75635abc6f90bd8 (diff)
The UI and API ensure that there are no duplicate entries making this code unnecessary
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/core/swg/SwXMLTextBlocks.cxx20
1 files changed, 17 insertions, 3 deletions
diff --git a/sw/source/core/swg/SwXMLTextBlocks.cxx b/sw/source/core/swg/SwXMLTextBlocks.cxx
index 11a71f959cd2..7cc77c973d89 100644
--- a/sw/source/core/swg/SwXMLTextBlocks.cxx
+++ b/sw/source/core/swg/SwXMLTextBlocks.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: SwXMLTextBlocks.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: mtg $ $Date: 2001-02-16 09:28:29 $
+ * last change: $Author: mtg $ $Date: 2001-02-23 14:31:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -923,15 +923,29 @@ void SwXMLTextBlocks::GeneratePackageName ( const String& rShort, String& rPacka
rPackageName.SetChar( nPos, rPackageName.GetChar( nPos ) & 0x0f );
++nPos;
}
- if (xBlkRoot.Is() || 0 == OpenFile ( TRUE ) )
+#if 0
+ /*
+ * We can assume that if the package name we generate is already in the storage,
+ * then we are over-writing it...*/
+ if (xBlkRoot.Is() || 0 == OpenFile ( FALSE ) )
{
+ if ( xBlkRoot->IsContained( rPackageName ) )
+ {
+ xBlkRoot->Remove ( rPackageName );
+ xBlkRoot->Commit();
+ }
+
+ /*
ULONG nIdx=0;
while ( xBlkRoot->IsContained( rPackageName ))
{
++nIdx;
rPackageName += String::CreateFromInt32( nIdx );
}
+ */
}
+#endif
+
}
ULONG SwXMLTextBlocks::PutText( const String& rShort, const String& rName,
const String& rText )