[Libreoffice-commits] core.git: scripting/source sdext/source sd/source

Takeshi Abe tabe at fixedpoint.jp
Sun Aug 18 15:48:39 PDT 2013


 scripting/source/provider/MasterScriptProvider.cxx |    2 +-
 scripting/source/stringresource/stringresource.cxx |    2 +-
 sd/source/filter/eppt/pptx-epptooxml.cxx           |    4 ++--
 sd/source/ui/controller/slidelayoutcontroller.cxx  |   12 ++++++------
 sd/source/ui/dlg/gluectrl.cxx                      |    2 +-
 sd/source/ui/sidebar/LayoutMenu.cxx                |    8 ++++----
 sd/source/ui/toolpanel/LayoutMenu.cxx              |    8 ++++----
 sd/source/ui/view/viewoverlaymanager.cxx           |    4 ++--
 sdext/source/presenter/PresenterComponent.cxx      |    2 +-
 9 files changed, 22 insertions(+), 22 deletions(-)

New commits:
commit f4004429d339009bec6babe30becdc9c727940b8
Author: Takeshi Abe <tabe at fixedpoint.jp>
Date:   Mon Aug 19 07:45:55 2013 +0900

    Mark as const
    
    Change-Id: Ic81dd60fadecf72f25792903985f2b387df7a7a0

diff --git a/scripting/source/provider/MasterScriptProvider.cxx b/scripting/source/provider/MasterScriptProvider.cxx
index f7dca4d..cb3783f 100644
--- a/scripting/source/provider/MasterScriptProvider.cxx
+++ b/scripting/source/provider/MasterScriptProvider.cxx
@@ -903,7 +903,7 @@ OUString urihelper_getImplementationName( )
         "com.sun.star.script.provider.ScriptURIHelper");
 }
 
