[ooo-build-commit] .: 2 commits - sd/source

Jan Holesovsky kendy at kemper.freedesktop.org
Thu Aug 26 07:25:13 PDT 2010


 sd/source/ui/func/fuinsert.cxx |   12 +++++++++++-
 sd/source/ui/view/sdview4.cxx  |    4 ----
 2 files changed, 11 insertions(+), 5 deletions(-)

New commits:
commit 7234327b5e949ec7769505f6dd02630135ec788f
Author: Thorsten Behrens <thb at openoffice.org>
Date:   Wed Aug 25 23:20:11 2010 +0200

    linkwarn-sd-no-dnd-links.diff: Do not link on drag and drop.
    
    n#348149

diff --git a/sd/source/ui/view/sdview4.cxx b/sd/source/ui/view/sdview4.cxx
index dce201f..9ec90c5 100755
--- a/sd/source/ui/view/sdview4.cxx
+++ b/sd/source/ui/view/sdview4.cxx
@@ -395,12 +395,8 @@ IMPL_LINK( View, DropInsertFileHdl, Timer*, EMPTYARG )
             if( !pGraphicFilter->ImportGraphic( aGraphic, aURL ) )
             {
                 sal_Int8    nTempAction = ( aIter == maDropFileVector.begin() ) ? mnAction : 0;
-                const bool bLink = ( ( nTempAction & DND_ACTION_LINK ) != 0 );
                 SdrGrafObj* pGrafObj = InsertGraphic( aGraphic, nTempAction, maDropPos, NULL, NULL );
 
-                if( pGrafObj && bLink )
-                    pGrafObj->SetGraphicLink( aCurrentDropFile, String() );
-
                 // return action from first inserted graphic
                 if( aIter == maDropFileVector.begin() )
                     mnAction = nTempAction;
commit 0ce143278c252f7b4f6e2065584fea12c7a1f93e
Author: Thorsten Behrens <thb at openoffice.org>
Date:   Wed Aug 25 22:53:55 2010 +0200

    linkwarn-dlg-in-apps.diff: Wire up link warning dlg in applications.
    
    n#348149

diff --git a/sd/source/ui/func/fuinsert.cxx b/sd/source/ui/func/fuinsert.cxx
index c09fed5..916a512 100755
--- a/sd/source/ui/func/fuinsert.cxx
+++ b/sd/source/ui/func/fuinsert.cxx
@@ -48,9 +48,11 @@
 #include <sfx2/request.hxx>
 #include <svl/globalnameitem.hxx>
 #include <unotools/pathoptions.hxx>
+#include <svtools/miscopt.hxx>
 #include <svx/pfiledlg.hxx>
 #include <svx/dialogs.hrc>
 #include <sfx2/linkmgr.hxx>
+#include <svx/linkwarn.hxx>
 #include <svx/svdetc.hxx>
 #include <avmedia/mediawindow.hxx>
 #ifndef _UNOTOOLS_UCBSTREAMHELPER_HXX
@@ -156,7 +158,15 @@ void FuInsertGraphic::DoExecute( SfxRequest&  )
 
                 if(pGrafObj && aDlg.IsAsLink())
                 {
-                    // store link only?
+                    // really store as link only?
+                    if( SvtMiscOptions().ShowLinkWarningDialog() )
+                    {
+                        SvxLinkWarningDialog aWarnDlg(mpWindow,aDlg.GetPath());
+                        if( aWarnDlg.Execute() != RET_OK )
+                            return; // don't store as link
+                    }
+
+                    // store as link
                     String aFltName(aDlg.GetCurrentFilter());
                     String aPath(aDlg.GetPath());
                     pGrafObj->SetGraphicLink(aPath, aFltName);


More information about the ooo-build-commit mailing list