officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu |    
5 
 sd/inc/app.hrc                                                           |    
2 
 sd/sdi/drviewsh.sdi                                                      |    
5 
 sd/sdi/sdraw.sdi                                                         |   
27 ---
 sd/source/ui/view/drviews1.cxx                                           |    
1 
 sd/source/ui/view/drviews7.cxx                                           |   
86 ----------
 sd/source/ui/view/drviewse.cxx                                           |   
13 -
 7 files changed, 3 insertions(+), 136 deletions(-)

New commits:
commit d30a44aff1fb049a71e4eb2612be65a735fbe918
Author: Philippe Jung <phil.j...@free.fr>
Date:   Wed Jul 8 19:59:58 2015 +0200

    Removal of SID_TITLE_MASTER related code
    
    i35731 fixed a bug by deprecating SID_TITLE_MASTER
    dispatch command in 2004.
    So the feature can not be called anymore since 2004.
    Ten years after, this changeset removes the code that could be
    considered as dead code.
    
    Change-Id: Ie212baf7ece2897578d2494030d790bcadd16f5f
    Reviewed-on: https://gerrit.libreoffice.org/16933
    Reviewed-by: Samuel Mehrbrodt <samuel.mehrbr...@cib.de>
    Tested-by: Samuel Mehrbrodt <samuel.mehrbr...@cib.de>

diff --git 
a/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu
index a569a11..10580cf 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/DrawImpressCommands.xcu
@@ -447,11 +447,6 @@
           <value xml:lang="en-US">~Notes Master</value>
         </prop>
       </node>
-      <node oor:name=".uno:TitleMasterPage" oor:op="replace">
-        <prop oor:name="Label" oor:type="xs:string">
-          <value xml:lang="en-US">~Title Slide Master</value>
-        </prop>
-      </node>
       <node oor:name=".uno:InsertPageQuick" oor:op="replace">
         <prop oor:name="Label" oor:type="xs:string">
           <value xml:lang="en-US">Insert Slide Direct</value>
diff --git a/sd/inc/app.hrc b/sd/inc/app.hrc
index 0b21cd0..f75757e 100644
--- a/sd/inc/app.hrc
+++ b/sd/inc/app.hrc
@@ -391,7 +391,7 @@
 #define SID_SLIDE_MASTERPAGE                (SID_SD_START+348)
 #define SID_HANDOUT_MASTERPAGE              (SID_SD_START+349)
 #define SID_NOTES_MASTERPAGE                (SID_SD_START+350)
-#define SID_TITLE_MASTERPAGE                (SID_SD_START+351)
+    // FREE
 #define SID_INSERTPAGE_QUICK                (SID_SD_START+352)
     // FREE
 #define SID_INSERT_FLD_PAGE_TITLE           (SID_SD_START+356)
diff --git a/sd/sdi/drviewsh.sdi b/sd/sdi/drviewsh.sdi
index 1d6a86d..682c7ec 100644
--- a/sd/sdi/drviewsh.sdi
+++ b/sd/sdi/drviewsh.sdi
@@ -150,11 +150,6 @@ interface ImpressEditView : DrawView
         ExecMethod = FuSupport ;
         StateMethod = GetMenuState ;
     ]
-    SID_TITLE_MASTERPAGE // deprecated, to be removed see issue #i35731#
-    [
-        ExecMethod = FuSupport ;
-        StateMethod = GetMenuState ;
-    ]
     SID_STYLE_FAMILY
     [
         ExecMethod = FuSupport ;
diff --git a/sd/sdi/sdraw.sdi b/sd/sdi/sdraw.sdi
index cda8bf8..fd0e8bc 100644
--- a/sd/sdi/sdraw.sdi
+++ b/sd/sdi/sdraw.sdi
@@ -6020,33 +6020,6 @@ SfxVoidItem TextToolbox SID_DRAWTBX_TEXT
     GroupId = GID_DRAWING;
 ]
 