-static struct cppu::ImplementationEntry s_entries [] =
+static const struct cppu::ImplementationEntry s_entries [] =
     {
         {
             sp_create, sp_getImplementationName,
diff --git a/scripting/source/stringresource/stringresource.cxx b/scripting/source/stringresource/stringresource.cxx
index 253d77b..33a2e30 100644
--- a/scripting/source/stringresource/stringresource.cxx
+++ b/scripting/source/stringresource/stringresource.cxx
@@ -2986,7 +2986,7 @@ const Reference< ucb::XSimpleFileAccess3 > StringResourceWithLocationImpl::getFi
 // component export operations
 // =============================================================================
 
-static struct ::cppu::ImplementationEntry s_component_entries [] =
+static const struct ::cppu::ImplementationEntry s_component_entries [] =
 {
     {
         create_StringResourceImpl, getImplementationName_StringResourceImpl,
diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
index 2535689..ca78715 100644
--- a/sd/source/filter/eppt/pptx-epptooxml.cxx
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -142,7 +142,7 @@ struct PPTXLayoutInfo {
     const char* sType;
 };
 
-static PPTXLayoutInfo aLayoutInfo[LAYOUT_SIZE] = {
+static const PPTXLayoutInfo aLayoutInfo[LAYOUT_SIZE] = {
     { 20, "Blank Slide", "blank" },
     { 0, "Title Slide", "tx" },
     { 1, "Title, Content", "obj" },
@@ -2158,7 +2158,7 @@ OUString PowerPointExport::implGetImplementationName() const
 
 // UNO component
 
-static struct cppu::ImplementationEntry g_entries[] =
+static const struct cppu::ImplementationEntry g_entries[] =
 {
     {
         oox::core::PowerPointExport_createInstance,
diff --git a/sd/source/ui/controller/slidelayoutcontroller.cxx b/sd/source/ui/controller/slidelayoutcontroller.cxx
index 38626bb..8a3fd5e 100644
--- a/sd/source/ui/controller/slidelayoutcontroller.cxx
+++ b/sd/source/ui/controller/slidelayoutcontroller.cxx
@@ -97,13 +97,13 @@ struct snewfoil_value_info
     AutoLayout maAutoLayout;
 };
 
-static snewfoil_value_info notes[] =
+static const snewfoil_value_info notes[] =
 {
     {BMP_FOILN_01, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB, AUTOLAYOUT_NOTES},
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
-static snewfoil_value_info handout[] =
+static const snewfoil_value_info handout[] =
 {
     {BMP_FOILH_01, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT1},
     {BMP_FOILH_02, STR_AUTOLAYOUT_HANDOUT2, WritingMode_LR_TB, AUTOLAYOUT_HANDOUT2},
@@ -114,7 +114,7 @@ static snewfoil_value_info handout[] =
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
-static snewfoil_value_info standard[] =
+static const snewfoil_value_info standard[] =
 {
     {BMP_LAYOUT_EMPTY,    STR_AUTOLAYOUT_NONE,                 WritingMode_LR_TB, AUTOLAYOUT_NONE         },
     {BMP_LAYOUT_HEAD03,   STR_AUTOLAYOUT_TITLE,                WritingMode_LR_TB, AUTOLAYOUT_TITLE        },
@@ -131,7 +131,7 @@ static snewfoil_value_info standard[] =
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE}
 };
 
-static snewfoil_value_info v_standard[] =
+static const snewfoil_value_info v_standard[] =
 {
     // vertical
     {BMP_LAYOUT_VERTICAL02, STR_AL_VERT_TITLE_TEXT_CHART,      WritingMode_TB_RL, AUTOLAYOUT_VERTICAL_TITLE_TEXT_CHART       },
@@ -143,7 +143,7 @@ static snewfoil_value_info v_standard[] =
 
 // -----------------------------------------------------------------------
 
-static void fillLayoutValueSet( ValueSet* pValue, snewfoil_value_info* pInfo )
+static void fillLayoutValueSet( ValueSet* pValue, const snewfoil_value_info* pInfo )
 {
     Size aLayoutItemSize;
     for( ; pInfo->mnBmpResId; pInfo++ )
@@ -198,7 +198,7 @@ LayoutToolbarMenu::LayoutToolbarMenu( SlideLayoutController& rController, const
     mpLayoutSet1 = createEmptyValueSetControl();
     mpLayoutSet1->SetSelectHdl( LINK( this, LayoutToolbarMenu, SelectHdl ) );
 
-    snewfoil_value_info* pInfo = 0;
+    const snewfoil_value_info* pInfo = 0;
     sal_Int16 nColCount = 4;
     switch( eMode )
     {
diff --git a/sd/source/ui/dlg/gluectrl.cxx b/sd/source/ui/dlg/gluectrl.cxx
index b1f760e..e0d09ba 100644
--- a/sd/source/ui/dlg/gluectrl.cxx
+++ b/sd/source/ui/dlg/gluectrl.cxx
@@ -38,7 +38,7 @@ using namespace ::com::sun::star::frame;
 
 // at the moment, Joe only supports the methods specified below
 #define ESCDIR_COUNT 5
-static sal_uInt16 aEscDirArray[] =
+static const sal_uInt16 aEscDirArray[] =
 {
     SDRESC_SMART,
     SDRESC_LEFT,
diff --git a/sd/source/ui/sidebar/LayoutMenu.cxx b/sd/source/ui/sidebar/LayoutMenu.cxx
index 0e4b234..e55f7e1 100644
--- a/sd/source/ui/sidebar/LayoutMenu.cxx
+++ b/sd/source/ui/sidebar/LayoutMenu.cxx
@@ -77,14 +77,14 @@ struct snewfoil_value_info
     AutoLayout maAutoLayout;
 };
 
-static snewfoil_value_info notes[] =
+static const snewfoil_value_info notes[] =
 {
     {BMP_FOILN_01, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB,
      AUTOLAYOUT_NOTES},
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
-static snewfoil_value_info handout[] =
+static const snewfoil_value_info handout[] =
 {
     {BMP_FOILH_01, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB,
      AUTOLAYOUT_HANDOUT1},
@@ -101,7 +101,7 @@ static snewfoil_value_info handout[] =
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
-static snewfoil_value_info standard[] =
+static const snewfoil_value_info standard[] =
 {
     {BMP_LAYOUT_EMPTY, STR_AUTOLAYOUT_NONE, WritingMode_LR_TB,        AUTOLAYOUT_NONE},
     {BMP_LAYOUT_HEAD03, STR_AUTOLAYOUT_TITLE, WritingMode_LR_TB,       AUTOLAYOUT_TITLE},
@@ -624,7 +624,7 @@ void LayoutMenu::Fill (void)
     catch (RuntimeException&)
     {}
 
-    snewfoil_value_info* pInfo = NULL;
+    const snewfoil_value_info* pInfo = NULL;
     if (sCenterPaneViewName.equals(framework::FrameworkHelper::msNotesViewURL))
     {
         pInfo = notes;
diff --git a/sd/source/ui/toolpanel/LayoutMenu.cxx b/sd/source/ui/toolpanel/LayoutMenu.cxx
index 8f444a3..1e34584 100644
--- a/sd/source/ui/toolpanel/LayoutMenu.cxx
+++ b/sd/source/ui/toolpanel/LayoutMenu.cxx
@@ -117,14 +117,14 @@ struct snewfoil_value_info
     AutoLayout maAutoLayout;
 };
 
-static snewfoil_value_info notes[] =
+static const snewfoil_value_info notes[] =
 {
     {BMP_FOILN_01, STR_AUTOLAYOUT_NOTES, WritingMode_LR_TB,
      AUTOLAYOUT_NOTES},
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
-static snewfoil_value_info handout[] =
+static const snewfoil_value_info handout[] =
 {
     {BMP_FOILH_01, STR_AUTOLAYOUT_HANDOUT1, WritingMode_LR_TB,
      AUTOLAYOUT_HANDOUT1},
@@ -141,7 +141,7 @@ static snewfoil_value_info handout[] =
     {0, 0, WritingMode_LR_TB, AUTOLAYOUT_NONE},
 };
 
-static snewfoil_value_info standard[] =
+static const snewfoil_value_info standard[] =
 {
     {BMP_LAYOUT_EMPTY, STR_AUTOLAYOUT_NONE, WritingMode_LR_TB,        AUTOLAYOUT_NONE},
     {BMP_LAYOUT_HEAD03, STR_AUTOLAYOUT_TITLE, WritingMode_LR_TB,       AUTOLAYOUT_TITLE},
@@ -774,7 +774,7 @@ void LayoutMenu::Fill (void)
     catch (RuntimeException&)
     {}
 
-    snewfoil_value_info* pInfo = NULL;
+    const snewfoil_value_info* pInfo = NULL;
     if (sCenterPaneViewName.equals(framework::FrameworkHelper::msNotesViewURL))
     {
         pInfo = notes;
diff --git a/sd/source/ui/view/viewoverlaymanager.cxx b/sd/source/ui/view/viewoverlaymanager.cxx
index e834999..a0cc133 100644
--- a/sd/source/ui/view/viewoverlaymanager.cxx
+++ b/sd/source/ui/view/viewoverlaymanager.cxx
@@ -65,8 +65,8 @@ class ImageButtonHdl;
 
 // --------------------------------------------------------------------
 
-static sal_uInt16 gButtonSlots[] = { SID_INSERT_TABLE, SID_INSERT_DIAGRAM, SID_INSERT_GRAPHIC, SID_INSERT_AVMEDIA };
-static sal_uInt16 gButtonToolTips[] = { STR_INSERT_TABLE, STR_INSERT_CHART, STR_INSERT_PICTURE, STR_INSERT_MOVIE };
+static const sal_uInt16 gButtonSlots[] = { SID_INSERT_TABLE, SID_INSERT_DIAGRAM, SID_INSERT_GRAPHIC, SID_INSERT_AVMEDIA };
+static const sal_uInt16 gButtonToolTips[] = { STR_INSERT_TABLE, STR_INSERT_CHART, STR_INSERT_PICTURE, STR_INSERT_MOVIE };
 
 // --------------------------------------------------------------------
 
diff --git a/sdext/source/presenter/PresenterComponent.cxx b/sdext/source/presenter/PresenterComponent.cxx
index d7ab29d..bb428ba 100644
--- a/sdext/source/presenter/PresenterComponent.cxx
+++ b/sdext/source/presenter/PresenterComponent.cxx
@@ -30,7 +30,7 @@ using namespace osl;
 
 namespace sdext { namespace presenter {
 
-static struct ImplementationEntry gServiceEntries[] =
+static const struct ImplementationEntry gServiceEntries[] =
 {
     {
         PresenterProtocolHandler::Create,


More information about the Libreoffice-commits mailing list