[Libreoffice-commits] core.git: include/sfx2 sfx2/sdi sw/source

Mathias Supp mathias.supp at vector.com
Tue Mar 25 03:32:43 PDT 2014


 include/sfx2/sfxsids.hrc               |    3 ++-
 sfx2/sdi/sfx.sdi                       |    5 +----
 sw/source/core/uibase/uiview/view2.cxx |    7 ++++++-
 3 files changed, 9 insertions(+), 6 deletions(-)

New commits:
commit 450cb7831f077df43582de15631de3886888e9e0
Author: Mathias Supp <mathias.supp at vector.com>
Date:   Tue Feb 25 04:04:48 2014 +0100

    add parameter to supress dialog
    
    With the new parameter you can now supress the dialog for document
    compare in writer.
    
    Change-Id: I984ee75552e5c006332331510df5d437b687903f

diff --git a/include/sfx2/sfxsids.hrc b/include/sfx2/sfxsids.hrc
index b8bef21..ebac7de 100644
--- a/include/sfx2/sfxsids.hrc
+++ b/include/sfx2/sfxsids.hrc
@@ -264,6 +264,7 @@
 #define SID_MAIL_SENDDOCASFORMAT            (SID_SFX_START + 1707)
 #define SID_MAIL_SENDDOCASMS                (SID_SFX_START + 1708)
 #define SID_MAIL_SENDDOCASOOO               (SID_SFX_START + 1709)
+#define SID_NO_ACCEPT_DIALOG                (SID_SFX_START + 1710)
 #define SID_NOAUTOSAVE                      (SID_SFX_START + 1711)
 #define SID_PRINT_SELECTEDSHEET             (SID_SFX_START + 1712)
 #define SID_OPTIONS_PAGEURL                 (SID_SFX_START + 1713)
@@ -285,6 +286,7 @@
 //      SID_SFX_free_START                  (SID_SFX_START + 1728)
 //      SID_SFX_free_END                    (SID_SFX_START + 3999)
 
+
 #define SID_OPEN_NEW_VIEW                   (SID_SFX_START + 520)
     // FREE, was SID_VIEW_ZOOM_MODE
     // FREE, was SID_VIEW_POS_SIZE
@@ -753,7 +755,6 @@
 #define SC_VIEW_START           (SID_SC_START)
 #endif
 #define FID_CHG_RECORD          (EDIT_MENU_START + 18)
-//see sc/inc/sc.hrc for the rest of the SC_VIEW_START entries
 #define SID_CHG_PROTECT         (SC_VIEW_START + 84)
 
 // eof ------------------------------------------------------------------------
diff --git a/sfx2/sdi/sfx.sdi b/sfx2/sdi/sfx.sdi
index bba571c..59e6254 100644
--- a/sfx2/sdi/sfx.sdi
+++ b/sfx2/sdi/sfx.sdi
@@ -1071,7 +1071,7 @@ SfxStringItem Comments SID_DOCINFO_COMMENTS
 
 
 SfxInt32Item CompareDocuments SID_DOCUMENT_COMPARE
-(SfxStringItem URL SID_FILE_NAME,SfxStringItem FilterName SID_FILTER_NAME,SfxStringItem Password SID_PASSWORD,SfxStringItem FilterOptions SID_FILE_FILTEROPTIONS,SfxInt16Item Version SID_VERSION)
+(SfxStringItem URL SID_FILE_NAME,SfxStringItem FilterName SID_FILTER_NAME,SfxStringItem Password SID_PASSWORD,SfxStringItem FilterOptions SID_FILE_FILTEROPTIONS,SfxInt16Item Version SID_VERSION, SfxBoolItem NoAcceptDialog SID_NO_ACCEPT_DIALOG)
 [
     /* flags: */
     AutoUpdate = FALSE,
@@ -4302,9 +4302,6 @@ SfxObjectItem Open SID_OPENDOC
     RecordPerSet;
     Asynchron;
 
-    /* status: */
-    SlotType = SfxStringItem
-
     /* config: */
     AccelConfig = TRUE,
     MenuConfig = TRUE,
diff --git a/sw/source/core/uibase/uiview/view2.cxx b/sw/source/core/uibase/uiview/view2.cxx
index b7d865e..52212a3 100644
--- a/sw/source/core/uibase/uiview/view2.cxx
+++ b/sw/source/core/uibase/uiview/view2.cxx
@@ -732,6 +732,7 @@ void SwView::Execute(SfxRequest &rReq)
                 sal_Int16 nVersion = 0;
                 bool bHasFileName = false;
                 m_pViewImpl->SetParam( 0 );
+                bool bNoAcceptDialog = false;
 
                 if( pArgs )
                 {
@@ -747,6 +748,10 @@ void SwView::Execute(SfxRequest &rReq)
                         nVersion = ((const SfxInt16Item *)pItem)->GetValue();
                         m_pViewImpl->SetParam( nVersion );
                     }
+                    if( SFX_ITEM_SET == pArgs->GetItemState( SID_NO_ACCEPT_DIALOG, sal_False, &pItem ))
+                    {
+                        bNoAcceptDialog = ((const SfxBoolItem *)pItem)->GetValue();
+                    }
                 }
 
                 m_pViewImpl->InitRequest( rReq );
@@ -756,7 +761,7 @@ void SwView::Execute(SfxRequest &rReq)
                 {
                     rReq.SetReturnValue( SfxInt32Item( nSlot, nFound ));
 
-                    if (nFound > 0) // show Redline browser
+                    if (nFound > 0 && !bNoAcceptDialog) // show Redline browser
                     {
                         SfxViewFrame* pVFrame = GetViewFrame();
                         pVFrame->ShowChildWindow(FN_REDLINE_ACCEPT);


More information about the Libreoffice-commits mailing list