[Libreoffice-commits] .: 4 commits - basic/source fpicker/source idl/source sfx2/inc sfx2/source shell/inc svx/source ucb/source xmloff/source

Caolán McNamara caolan at kemper.freedesktop.org
Mon Jan 24 06:50:53 PST 2011


 basic/source/classes/sbxmod.cxx              |    3 --
 fpicker/source/unx/kde/kdecommandthread.cxx  |    2 +
 fpicker/source/unx/kde/kdefilepicker.cxx     |    2 +
 fpicker/source/unx/kde/kdefilepicker.hxx     |    2 +
 fpicker/source/unx/kde/kdefpmain.cxx         |    2 +
 fpicker/source/unx/kde/kdemodalityfilter.cxx |    2 +
 idl/source/cmptools/lex.cxx                  |    3 --
 sfx2/inc/sfx2/docfile.hxx                    |    1 
 sfx2/inc/sfx2/sfxhtml.hxx                    |    6 ----
 sfx2/source/appl/appcfg.cxx                  |    7 ----
 sfx2/source/appl/appserv.cxx                 |    2 -
 sfx2/source/bastyp/progress.cxx              |    3 --
 sfx2/source/bastyp/sfxhtml.cxx               |   17 ------------
 sfx2/source/control/dispatch.cxx             |    9 +-----
 sfx2/source/control/statcach.cxx             |    2 -
 sfx2/source/control/unoctitm.cxx             |    5 ---
 sfx2/source/dialog/dinfdlg.cxx               |    2 -
 sfx2/source/dialog/dockwin.cxx               |    3 --
 sfx2/source/dialog/filedlghelper.cxx         |   23 ----------------
 sfx2/source/doc/docfile.cxx                  |   38 +--------------------------
 sfx2/source/doc/objcont.cxx                  |    2 -
 sfx2/source/doc/objstor.cxx                  |    2 +
 sfx2/source/doc/objxtor.cxx                  |    8 -----
 sfx2/source/doc/sfxbasemodel.cxx             |    1 
 sfx2/source/view/viewprn.cxx                 |   35 ------------------------
 shell/inc/kde_headers.h                      |    3 +-
 svx/source/svdraw/svdundo.cxx                |    1 
 ucb/source/sorter/sortresult.cxx             |    2 -
 xmloff/source/core/xmluconv.cxx              |    2 -
 xmloff/source/draw/animationimport.cxx       |    4 +-
 xmloff/source/draw/xexptran.cxx              |    1 
 xmloff/source/table/XMLTableImport.cxx       |   14 ++++-----
 32 files changed, 33 insertions(+), 176 deletions(-)

New commits:
commit b93aee14736e65b13887ad0d1ebb32f214d3cb05
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Mon Jan 24 14:50:41 2011 +0000

    WaE: gcc 4.6.0 various warnings

diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx
index 286b70c..c5849d7 100644
--- a/basic/source/classes/sbxmod.cxx
+++ b/basic/source/classes/sbxmod.cxx
@@ -300,9 +300,8 @@ DocObjectWrapper::invoke( const ::rtl::OUString& aFunctionName, const Sequence<
 
     // call method
     SbxVariableRef xReturn = new SbxVariable;
-    ErrCode nErr = SbxERR_OK;
 
-    nErr = pMethod->Call( xReturn );
+    pMethod->Call( xReturn );
     Any aReturn;
     // get output parameters
     if ( xSbxParams.Is() )
diff --git a/idl/source/cmptools/lex.cxx b/idl/source/cmptools/lex.cxx
index fa0c477..8b98334 100644
--- a/idl/source/cmptools/lex.cxx
+++ b/idl/source/cmptools/lex.cxx
@@ -338,8 +338,6 @@ ULONG SvTokenStream::GetNumber()
 *************************************************************************/
 BOOL SvTokenStream::MakeToken( SvToken & rToken )
 {
-    USHORT          i;
-
     do
     {
         if( 0 == c )
@@ -412,7 +410,6 @@ BOOL SvTokenStream::MakeToken( SvToken & rToken )
     else if( c == '"' )
     {
         ByteString          aStr;
-        i = 0;
         BOOL bDone = FALSE;
         while( !bDone && !IsEof() && c )
         {
diff --git a/svx/source/svdraw/svdundo.cxx b/svx/source/svdraw/svdundo.cxx
index 56e9dd9..abc6558 100644
--- a/svx/source/svdraw/svdundo.cxx
+++ b/svx/source/svdraw/svdundo.cxx
@@ -1454,6 +1454,7 @@ void SdrUndoPage::ImpRemovePage(USHORT nNum)
             pChkPg=rMod.RemovePage(nNum);
         }
         DBG_ASSERT(pChkPg==&mrPage,"SdrUndoPage::ImpRemovePage(): RemovePage!=&mrPage");
+        (void)pChkPg;
     }
 }
 
diff --git a/ucb/source/sorter/sortresult.cxx b/ucb/source/sorter/sortresult.cxx
index c18535d..02f2d05 100644
--- a/ucb/source/sorter/sortresult.cxx
+++ b/ucb/source/sorter/sortresult.cxx
@@ -1469,7 +1469,7 @@ void SortedResultSet::Initialize(
 
     // insert some dummy entries first and replace then
     // the entries with the right ones
-    sal_uInt32 i;
+    size_t i;
 
     for ( i=1; i<maS2O.Count(); i++ )
         maO2S.Insert( (void*) 0, i );   // Insert( data, pos )
diff --git a/xmloff/source/core/xmluconv.cxx b/xmloff/source/core/xmluconv.cxx
index 3d209a3..fc40061 100644
--- a/xmloff/source/core/xmluconv.cxx
+++ b/xmloff/source/core/xmluconv.cxx
@@ -1734,7 +1734,6 @@ void SvXMLUnitConverter::convertNumFormat( OUStringBuffer& rBuffer,
                            sal_Int16 nType ) const
 {
     enum XMLTokenEnum eFormat = XML_TOKEN_INVALID;
-    sal_Bool bExt = sal_False;
     switch( nType )
     {
     case NumberingType::CHARS_UPPER_LETTER:     eFormat = XML_A_UPCASE; break;
@@ -1752,7 +1751,6 @@ void SvXMLUnitConverter::convertNumFormat( OUStringBuffer& rBuffer,
         DBG_ASSERT( eFormat != XML_TOKEN_INVALID, "invalid number format" );
         break;
     default:
-        bExt = sal_True;
         break;
     }
 
diff --git a/xmloff/source/draw/animationimport.cxx b/xmloff/source/draw/animationimport.cxx
index ef83d16..ed298e5 100644
--- a/xmloff/source/draw/animationimport.cxx
+++ b/xmloff/source/draw/animationimport.cxx
@@ -530,8 +530,8 @@ Sequence< Any > AnimationsImportHelperImpl::convertValueSequence( XMLTokenEnum e
 
         // fill the sequence
         Any* pValues = aValues.getArray();
-        sal_Int32 nIndex, nElement;
-        for( nIndex = 0, nElement = 0; nElements && (nIndex >= 0); nElements-- )
+        sal_Int32 nIndex;
+        for( nIndex = 0; nElements && (nIndex >= 0); nElements-- )
         {
             *pValues++ = convertValue( eAttributeName, rValue.getToken( 0, ';', nIndex ) );
         }
diff --git a/xmloff/source/draw/xexptran.cxx b/xmloff/source/draw/xexptran.cxx
index b8eb90f..833b957 100644
--- a/xmloff/source/draw/xexptran.cxx
+++ b/xmloff/source/draw/xexptran.cxx
@@ -2359,6 +2359,7 @@ SdXMLImExSvgDElement::SdXMLImExSvgDElement(const OUString& rNew,
     }
 
     DBG_ASSERT(!bEllipticalArc, "XMLIMP: non-interpreted tags in svg:d element!");
+    (void)bEllipticalArc;
 
     if(nNumPolys)
     {
diff --git a/xmloff/source/table/XMLTableImport.cxx b/xmloff/source/table/XMLTableImport.cxx
index 4d591f1..38e2953 100644
--- a/xmloff/source/table/XMLTableImport.cxx
+++ b/xmloff/source/table/XMLTableImport.cxx
@@ -454,9 +454,7 @@ SvXMLImportContext * XMLTableImportContext::ImportRow( USHORT nPrefix, const OUS
 
         Reference< XPropertySet > xRowSet( mxRows->getByIndex(mnCurrentRow), UNO_QUERY );
 
-        sal_Int32 nRepeated = 1;
         OUString sStyleName;
-        sal_Bool bVisibility = sal_True;
 
         // read attributes for the table-row
         sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0;
@@ -469,11 +467,7 @@ SvXMLImportContext * XMLTableImportContext::ImportRow( USHORT nPrefix, const OUS
             sal_uInt16 nPrefix2 = GetImport().GetNamespaceMap().GetKeyByAttrName( sAttrName, &aLocalName );
             if( nPrefix2 == XML_NAMESPACE_TABLE )
             {
-                if( IsXMLToken( aLocalName, XML_NUMBER_ROWS_REPEATED ) )
-                {
-                    nRepeated = sValue.toInt32();
-                }
-                else if( IsXMLToken( aLocalName, XML_STYLE_NAME ) )
+                if( IsXMLToken( aLocalName, XML_STYLE_NAME ) )
                 {
                     sStyleName = sValue;
                 }
@@ -481,10 +475,16 @@ SvXMLImportContext * XMLTableImportContext::ImportRow( USHORT nPrefix, const OUS
                 {
                     msDefaultCellStyleName = sValue;
                 }
+#if 0
                 else if( IsXMLToken( aLocalName, XML_VISIBILITY ) )
                 {
                     bVisibility = IsXMLToken( sValue, XML_VISIBLE );
                 }
+                else if( IsXMLToken( aLocalName, XML_NUMBER_ROWS_REPEATED ) )
+                {
+                    nRepeated = sValue.toInt32();
+                }
+#endif
             }
             else if ( (XML_NAMESPACE_XML == nPrefix2) &&
                  IsXMLToken(aLocalName, XML_ID)   )
commit 8b3801e24fb3ba3d8bc5283ffff83d19bd0d369f
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Mon Jan 24 10:40:29 2011 +0000

    WaE: gcc 4.6.0 various warnings

diff --git a/shell/inc/kde_headers.h b/shell/inc/kde_headers.h
index d69bb0d..797a12f 100644
--- a/shell/inc/kde_headers.h
+++ b/shell/inc/kde_headers.h
@@ -32,6 +32,8 @@
 /* ********* Suppress warnings if needed */
 #include "sal/config.h"
 
+#include <cstddef>
+
 #if defined __GNUC__
 #pragma GCC system_header
 #endif
@@ -91,7 +93,6 @@
 #include <kabc/field.h>
 #include <kabc/stdaddressbook.h>
 
-
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
commit 14a73eaa77b5000ab83a672be964e923f65ca9e0
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Mon Jan 24 10:40:19 2011 +0000

    WaE: gcc 4.6.0 various warnings

diff --git a/fpicker/source/unx/kde/kdecommandthread.cxx b/fpicker/source/unx/kde/kdecommandthread.cxx
index 3e7df60..499c3ad 100644
--- a/fpicker/source/unx/kde/kdecommandthread.cxx
+++ b/fpicker/source/unx/kde/kdecommandthread.cxx
@@ -26,6 +26,8 @@
  *
  ************************************************************************/
 
+#include <cstddef>
+
 #include <kdecommandthread.hxx>
 
 #include <qstringlist.h>
diff --git a/fpicker/source/unx/kde/kdefilepicker.cxx b/fpicker/source/unx/kde/kdefilepicker.cxx
index 35e60d2..0af35dc 100644
--- a/fpicker/source/unx/kde/kdefilepicker.cxx
+++ b/fpicker/source/unx/kde/kdefilepicker.cxx
@@ -26,6 +26,8 @@
  *
  ************************************************************************/
 
+#include <cstddef>
+
 #include <kdecommandthread.hxx>
 #include <kdefilepicker.hxx>
 
diff --git a/fpicker/source/unx/kde/kdefilepicker.hxx b/fpicker/source/unx/kde/kdefilepicker.hxx
index d0e0330..4d545eb 100644
--- a/fpicker/source/unx/kde/kdefilepicker.hxx
+++ b/fpicker/source/unx/kde/kdefilepicker.hxx
@@ -29,6 +29,8 @@
 #ifndef _KDEFILEPICKER_HXX_
 #define _KDEFILEPICKER_HXX_
 
+#include <cstddef>
+
 #include <kfiledialog.h>
 #include <kfilefiltercombo.h>
 
diff --git a/fpicker/source/unx/kde/kdefpmain.cxx b/fpicker/source/unx/kde/kdefpmain.cxx
index 002eb80..2300fe6 100644
--- a/fpicker/source/unx/kde/kdefpmain.cxx
+++ b/fpicker/source/unx/kde/kdefpmain.cxx
@@ -26,6 +26,8 @@
  *
  ************************************************************************/
 
+#include <cstddef>
+
 #include <kdemodalityfilter.hxx>
 #include <kdefilepicker.hxx>
 #include <kdecommandthread.hxx>
diff --git a/fpicker/source/unx/kde/kdemodalityfilter.cxx b/fpicker/source/unx/kde/kdemodalityfilter.cxx
index 99fbf92..5aeddb0 100644
--- a/fpicker/source/unx/kde/kdemodalityfilter.cxx
+++ b/fpicker/source/unx/kde/kdemodalityfilter.cxx
@@ -26,6 +26,8 @@
  *
  ************************************************************************/
 
+#include <cstddef>
+
 #include <kdemodalityfilter.hxx>
 
 #include <kapplication.h>
commit 135cce3ab24149d0f30ac0afd907c0ecf06765ec
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Jan 23 20:52:54 2011 +0000

    WaE: gcc 4.6.0 various warnings

diff --git a/sfx2/inc/sfx2/docfile.hxx b/sfx2/inc/sfx2/docfile.hxx
index 64145b6..226aef8 100644
--- a/sfx2/inc/sfx2/docfile.hxx
+++ b/sfx2/inc/sfx2/docfile.hxx
@@ -188,7 +188,6 @@ public:
     void                SetDataAvailableLink( const Link& rLink );
     Link                GetDataAvailableLink( ) const;
 
-    sal_uInt32          GetMIMEAndRedirect( String& );
     sal_uInt32          GetErrorCode() const;
     sal_uInt32          GetError() const
                         { return ERRCODE_TOERROR(GetErrorCode()); }
diff --git a/sfx2/inc/sfx2/sfxhtml.hxx b/sfx2/inc/sfx2/sfxhtml.hxx
index 7d52f34..6a24421 100644
--- a/sfx2/inc/sfx2/sfxhtml.hxx
+++ b/sfx2/inc/sfx2/sfxhtml.hxx
@@ -99,12 +99,6 @@ protected:
     void StartFileDownload( const String& rURL, int nToken,
                             SfxObjectShell *pSh=0 );
 
-    // Ermittelnd des MIME-Types eines zuvor downloadeten Files. Kann nur
-    // unmittelbar vor FinishFileDownload aufgerufen werden, nie aber
-    // danach.
-
-    BOOL GetFileDownloadMIME( String& rMime );
-
     // Beenden eines asynchronen File-Downloads. Gibt TRUE zurueck, wenn
     // der Download geklappt hat. Das gelesene File befindet sich dann in
     // dem uebergeben String.
diff --git a/sfx2/source/appl/appcfg.cxx b/sfx2/source/appl/appcfg.cxx
index 3d5962e..d450933 100644
--- a/sfx2/source/appl/appcfg.cxx
+++ b/sfx2/source/appl/appcfg.cxx
@@ -524,7 +524,6 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
     const SfxPoolItem *pItem = 0;
     SfxItemPool &rPool = GetPool();
     BOOL bResetSession = FALSE;
-    BOOL bProxiesModified = FALSE;
 
     SvtSaveOptions aSaveOptions;
     SvtUndoOptions aUndoOptions;
@@ -749,7 +748,6 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
         DBG_ASSERT( pItem->ISA(SfxUInt16Item), "UInt16Item expected" );
         aInetOptions.SetProxyType((SvtInetOptions::ProxyType)( (const SfxUInt16Item*)pItem )->GetValue());
         bResetSession = TRUE;
-        bProxiesModified = TRUE;
     }
 
     if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_HTTP_PROXY_NAME ), TRUE, &pItem ) )
@@ -757,35 +755,30 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
         DBG_ASSERT( pItem->ISA(SfxStringItem), "StringItem expected" );
         aInetOptions.SetProxyHttpName( ((const SfxStringItem *)pItem)->GetValue() );
         bResetSession = TRUE;
-        bProxiesModified = TRUE;
     }
     if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_HTTP_PROXY_PORT ), TRUE, &pItem ) )
     {
         DBG_ASSERT( pItem->ISA(SfxInt32Item), "Int32Item expected" );
         aInetOptions.SetProxyHttpPort( ( (const SfxInt32Item*)pItem )->GetValue() );
         bResetSession = TRUE;
-        bProxiesModified = TRUE;
     }
     if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_FTP_PROXY_NAME ), TRUE, &pItem ) )
     {
         DBG_ASSERT( pItem->ISA(SfxStringItem), "StringItem expected" );
         aInetOptions.SetProxyFtpName( ((const SfxStringItem *)pItem)->GetValue() );
         bResetSession = TRUE;
-        bProxiesModified = TRUE;
     }
     if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_FTP_PROXY_PORT ), TRUE, &pItem ) )
     {
         DBG_ASSERT( pItem->ISA(SfxInt32Item), "Int32Item expected" );
         aInetOptions.SetProxyFtpPort( ( (const SfxInt32Item*)pItem )->GetValue() );
         bResetSession = TRUE;
-        bProxiesModified = TRUE;
     }
     if ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_NOPROXY, TRUE, &pItem))
     {
         DBG_ASSERT(pItem->ISA(SfxStringItem), "StringItem expected");
         aInetOptions.SetProxyNoProxy(((const SfxStringItem *)pItem)->GetValue());
         bResetSession = TRUE;
-        bProxiesModified = TRUE;
     }
 
     // Secure-Referers
diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx
index 55967a1..7396aa4 100644
--- a/sfx2/source/appl/appserv.cxx
+++ b/sfx2/source/appl/appserv.cxx
@@ -335,7 +335,6 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq )
         case SID_SAVEDOCS:
         {
             BOOL bOK = TRUE;
-            BOOL bTmpDone = TRUE;
             for ( SfxObjectShell *pObjSh = SfxObjectShell::GetFirst();
                   pObjSh;
                   pObjSh = SfxObjectShell::GetNext( *pObjSh ) )
@@ -345,7 +344,6 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq )
                 {
                     pObjSh->ExecuteSlot( aReq );
                     SfxBoolItem *pItem = PTR_CAST( SfxBoolItem, aReq.GetReturnValue() );
-                    bTmpDone = aReq.IsDone();
                     if ( !pItem || !pItem->GetValue() )
                         bOK = FALSE;
                 }
diff --git a/sfx2/source/bastyp/progress.cxx b/sfx2/source/bastyp/progress.cxx
index d4c7f14..9225093 100644
--- a/sfx2/source/bastyp/progress.cxx
+++ b/sfx2/source/bastyp/progress.cxx
@@ -366,8 +366,6 @@ BOOL SfxProgress::SetState
 
     if( pImp->pActiveProgress ) return TRUE;
 
-    // neuen Wert "ubernehmen
-    BOOL bOver=FALSE;
     nVal = nNewVal;
 
     // neuer Range?
@@ -376,7 +374,6 @@ BOOL SfxProgress::SetState
         DBG( DbgOutf( "SfxProgress: range changed from %lu to %lu",
                       pImp->nMax, nNewRange ) );
         pImp->nMax = nNewRange;
-        bOver = TRUE;
     }
 
     if ( !pImp->xStatusInd.is() )
diff --git a/sfx2/source/bastyp/sfxhtml.cxx b/sfx2/source/bastyp/sfxhtml.cxx
index c0d97a0..3360573 100644
--- a/sfx2/source/bastyp/sfxhtml.cxx
+++ b/sfx2/source/bastyp/sfxhtml.cxx
@@ -288,12 +288,6 @@ void SfxHTMLParser::StartFileDownload( const String& rURL, int nToken,
     }
 }
 
-BOOL SfxHTMLParser::GetFileDownloadMIME( String& rMIME )
-{
-    return pDLMedium && pDLMedium->GetErrorCode()==0 &&
-           pDLMedium->GetMIMEAndRedirect(rMIME)==0;
-}
-
 BOOL SfxHTMLParser::FinishFileDownload( String& rStr )
 {
     String aStr;
@@ -315,17 +309,6 @@ BOOL SfxHTMLParser::FinishFileDownload( String& rStr )
                         ? (xub_StrLen)aStream.Tell()
                         : STRING_MAXLEN;
 
-        // TODO: untested!!!
-        rtl_TextEncoding eEnc =
-            GetExtendedCompatibilityTextEncoding( RTL_TEXTENCODING_ISO_8859_1 );
-        String sMime;
-        if( pDLMedium->GetMIMEAndRedirect( sMime ) == 0 )
-        {
-            rtl_TextEncoding eMimeEnc = GetEncodingByMIME( sMime );
-            if( RTL_TEXTENCODING_DONTKNOW != eMimeEnc )
-                eEnc = eMimeEnc;
-        }
-
         ByteString sBuffer;
         sal_Char* pBuffer = sBuffer.AllocBuffer(nLen);
         aStream.Seek( 0 );
diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx
index 4adc4e4..0ef73d9 100644
--- a/sfx2/source/control/dispatch.cxx
+++ b/sfx2/source/control/dispatch.cxx
@@ -1112,7 +1112,6 @@ sal_uInt16 SfxDispatcher::ExecuteFunction( sal_uInt16 nSlot, SfxPoolItem **pArgs
             eCall = SFX_CALLMODE_ASYNCHRON;
         else if ( pSlot->GetMode() & SFX_SLOT_ASYNCHRON )
             eCall = SFX_CALLMODE_ASYNCHRON;
-        sal_Bool bDone = sal_False;
         if ( pArgs && *pArgs )
         {
             SfxAllItemSet aSet( pShell->GetPool() );
@@ -1120,13 +1119,11 @@ sal_uInt16 SfxDispatcher::ExecuteFunction( sal_uInt16 nSlot, SfxPoolItem **pArgs
                 MappedPut_Impl( aSet, **pArg );
             SfxRequest aReq( nSlot, eCall, aSet );
             _Execute( *pShell, *pSlot, aReq, eCall );
-            bDone = aReq.IsDone();
         }
         else
         {
             SfxRequest aReq( nSlot, eCall, pShell->GetPool() );
             _Execute( *pShell, *pSlot, aReq, eCall );
-            bDone = aReq.IsDone();
         }
     }
 
@@ -1169,10 +1166,8 @@ sal_uInt16 SfxDispatcher::ExecuteFunction( sal_uInt16 nSlot, const SfxItemSet& r
             eCall = SFX_CALLMODE_ASYNCHRON;
         else if ( pSlot->GetMode() & SFX_SLOT_ASYNCHRON )
             eCall = SFX_CALLMODE_ASYNCHRON;
-        sal_Bool bDone = sal_False;
-            SfxRequest aReq( nSlot, eCall, rArgs );
-            _Execute( *pShell, *pSlot, aReq, eCall );
-            bDone = aReq.IsDone();
+        SfxRequest aReq( nSlot, eCall, rArgs );
+        _Execute( *pShell, *pSlot, aReq, eCall );
     }
 
     return nRet;
diff --git a/sfx2/source/control/statcach.cxx b/sfx2/source/control/statcach.cxx
index 41eafeb..94fcde6 100644
--- a/sfx2/source/control/statcach.cxx
+++ b/sfx2/source/control/statcach.cxx
@@ -388,7 +388,6 @@ void SfxStateCache::SetVisibleState( BOOL bShow )
 {
     SfxItemState		eState( SFX_ITEM_AVAILABLE );
     const SfxPoolItem*	pState( NULL );
-    sal_Bool            bNotify( sal_False );
     sal_Bool            bDeleteItem( sal_False );
 
     if ( bShow != bItemVisible )
@@ -405,7 +404,6 @@ void SfxStateCache::SetVisibleState( BOOL bShow )
                 pState = pLastItem;
 
             eState = eLastState;
-            bNotify = ( pState != 0 );
         }
         else
         {
diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index 8c15a25..c5a2a16 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -743,7 +743,6 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util
             aInternalSet.Put( SfxUnoFrameItem( SID_FILLFRAME, xFrameRef ) );
 
         sal_Bool bSuccess = sal_False;
-        sal_Bool bFailure = sal_False;
         const SfxPoolItem* pItem = NULL;
         SfxShell* pShell( 0 );
         // #i102619# Retrieve metric from shell before execution - the shell could be destroyed after execution 
@@ -784,7 +783,6 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util
                         pDispatcher->GetBindings()->Execute_Impl( aReq, pSlot, pShell );
                         pItem = aReq.GetReturnValue();
                         bSuccess = aReq.IsDone() || pItem != NULL;
-                        bFailure = aReq.IsCancelled();
                         if ( bVBARequest )
                         {
                             SFX_REQUEST_ARG( aReq, pDlgRet, SfxBoolItem, SID_DIALOG_RETURN, FALSE );
@@ -834,11 +832,8 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util
             ::com::sun::star::frame::DispatchResultEvent aEvent;
             if ( bSuccess )
                 aEvent.State = com::sun::star::frame::DispatchResultState::SUCCESS;
-//            else if ( bFailure )
             else
                 aEvent.State = com::sun::star::frame::DispatchResultState::FAILURE;
-//            else
-//                aEvent.State = com::sun::star::frame::DispatchResultState::DONTKNOW;
 
             aEvent.Source = (::com::sun::star::frame::XDispatch*) pDispatch;
             if ( bSuccess && pItem && !pItem->ISA(SfxVoidItem) )
diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx
index 9e404e8..28a5c19 100644
--- a/sfx2/source/dialog/dinfdlg.cxx
+++ b/sfx2/source/dialog/dinfdlg.cxx
@@ -2077,7 +2077,7 @@ void CustomPropertiesWindow::AddLine( const ::rtl::OUString& sName, Any& rAny )
     SvtSysLocale aSysLocale;
     const LocaleDataWrapper& rLocaleWrapper = aSysLocale.GetLocaleData();
     pNewLine->m_aNameBox.SetText( sName );
-    sal_Int32 nType = CUSTOM_TYPE_UNKNOWN;
+    sal_IntPtr nType = CUSTOM_TYPE_UNKNOWN;
     String sValue;
 
     if ( rAny >>= nTmpValue )
diff --git a/sfx2/source/dialog/dockwin.cxx b/sfx2/source/dialog/dockwin.cxx
index d370082..3e1ddaf 100644
--- a/sfx2/source/dialog/dockwin.cxx
+++ b/sfx2/source/dialog/dockwin.cxx
@@ -823,11 +823,8 @@ void SfxDockingWindow::EndDocking( const Rectangle& rRect, BOOL bFloatMode )
 
     SfxWorkWindow *pWorkWin = pBindings->GetWorkWindow_Impl();
     BOOL bReArrange = FALSE;
-    SfxChildIdentifier eIdent = SFX_CHILDWIN_DOCKINGWINDOW;
     if ( pImp->bSplitable )
     {
-        eIdent = SFX_CHILDWIN_SPLITWINDOW;
-
         // Wenn sich das Alignment "andert und das Fenster befindet sich
         // im angedockten Zustand in einem SplitWindow, mu\s umgemeldet werden
         // Wenn neu angedockt wird, machen PrepareToggleFloatingMode()
diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx
index 9b5bdfe..416f9ce 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -2298,30 +2298,9 @@ void FileDialogHelper_Impl::SetContext( FileDialogHelper::Context _eNewContext )
 {
     meContext = _eNewContext;
 
-    sal_Int32		nNewHelpId = 0;
-    OUString		aConfigId;
-
-    switch( _eNewContext )
-    {
-// #104952#	dependency to SVX not allowed! When used again, another solution has to be found
-//		case FileDialogHelper::SW_INSERT_GRAPHIC:
-//		case FileDialogHelper::SC_INSERT_GRAPHIC:
-//		case FileDialogHelper::SD_INSERT_GRAPHIC:		nNewHelpId = SID_INSERT_GRAPHIC;		break;
-        case FileDialogHelper::SW_INSERT_SOUND:
-        case FileDialogHelper::SC_INSERT_SOUND:
-        case FileDialogHelper::SD_INSERT_SOUND:			nNewHelpId = SID_INSERT_SOUND;			break;
-        case FileDialogHelper::SW_INSERT_VIDEO:
-        case FileDialogHelper::SC_INSERT_VIDEO:
-        case FileDialogHelper::SD_INSERT_VIDEO:			nNewHelpId = SID_INSERT_VIDEO;			break;
-              default: break;
-    }
-
-    const OUString*	pConfigId = GetLastFilterConfigId( _eNewContext );
+    const OUString* pConfigId = GetLastFilterConfigId( _eNewContext );
     if( pConfigId )
         LoadLastUsedFilter( *pConfigId );
-
-//	if( nNewHelpId )
-//		this->setDialogHelpId( nNewHelpId );
 }
 
 // ------------------------------------------------------------------------
diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index 44469f0..3848ac7 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -2358,7 +2358,8 @@ void SfxMedium::GetMedium_Impl()
 
         pImp->bDownloadDone = sal_True;
         pImp->aDoneLink.ClearPendingCall();
-        pImp->aDoneLink.Call( (void*) GetError() );
+        sal_uIntPtr nError = GetError();
+        pImp->aDoneLink.Call( (void*)nError );
     }
 }
 
@@ -2967,12 +2968,10 @@ SfxMedium::SfxMedium( const ::com::sun::star::uno::Sequence< ::com::sun::star::b
         aFilterName = pFilterNameItem->GetValue();
     pFilter = SFX_APP()->GetFilterMatcher().GetFilter4FilterName( aFilterName );
 
-    sal_Bool bSalvage = sal_False;
     SFX_ITEMSET_ARG( pSet, pSalvageItem, SfxStringItem, SID_DOC_SALVAGE, sal_False );
     if( pSalvageItem )
     {
         // QUESTION: there is some treatment of Salvage in Init_Impl; align!
-        bSalvage = sal_True;
         if ( pSalvageItem->GetValue().Len() )
         {
             // if an URL is provided in SalvageItem that means that the FileName refers to a temporary file
@@ -3095,39 +3094,6 @@ const String& SfxMedium::GetPreRedirectedURL() const
 {
     return pImp->aPreRedirectionURL;
 }
-//----------------------------------------------------------------
-
-sal_uInt32 SfxMedium::GetMIMEAndRedirect( String& /*rName*/ )
-{
-/* dv !!!! not needed any longer ?
-    INetProtocol eProt = GetURLObject().GetProtocol();
-    if( eProt == INET_PROT_FTP && SvBinding::ShouldUseFtpProxy( GetURLObject().GetMainURL( INetURLObject::NO_DECODE ) ) )
-    {
-        Any aAny( UCB_Helper::GetProperty( GetContent(), WID_FLAG_IS_FOLDER ) );
-        sal_Bool bIsFolder = FALSE;
-        if ( ( aAny >>= bIsFolder ) && bIsFolder )
-            return ERRCODE_NONE;
-    }
-
-    GetMedium_Impl();
-    if( !eError && pImp->xBinding.Is() )
-    {
-        eError = pImp->xBinding->GetMimeType( rName );
-
-        // Wir koennen keine Parameter wie CharSets usw.
-        rName = rName.GetToken( 0, ';' );
-        if( !eError )
-        {
-            if( !pImp->aPreRedirectionURL.Len() )
-                pImp->aPreRedirectionURL = aLogicName;
-            SetName( pImp->xBinding->GetRedirectedURL() );
-        }
-        pImp->aExpireTime = pImp->xBinding->GetExpireDateTime();
-    }
-    return eError;
-*/
-    return 0;
-}
 
 //----------------------------------------------------------------
 
diff --git a/sfx2/source/doc/objcont.cxx b/sfx2/source/doc/objcont.cxx
index 94489c4..4dd1601 100644
--- a/sfx2/source/doc/objcont.cxx
+++ b/sfx2/source/doc/objcont.cxx
@@ -683,7 +683,6 @@ BOOL SfxObjectShell::Print
             SetOrganizerSearchMask(pStylePool);
             SfxStyleSheetIterator* pIter = pStylePool->CreateIterator(
                 pStylePool->GetSearchFamily(), pStylePool->GetSearchMask() );
-            USHORT nStyles = pIter->Count();
             SfxStyleSheetBase *pStyle = pIter->First();
             if ( !pStyle )
                 return TRUE;
@@ -713,7 +712,6 @@ BOOL SfxObjectShell::Print
             aOutPos.Y() += nTextHeight;
             aOutPos.Y() += nTextHeight/2;
             aFont.SetSize(Size(0, 35)); // 10pt
-            nStyles = 1;
             while(pStyle)
             {
                 // print template name
diff --git a/sfx2/source/doc/objstor.cxx b/sfx2/source/doc/objstor.cxx
index 69861e3..be127c5 100644
--- a/sfx2/source/doc/objstor.cxx
+++ b/sfx2/source/doc/objstor.cxx
@@ -2587,6 +2587,7 @@ sal_Bool SfxObjectShell::DoSave_Impl( const SfxItemSet* pArgs )
         sal_Bool bOpen( sal_False );
         bOpen = DoSaveCompleted( pMediumTmp );
         DBG_ASSERT(bOpen,"Fehlerbehandlung fuer DoSaveCompleted nicht implementiert");
+        (void)bOpen;
     }
     else
     {
@@ -2915,6 +2916,7 @@ sal_Bool SfxObjectShell::PreDoSaveAs_Impl
                 BOOL bRet( FALSE );
                 bRet = DoSaveCompleted( pMedium );
                 DBG_ASSERT( bRet, "Error in DoSaveCompleted, can't be handled!");
+                (void)bRet;
             }
 
             // TODO/LATER: disconnect the new file from the storage for the case when pure saving is done
diff --git a/sfx2/source/doc/objxtor.cxx b/sfx2/source/doc/objxtor.cxx
index a5fe210..eb25b3f 100644
--- a/sfx2/source/doc/objxtor.cxx
+++ b/sfx2/source/doc/objxtor.cxx
@@ -616,7 +616,6 @@ sal_uInt16 SfxObjectShell::PrepareClose
     SfxViewFrame *pFrame = SfxObjectShell::Current() == this
         ? SfxViewFrame::Current() : SfxViewFrame::GetFirst( this );
 
-    sal_Bool bClose = sal_False;
     if ( bUI && IsModified() && pFrame )
     {
         // minimierte restoren
@@ -663,8 +662,6 @@ sal_uInt16 SfxObjectShell::PrepareClose
 
             if ( !pPoolItem || pPoolItem->ISA(SfxVoidItem) || ( pPoolItem->ISA(SfxBoolItem) && !( (const SfxBoolItem*) pPoolItem )->GetValue() ) )
                 return sal_False;
-            else
-                bClose = sal_True;
         }
         else if ( RET_CANCEL == nRet )
             // abgebrochen
@@ -673,11 +670,6 @@ sal_uInt16 SfxObjectShell::PrepareClose
         {
             return RET_NEWTASK;
         }
-        else
-        {
-            // Bei Nein nicht noch Informationlost
-            bClose = sal_True;
-        }
     }
 
     pImp->bPreparedForClose = sal_True;
diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx
index 68f3f61..2ed1222 100644
--- a/sfx2/source/doc/sfxbasemodel.cxx
+++ b/sfx2/source/doc/sfxbasemodel.cxx
@@ -3362,7 +3362,6 @@ void SAL_CALL SfxBaseModel::setVisualAreaSize( sal_Int64 nAspect, const awt::Siz
         Size aWinSize = pWindow->GetSizePixel();
         awt::Size aCurrent = getVisualAreaSize( nAspect );
         Size aDiff( aSize.Width-aCurrent.Width, aSize.Height-aCurrent.Height );
-        Size aWrongDiff = OutputDevice::LogicToLogic( aDiff , m_pData->m_pObjectShell->GetMapUnit(), pWindow->GetMapMode() );
         aDiff = pViewFrm->GetViewShell()->GetWindow()->LogicToPixel( aDiff );
         aWinSize.Width() += aDiff.Width();
         aWinSize.Height() += aDiff.Height();
diff --git a/sfx2/source/view/viewprn.cxx b/sfx2/source/view/viewprn.cxx
index ce2093c..533bb91 100644
--- a/sfx2/source/view/viewprn.cxx
+++ b/sfx2/source/view/viewprn.cxx
@@ -490,34 +490,6 @@ IMPL_LINK( SfxDialogExecutor_Impl, Execute, void *, EMPTYARG )
 
 //-------------------------------------------------------------------------
 
-BOOL UseStandardPrinter_Impl( Window* /*pParent*/, SfxPrinter* pDocPrinter )
-{
-    // Optionen abfragen, ob gewarnt werden soll (Doc uebersteuert App)
-    BOOL bWarn = FALSE;
-    const SfxItemSet *pDocOptions = &pDocPrinter->GetOptions();
-    if ( pDocOptions )
-    {
-        USHORT nWhich = pDocOptions->GetPool()->GetWhich(SID_PRINTER_NOTFOUND_WARN);
-        const SfxBoolItem* pBoolItem = NULL;
-        pDocPrinter->GetOptions().GetItemState( nWhich, FALSE, (const SfxPoolItem**) &pBoolItem );
-        if ( pBoolItem )
-            bWarn = pBoolItem->GetValue();
-    }
-/*
-    // ggf. den User fragen
-    if ( bWarn )
-    {
-        // Geht nicht mehr ohne OrigJobSetup!
-        String aTmp( SfxResId( STR_PRINTER_NOTAVAIL ) );
-        QueryBox aBox( pParent, WB_OK_CANCEL | WB_DEF_OK, aTmp );
-        return RET_OK == aBox.Execute();
-    }
-*/
-    // nicht gewarnt => einfach so den StandardDrucker nehmen
-    return TRUE;
-}
-//-------------------------------------------------------------------------
-
 SfxPrinter* SfxViewShell::SetPrinter_Impl( SfxPrinter *pNewPrinter )
 
 /*  Interne Methode zum Setzen der Unterschiede von 'pNewPrinter' zum
@@ -824,13 +796,6 @@ void SfxViewShell::ExecPrint_Impl( SfxRequest &rReq )
                     ErrorBox( NULL, WB_OK | WB_DEF_OK, String( SfxResId( STR_NODEFPRINTER ) ) ).Execute();
             }
 
-            if ( !pPrinter->IsOriginal() && rReq.GetArgs() && !UseStandardPrinter_Impl( NULL, pPrinter ) )
-            {
-                // printer is not available, but standard printer should not be used
-                rReq.SetReturnValue(SfxBoolItem(0,FALSE));
-                break;
-            }
-
             // FIXME: printer isn't used for printing anymore!
             if( pPrinter->IsPrinting() )
             {


More information about the Libreoffice-commits mailing list