summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorThomas Arnhold <thomas@arnhold.org>2012-06-28 18:34:33 +0200
committerThomas Arnhold <thomas@arnhold.org>2012-06-29 09:25:12 +0200
commit688fcc847b0985b6c4c199ff2d701670e5dee46d (patch)
tree8327cb438f442366d0f241810fc3fc69afaf0577 /filter
parent4c4d748767c5740cc4b5348c69ad86c68db234bd (diff)
Remove unused locals
Change-Id: I14369787e99d31cba32957301340cef2fc832b91
Diffstat (limited to 'filter')
-rw-r--r--filter/source/msfilter/mscodec.cxx19
-rw-r--r--filter/source/xsltdialog/xmlfileview.cxx137
2 files changed, 0 insertions, 156 deletions
diff --git a/filter/source/msfilter/mscodec.cxx b/filter/source/msfilter/mscodec.cxx
index a081209b5d1b..5fcd1328625b 100644
--- a/filter/source/msfilter/mscodec.cxx
+++ b/filter/source/msfilter/mscodec.cxx
@@ -276,25 +276,6 @@ MSCodec_Std97::~MSCodec_Std97 ()
rtl_cipher_destroy (m_hCipher);
}
-#if 0
-#if DEBUG_MSO_ENCRYPTION_STD97
-static void lcl_PrintKeyData(const sal_uInt8* pKeyData, const char* msg)
-{
- printf("pKeyData: (%s)\n", msg);
- for (int j = 0; j < 4; ++j)
- {
- for (int i = 0; i < 16; ++i)
- printf("%2.2x ", pKeyData[j*16+i]);
- printf("\n");
- }
-}
-#else
-static void lcl_PrintKeyData(const sal_uInt8* /*pKeyData*/, const char* /*msg*/)
-{
-}
-#endif
-#endif
-
#if DEBUG_MSO_ENCRYPTION_STD97
static void lcl_PrintDigest(const sal_uInt8* pDigest, const char* msg)
{
diff --git a/filter/source/xsltdialog/xmlfileview.cxx b/filter/source/xsltdialog/xmlfileview.cxx
index 29f724d49701..ca1fa3f425f1 100644
--- a/filter/source/xsltdialog/xmlfileview.cxx
+++ b/filter/source/xsltdialog/xmlfileview.cxx
@@ -147,141 +147,4 @@ void TextViewOutWin::Paint( const Rectangle& rRect )
pTextView->Paint( rRect );
}
-///////////////////////////////////////////////////////////////////////
-
-void lcl_Highlight(const String& rSource, SwTextPortions& aPortionList)
-{
- const sal_Unicode cOpenBracket = '<';
- const sal_Unicode cCloseBracket= '>';
- const sal_Unicode cSlash = '/';
- const sal_Unicode cExclamation = '!';
- const sal_Unicode cMinus = '-';
- const sal_Unicode cSpace = ' ';
- const sal_Unicode cTab = 0x09;
- const sal_Unicode cLF = 0x0a;
- const sal_Unicode cCR = 0x0d;
-
-
- const sal_uInt16 nStrLen = rSource.Len();
- sal_uInt16 nInsert = 0; // Number of inserted Portions
- sal_uInt16 nActPos = 0; // Position, at the '<' was found
- sal_uInt16 nOffset = 0; // Offset of nActPos for '<'
- sal_uInt16 nPortStart = USHRT_MAX; // For the TextPortion
- sal_uInt16 nPortEnd = 0; //
- SwTextPortion aText;
- while(nActPos < nStrLen)
- {
- svtools::ColorConfigEntry eFoundType = svtools::HTMLUNKNOWN;
- if(rSource.GetChar(nActPos) == cOpenBracket && nActPos < nStrLen - 2 )
- {
- // 'leere' Portion einfuegen
- if(nPortEnd < nActPos - 1 )
- {
- aText.nLine = 0;
- // am Anfang nicht verschieben
- aText.nStart = nPortEnd;
- if(nInsert)
- aText.nStart += 1;
- aText.nEnd = nActPos - 1;
- aText.eType = svtools::HTMLUNKNOWN;
- aPortionList.push_back( aText );
- nInsert++;
- }
- sal_Unicode cFollowFirst = rSource.GetChar((xub_StrLen)(nActPos + 1));
- sal_Unicode cFollowNext = rSource.GetChar((xub_StrLen)(nActPos + 2));
- if(cExclamation == cFollowFirst)
- {
- // "<!" SGML oder Kommentar
- if(cMinus == cFollowNext &&
- nActPos < nStrLen - 3 && cMinus == rSource.GetChar((xub_StrLen)(nActPos + 3)))
- {
- eFoundType = svtools::HTMLCOMMENT;
- }
- else
- eFoundType = svtools::HTMLSGML;
- nPortStart = nActPos;
- nPortEnd = nActPos + 1;
- }
- else if(cSlash == cFollowFirst)
- {
- // "</" Slash ignorieren
- nPortStart = nActPos;
- nActPos++;
- nOffset++;
- }
- if(svtools::HTMLUNKNOWN == eFoundType)
- {
- //jetzt koennte hier ein keyword folgen
- sal_uInt16 nSrchPos = nActPos;
- while(++nSrchPos < nStrLen - 1)
- {
- sal_Unicode cNext = rSource.GetChar(nSrchPos);
- if( cNext == cSpace ||
- cNext == cTab ||
- cNext == cLF ||
- cNext == cCR)
- break;
- else if(cNext == cCloseBracket)
- {
- break;
- }
- }
- if(nSrchPos > nActPos + 1)
- {
- //irgend ein String wurde gefunden
- String sToken = rSource.Copy(nActPos + 1, nSrchPos - nActPos - 1 );
- sToken.ToUpperAscii();
- {
- //Token gefunden
- eFoundType = svtools::HTMLKEYWORD;
- nPortEnd = nSrchPos;
- nPortStart = nActPos;
- }
- }
- }
- // jetzt muss noch '>' gesucht werden
- if(svtools::HTMLUNKNOWN != eFoundType)
- {
- sal_Bool bFound = sal_False;
- for(sal_uInt16 i = nPortEnd; i < nStrLen; i++)
- if(cCloseBracket == rSource.GetChar(i))
- {
- bFound = sal_True;
- nPortEnd = i;
- break;
- }
- if(!bFound && (eFoundType == svtools::HTMLCOMMENT))
- {
- // Kommentar ohne Ende in dieser Zeile
- bFound = sal_True;
- nPortEnd = nStrLen - 1;
- }
-
- if(bFound ||(eFoundType == svtools::HTMLCOMMENT))
- {
- SwTextPortion aText2;
- aText2.nLine = 0;
- aText2.nStart = nPortStart + 1;
- aText2.nEnd = nPortEnd;
- aText2.eType = eFoundType;
- aPortionList.push_back( aText2 );
- nInsert++;
- eFoundType = svtools::HTMLUNKNOWN;
- }
-
- }
- }
- nActPos++;
- }
- if(nInsert && nPortEnd < nActPos - 1)
- {
- aText.nLine = 0;
- aText.nStart = nPortEnd + 1;
- aText.nEnd = nActPos - 1;
- aText.eType = svtools::HTMLUNKNOWN;
- aPortionList.push_back( aText );
- nInsert++;
- }
-}
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */