[Libreoffice-commits] .: regexp/source svl/source svtools/source toolkit/source vcl/aqua vcl/unx

Takeshi Abe tabe at kemper.freedesktop.org
Fri Jun 17 08:05:53 PDT 2011


 regexp/source/reclass.cxx             |    7 -------
 svl/source/numbers/zformat.cxx        |   17 +----------------
 svl/source/svdde/ddesvr.cxx           |   29 -----------------------------
 svtools/source/contnr/imivctl1.cxx    |    7 -------
 toolkit/source/layout/vcl/wbutton.cxx |    4 ----
 vcl/aqua/source/gdi/salatslayout.cxx  |    2 --
 vcl/unx/kde4/KDESalFrame.cxx          |    2 --
 7 files changed, 1 insertion(+), 67 deletions(-)

New commits:
commit 11c610909993e9eaa39056da929cc83be1516445
Author: Takeshi Abe <tabe at fixedpoint.jp>
Date:   Sat Jun 18 00:00:52 2011 +0900

    remove dead code

diff --git a/regexp/source/reclass.cxx b/regexp/source/reclass.cxx
index 448dfe9..da85387 100644
--- a/regexp/source/reclass.cxx
+++ b/regexp/source/reclass.cxx
@@ -1362,13 +1362,6 @@ Regexpr::regex_compile()
       case (sal_Unicode)')':
     goto normal_backslash;
 
-    // unreachable (after goto):
-#if 0
-    if (COMPILE_STACK_EMPTY) {
-      FREE_STACK_RETURN(REG_ERPAREN);
-    }
-#endif
-
       handle_close:
     if (fixup_alt_jump) {
       /* Push a dummy failure point at the end of the
diff --git a/svl/source/numbers/zformat.cxx b/svl/source/numbers/zformat.cxx
index 16fc5ec..dbe5ced 100644
--- a/svl/source/numbers/zformat.cxx
+++ b/svl/source/numbers/zformat.cxx
@@ -2007,15 +2007,7 @@ sal_Bool SvNumberformat::GetOutputString(String& sString,
     }
     return sal_False;
 }
-/*
-void SvNumberformat::GetNextFareyNumber(sal_uLong nPrec, sal_uLong x0, sal_uLong x1,
-                                        sal_uLong y0, sal_uLong y1,
-                                        sal_uLong& x2,sal_uLong& y2)
-{
-    x2 = ((y0+nPrec)/y1)*x1 - x0;
-    y2 = ((y0+nPrec)/y1)*y1 - y0;
-}
-*/
+
 sal_uLong SvNumberformat::ImpGGT(sal_uLong x, sal_uLong y)
 {
     if (y == 0)
@@ -2417,7 +2409,6 @@ sal_Bool SvNumberformat::GetOutputString(double fNumber,
                     {
                         sal_uLong x2 = ((y0+nBasis)/y1)*x1 - x0; // naechste Farey-Zahl
                         sal_uLong y2 = ((y0+nBasis)/y1)*y1 - y0;
-//                      GetNextFareyNumber(nBasis, x0, x1, y0, y1, x2, y2);
                         x0 = x1;
                         y0 = y1;
                         x1 = x2;
@@ -2446,11 +2437,6 @@ sal_Bool SvNumberformat::GetOutputString(double fNumber,
                 else                                    // grosse Nenner
                 {                                       // 0,1234->123/1000
                     sal_uLong nGgt;
-/*
-                    nDiv = nBasis+1;
-                    nFrac = ((sal_uLong)floor(0.5 + fNumber *
-                                    pow(10.0,rInfo.nCntExp)));
-*/
                     nDiv = 10000000;
                     nFrac = ((sal_uLong)floor(0.5 + fNumber * 10000000.0));
                     nGgt = ImpGGT(nDiv, nFrac);
@@ -4421,7 +4407,6 @@ String SvNumberformat::GetMappedFormatstring(
                         case NF_SYMBOLTYPE_CALDEL :
                             if ( pStr[j+1].EqualsAscii("buddhist") )
                             {
-                                //aStr.InsertAscii( "[$-", aStr.Len() );
                                 aStr.InsertAscii( "[$-", 0 );
                                 if ( rNum.IsSet() && rNum.GetNatNum() == 1 &&
                                         MsLangId::getRealLanguage( rNum.GetLang() ) ==
diff --git a/svl/source/svdde/ddesvr.cxx b/svl/source/svdde/ddesvr.cxx
index 8546688..12b217c 100644
--- a/svl/source/svdde/ddesvr.cxx
+++ b/svl/source/svdde/ddesvr.cxx
@@ -88,7 +88,6 @@ HDDEDATA CALLBACK _export DdeInternal::SvrCallback(
         {
             int nTopics = 0;
 
-#if 1
             TCHAR chTopicBuf[250];
             if( hText1 )
                 DdeQueryString( pInst->hDdeInstSvr, hText1, chTopicBuf,
@@ -117,20 +116,6 @@ HDDEDATA CALLBACK _export DdeInternal::SvrCallback(
                 }
             }
 
-#else
-            for( pService = rAll.First();pService;pService = rAll.Next() )
-            {
-                if ( !hText2 || ( *pService->pName == hText2 ) )
-                {
-                    std::vector<DdeTopic*>::const_iterator iter;
-                    for (iter = pService->aTopics.begin(); iter != pService->aTopics.end(); ++iter)
-                    {
-                        if ( !hText1 || iter->pName == hText1 )
-                            nTopics++;
-                    }
-                }
-            }
-#endif
             if( !nTopics )
                 return (HDDEDATA)NULL;
 
@@ -143,18 +128,6 @@ HDDEDATA CALLBACK _export DdeInternal::SvrCallback(
             {
                 if ( !hText2 || (*pService->pName == hText2 ) )
                 {
-#if 0
-                    for ( pTopic = pService->aTopics.First(); pTopic;
-                          pTopic = pService->aTopics.Next() )
-                    {
-                        if ( !hText1 || (*pTopic->pName == hText1) )
-                        {
-                            q->hszSvc   = *pService->pName;
-                            q->hszTopic = *pTopic->pName;
-                            q++;
-                        }
-                    }
-#else
                     String sTopics( pService->Topics() );
                     sal_uInt16 n = 0;
                     while( STRING_NOTFOUND != n )
@@ -173,8 +146,6 @@ HDDEDATA CALLBACK _export DdeInternal::SvrCallback(
                             }
                         }
                     }
-
-#endif
                 }
             }
 
diff --git a/svtools/source/contnr/imivctl1.cxx b/svtools/source/contnr/imivctl1.cxx
index e0ea76a..86b8e04 100644
--- a/svtools/source/contnr/imivctl1.cxx
+++ b/svtools/source/contnr/imivctl1.cxx
@@ -2754,15 +2754,8 @@ void SvxIconChoiceCtrl_Impl::Command( const CommandEvent& rCEvt )
         (rCEvt.GetCommand() == COMMAND_STARTAUTOSCROLL) ||
         (rCEvt.GetCommand() == COMMAND_AUTOSCROLL) )
     {
-#if 1
         if( HandleScrollCommand( rCEvt ) )
             return;
-#else
-        ScrollBar* pHor = aHorSBar.IsVisible() ? &aHorSBar : 0;
-        ScrollBar* pVer = aVerSBar.IsVisible() ? &aVerSBar : 0;
-        if( pView->HandleScrollCommand( rCEvt, pHor, pVer ) )
-            return;
-#endif
     }
 }
 
diff --git a/toolkit/source/layout/vcl/wbutton.cxx b/toolkit/source/layout/vcl/wbutton.cxx
index 5e303ad..96e6aeb 100644
--- a/toolkit/source/layout/vcl/wbutton.cxx
+++ b/toolkit/source/layout/vcl/wbutton.cxx
@@ -276,7 +276,6 @@ public:
         if ( !mxRadioButton.is() )
             return;
 
-#if 1
         // Have setState fire item event for
         // RadioGroups::RadioGroup::itemStateChanged ()
         ::RadioButton *r = static_cast<RadioButton*>(mpWindow)->GetRadioButton ();
@@ -284,9 +283,6 @@ public:
         r->EnableRadioCheck();
         mxRadioButton->setState( !!bCheck );
         r->EnableRadioCheck (state);
-#else
-        mxRadioButton->setState( !!bCheck );
-#endif
         fireToggle();
     }
 
diff --git a/vcl/aqua/source/gdi/salatslayout.cxx b/vcl/aqua/source/gdi/salatslayout.cxx
index 33ddf75..b1f92f8 100644
--- a/vcl/aqua/source/gdi/salatslayout.cxx
+++ b/vcl/aqua/source/gdi/salatslayout.cxx
@@ -1043,7 +1043,6 @@ bool ATSLayout::GetDeltaY() const
     if( mpDeltaY != NULL )
         return true;
 
-#if 1
     if( !maATSULayout )
         return false;
 
@@ -1069,7 +1068,6 @@ bool ATSLayout::GetDeltaY() const
         mpDeltaY = NULL;
         return false;
     }
-#endif
     
     return true;
 }
diff --git a/vcl/unx/kde4/KDESalFrame.cxx b/vcl/unx/kde4/KDESalFrame.cxx
index d179acf..2f809b3 100644
--- a/vcl/unx/kde4/KDESalFrame.cxx
+++ b/vcl/unx/kde4/KDESalFrame.cxx
@@ -88,8 +88,6 @@ static OUString readEntryUntranslated( KConfigGroup *pGroup, const char *pKey )
     return OUString::createFromAscii( (const char *) pGroup->readEntryUntranslated( pKey ).toAscii() );
 }
 
-#if 0
-#endif
 /** Helper function to add information to Font from QFont.
 
     Mostly grabbed from the Gtk+ vclplug (salnativewidgets-gtk.cxx).


More information about the Libreoffice-commits mailing list