-SfxVoidItem TitleMasterPage SID_TITLE_MASTERPAGE
-(SfxBoolItem Isactive ID_VAL_ISACTIVE)
-[
-    /* flags: */
-    AutoUpdate = FALSE,
-    Cachable = Cachable,
-    FastCall = FALSE,
-    HasCoreId = FALSE,
-    HasDialog = FALSE,
-    ReadOnlyDoc = TRUE,
-    Toggle = FALSE,
-    Container = FALSE,
-    RecordAbsolute = FALSE,
-    RecordPerSet;
-    Synchron;
-
-    /* status: */
-    SlotType = SfxBoolItem
-
-    /* config: */
-    AccelConfig = TRUE,
-    MenuConfig = TRUE,
-    StatusBarConfig = FALSE,
-    ToolBoxConfig = TRUE,
-    GroupId = GID_VIEW;
-]
-
 SfxBoolItem Torus SID_3D_TORUS
 
 [
diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx
index 3c510e5..8be1d79 100644
--- a/sd/source/ui/view/drviews1.cxx
+++ b/sd/source/ui/view/drviews1.cxx
@@ -486,7 +486,6 @@ void DrawViewShell::ChangeEditMode(EditMode eEMode, bool 
bIsLayerModeActive)
         Invalidate( SID_DELETE_MASTER_PAGE );
         Invalidate( SID_DELETE_PAGE );
         Invalidate( SID_SLIDE_MASTERPAGE );
-        Invalidate( SID_TITLE_MASTERPAGE );
         Invalidate( SID_NOTES_MASTERPAGE );
         Invalidate( SID_HANDOUT_MASTERPAGE );
         InvalidateWindows();
diff --git a/sd/source/ui/view/drviews7.cxx b/sd/source/ui/view/drviews7.cxx
index 63108ae..feaad5e 100644
--- a/sd/source/ui/view/drviews7.cxx
+++ b/sd/source/ui/view/drviews7.cxx
@@ -752,40 +752,6 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
         rSet.Put(SfxBoolItem(SID_NOTES_MASTERPAGE, false));
         rSet.Put(SfxBoolItem(SID_HANDOUT_MASTERPAGE, false));
 
-        if (mePageKind == PK_STANDARD &&
-            rSet.GetItemState(SID_TITLE_MASTERPAGE) == SfxItemState::DEFAULT)
-        {
-            // Is there a page with the AutoLayout "Title"?
-            bool bDisable = true;
-            sal_uInt16 i = 0;
-            sal_uInt16 nCount = GetDoc()->GetSdPageCount(PK_STANDARD);
-
-            while (i < nCount && bDisable)
-            {
-                SdPage* pPage = GetDoc()->GetSdPage(i, PK_STANDARD);
-
-                if (pPage->GetAutoLayout() == AUTOLAYOUT_TITLE)
-                {
-                    bDisable = false;
-                }
-
-                i++;
-            }
-
-            if (bDisable)
-            {
-                rSet.DisableItem(SID_TITLE_MASTERPAGE);
-            }
-            else
-            {
-                rSet.Put(SfxBoolItem(SID_TITLE_MASTERPAGE, false));
-            }
-        }
-        else
-        {
-            rSet.DisableItem(SID_TITLE_MASTERPAGE);
-        }
-
         rSet.DisableItem (SID_INSERT_MASTER_PAGE);
         rSet.DisableItem (SID_DELETE_MASTER_PAGE);
         rSet.DisableItem (SID_RENAME_MASTER_PAGE);
@@ -805,68 +771,16 @@ void DrawViewShell::GetMenuState( SfxItemSet &rSet )
             rSet.Put(SfxBoolItem(SID_NOTES_MASTERPAGE, false));
             rSet.Put(SfxBoolItem(SID_HANDOUT_MASTERPAGE, false));
 
-            if (rSet.GetItemState(SID_TITLE_MASTERPAGE) == 
SfxItemState::DEFAULT)
-            {
-                bool bCheck = false;
-                bool bDisable = true;
-                if( pPageView )
-                {
-                    SdPage* pMPage = dynamic_cast< SdPage* >( 
pPageView->GetPage() );
-
-                    sal_uInt16 i = 0;
-                    sal_uInt16 nCount = GetDoc()->GetSdPageCount(PK_STANDARD);
-
-                    // Is there a reference to the current master page from a 
page
-                    // with the AutoLayout "Title"?
-                    while (i < nCount && !bCheck && bDisable)
-                    {
-                        SdPage* pPage = GetDoc()->GetSdPage(i, PK_STANDARD);
-
-                        // page does reference the current master page
-                        if (pPage->GetAutoLayout() == AUTOLAYOUT_TITLE)
-                        {
-                            // a page does have a AutoLayout "Title"
-                            bDisable = false;
-
-                            SdPage& rRefMPage = 
static_cast<SdPage&>(pPage->TRG_GetMasterPage());
-
-                            if(&rRefMPage == pMPage)
-                            {
-                                // a page with the AutoLayout "Title" does 
reference
-                                // the current master page
-                                bCheck = true;
-                            }
-                        }
-
-                        i++;
-                    }
-                }
-
-                if (bCheck)
-                {
-                    rSet.Put(SfxBoolItem(SID_SLIDE_MASTERPAGE, false));
-                }
-
-                rSet.Put(SfxBoolItem(SID_TITLE_MASTERPAGE, bCheck));
-
-                if (bDisable)
-                {
-                    rSet.ClearItem(SID_TITLE_MASTERPAGE);
-                    rSet.DisableItem(SID_TITLE_MASTERPAGE);
-                }
-            }
         }
         else if (mePageKind == PK_NOTES)
         {
             rSet.Put(SfxBoolItem(SID_SLIDE_MASTERPAGE, false));
-            rSet.DisableItem(SID_TITLE_MASTERPAGE);
             rSet.Put(SfxBoolItem(SID_NOTES_MASTERPAGE, true));
             rSet.Put(SfxBoolItem(SID_HANDOUT_MASTERPAGE, false));
         }
         else if (mePageKind == PK_HANDOUT)
         {
             rSet.Put(SfxBoolItem(SID_SLIDE_MASTERPAGE, false));
-            rSet.DisableItem(SID_TITLE_MASTERPAGE);
             rSet.Put(SfxBoolItem(SID_NOTES_MASTERPAGE, false));
             rSet.Put(SfxBoolItem(SID_HANDOUT_MASTERPAGE, true));
         }
diff --git a/sd/source/ui/view/drviewse.cxx b/sd/source/ui/view/drviewse.cxx
index be767842..fea938d 100644
--- a/sd/source/ui/view/drviewse.cxx
+++ b/sd/source/ui/view/drviewse.cxx
@@ -982,7 +982,6 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
 
         case SID_MASTERPAGE:          // BASIC
         case SID_SLIDE_MASTERPAGE:    // BASIC
-        case SID_TITLE_MASTERPAGE:    // BASIC
         case SID_NOTES_MASTERPAGE:    // BASIC
         case SID_HANDOUT_MASTERPAGE:  // BASIC
         {
@@ -1002,12 +1001,10 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
 
             if (nSId == SID_MASTERPAGE                                       ||
                 (nSId == SID_SLIDE_MASTERPAGE   && mePageKind == PK_STANDARD) 
||
-                (nSId == SID_TITLE_MASTERPAGE   && mePageKind == PK_STANDARD) 
||
                 (nSId == SID_NOTES_MASTERPAGE   && mePageKind == PK_NOTES)    
||
                 (nSId == SID_HANDOUT_MASTERPAGE && mePageKind == PK_HANDOUT))
             {
-                if (nSId == SID_TITLE_MASTERPAGE ||
-                    nSId == SID_SLIDE_MASTERPAGE)
+                if (nSId == SID_SLIDE_MASTERPAGE)
                 {
                     // Is there a page with the AutoLayout "Title"?
                     bool bFound = false;
@@ -1018,12 +1015,7 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
                     {
                         SdPage* pPage = GetDoc()->GetSdPage(i, PK_STANDARD);
 
-                        if (nSId == SID_TITLE_MASTERPAGE && 
pPage->GetAutoLayout() == AUTOLAYOUT_TITLE)
-                        {
-                            bFound = true;
-                            SwitchPage((pPage->GetPageNum() - 1) / 2);
-                        }
-                        else if (nSId == SID_SLIDE_MASTERPAGE && 
pPage->GetAutoLayout() != AUTOLAYOUT_TITLE)
+                        if (nSId == SID_SLIDE_MASTERPAGE && 
pPage->GetAutoLayout() != AUTOLAYOUT_TITLE)
                         {
                             bFound = true;
                             SwitchPage((pPage->GetPageNum() - 1) / 2);
@@ -1049,7 +1041,6 @@ void DrawViewShell::FuSupport(SfxRequest& rReq)
                 switch (nSId)
                 {
                     case SID_SLIDE_MASTERPAGE:
-                    case SID_TITLE_MASTERPAGE:
                     default:
                         sRequestedView = 
framework::FrameworkHelper::msImpressViewURL;
                         ePageKind = PK_STANDARD;
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to