Re: help with the LO bibliography as seen by the source code?

2015-05-08 Thread Yury
Yury  gmail.com> writes:

> I'm trying to create some kind of a stopgap solution for the 
> https://bugs.documentfoundation.org/show_bug.cgi?id=88697
...

Never mind, guys, I've managed to do this (see issue page for details).
Thank to all who helped (empty set :))

-Yury

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: libreofficekit/qa

2015-05-08 Thread Miklos Vajna
 libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx |2 --
 1 file changed, 2 deletions(-)

New commits:
commit 61b44da9fbf35100ac96896f04dee5b779305d68
Author: Miklos Vajna 
Date:   Fri May 8 09:06:49 2015 +0200

gtktiledviewer: unused pFileName

Change-Id: I30cd9d8adffbdf9d7451bca0c09aa56639379486

diff --git a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx 
b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
index ac74266..72988d7 100644
--- a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
+++ b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
@@ -50,7 +50,6 @@ GtkWidget* pFindbar;
 GtkWidget* pFindbarEntry;
 
 static LibreOfficeKit* pOffice;
-static char* pFileName;
 
 static void lcl_registerToolItem(GtkToolItem* pItem, const std::string& rName)
 {
@@ -438,7 +437,6 @@ int main( int argc, char* argv[] )
 // Hide the findbar by default.
 gtk_widget_hide(pFindbar);
 
-pFileName = argv[2];
 int bOpened = lok_docview_open_document( LOK_DOCVIEW(pDocView), argv[2] );
 if (!bOpened)
 g_error("main: lok_docview_open_document() failed with '%s'", 
pOffice->pClass->getError(pOffice));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: 15 commits - animations/source avmedia/source bean/native bridges/source chart2/source compilerplugins/clang connectivity/source cui/source desktop/unx extensions/sourc

2015-05-08 Thread Stephan Bergmann
 animations/source/animcore/animcore.cxx  |8 
 avmedia/source/gstreamer/gstplayer.cxx   |2 
 bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow.c |2 
 bridges/source/jni_uno/jni_base.h|4 
 bridges/source/jni_uno/jni_bridge.cxx|8 
 bridges/source/jni_uno/jni_data.cxx  |3 
 chart2/source/view/main/GL3DRenderer.cxx |2 
 compilerplugins/clang/implicitboolconversion.cxx |  131 
++
 connectivity/source/drivers/firebird/Connection.cxx  |2 
 connectivity/source/drivers/hsqldb/HStorageAccess.cxx|2 
 connectivity/source/drivers/hsqldb/HStorageMap.cxx   |6 
 connectivity/source/drivers/hsqldb/StorageFileAccess.cxx |4 
 connectivity/source/drivers/jdbc/Reader.cxx  |6 
 cui/source/customize/eventdlg.cxx|2 
 desktop/unx/source/start.c   |2 
 extensions/source/update/check/updatecheckconfig.cxx |4 
 io/source/acceptor/acc_socket.cxx|2 
 io/source/connector/connector.cxx|2 
 javaunohelper/source/bootstrap.cxx   |6 
 mysqlc/source/mysqlc_resultsetmetadata.cxx   |4 
 odk/examples/DevelopersGuide/Database/DriverSkeleton/SConnection.cxx |2 
 package/source/xstor/xstorage.cxx|2 
 sal/textenc/tcvtutf7.cxx |   76 
++---
 sd/source/ui/annotations/annotationtag.cxx   |2 
 sd/source/ui/sidebar/LayoutMenu.cxx  |6 
 sd/source/ui/slidesorter/controller/SlideSorterController.cxx|2 
 sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx  |4 
 sd/source/ui/view/ViewShellManager.cxx   |2 
 sfx2/source/dialog/templdlg.cxx  |6 
 sfx2/source/menu/mnuitem.cxx |2 
 sfx2/source/menu/mnumgr.cxx  |6 
 sfx2/source/menu/virtmenu.cxx|6 
 sfx2/source/sidebar/AsynchronousCall.cxx |2 
 sfx2/source/sidebar/Deck.cxx |2 
 sfx2/source/sidebar/SidebarController.cxx|4 
 stoc/source/javavm/javavm.cxx|8 
 svtools/source/svrtf/rtfkeywd.cxx|4 
 svx/source/form/formfeaturedispatcher.cxx|2 
 sw/source/ui/table/tautofmt.cxx  |2 
 sw/source/uibase/docvw/SidebarWin.cxx|2 
 sw/source/uibase/utlui/glbltree.cxx  |2 
 test/source/sheet/xdatabaserange.cxx |4 
 testtools/source/bridgetest/constructors.cxx |4 
 writerfilter/source/dmapper/PropertyMapHelper.cxx|2 
 xmloff/source/forms/elementexport.cxx|2 
 xmloff/source/transform/OOo2Oasis.cxx|   16 -
 46 files changed, 206 insertions(+), 168 deletions(-)

New commits:
commit 9be45dd750ede909ba3a181662c1bfa18e662a75
Author: Stephan Bergmann 
Date:   Fri May 8 09:48:38 2015 +0200

lopluign:implicitboolconversion: warn about conversion from sal_Bool etc., 
too

Change-Id: I5bc23a2b599742c579ad82c1b1f68df130ac426b

diff --git a/compilerplugins/clang/implicitboolconversion.cxx 
b/compilerplugins/clang/implicitboolconversion.cxx
index dec8e23..0d933bf 100644
--- a/compilerplugins/clang/implicitboolconversion.cxx
+++ b/compilerplugins/clang/implicitboolconversion.cxx
@@ -71,6 +71,14 @@ SubstTemplateTypeParmType const * 
getAsSubstTemplateTypeParmType(QualType type)
 }
 }
 
+bool areSameTypedef(QualType type1, QualType type2) {
+// type1.getTypePtr() == typ2.getTypePtr() fails for e.g. ::sal_Bool vs.
+// sal_Bool:
+auto t1 = type1->getAs();
+auto t2 = type2->getAs();
+return t1 != nullptr && t2 != nullptr && t1->getDecl() == t2->getDecl();
+}
+
 bool isBool(QualType type, bool allowTypedefs = true) {
 if (type->isBooleanType()) {
 return true;
@@ -93,6 +101,11 @@ bool isBool(Expr const * expr, bool allowTypedefs = true) {
 return isBool(expr->getType(), allowTypedefs);
 }
 
+bool isMatchingBool(Expr const * expr, Expr const * comparisonExpr) {
+return isBool(expr, false)
+|| areSameTypedef(expr->getType(), compa

[Libreoffice-commits] core.git: libreofficekit/qa

2015-05-08 Thread Tor Lillqvist
 libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit c5a96b5d3d2a40ab202acc1559c361712d8ffe32
Author: Tor Lillqvist 
Date:   Fri May 8 10:50:14 2015 +0300

Clarify the usage message a bit

Change-Id: I6ae2f5c12ae5c20fd2f33bff639129dd303c3c20

diff --git a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx 
b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
index 72988d7..14cf767 100644
--- a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
+++ b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
@@ -28,7 +28,7 @@
 
 static int help()
 {
-fprintf( stderr, "Usage: gtktiledviewer 
 \n" );
+fprintf( stderr, "Usage: gtktiledviewer 
 
\n" );
 return 1;
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


four changes of suspicious code (connectivity, sc, sw, editeng)

2015-05-08 Thread Stephan Bergmann
The updated loplugin:implicitboolconversion now also warns about 
implicit conversions from bool-like types like sal_Bool.  That flagged 
four places that I tried to fix as best I could, but wouldn't mind if 
others more familiar with the respective code would take a look, too:


One is in connectivity (Lionel, do you happen to know how to trigger 
that code?):



commit c5e08b42ace5f4481c3db87b4fb6ae2dbf9d9a51
Author: Stephan Bergmann 
Date:   Fri May 8 09:26:35 2015 +0200

I very much assume this wants to call java.io.Reader.ready

...seeing that there is no java.io.Reader.available.  (And then, there's no 
good
way to map from java.io.Reader.ready's boolean value to
css.io.XInputStream.available's long value, so conservatively map true to 
1.)

But I have no idea how to trigger this code.

Change-Id: I18d12e0d968141410a1b56e700ed544edceda97c

diff --git a/connectivity/source/drivers/jdbc/Reader.cxx 
b/connectivity/source/drivers/jdbc/Reader.cxx
index a7cd369..20db510 100644
--- a/connectivity/source/drivers/jdbc/Reader.cxx
+++ b/connectivity/source/drivers/jdbc/Reader.cxx
@@ -57,19 +57,19 @@ void SAL_CALL java_io_Reader::skipBytes( sal_Int32 
nBytesToSkip ) throw(::com::s

 sal_Int32 SAL_CALL java_io_Reader::available(  ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)
 {
-jboolean out(sal_False);
+jboolean out;
 SDBThreadAttach t; OSL_ENSURE(t.pEnv,"Java Enviroment geloescht worden!");

 {
 static const char * cSignature = "()Z";
-static const char * cMethodName = "available";
+static const char * cMethodName = "ready";
 // Java-Call
 static jmethodID mID(NULL);
 obtainMethodId_throwRuntime(t.pEnv, cMethodName,cSignature, mID);
 out = t.pEnv->CallBooleanMethod( object, mID);
 ThrowRuntimeException(t.pEnv,*this);
 } //t.pEnv
-return out;
+return out ? 1 : 0; // no way to tell *how much* is ready
 }

 void SAL_CALL java_io_Reader::closeInput(  ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)


One is in sc:


commit f593be5bcde09965bb3478e00bcdedbc6bd5bc57
Author: Stephan Bergmann 
Date:   Wed May 6 08:17:32 2015 +0200

SfxBoolItem takes a sal_uInt16 nWhich as first argument

This code was like that ever since 9ae5a91f7955e44d3b24a3f7741f9bca02ac7f24
"initial import."  From the surrounding code, the best bet appears to be
ATTR_LINEBREAK?

Change-Id: Id0e3346f2f9bb9c00c202003d06c2518dea38112

diff --git a/sc/source/filter/starcalc/scflt.cxx 
b/sc/source/filter/starcalc/scflt.cxx
index 682eb20..b21f9a4 100644
--- a/sc/source/filter/starcalc/scflt.cxx
+++ b/sc/source/filter/starcalc/scflt.cxx
@@ -1189,7 +1189,7 @@ void Sc10Import::LoadPatternCollection()
 }

 if( ( OJustify & ojWordBreak ) == ojWordBreak )
-rItemSet.Put( SfxBoolItem( sal_True ) );
+rItemSet.Put( SfxBoolItem( ATTR_LINEBREAK, true ) );
 if( ( OJustify & ojBottomTop ) == ojBottomTop )
 rItemSet.Put( SfxInt32Item( ATTR_ROTATE_VALUE, 9000 ) );
 else if( ( OJustify & ojTopBottom ) == ojTopBottom )
@@ -1830,7 +1830,7 @@ void Sc10Import::LoadColAttr(SCCOL Col, SCTAB Tab)
 }

 if (OJustify & ojWordBreak)
-aScPattern.GetItemSet().Put(SfxBoolItem(sal_True));
+aScPattern.GetItemSet().Put(SfxBoolItem(ATTR_LINEBREAK, true));
 if (OJustify & ojBottomTop)
 
aScPattern.GetItemSet().Put(SfxInt32Item(ATTR_ROTATE_VALUE,9000));
 else if (OJustify & ojTopBottom)


One is in sw:


commit 2c9b7e3304db9d571d15a4ba3732acf8cf40cffe
Author: Stephan Bergmann 
Date:   Wed May 6 15:16:37 2015 +0200

SvxOpaqueItem takes a sal_uInt16 nId as first argument

This code was like that ever since 84a3db80b4fd66c6854b3135b5f69b61fd828e62
"initial import."  From other uses of SvxOpaqueItem, the best bet appears 
to be
RES_OPAQUE.

Change-Id: I19de8fac4f41716d9c2a73bda4a8cea200ae99f8

diff --git a/sw/source/core/doc/DocumentStylePoolManager.cxx 
b/sw/source/core/doc/DocumentStylePoolManager.cxx
index 3276b9f4..8d4fe0e 100644
--- a/sw/source/core/doc/DocumentStylePoolManager.cxx
+++ b/sw/source/core/doc/DocumentStylePoolManager.cxx
@@ -1318,7 +1318,7 @@ SwFmt* DocumentStylePoolManager::GetFmtFromPool( 
sal_uInt16 nId )
 aSet.Put( SwFmtAnchor( FLY_AT_PAGE ));
 aSet.Put( SwFmtHoriOrient( 0, text::HoriOrientation::CENTER, 
text::RelOrientation::FRAME ));
 aSet.Put( SwFmtVertOrient( 0, text::VertOrientation::CENTER, 
text::RelOrientation::FRAME ));
-aSet.Put( SvxOpaqueItem( sal_False ));
+aSet.Put( SvxOpaqueItem( RES_OPAQUE, false ));
 aSet.Put( SwFm

Build dependency on external cppunit

2015-05-08 Thread Richard Cochran
Dear list,

I am trying to build Version 4.4.0.3 with a -j30 parallel build, but I
am running into this error.

  In file included from 
/git/libreoffice/sal/cppunittester/cppunittester.cxx:28:0:
  /git/libreoffice/include/cppunittester/protectorfactory.hxx:24:31: fatal 
error: cppunit/Protector.h: 
  No such file or directory
   #include 

I am not using '--with-system-cppunit'.

Questions:

1. Where is the dependency from sal->cppunit specified?

2. How can I force a build of cppunit (and other externals)?

Thanks,
Richard
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: connectivity/source include/connectivity include/sfx2 include/sot include/svx sfx2/source sot/source svx/source sw/inc sw/source unusedcode.easy

2015-05-08 Thread Caolán McNamara
 connectivity/source/commontools/dbtools.cxx |5 -
 include/connectivity/dbtools.hxx|2 
 include/sfx2/mnuitem.hxx|   24 +-
 include/sot/stg.hxx |2 
 include/svx/dlgctrl.hxx |1 
 sfx2/source/menu/mnuitem.cxx|   93 --
 sfx2/source/sidebar/Deck.cxx|5 -
 sfx2/source/sidebar/Deck.hxx|1 
 sfx2/source/sidebar/SidebarController.cxx   |1 
 sot/source/sdstor/ucbstorage.cxx|   97 
 svx/source/dialog/dlgctrl.cxx   |   17 
 sw/inc/unotxdoc.hxx |1 
 sw/source/uibase/uno/unotxdoc.cxx   |9 --
 unusedcode.easy |3 
 14 files changed, 10 insertions(+), 251 deletions(-)

New commits:
commit efdd215124df0ab98a33525ac01a9d8ff4a542d4
Author: Caolán McNamara 
Date:   Fri May 8 09:21:42 2015 +0100

callcatcher: update unused code

Change-Id: I8563922204d3ec93bf138cbd1aaba620c0215bf7

diff --git a/connectivity/source/commontools/dbtools.cxx 
b/connectivity/source/commontools/dbtools.cxx
index adbb61f..f49bdc6 100644
--- a/connectivity/source/commontools/dbtools.cxx
+++ b/connectivity/source/commontools/dbtools.cxx
@@ -737,11 +737,6 @@ Sequence< OUString > getFieldNamesByCommandDescriptor( 
const Reference< XConnect
 return aNames;
 }
 
-SQLContext prependContextInfo(const SQLException& _rException, const 
Reference< XInterface >& _rxContext, const OUString& _rContextDescription, 
const OUString& _rContextDetails)
-{
-return SQLContext( _rContextDescription, _rxContext, OUString(), 0, 
makeAny( _rException ), _rContextDetails );
-}
-
 SQLException prependErrorInfo( const SQLException& _rChainedException, const 
Reference< XInterface >& _rxContext,
 const OUString& _rAdditionalError, const StandardSQLState _eSQLState, 
const sal_Int32 _nErrorCode )
 {
diff --git a/include/connectivity/dbtools.hxx b/include/connectivity/dbtools.hxx
index 77ed4fd..02b3f06 100644
--- a/include/connectivity/dbtools.hxx
+++ b/include/connectivity/dbtools.hxx
@@ -302,8 +302,6 @@ namespace dbtools
 /** create a new ::com::sun::star::sdbc::SQLContext, fill it with the 
given descriptions and the given source,
 and append _rException (i.e. put it into the NextException 
member of the SQLContext).
 */
-OOO_DLLPUBLIC_DBTOOLS ::com::sun::star::sdb::SQLContext 
prependContextInfo(const ::com::sun::star::sdbc::SQLException& _rException, 
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& 
_rxContext, const OUString& _rContextDescription, const OUString& 
_rContextDetails );
-
 OOO_DLLPUBLIC_DBTOOLS
 ::com::sun::star::sdbc::SQLException prependErrorInfo(
 const ::com::sun::star::sdbc::SQLException& _rChainedException,
diff --git a/include/sfx2/mnuitem.hxx b/include/sfx2/mnuitem.hxx
index 0d40854..8e5e0cd 100644
--- a/include/sfx2/mnuitem.hxx
+++ b/include/sfx2/mnuitem.hxx
@@ -120,27 +120,13 @@ inline SfxVirtualMenu* SfxMenuControl::GetPopupMenu() 
const
{ SfxMenuControl::RegisterMenuControl( pMod, new 
SfxMenuCtrlFactory( \
 Class::CreateImpl, TYPE(nItemClass), nSlotId ) ); }
 
-class SfxAppMenuControl_Impl : public SfxMenuControl
+struct ExecuteInfo
 {
-PopupMenu*  pMenu;
-OUStringm_sIconTheme;
-boolm_bShowMenuImages;
+::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > 
xDispatch;
+::com::sun::star::util::URL
aTargetURL;
+::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >  
aArgs;
 
-protected:
-DECL_LINK_TYPED( Activate, Menu *, bool ); // Needed to support high 
contrast images
-
-public:
-SfxAppMenuControl_Impl( sal_uInt16 nPos, Menu& rMenu, SfxBindings& 
rBindings );
-virtual ~SfxAppMenuControl_Impl();
-
-struct ExecuteInfo
-{
-::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > 
xDispatch;
-::com::sun::star::util::URL
aTargetURL;
-::com::sun::star::uno::Sequence< 
::com::sun::star::beans::PropertyValue >  aArgs;
-};
-
-DECL_STATIC_LINK( SfxAppMenuControl_Impl, ExecuteHdl_Impl, ExecuteInfo* );
+DECL_STATIC_LINK( ExecuteInfo, ExecuteHdl_Impl, ExecuteInfo* );
 };
 
 #endif
diff --git a/include/sot/stg.hxx b/include/sot/stg.hxx
index a6be7ce..5f4ba36 100644
--- a/include/sot/stg.hxx
+++ b/include/sot/stg.hxx
@@ -284,9 +284,7 @@ protected:
 virtual ~UCBStorage();
 public:
 static bool IsStorageFile( SvStream* );
-static bool IsDiskSpannedFile( SvStream* );
 static OUString GetLinkedFile( SvStream& );
-static OUString CreateLinkFile( const OUString& rName );
 

[Libreoffice-commits] core.git: 2 commits - dbaccess/source

2015-05-08 Thread Miklos Vajna
 dbaccess/source/core/dataaccess/databasecontext.cxx |   10 +-
 dbaccess/source/filter/xml/xmlfilter.cxx|4 
 2 files changed, 13 insertions(+), 1 deletion(-)

New commits:
commit a20d53afb97a278a16ad604cb65f107d33ab4fb9
Author: Miklos Vajna 
Date:   Fri May 8 11:14:12 2015 +0200

dbaccess: handle URL mark as StreamRelPath in ODatabaseContext

With this, dbaccess can not only load .odb files, but also other ODF
packages as well, as long as the URL's mark (the part after the "#")
contains under what namespace the real .odb is.

This will be used for embedding data source definitions into .odt
documents by Writer in a bit.

Change-Id: Ic1e922418c185fd6ec49d442a3419b80c9a6c76a

diff --git a/dbaccess/source/core/dataaccess/databasecontext.cxx 
b/dbaccess/source/core/dataaccess/databasecontext.cxx
index e4fb8e6..4e6c185 100644
--- a/dbaccess/source/core/dataaccess/databasecontext.cxx
+++ b/dbaccess/source/core/dataaccess/databasecontext.cxx
@@ -310,9 +310,15 @@ Reference< XInterface >  
ODatabaseContext::getRegisteredObject(const OUString& _
 return loadObjectFromURL( _rName, sURL );
 }
 
-Reference< XInterface > ODatabaseContext::loadObjectFromURL(const OUString& 
_rName,const OUString& _sURL)
+Reference< XInterface > ODatabaseContext::loadObjectFromURL(const OUString& 
_rName,const OUString& rURL)
 {
+OUString _sURL(rURL);
 INetURLObject aURL( _sURL );
+
+OUString aMark = aURL.GetMark(INetURLObject::DECODE_WITH_CHARSET);
+if (!aMark.isEmpty())
+_sURL = aURL.GetURLNoMark();
+
 if ( aURL.GetProtocol() == INetProtocol::NotValid )
 throw NoSuchElementException( _rName, *this );
 
@@ -361,6 +367,8 @@ Reference< XInterface > 
ODatabaseContext::loadObjectFromURL(const OUString& _rNa
 aArgs.put( "URL", _sURL );
 aArgs.put( "MacroExecutionMode", MacroExecMode::USE_CONFIG );
 aArgs.put( "InteractionHandler", 
task::InteractionHandler::createWithParent(m_aContext, 0) );
+if (!aMark.isEmpty())
+aArgs.put("StreamRelPath", aMark);
 
 Sequence< PropertyValue > aResource( aArgs.getPropertyValues() );
 xLoad->load( aResource );
commit dbab26d1fdcc0891a0f3e098f10a5c98e328a48b
Author: Miklos Vajna 
Date:   Fri May 8 11:13:27 2015 +0200

dbaccess: handle StreamRelPath in ODBFilter::implImport()

Change-Id: I8a4d21f8bef272a6cdb5a72da274e65516c36617

diff --git a/dbaccess/source/filter/xml/xmlfilter.cxx 
b/dbaccess/source/filter/xml/xmlfilter.cxx
index 4d2e8cc..60fd9f3 100644
--- a/dbaccess/source/filter/xml/xmlfilter.cxx
+++ b/dbaccess/source/filter/xml/xmlfilter.cxx
@@ -457,6 +457,10 @@ bool ODBFilter::implImport( const Sequence< PropertyValue 
>& rDescriptor )
 try
 {
 xStorage.set(pMedium->GetStorage(false), UNO_QUERY_THROW);
+
+OUString sStreamRelPath = 
aMediaDescriptor.getOrDefault("StreamRelPath", OUString());
+if (!sStreamRelPath.isEmpty())
+xStorage = xStorage->openStorageElement(sStreamRelPath, 
embed::ElementModes::READ);
 }
 catch (const Exception&)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: include/oox oox/source

2015-05-08 Thread Miklos Vajna
 include/oox/helper/attributelist.hxx |3 ---
 oox/source/helper/attributelist.cxx  |7 ---
 2 files changed, 10 deletions(-)

New commits:
commit 80743f11fcdb49f997b0a8ff08bee28a0f2cfce7
Author: Miklos Vajna 
Date:   Fri May 8 11:37:45 2015 +0200

Unused oox::AttributeList::getUnsignedHex() variant

Change-Id: I4ec0cd4781aaa905f734b15ba4eff7819ca01082

diff --git a/include/oox/helper/attributelist.hxx 
b/include/oox/helper/attributelist.hxx
index 38bdf34..0e5eb5e 100644
--- a/include/oox/helper/attributelist.hxx
+++ b/include/oox/helper/attributelist.hxx
@@ -112,9 +112,6 @@ public:
 /** Returns the 32-bit signed integer value of the specified attribute 
(hexadecimal). */
 OptValue< sal_Int32 > getIntegerHex( sal_Int32 nAttrToken ) const;
 
-/** Returns the 32-bit unsigned integer value of the specified attribute 
(hexadecimal). */
-OptValue< sal_uInt32 > getUnsignedHex( sal_Int32 nAttrToken ) const;
-
 /** Returns the boolean value of the specified attribute. */
 OptValue< bool >getBool( sal_Int32 nAttrToken ) const;
 
diff --git a/oox/source/helper/attributelist.cxx 
b/oox/source/helper/attributelist.cxx
index 34cd8402..e2e5f9a 100644
--- a/oox/source/helper/attributelist.cxx
+++ b/oox/source/helper/attributelist.cxx
@@ -191,13 +191,6 @@ OptValue< sal_Int32 > AttributeList::getIntegerHex( 
sal_Int32 nAttrToken ) const
 return OptValue< sal_Int32 >( bValid, bValid ? 
AttributeConversion::decodeIntegerHex( aValue ) : 0 );
 }
 
-OptValue< sal_uInt32 > AttributeList::getUnsignedHex( sal_Int32 nAttrToken ) 
const
-{
-OUString aValue = mxAttribs->getOptionalValue( nAttrToken );
-bool bValid = !aValue.isEmpty();
-return OptValue< sal_uInt32 >( bValid, bValid ? 
AttributeConversion::decodeUnsignedHex( aValue ) : 0 );
-}
-
 OptValue< bool > AttributeList::getBool( sal_Int32 nAttrToken ) const
 {
 const char *pAttr;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Changes to 'private/bubli/sw_16bit'

2015-05-08 Thread Matteo Casalin
New branch 'private/bubli/sw_16bit' available with the following commits:
commit a98ef8adcc10bec409e8132ace3de1e6606e6c8f
Author: Matteo Casalin 
Date:   Sun Apr 26 13:12:37 2015 +0200

Use auto and range-based for loops

Change-Id: I400bce4479eb0ab8105384f88a379c3ea90b9f66

commit 76c34865f595e0f79775d0f3e22e8ff62844867a
Author: Matteo Casalin 
Date:   Sun May 3 19:04:23 2015 +0200

Use range-based for loops

Change-Id: I02dbe522c61804e5868b350e99ab02f691f36b0b

commit 5b737ca478f70d652ea36338b005425eec8c8f18
Author: Matteo Casalin 
Date:   Sun May 3 19:22:22 2015 +0200

Use auto and range-based for loops

Change-Id: I5fecd9cfb64fee9d18e4491e6219c1b90e64ea7c

commit b271abe87672881ed0ae94c5f287ac2f93e81815
Author: Matteo Casalin 
Date:   Sun May 3 22:28:13 2015 +0200

Use range-based for loops, better integer types and avoid some casts

Change-Id: Ife8bb0bb1d20655c0526aad1d4921713c961eb7a

commit bde8062181295d832ace1c0f2bc8a54d17da8c0c
Author: Katarina Behrens 
Date:   Sun May 3 23:25:52 2015 +0200

tdf#89783: Adjust to new GetPos retval (size_t vs. sal_uInt16)

Some of the usages of GetPos were just misusing it to find out
whether a vector contains given element -- use Contains() in those
cases

This patch is partially based on work of Christoph Lutz

Conflicts:
sw/source/filter/ww8/wrtw8esh.cxx
sw/source/filter/ww8/wrtw8num.cxx

Change-Id: I40bedba905e7577ba23f69acee178e0ea7cc1521

commit 4925372f705239aebe8424e55df6a2a9718d1174
Author: Vasily Melenchuk 
Date:   Mon Apr 6 12:23:09 2015 +0300

tdf#89783: sal_uInt16 replacement by size_t: sections

These replacements allow LO to load, save and mail merge documents having
more than 65536 sections in total.

Change-Id: I0e70889b1edc6e472a39f1f2638ac3c70a0d7058

Signed-off-by: Katarina Behrens 

commit 447de7e569739aa05f9a0dbd1128306c65c457ce
Author: Katarina Behrens 
Date:   Wed Apr 29 10:16:19 2015 +0200

tdf#89783: avoid endless loop with >65k style names

Change-Id: I09be0ade1cd66253f420c2158ef6c093758ca493

commit ca0579f2bbf0b8bce8b3d3a79931758ebf4bd90e
Author: Katarina Behrens 
Date:   Wed Apr 29 10:13:18 2015 +0200

tdf#89783: fix another potential endless loop

the same pattern as in 4de83e2c322509c0fb1b989f7e4898728fc4a

Change-Id: I38d48b9c1302f23a0d2537f8e5eced2ee64ddf4e

commit f3ddeb1d66de742648556fe569ab6638851c8bc2
Author: Christoph Lutz 
Date:   Tue Apr 28 17:55:11 2015 +0200

tdf#89783: MM fixes potential endless loops with dbgutil build

Change-Id: I0eeb0decab588d89881a24983eb89727c3d9151b
Reviewed-on: https://gerrit.libreoffice.org/15561
Reviewed-by: Katarina Behrens 
Tested-by: Katarina Behrens 

___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: vcl/inc vcl/unx

2015-05-08 Thread Stephan Bergmann
 vcl/inc/unx/gtk/gtkgdi.hxx|   17 --
 vcl/unx/gtk/app/gtkdata.cxx   |1 
 vcl/unx/gtk/gdi/gtkprintwrapper.cxx   |   21 ++
 vcl/unx/gtk/window/gtksalframe.cxx|5 
 vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx |   18 +-
 vcl/unx/kde/UnxCommandThread.cxx  |   72 
 vcl/unx/kde/UnxCommandThread.hxx  |1 
 vcl/unx/kde/UnxFilePicker.cxx |  215 +-
 vcl/unx/kde/UnxFilePicker.hxx |3 
 vcl/unx/kde/fpicker/kdecommandthread.cxx  |   90 +-
 vcl/unx/kde/fpicker/kdecommandthread.hxx  |1 
 vcl/unx/kde/fpicker/kdefilepicker.cxx |  130 ---
 vcl/unx/kde/fpicker/kdefilepicker.hxx |4 
 vcl/unx/kde/salnativewidgets-kde.cxx  |   76 -
 14 files changed, 344 insertions(+), 310 deletions(-)

New commits:
commit 79776356d9597f3c0e06f8e81019909bdbb1a560
Author: Stephan Bergmann 
Date:   Fri May 8 11:56:28 2015 +0200

loplugin:staticmethods

Change-Id: Ie3629a14c7a15a0f5f93a4bfc663a2bb52a8735d

diff --git a/vcl/inc/unx/gtk/gtkgdi.hxx b/vcl/inc/unx/gtk/gtkgdi.hxx
index 2805ef6..68c6cf7 100644
--- a/vcl/inc/unx/gtk/gtkgdi.hxx
+++ b/vcl/inc/unx/gtk/gtkgdi.hxx
@@ -80,36 +80,35 @@ private:
 static GtkStyleContext *mpListboxStyle;
 static GtkStyleContext *mpNoteBookStyle;
 
-void getStyleContext(GtkStyleContext** style, GtkWidget* widget);
-Rectangle NWGetScrollButtonRect( ControlPart nPart, Rectangle aAreaRect );
-Rectangle NWGetSpinButtonRect( ControlPart nPart, Rectangle aAreaRect);
-Rectangle NWGetComboBoxButtonRect( ControlType nType, ControlPart nPart, 
Rectangle aAreaRect );
+static Rectangle NWGetScrollButtonRect( ControlPart nPart, Rectangle 
aAreaRect );
+static Rectangle NWGetSpinButtonRect( ControlPart nPart, Rectangle 
aAreaRect);
+static Rectangle NWGetComboBoxButtonRect( ControlType nType, ControlPart 
nPart, Rectangle aAreaRect );
 
-void PaintScrollbar(GtkStyleContext *context,
+static void PaintScrollbar(GtkStyleContext *context,
 cairo_t *cr,
 const Rectangle& rControlRectangle,
 ControlType nType,
 ControlPart nPart,
 const ImplControlValue& aValue );
-void PaintOneSpinButton( GtkStyleContext *context,
+static void PaintOneSpinButton( GtkStyleContext *context,
  cairo_t *cr,
  ControlType nType,
  ControlPart nPart,
  Rectangle aAreaRect,
  ControlState nState );
-void PaintSpinButton(GtkStyleContext *context,
+static void PaintSpinButton(GtkStyleContext *context,
  cairo_t *cr,
  const Rectangle& rControlRectangle,
  ControlType nType,
  ControlPart nPart,
  const ImplControlValue& aValue );
-void PaintCombobox( GtkStyleContext *context,
+static void PaintCombobox( GtkStyleContext *context,
 cairo_t *cr,
 const Rectangle& rControlRectangle,
 ControlType nType,
 ControlPart nPart,
 const ImplControlValue& aValue );
-void PaintCheckOrRadio(GtkStyleContext *context,
+static void PaintCheckOrRadio(GtkStyleContext *context,
cairo_t *cr,
const Rectangle& rControlRectangle,
ControlType nType);
diff --git a/vcl/unx/gtk/app/gtkdata.cxx b/vcl/unx/gtk/app/gtkdata.cxx
index d1f594f..0d5aea0 100644
--- a/vcl/unx/gtk/app/gtkdata.cxx
+++ b/vcl/unx/gtk/app/gtkdata.cxx
@@ -169,6 +169,7 @@ GdkFilterReturn GtkSalDisplay::filterGdkEvent( GdkXEvent* 
sys_event,
 
 return aFilterReturn;
 #else
+(void) this; // loplugin:staticmethods
 (void) sys_event;
 //FIXME: implement filterGdkEvent ...
 return GDK_FILTER_CONTINUE;
diff --git a/vcl/unx/gtk/gdi/gtkprintwrapper.cxx 
b/vcl/unx/gtk/gdi/gtkprintwrapper.cxx
index 809ddae..1db42c8 100644
--- a/vcl/unx/gtk/gdi/gtkprintwrapper.cxx
+++ b/vcl/unx/gtk/gdi/gtkprintwrapper.cxx
@@ -112,6 +112,7 @@ bool GtkPrintWrapper::supportsPrinting() const
 && m_print_unix_dialog_set_settings
 ;
 #else
+(void) this; // loplugin:staticmethods
 return true;
 #endif
 }
@@ -125,6 +126,7 @@ bool GtkPrintWrapper::supportsPrintSelection() const
 && m_print_unix_dialog_set_has_selection
 ;
 #else
+(void) this; // loplugin:staticmethods
 return true;
 #endif
 }
@@ -135,6 +137,7 @@ GtkPageSetup* GtkPrintWrapper::page_setup_new() const
 assert(m_page_setup_new);
 return (*m_page_setup_new)();
 #else
+(void) this; // loplugin:staticmethods
 return gtk_page_setup_new

Re: Build dependency on external cppunit

2015-05-08 Thread Stephan Bergmann

On 05/08/2015 10:45 AM, Richard Cochran wrote:

1. Where is the dependency from sal->cppunit specified?


in sal/Executable_cppunittester.mk:


$(eval $(call gb_Executable_use_externals,cppunittester,\
boost_headers \
cppunit \
))



___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2015-05-08 Thread Caolán McNamara
 include/sfx2/mnuitem.hxx |9 -
 sfx2/source/menu/mnuitem.cxx |   15 ---
 2 files changed, 12 insertions(+), 12 deletions(-)

New commits:
commit eef0e91d5ec90d7e972195b8d3b059ffab39c92d
Author: Caolán McNamara 
Date:   Fri May 8 11:07:10 2015 +0100

there's another ExecuteInfo in sw

Change-Id: Id72d3cdfa8b0d5e62fc04ddc464069ac58df0f58

diff --git a/include/sfx2/mnuitem.hxx b/include/sfx2/mnuitem.hxx
index 8e5e0cd..3f6586f 100644
--- a/include/sfx2/mnuitem.hxx
+++ b/include/sfx2/mnuitem.hxx
@@ -120,15 +120,6 @@ inline SfxVirtualMenu* SfxMenuControl::GetPopupMenu() const
{ SfxMenuControl::RegisterMenuControl( pMod, new 
SfxMenuCtrlFactory( \
 Class::CreateImpl, TYPE(nItemClass), nSlotId ) ); }
 
-struct ExecuteInfo
-{
-::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > 
xDispatch;
-::com::sun::star::util::URL
aTargetURL;
-::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >  
aArgs;
-
-DECL_STATIC_LINK( ExecuteInfo, ExecuteHdl_Impl, ExecuteInfo* );
-};
-
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/menu/mnuitem.cxx b/sfx2/source/menu/mnuitem.cxx
index c3daef0..9d10b93 100644
--- a/sfx2/source/menu/mnuitem.cxx
+++ b/sfx2/source/menu/mnuitem.cxx
@@ -327,6 +327,15 @@ SfxUnoMenuControl::~SfxUnoMenuControl()
 pUnoCtrl->release();
 }
 
+struct MenuExecuteInfo
+{
+::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > 
xDispatch;
+::com::sun::star::util::URL
aTargetURL;
+::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >  
aArgs;
+
+DECL_STATIC_LINK( MenuExecuteInfo, ExecuteHdl_Impl, MenuExecuteInfo* );
+};
+
 sal_IntPtr Select_Impl( void* /*pHdl*/, void* pVoid )
 {
 Menu* pMenu = static_cast(pVoid);
@@ -360,17 +369,17 @@ sal_IntPtr Select_Impl( void* /*pHdl*/, void* pVoid )
 
 if ( xDisp.is() )
 {
-ExecuteInfo* pExecuteInfo = new ExecuteInfo;
+MenuExecuteInfo* pExecuteInfo = new MenuExecuteInfo;
 pExecuteInfo->xDispatch = xDisp;
 pExecuteInfo->aTargetURL= aTargetURL;
 pExecuteInfo->aArgs = Sequence< PropertyValue >();
-Application::PostUserEvent( LINK( 0, ExecuteInfo, ExecuteHdl_Impl), 
pExecuteInfo );
+Application::PostUserEvent( LINK( 0, MenuExecuteInfo, 
ExecuteHdl_Impl), pExecuteInfo );
 }
 
 return sal_IntPtr(true);
 }
 
-IMPL_STATIC_LINK_NOINSTANCE( ExecuteInfo, ExecuteHdl_Impl, ExecuteInfo*, 
pExecuteInfo )
+IMPL_STATIC_LINK_NOINSTANCE( MenuExecuteInfo, ExecuteHdl_Impl, 
MenuExecuteInfo*, pExecuteInfo )
 {
 pExecuteInfo->xDispatch->dispatch( pExecuteInfo->aTargetURL, 
pExecuteInfo->aArgs );
 delete pExecuteInfo;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2015-05-08 Thread Michael Meeks
 sfx2/source/dialog/dockwin.cxx |   14 +++---
 1 file changed, 7 insertions(+), 7 deletions(-)

New commits:
commit 1394e45450e58d23223ac3bea264a15e0b2b9078
Author: Michael Meeks 
Date:   Fri May 8 11:07:22 2015 +0100

tdf#91128 - Dockwin post-dispose crash fix.

Change-Id: I46252c272d45209f8cb3fd072df4109440d3fcae

diff --git a/sfx2/source/dialog/dockwin.cxx b/sfx2/source/dialog/dockwin.cxx
index 0c6af19..8b4b8f3 100644
--- a/sfx2/source/dialog/dockwin.cxx
+++ b/sfx2/source/dialog/dockwin.cxx
@@ -450,7 +450,7 @@ void SfxDockingWindow::Resize()
 {
 DockingWindow::Resize();
 Invalidate();
-if ( pImp->bConstructed && pMgr )
+if ( pImp && pImp->bConstructed && pMgr )
 {
 if ( IsFloatingMode() )
 {
@@ -501,7 +501,7 @@ bool SfxDockingWindow::PrepareToggleFloatingMode()
 */
 
 {
-if (!pImp->bConstructed)
+if (!pImp || !pImp->bConstructed)
 return true;
 
 if ( (Application::IsInModalMode() && IsFloatingMode()) || !pMgr )
@@ -554,7 +554,7 @@ void SfxDockingWindow::ToggleFloatingMode()
 SfxDockingWindow::ToggleFloatingMode() must be called.
 */
 {
-if ( !pImp->bConstructed || !pMgr )
+if ( !pImp || !pImp->bConstructed || !pMgr )
 return; // No Handler call
 
 // Remember old alignment and then switch.
@@ -638,7 +638,7 @@ void SfxDockingWindow::StartDocking()
 the end.
 */
 {
-if ( !pImp->bConstructed || !pMgr )
+if ( !pImp || !pImp->bConstructed || !pMgr )
 return;
 SfxChildIdentifier eIdent = SfxChildIdentifier::DOCKINGWINDOW;
 if ( pImp->bSplitable )
@@ -672,7 +672,7 @@ bool SfxDockingWindow::Docking( const Point& rPos, 
Rectangle& rRect )
 if ( Application::IsInModalMode() )
 return true;
 
-if ( !pImp->bConstructed || !pMgr )
+if ( !pImp || !pImp->bConstructed || !pMgr )
 {
 rRect.SetSize( Size() );
 return IsFloatingMode();
@@ -771,7 +771,7 @@ void SfxDockingWindow::EndDocking( const Rectangle& rRect, 
bool bFloatMode )
 SfxDockingWindow::EndDocking() must be called first.
 */
 {
-if ( !pImp->bConstructed || IsDockingCanceled() || !pMgr )
+if ( !pImp || !pImp->bConstructed || IsDockingCanceled() || !pMgr )
 return;
 
 SfxWorkWindow *pWorkWin = pBindings->GetWorkWindow_Impl();
@@ -1242,7 +1242,7 @@ void SfxDockingWindow::FillInfo(SfxChildWinInfo& rInfo) 
const
 if ( !pMgr )
 return;
 
-if ( GetFloatingWindow() && pImp->bConstructed )
+if ( GetFloatingWindow() && pImp && pImp->bConstructed )
 pImp->aWinState = GetFloatingWindow()->GetWindowState();
 
 rInfo.aWinState = pImp->aWinState;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: connectivity/source

2015-05-08 Thread Stephan Bergmann
 connectivity/source/drivers/evoab2/NResultSet.cxx |   70 +-
 connectivity/source/drivers/evoab2/NStatement.cxx |   41 ++---
 connectivity/source/drivers/evoab2/NStatement.hxx |4 
 connectivity/source/drivers/kab/KDriver.cxx   |  151 +++---
 connectivity/source/drivers/kab/KDriver.hxx   |   16 --
 5 files changed, 138 insertions(+), 144 deletions(-)

New commits:
commit ece4466e4ff5f89aad0ec88b39269cfac0dc76c3
Author: Stephan Bergmann 
Date:   Fri May 8 12:27:52 2015 +0200

loplugin:staticmethods

Change-Id: Ic93e560641f1ec1c5fc316ed126617c6d99ab5b5

diff --git a/connectivity/source/drivers/evoab2/NResultSet.cxx 
b/connectivity/source/drivers/evoab2/NResultSet.cxx
index 7fc072f..077bf16 100644
--- a/connectivity/source/drivers/evoab2/NResultSet.cxx
+++ b/connectivity/source/drivers/evoab2/NResultSet.cxx
@@ -368,6 +368,18 @@ OString OEvoabVersionHelper::getUserName( EBook *pBook )
 return aName;
 }
 
+namespace {
+
+bool isBookBackend( EBookClient *pBook, const char *backendname)
+{
+if (!pBook)
+return false;
+ESource *pSource = e_client_get_source ((EClient *) pBook);
+return isSourceBackend(pSource, backendname);
+}
+
+}
+
 class OEvoabVersion36Helper : public OEvoabVersionHelper
 {
 private:
@@ -416,14 +428,6 @@ public:
 return pBook;
 }
 
-bool isBookBackend( EBookClient *pBook, const char *backendname)
-{
-if (!pBook)
-return false;
-ESource *pSource = e_client_get_source ((EClient *) pBook);
-return isSourceBackend(pSource, backendname);
-}
-
 virtual bool isLDAP( EBook *pBook ) SAL_OVERRIDE
 {
 return isBookBackend(pBook, "ldap");
@@ -490,37 +494,41 @@ protected:
 }
 };
 
-class OEvoabVersion35Helper : public OEvoabVersionHelper
-{
-private:
-GList *m_pContacts;
+namespace {
 
-ESource * findSource( const char *id )
-{
-ESourceList *pSourceList = NULL;
+ESource * findSource( const char *id )
+{
+ESourceList *pSourceList = NULL;
 
-g_return_val_if_fail (id != NULL, NULL);
+g_return_val_if_fail (id != NULL, NULL);
 
-if (!e_book_get_addressbooks (&pSourceList, NULL))
-pSourceList = NULL;
+if (!e_book_get_addressbooks (&pSourceList, NULL))
+pSourceList = NULL;
 
-for ( GSList *g = e_source_list_peek_groups (pSourceList); g; g = 
g->next)
+for ( GSList *g = e_source_list_peek_groups (pSourceList); g; g = g->next)
+{
+for (GSList *s = e_source_group_peek_sources (E_SOURCE_GROUP 
(g->data)); s; s = s->next)
 {
-for (GSList *s = e_source_group_peek_sources (E_SOURCE_GROUP 
(g->data)); s; s = s->next)
-{
-ESource *pSource = E_SOURCE (s->data);
-if (!strcmp (e_source_peek_name (pSource), id))
-return pSource;
-}
+ESource *pSource = E_SOURCE (s->data);
+if (!strcmp (e_source_peek_name (pSource), id))
+return pSource;
 }
-return NULL;
 }
+return NULL;
+}
 
-bool isAuthRequired( EBook *pBook )
-{
-return e_source_get_property( e_book_get_source( pBook ),
-  "auth" ) != NULL;
-}
+bool isAuthRequired( EBook *pBook )
+{
+return e_source_get_property( e_book_get_source( pBook ),
+  "auth" ) != NULL;
+}
+
+}
+
+class OEvoabVersion35Helper : public OEvoabVersionHelper
+{
+private:
+GList *m_pContacts;
 
 public:
 OEvoabVersion35Helper()
diff --git a/connectivity/source/drivers/evoab2/NStatement.cxx 
b/connectivity/source/drivers/evoab2/NStatement.cxx
index c824188..f8cb606 100644
--- a/connectivity/source/drivers/evoab2/NStatement.cxx
+++ b/connectivity/source/drivers/evoab2/NStatement.cxx
@@ -49,6 +49,26 @@ using namespace com::sun::star::container;
 using namespace com::sun::star::io;
 using namespace com::sun::star::util;
 
+namespace {
+
+EBookQuery * createTrue()
+{ // Not the world's most efficient unconditional true but ...
+return e_book_query_from_string("(exists \"full_name\")");
+}
+
+EBookQuery * createTest( const OUString &aColumnName,
+ EBookQueryTest eTest,
+ const OUString &aMatch )
+{
+OString sMatch = OUStringToOString( aMatch, RTL_TEXTENCODING_UTF8 );
+OString sColumnName = OUStringToOString( aColumnName, 
RTL_TEXTENCODING_UTF8 );
+
+return e_book_query_field_test( e_contact_field_id( sColumnName.getStr() ),
+eTest, sMatch.getStr() );
+}
+
+}
+
 OCommonStatement::OCommonStatement(OEvoabConnection* _pConnection)
 : OCommonStatement_IBase(m_aMutex)
 , ::comphelper::OPropertyContainer(OCommonStatement_IBase::rBHelper)
@@ -152,27 +172,6 @@ void SAL_CALL OCommonStatement::close(  ) 
throw(SQLException, RuntimeException,
 dispose();
 }
 
-
-EBookQuery *
-OCommonStatement::createTrue()
-{ // N

[Libreoffice-commits] core.git: 2 commits - sc/source vcl/README.lifecycle

2015-05-08 Thread Michael Meeks
 sc/source/ui/inc/tabvwsh.hxx   |6 +++---
 sc/source/ui/view/reffact.cxx  |2 +-
 sc/source/ui/view/tabvwshc.cxx |   11 ++-
 vcl/README.lifecycle   |   24 
 4 files changed, 34 insertions(+), 9 deletions(-)

New commits:
commit b6bd432a584c1361ca6277794f8a5466fc01bc52
Author: Michael Meeks 
Date:   Fri May 8 11:34:22 2015 +0100

vcl: more VclPtr debugging docs in the README.lifecycle.

Change-Id: I49d06d54157e1e7c5b7ce2aa3f8917763de6826d

diff --git a/vcl/README.lifecycle b/vcl/README.lifecycle
index 7c2ceb2..55ec160 100644
--- a/vcl/README.lifecycle
+++ b/vcl/README.lifecycle
@@ -299,4 +299,28 @@ ways and often both.
cleanup methods, especially LoseFocus continue to work even
on disposed Window sub-class instances.
 
+** It crashes with some invalid memory ...
+
+Assuming that the invalid memory is a Window sub-class itself,
+   then almost certainly there is some cockup in the
+   reference-counting; eg. if you hit an OutputDevice::release
+   assert on mnRefCount - then almost certainly you have a
+   Window that has already been destroyed. This can easily
+   happen via this sort of pattern:
+
+   ModelessDialog *pDlg = VclPtr(nullptr /* parent */);
+   // by here the pDlg quite probably points to free'd memory
+   ...
+
+   It is necessary in these cases to ensure that the *pDlg is
+   a VclPtr instead.
+
+** It crashes with some invalid memory #2 ...
+
+   Often a ::dispose method will free some pImpl member, but
+   not NULL it; and (cf. above) we can now get various virtual
+   methods called post-dispose; so:
+
+   a) delete pImpl; pImpl = NULL; // in the destructor
+   b) if (pImpl && ...)   // in the subsequently called method
 
commit 087f7fe50b03307e2d9202365886e8c37bd7e6e3
Author: Michael Meeks 
Date:   Fri May 8 11:33:33 2015 +0100

tdf#91125 - nail a clutch of calc modeless dialog lifecycle issues.

Good idea to hold a reference after creation.

Change-Id: I450c415259c4011c8b3fb8be715e55643765d9db

diff --git a/sc/source/ui/inc/tabvwsh.hxx b/sc/source/ui/inc/tabvwsh.hxx
index 4bc50e5..04e21a9 100644
--- a/sc/source/ui/inc/tabvwsh.hxx
+++ b/sc/source/ui/inc/tabvwsh.hxx
@@ -356,9 +356,9 @@ public:
 voidDeactivateOle();
 
 SC_DLLPUBLIC static ScTabViewShell* GetActiveViewShell();
-SfxModelessDialog*  CreateRefDialog( SfxBindings* pB, SfxChildWindow* pCW,
-SfxChildWinInfo* pInfo,
-vcl::Window* pParent, sal_uInt16 
nSlotId );
+VclPtr CreateRefDialog( SfxBindings* pB, 
SfxChildWindow* pCW,
+   SfxChildWinInfo* pInfo,
+   vcl::Window* pParent, 
sal_uInt16 nSlotId );
 
 voidUpdateOleZoom();
 inline SbxObject* GetScSbxObject() const
diff --git a/sc/source/ui/view/reffact.cxx b/sc/source/ui/view/reffact.cxx
index 4ba4eb9..b05db95f 100644
--- a/sc/source/ui/view/reffact.cxx
+++ b/sc/source/ui/view/reffact.cxx
@@ -90,7 +90,7 @@ namespace
 pViewShell = PTR_CAST( ScTabViewShell, SfxViewShell::Current() ); \
 OSL_ENSURE( pViewShell, "missing view shell :-(" ); \
 pWindow = pViewShell ?  \
-pViewShell->CreateRefDialog( p, this, pInfo, pParentP, sid ) : 
NULL;\
+pViewShell->CreateRefDialog( p, this, pInfo, pParentP, sid ) : 
nullptr;\
 if (pViewShell && !pWindow)
 \
 pViewShell->GetViewFrame()->SetChildWindow( nId, false );  
 \
 }
diff --git a/sc/source/ui/view/tabvwshc.cxx b/sc/source/ui/view/tabvwshc.cxx
index fbbfa24..4d5d2d4 100644
--- a/sc/source/ui/view/tabvwshc.cxx
+++ b/sc/source/ui/view/tabvwshc.cxx
@@ -113,9 +113,10 @@ void 
ScTabViewShell::SwitchBetweenRefDialogs(SfxModelessDialog* pDialog)
}
 }
 
-SfxModelessDialog* ScTabViewShell::CreateRefDialog(
-SfxBindings* pB, SfxChildWindow* pCW, SfxChildWinInfo* 
pInfo,
-vcl::Window* pParent, sal_uInt16 nSlotId )
+VclPtr ScTabViewShell::CreateRefDialog(
+SfxBindings* pB, SfxChildWindow* pCW,
+SfxChildWinInfo* pInfo,
+vcl::Window* pParent, sal_uInt16 nSlotId )
 {
 //  Dialog nur aufmachen, wenn ueber ScModule::SetRefDialog gerufen, damit
 //  z.B. nach einem Absturz offene Ref-Dialoge nicht wiederkommen 
(#42341#).
@@ -132,7 +133,7 @@ SfxModelessDialog* ScTabViewShell::CreateRefDialog(
 return NULL;
 }
 
-SfxModelessDialog* pResult = 0;
+VclPtr pResult;
 
 if(pCW)
 pCW->SetHideNotDelete(true);
@@ -156,7 +157,7 @@ SfxModelessDialog* ScTabViewShell::CreateRefDialog(
  ScAddress( G

[Libreoffice-commits] core.git: solenv/bin

2015-05-08 Thread Andras Timar
 solenv/bin/modules/installer/simplepackage.pm |7 +++
 1 file changed, 7 insertions(+)

New commits:
commit 2df138b483f60ffdcd3b62c8c2884d2f5cc076af
Author: Andras Timar 
Date:   Fri May 8 11:38:56 2015 +0200

tdf#78834 enable localized system dialogs on OS X

Change-Id: I37f5b183b36f2a3077f591162402ddd83e4a46d4
Reviewed-on: https://gerrit.libreoffice.org/15673
Reviewed-by: Andras Timar 
Tested-by: Andras Timar 

diff --git a/solenv/bin/modules/installer/simplepackage.pm 
b/solenv/bin/modules/installer/simplepackage.pm
index ae91d0c..d470b4e 100644
--- a/solenv/bin/modules/installer/simplepackage.pm
+++ b/solenv/bin/modules/installer/simplepackage.pm
@@ -395,6 +395,13 @@ sub create_package
 }
 else
 {
+my $subdir = 
"$tempdir/$packagename/$volume_name_classic_app.app/Contents/Resources";
+if ( ! -d $subdir ) { 
installer::systemactions::create_directory($subdir); }
+# iterate over OS X localizations
+foreach $lang ("ca", "cs", "da", "de", "el", "en", "es", "fi", 
"fr", "hr", "hu", "id", "it", "ja", "ko", "ms", "nl", "no", "pl", "pt", 
"pt_PT", "ro", "ru", "sk", "sv", "th", "tr", "uk", "vi", "zh_CN", "zh_TW")
+{
+installer::systemactions::create_directory($subdir . "/" . 
$lang . ".lproj");
+}
 if (($volume_name_classic_app eq 'LibreOffice' || 
$volume_name_classic_app eq 'LibreOfficeDev') &&
 defined($ENV{'MACOSX_CODESIGNING_IDENTITY'}) && 
$ENV{'MACOSX_CODESIGNING_IDENTITY'} ne "" )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-4.3' - 2 commits - distro-configs/CPOSX.conf solenv/bin

2015-05-08 Thread Andras Timar
 distro-configs/CPOSX.conf |1 -
 solenv/bin/modules/installer/simplepackage.pm |7 +++
 2 files changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 1baeefbe596142484daed14576af09b30cce07db
Author: Andras Timar 
Date:   Fri May 8 11:38:56 2015 +0200

tdf#78834 enable localized system dialogs on OS X

Change-Id: I37f5b183b36f2a3077f591162402ddd83e4a46d4
Reviewed-on: https://gerrit.libreoffice.org/15673
Reviewed-by: Andras Timar 
Tested-by: Andras Timar 
(cherry picked from commit 2df138b483f60ffdcd3b62c8c2884d2f5cc076af)

diff --git a/solenv/bin/modules/installer/simplepackage.pm 
b/solenv/bin/modules/installer/simplepackage.pm
index 118d420..81d765d 100644
--- a/solenv/bin/modules/installer/simplepackage.pm
+++ b/solenv/bin/modules/installer/simplepackage.pm
@@ -395,6 +395,13 @@ sub create_package
 }
 else
 {
+my $subdir = 
"$tempdir/$packagename/$volume_name_classic_app.app/Contents/Resources";
+if ( ! -d $subdir ) { 
installer::systemactions::create_directory($subdir); }
+# iterate over OS X localizations
+foreach $lang ("ca", "cs", "da", "de", "el", "en", "es", "fi", 
"fr", "hr", "hu", "id", "it", "ja", "ko", "ms", "nl", "no", "pl", "pt", 
"pt_PT", "ro", "ru", "sk", "sv", "th", "tr", "uk", "vi", "zh_CN", "zh_TW")
+{
+installer::systemactions::create_directory($subdir . "/" . 
$lang . ".lproj");
+}
 if (($volume_name_classic_app eq 'LibreOffice' || 
$volume_name_classic_app eq 'LibreOfficeDev') &&
 defined($ENV{'MACOSX_CODESIGNING_IDENTITY'}) && 
$ENV{'MACOSX_CODESIGNING_IDENTITY'} ne "" )
 {
commit 8d0ce0be05a528632de49b6e1074554ab545
Author: Andras Timar 
Date:   Fri May 8 13:32:17 2015 +0200

tweak CPOSX.conf

Change-Id: I56ba01d0a7b3bad6cb152e080a5c6c9f926c7949

diff --git a/distro-configs/CPOSX.conf b/distro-configs/CPOSX.conf
index f591a92..9767287 100644
--- a/distro-configs/CPOSX.conf
+++ b/distro-configs/CPOSX.conf
@@ -7,7 +7,6 @@
 --disable-online-update
 --disable-odk
 --enable-epm
---with-macosx-sdk=10.8
 --with-macosx-version-min-required=10.6
 --enable-ext-wiki-publisher
 --enable-report-builder
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2015-05-08 Thread Caolán McNamara
 sw/source/core/inc/flowfrm.hxx|8 
 sw/source/core/inc/txtfrm.hxx |   34 +++---
 sw/source/core/layout/flowfrm.cxx |2 +-
 sw/source/core/layout/layact.cxx  |2 +-
 sw/source/core/text/frmform.cxx   |6 +++---
 sw/source/core/text/frmpaint.cxx  |4 ++--
 sw/source/core/text/txtfrm.cxx|4 ++--
 sw/source/core/text/txthyph.cxx   |2 +-
 8 files changed, 41 insertions(+), 21 deletions(-)

New commits:
commit 303f08fe4292341cda40f70da3d0f82d69f697aa
Author: Caolán McNamara 
Date:   Fri May 8 12:37:39 2015 +0100

rename these scope lock guards, no logic change

Change-Id: Ib1ec9c07ef38e22d739e80693eeb2d52e8e3b5f7

diff --git a/sw/source/core/inc/flowfrm.hxx b/sw/source/core/inc/flowfrm.hxx
index 59bafa4..4d27910 100644
--- a/sw/source/core/inc/flowfrm.hxx
+++ b/sw/source/core/inc/flowfrm.hxx
@@ -62,7 +62,7 @@ class SwFlowFrm
 friend inline void TableSplitRecalcUnlock( SwFlowFrm * );
 // #i44049#
 friend class SwObjectFormatterTxtFrm;
-friend class JoinLockGuard;
+friend class FlowFrmJoinLockGuard;
 
 // TblSel is allowed to reset the follow-bit
 friend inline void UnsetFollow( SwFlowFrm *pFlow );
@@ -238,7 +238,7 @@ inline bool SwFlowFrm::IsFwdMoveAllowed()
 
 //use this to protect a SwLayoutFrm for a given scope from getting merged with
 //its neighbour and thus deleted
-class JoinLockGuard
+class FlowFrmJoinLockGuard
 {
 private:
 SwFlowFrm *m_pFlow;
@@ -247,7 +247,7 @@ public:
 //JoinLock pParent for the lifetime of the Cut/Paste call, etc. to avoid
 //SwSectionFrm::MergeNext removing the pParent we're trying to reparent
 //into
-JoinLockGuard(SwLayoutFrm* pFrm)
+FlowFrmJoinLockGuard(SwLayoutFrm* pFrm)
 {
 m_pFlow = SwFlowFrm::CastFlowFrm(pFrm);
 if (m_pFlow)
@@ -261,7 +261,7 @@ public:
 }
 }
 
-~JoinLockGuard()
+~FlowFrmJoinLockGuard()
 {
 if (m_pFlow && !m_bOldJoinLocked)
 m_pFlow->UnlockJoin();
diff --git a/sw/source/core/inc/txtfrm.hxx b/sw/source/core/inc/txtfrm.hxx
index 7fe60f1..784db5f 100644
--- a/sw/source/core/inc/txtfrm.hxx
+++ b/sw/source/core/inc/txtfrm.hxx
@@ -53,7 +53,7 @@ class SwTxtFrm: public SwCntntFrm
 friend class SwTxtIter;
 friend class SwTestFormat;
 friend class WidowsAndOrphans;
-friend class SwTxtFrmLocker; // May Lock()/Unlock()
+friend class TxtFrmLockGuard; // May Lock()/Unlock()
 friend bool sw_ChangeOffset( SwTxtFrm* pFrm, sal_Int32 nNew );
 
 static SwCache *pTxtCache;  // Pointer to the Line Cache
@@ -649,15 +649,35 @@ public:
 virtual void dumpAsXmlAttributes(xmlTextWriterPtr writer) const 
SAL_OVERRIDE;
 };
 
-class SwTxtFrmLocker
+//use this to protect a SwTxtFrm for a given scope from getting merged with
+//its neighbour and thus deleted
+class TxtFrmLockGuard
 {
 private:
-SwTxtFrm * const pFrm;
+SwTxtFrm *m_pTxtFrm;
+bool m_bOldLocked;
 public:
-inline SwTxtFrmLocker( SwTxtFrm *pTxtFrm )
-: pFrm( pTxtFrm->IsLocked() ? 0 : pTxtFrm )
-{ if( pFrm ) pFrm->Lock(); }
-inline ~SwTxtFrmLocker() { if( pFrm ) pFrm->Unlock(); }
+//Lock pFrm for the lifetime of the Cut/Paste call, etc. to avoid
+//SwTxtFrm::_AdjustFollow removing the pFrm we're trying to Make
+TxtFrmLockGuard(SwFrm* pFrm)
+{
+m_pTxtFrm = pFrm->IsTxtFrm() ? static_cast(pFrm) : 0;
+if (m_pTxtFrm)
+{
+m_bOldLocked = m_pTxtFrm->IsLocked();
+m_pTxtFrm->Lock();
+}
+else
+{
+m_bOldLocked = false;
+}
+}
+
+~TxtFrmLockGuard()
+{
+if (m_pTxtFrm && !m_bOldLocked)
+m_pTxtFrm->Unlock();
+}
 };
 
 inline const SwParaPortion *SwTxtFrm::GetPara() const
diff --git a/sw/source/core/layout/flowfrm.cxx 
b/sw/source/core/layout/flowfrm.cxx
index f84d7a8..a41bb67 100644
--- a/sw/source/core/layout/flowfrm.cxx
+++ b/sw/source/core/layout/flowfrm.cxx
@@ -581,7 +581,7 @@ void SwFlowFrm::MoveSubTree( SwLayoutFrm* pParent, SwFrm* 
pSibling )
 //JoinLock pParent for the lifetime of the Cut/Paste call to avoid
 //SwSectionFrm::MergeNext removing the pParent we're trying to reparent
 //into
-JoinLockGuard aJoinGuard(pParent);
+FlowFrmJoinLockGuard aJoinGuard(pParent);
 pOldParent = CutTree( &m_rThis );
 bInvaLay = PasteTree( &m_rThis, pParent, pSibling, pOldParent );
 }
diff --git a/sw/source/core/layout/layact.cxx b/sw/source/core/layout/layact.cxx
index 88e5fe0..732c67a 100644
--- a/sw/source/core/layout/layact.cxx
+++ b/sw/source/core/layout/layact.cxx
@@ -1242,7 +1242,7 @@ bool SwLayAction::FormatLayout( SwLayoutFrm *pLay, bool 
bAddRect )
 {
 //JoinLock pParent for the lifetime of the Calc call to avoid
 //SwSectionFrm::MergeNext removing the pLay we're trying to Format
-JoinLockGuard aJoinGuard(pLay);
+FlowFrmJoinLockGuard 

[Libreoffice-commits] core.git: Branch 'refs/notes/commits' - 5b/0df64160678bbbd373bd80de8583d25c77df49

2015-05-08 Thread Caolán McNamara
 5b/0df64160678bbbd373bd80de8583d25c77df49 |1 +
 1 file changed, 1 insertion(+)

New commits:
commit fe5d4a8e050bb37559041f712e39110d2ce7
Author: Caolán McNamara 
Date:   Fri May 8 12:40:33 2015 +0100

Notes added by 'git notes add'

diff --git a/5b/0df64160678bbbd373bd80de8583d25c77df49 
b/5b/0df64160678bbbd373bd80de8583d25c77df49
new file mode 100644
index 000..7239d27
--- /dev/null
+++ b/5b/0df64160678bbbd373bd80de8583d25c77df49
@@ -0,0 +1 @@
+prefer: f974db5d89eacf0c23e303c22c62972014e9db16
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: include/vcl sd/source vcl/osx vcl/win

2015-05-08 Thread Noel Grandin
 include/vcl/cmdevt.hxx   |   53 ---
 sd/source/ui/app/sdmod1.cxx  |2 -
 sd/source/ui/slideshow/slideshowimpl.cxx |   22 ++--
 vcl/osx/salinst.cxx  |   22 ++--
 vcl/win/source/window/salframe.cxx   |   36 ++---
 5 files changed, 69 insertions(+), 66 deletions(-)

New commits:
commit 32186f005088fbace08b791df5cf5557f6e5fd24
Author: Noel Grandin 
Date:   Wed May 6 15:42:16 2015 +0200

convert MEDIA_COMMAND constants to scoped enum

Change-Id: Id3731144fab89cdab9a6f66d78a1ebe1ebd4f61c
Reviewed-on: https://gerrit.libreoffice.org/15652
Reviewed-by: Noel Grandin 
Tested-by: Noel Grandin 

diff --git a/include/vcl/cmdevt.hxx b/include/vcl/cmdevt.hxx
index fd308eb..3216468 100644
--- a/include/vcl/cmdevt.hxx
+++ b/include/vcl/cmdevt.hxx
@@ -274,40 +274,43 @@ public:
 };
 
 // Media Commands
-#define MEDIA_COMMAND_CHANNEL_DOWN   ((sal_Int16)1) // Decrement the 
channel value, for example, for a TV or radio tuner.
-#define MEDIA_COMMAND_CHANNEL_UP ((sal_Int16)2) // Increment the 
channel value, for example, for a TV or radio tuner.
-#define MEDIA_COMMAND_NEXTTRACK  ((sal_Int16)3) // Go to next 
media track/slide.
-#define MEDIA_COMMAND_PAUSE  ((sal_Int16)4) // Pause. If 
already paused, take no further action. This is a direct PAUSE command that has 
no state.
-#define MEDIA_COMMAND_PLAY   ((sal_Int16)5) // Begin playing 
at the current position. If already paused, it will resume. This is a direct 
PLAY command that has no state.
-#define MEDIA_COMMAND_PLAY_PAUSE ((sal_Int16)6) // Play or pause 
playback.
-#define MEDIA_COMMAND_PREVIOUSTRACK  ((sal_Int16)7) // Go to previous 
media track/slide.
-#define MEDIA_COMMAND_RECORD ((sal_Int16)8) // Begin recording 
the current stream.
-#define MEDIA_COMMAND_REWIND ((sal_Int16)9)// Go backward in a 
stream at a higher rate of speed.
-#define MEDIA_COMMAND_STOP   ((sal_Int16)10)// Stop playback.
-#define MEDIA_COMMAND_MIC_ON_OFF_TOGGLE  ((sal_Int16)11)// Toggle the 
microphone.
-#define MEDIA_COMMAND_MICROPHONE_VOLUME_DOWN ((sal_Int16)12)// Increase 
microphone volume.
-#define MEDIA_COMMAND_MICROPHONE_VOLUME_MUTE ((sal_Int16)13)// Mute the 
microphone.
-#define MEDIA_COMMAND_MICROPHONE_VOLUME_UP   ((sal_Int16)14)// Decrease 
microphone volume.
-#define MEDIA_COMMAND_VOLUME_DOWN((sal_Int16)15)// Lower the 
volume.
-#define MEDIA_COMMAND_VOLUME_MUTE((sal_Int16)16)// Mute the volume.
-#define MEDIA_COMMAND_VOLUME_UP  ((sal_Int16)17)// Raise the 
volume.
-#define MEDIA_COMMAND_MENU   ((sal_Int16)18)// Button Menu 
pressed.
-#define MEDIA_COMMAND_MENU_HOLD  ((sal_Int16)19)// Button Menu 
(long) pressed.
-#define MEDIA_COMMAND_PLAY_HOLD  ((sal_Int16)20)// Button Play 
(long) pressed.
-#define MEDIA_COMMAND_NEXTTRACK_HOLD ((sal_Int16)21)// Button Right 
holding pressed.
-#define MEDIA_COMMAND_PREVIOUSTRACK_HOLD ((sal_Int16)22)// Button Left 
holding pressed.
+enum class MediaCommand
+{
+ChannelDown   = 1, // Decrement the channel value, for example, 
for a TV or radio tuner.
+ChannelUp = 2, // Increment the channel value, for example, 
for a TV or radio tuner.
+NextTrack = 3, // Go to next media track/slide.
+Pause = 4, // Pause. If already paused, take no further 
action. This is a direct PAUSE command that has no state.
+Play  = 5, // Begin playing at the current position. If 
already paused, it will resume. This is a direct PLAY command that has no state.
+PlayPause = 6, // Play or pause playback.
+PreviousTrack = 7, // Go to previous media track/slide.
+Record= 8, // Begin recording the current stream.
+Rewind= 9,// Go backward in a stream at a higher rate of 
speed.
+Stop  = 10,// Stop playback.
+MicOnOffToggle= 11,// Toggle the microphone.
+MicrophoneVolumeDown  = 12,// Increase microphone volume.
+MicrophoneVolumeMute  = 13,// Mute the microphone.
+MicrophoneVolumeUp= 14,// Decrease microphone volume.
+VolumeDown= 15,// Lower the volume.
+VolumeMute= 16,// Mute the volume.
+VolumeUp  = 17,// Raise the volume.
+Menu  = 18,// Button Menu pressed.
+MenuHold  = 19,// Button Menu (long) pressed.
+PlayHold  = 20,// Button Play (long) pressed.
+NextTrackHold = 21,// Button Right holding pressed.
+PreviousTrackHold = 22,// Button Left holding pressed.
+};
 
 class VCL_DLLPUBLIC CommandMediaData
 {
-sal_Int16 m_nMediaId;
+MediaCommand m_nMediaId;
 bool m_bPassThroughToOS;
 public:
-CommandMediaDa

[Libreoffice-commits] core.git: 2 commits - uui/source

2015-05-08 Thread Caolán McNamara
 uui/source/iahndl-locking.cxx |   11 ---
 1 file changed, 4 insertions(+), 7 deletions(-)

New commits:
commit f0bed251563113311d73312f0126bcf8852f888e
Author: Caolán McNamara 
Date:   Fri May 8 12:51:16 2015 +0100

VclPtr: presumably these also leak

Change-Id: Ib92a1d91464bc95a80415e1651bac78a65a8b31d

diff --git a/uui/source/iahndl-locking.cxx b/uui/source/iahndl-locking.cxx
index cd55c38..db43be7 100644
--- a/uui/source/iahndl-locking.cxx
+++ b/uui/source/iahndl-locking.cxx
@@ -160,8 +160,7 @@ handleChangedByOthersRequest_(
 if (!xManager.get())
 return;
 
-VclPtr< FileChangedQueryBox > xDialog(
-VclPtr::Create( pParent, xManager.get() ) );
+ScopedVclPtrInstance< FileChangedQueryBox > xDialog(pParent, 
xManager.get());
 sal_Int32 nResult = xDialog->Execute();
 
 if ( nResult == RET_YES )
@@ -195,8 +194,7 @@ handleLockFileIgnoreRequest_(
 if (!xManager.get())
 return;
 
-VclPtr< LockFailedQueryBox > xDialog(
-VclPtr::Create( pParent, xManager.get() ) );
+ScopedVclPtrInstance< LockFailedQueryBox > xDialog(pParent, 
xManager.get());
 sal_Int32 nResult = xDialog->Execute();
 
 if ( nResult == RET_OK )
commit fdb363b43f515827a6b98877ea28a7ed0958ca69
Author: Caolán McNamara 
Date:   Fri May 8 12:49:30 2015 +0100

VclPtr: AlreadyOpenQueryBox doesn't get deleted

Change-Id: I793b4377067bd3abc92c943aa0005fd4771b1460

diff --git a/uui/source/iahndl-locking.cxx b/uui/source/iahndl-locking.cxx
index 0b7c5cf..cd55c38 100644
--- a/uui/source/iahndl-locking.cxx
+++ b/uui/source/iahndl-locking.cxx
@@ -120,11 +120,10 @@ handleLockedDocumentRequest_(
 aMessage = UUIInteractionHelper::replaceMessageWithArguments(
 aMessage, aArguments );
 
-VclPtr< AlreadyOpenQueryBox > xDialog(
-VclPtr::Create( pParent,
+ScopedVclPtrInstance< AlreadyOpenQueryBox > xDialog( pParent,
  xManager.get(),
  aMessage,
- nMode == UUI_DOC_OWN_SAVE_LOCK ) );
+ nMode == UUI_DOC_OWN_SAVE_LOCK );
 nResult = xDialog->Execute();
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: vcl/source

2015-05-08 Thread Michael Meeks
 vcl/source/control/ctrl.cxx |   13 +
 1 file changed, 5 insertions(+), 8 deletions(-)

New commits:
commit 94cd5204e302950038278f3828a2d98c51361167
Author: Michael Meeks 
Date:   Fri May 8 12:20:18 2015 +0100

vcl: Control - hold a VclPtr instead of a dogtag over emission.

Change-Id: Ibedf2fc25ac141e10d07ba757fa6c76a4c4a6cff

diff --git a/vcl/source/control/ctrl.cxx b/vcl/source/control/ctrl.cxx
index af9b3d4..34c4248 100644
--- a/vcl/source/control/ctrl.cxx
+++ b/vcl/source/control/ctrl.cxx
@@ -324,21 +324,18 @@ void Control::AppendLayoutData( const Control& 
rSubControl ) const
 }
 }
 
-bool Control::ImplCallEventListenersAndHandler(  sal_uLong nEvent, const 
Link<>& rHandler, void* pCaller )
+bool Control::ImplCallEventListenersAndHandler( sal_uLong nEvent, const 
Link<>& rHandler, void* pCaller )
 {
-ImplDelData aCheckDelete;
-ImplAddDel( &aCheckDelete );
+VclPtr xThis(this);
 
 CallEventListeners( nEvent );
-if ( !aCheckDelete.IsDead() )
+
+if ( !xThis->IsDisposed() )
 {
 rHandler.Call( pCaller );
 
-if ( !aCheckDelete.IsDead() )
-{
-ImplRemoveDel( &aCheckDelete );
+if ( !xThis->IsDisposed() )
 return false;
-}
 }
 return true;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: uui/source

2015-05-08 Thread Caolán McNamara
 uui/source/iahndl-authentication.cxx |   11 +--
 1 file changed, 5 insertions(+), 6 deletions(-)

New commits:
commit cd3e9457dac61766791adb59032b0202c0037505
Author: Caolán McNamara 
Date:   Fri May 8 12:56:07 2015 +0100

VclPtr: presumably these also leak

Change-Id: I6118e908e2c56f67593315e8d8499b28b9489810

diff --git a/uui/source/iahndl-authentication.cxx 
b/uui/source/iahndl-authentication.cxx
index 47ed642..3249e9d 100644
--- a/uui/source/iahndl-authentication.cxx
+++ b/uui/source/iahndl-authentication.cxx
@@ -88,8 +88,7 @@ executeLoginDialog(
 if (!bCanUseSysCreds)
 nFlags |= LF_NO_USESYSCREDS;
 
-VclPtr< LoginDialog > xDialog(
-VclPtr::Create(pParent, nFlags, 
rInfo.GetServer(), rRealm));
+ScopedVclPtrInstance< LoginDialog > xDialog(pParent, nFlags, 
rInfo.GetServer(), rRealm);
 if (!rInfo.GetErrorText().isEmpty())
 xDialog->SetErrorText(rInfo.GetErrorText());
 xDialog->SetName(rInfo.GetUserName());
@@ -417,8 +416,8 @@ executeMasterPasswordDialog(
 boost::scoped_ptr< ResMgr > xManager(ResMgr::CreateResMgr("uui"));
 if( nMode == task::PasswordRequestMode_PASSWORD_CREATE )
 {
-VclPtr< MasterPasswordCreateDialog > xDialog(
-VclPtr::Create(pParent, 
xManager.get()));
+ScopedVclPtrInstance< MasterPasswordCreateDialog > xDialog(
+pParent, xManager.get());
 rInfo.SetResult(xDialog->Execute()
 == RET_OK ? ERRCODE_BUTTON_OK : ERRCODE_BUTTON_CANCEL);
 aMaster = OUStringToOString(
@@ -426,8 +425,8 @@ executeMasterPasswordDialog(
 }
 else
 {
-VclPtr< MasterPasswordDialog > xDialog(
-VclPtr::Create(pParent, nMode, 
xManager.get()));
+ScopedVclPtrInstance< MasterPasswordDialog > xDialog(
+pParent, nMode, xManager.get());
 rInfo.SetResult(xDialog->Execute()
 == RET_OK ? ERRCODE_BUTTON_OK : ERRCODE_BUTTON_CANCEL);
 aMaster = OUStringToOString(
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Build dependency on external cppunit

2015-05-08 Thread Richard Cochran
On Fri, May 08, 2015 at 12:08:23PM +0200, Stephan Bergmann wrote:
> On 05/08/2015 10:45 AM, Richard Cochran wrote:
> >1. Where is the dependency from sal->cppunit specified?
> 
> in sal/Executable_cppunittester.mk:
> 
> >$(eval $(call gb_Executable_use_externals,cppunittester,\
> > boost_headers \
> > cppunit \
> >))

Hm, I saw that, but still the build breaks.  The include path would be
correct, but the cppunit tar file never gets unpacked.

Any ideas?

Can't I just force cppunit to build manually beforehand?


Thanks,
Richard
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: sw/inc sw/qa sw/source

2015-05-08 Thread Caolán McNamara
 sw/inc/modeltoviewhelper.hxx |   25 ++---
 sw/qa/core/uwriter.cxx   |   32 +--
 sw/source/core/txtnode/modeltoviewhelper.cxx |   22 +-
 sw/source/core/txtnode/ndtxt.cxx |4 +--
 sw/source/core/txtnode/txtedt.cxx|2 -
 5 files changed, 47 insertions(+), 38 deletions(-)

New commits:
commit 520400e8faf8e7346d16f34babb6258033673e12
Author: Caolán McNamara 
Date:   Fri May 8 12:59:51 2015 +0100

convert EXPAND constants to scoped enum

Change-Id: I98a0fecf15337db729b39b80aa9c664abcdd3daa

diff --git a/sw/inc/modeltoviewhelper.hxx b/sw/inc/modeltoviewhelper.hxx
index d99c9db..386b536 100644
--- a/sw/inc/modeltoviewhelper.hxx
+++ b/sw/inc/modeltoviewhelper.hxx
@@ -22,6 +22,7 @@
 
 #include 
 #include 
+#include 
 #include 
 
 class SwTxtNode;
@@ -61,13 +62,21 @@ class SwTxtNode;
 0111: expanding fields + hiding hiddens + hiding redlines gives: BB 
foo C foo D
 */
 
-#define PASSTHROUGH0x
-#define EXPANDFIELDS   0x0001
-#define EXPANDFOOTNOTE 0x0002
-#define HIDEINVISIBLE  0x0004
-#define HIDEDELETIONS  0x0008
-/// do not expand to content, but replace with ZWSP
-#define REPLACEMODE0x0010
+enum class ExpandMode
+{
+PassThrough= 0x,
+ExpandFields   = 0x0001,
+ExpandFootnote = 0x0002,
+HideInvisible  = 0x0004,
+HideDeletions  = 0x0008,
+/// do not expand to content, but replace with zwsp
+ReplaceMode= 0x0010,
+};
+
+namespace o3tl
+{
+template<> struct typed_flags : is_typed_flags {};
+}
 
 class ModelToViewHelper
 {
@@ -118,7 +127,7 @@ public:
 
 ModelToViewHelper(const SwTxtNode &rNode,
 // defaults are appropriate for spell/grammar checking
-sal_uInt16 eMode = EXPANDFIELDS | EXPANDFOOTNOTE | REPLACEMODE);
+ExpandMode eMode = ExpandMode::ExpandFields | 
ExpandMode::ExpandFootnote | ExpandMode::ReplaceMode);
 ModelToViewHelper() //pass through filter, view == model
 {
 }
diff --git a/sw/qa/core/uwriter.cxx b/sw/qa/core/uwriter.cxx
index b56d308..1d5986c 100644
--- a/sw/qa/core/uwriter.cxx
+++ b/sw/qa/core/uwriter.cxx
@@ -341,7 +341,7 @@ void SwDocTest::testModelToViewHelperPassthrough()
 {
 SwTxtNode* pTxtNode = getModelToViewTestDocument(m_pDoc);
 
-ModelToViewHelper aModelToViewHelper(*pTxtNode, PASSTHROUGH);
+ModelToViewHelper aModelToViewHelper(*pTxtNode, ExpandMode::PassThrough);
 OUString sViewText = aModelToViewHelper.getViewText();
 OUString sModelText = pTxtNode->GetTxt();
 CPPUNIT_ASSERT_EQUAL(sModelText, sViewText);
@@ -351,7 +351,7 @@ void 
SwDocTest::testModelToViewHelperExpandFieldsExpandFootnote()
 {
 SwTxtNode* pTxtNode = getModelToViewTestDocument(m_pDoc);
 
-ModelToViewHelper aModelToViewHelper(*pTxtNode, EXPANDFIELDS | 
EXPANDFOOTNOTE);
+ModelToViewHelper aModelToViewHelper(*pTxtNode, ExpandMode::ExpandFields | 
ExpandMode::ExpandFootnote);
 OUString sViewText = aModelToViewHelper.getViewText();
 CPPUNIT_ASSERT_EQUAL(
 OUString("A B foo C foo D"), sViewText);
@@ -362,7 +362,7 @@ void 
SwDocTest::testModelToViewHelperExpandFieldsExpandFootnoteReplaceMode()
 SwTxtNode* pTxtNode = getModelToViewTestDocument(m_pDoc);
 
 ModelToViewHelper aModelToViewHelper(*pTxtNode,
-EXPANDFIELDS | EXPANDFOOTNOTE | REPLACEMODE);
+ExpandMode::ExpandFields | ExpandMode::ExpandFootnote | 
ExpandMode::ReplaceMode);
 OUString sViewText = aModelToViewHelper.getViewText();
 CPPUNIT_ASSERT_EQUAL(
 OUString("A B " + OUString(CHAR_ZWSP) + " C " + 
OUString(CHAR_ZWSP) + " D"),
@@ -381,7 +381,7 @@ void SwDocTest::testModelToViewHelperExpandFields()
 {
 SwTxtNode* pTxtNode = getModelToViewTestDocument(m_pDoc);
 
-ModelToViewHelper aModelToViewHelper(*pTxtNode, EXPANDFIELDS);
+ModelToViewHelper aModelToViewHelper(*pTxtNode, ExpandMode::ExpandFields);
 OUString sViewText = aModelToViewHelper.getViewText();
 CPPUNIT_ASSERT_EQUAL(
 OUString("A B  C  D"), sViewText);
@@ -392,7 +392,7 @@ void 
SwDocTest::testModelToViewHelperExpandFieldsReplaceMode()
 SwTxtNode* pTxtNode = getModelToViewTestDocument(m_pDoc);
 
 ModelToViewHelper aModelToViewHelper(*pTxtNode,
-EXPANDFIELDS | REPLACEMODE);
+ExpandMode::ExpandFields | ExpandMode::ReplaceMode);
 OUString sViewText = aModelToViewHelper.getViewText();
 CPPUNIT_ASSERT_EQUAL(OUString("A B  C  D"),
 sViewText);
@@ -406,7 +406,7 @@ void 
SwDocTest::testModelToViewHelperExpandFieldsHideInvisible()
 {
 SwTxtNode* pTxtNode = getModelToViewTestDocument(m_pDoc);
 
-ModelToViewHelper aModelToViewHelper(*pTxtNode, HIDEINVISIBLE);
+ModelToViewHelper aModelToViewHelper(*pTxtNode, ExpandMode::HideInvisible);
 OUString sViewText = aModelToViewHelper.getViewText();
 CPPUNIT_ASSERT_EQUAL(
 OUStri

[Libreoffice-commits] core.git: svtools/source

2015-05-08 Thread Miklos Vajna
 svtools/source/control/roadmap.cxx |7 +++
 1 file changed, 7 insertions(+)

New commits:
commit d174c1abc872e2f63b529455c19a92c1063b24a6
Author: Miklos Vajna 
Date:   Fri May 8 13:20:24 2015 +0200

tdf#91157 svtools: fix missing dispose in RoadmapItem causing MM crash

Change-Id: I42a67ac2712dcf124e4fea3c9bbf705f211fe008

diff --git a/svtools/source/control/roadmap.cxx 
b/svtools/source/control/roadmap.cxx
index 7376c1b..52ac89a 100644
--- a/svtools/source/control/roadmap.cxx
+++ b/svtools/source/control/roadmap.cxx
@@ -57,6 +57,7 @@ namespace svt
 
 public:
 RoadmapItem( ORoadmap& _rParent, const Size& _rItemPlayground );
+~RoadmapItem();
 
 voidSetID( sal_Int16 _ID );
 sal_Int16   GetID() const;
@@ -686,6 +687,12 @@ namespace svt
 mpDescription->Show();
 }
 
+RoadmapItem::~RoadmapItem()
+{
+mpID.disposeAndClear();
+mpDescription.disposeAndClear();
+}
+
 
 bool RoadmapItem::Contains( const vcl::Window* _pWindow ) const
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: mysqlc/source

2015-05-08 Thread Stephan Bergmann
 mysqlc/source/mysqlc_connection.cxx |6 --
 mysqlc/source/mysqlc_connection.hxx |5 -
 2 files changed, 11 deletions(-)

New commits:
commit ecad097109609ca590f227b09f74fdb679903c77
Author: Stephan Bergmann 
Date:   Fri May 8 14:37:28 2015 +0200

Remove dead code

Change-Id: Id2b755c500c32392cdb5cc84ee901f0737347350

diff --git a/mysqlc/source/mysqlc_connection.cxx 
b/mysqlc/source/mysqlc_connection.cxx
index d26558b..d6a8fe4 100644
--- a/mysqlc/source/mysqlc_connection.cxx
+++ b/mysqlc/source/mysqlc_connection.cxx
@@ -551,12 +551,6 @@ void SAL_CALL OConnection::clearWarnings()
 // you should clear your collected warnings here#
 }
 
-void OConnection::buildTypeInfo()
-throw(SQLException)
-{
-OSL_TRACE("OConnection::buildTypeInfo");
-}
-
 void OConnection::disposing()
 {
 OSL_TRACE("OConnection::disposing");
diff --git a/mysqlc/source/mysqlc_connection.hxx 
b/mysqlc/source/mysqlc_connection.hxx
index 801ba70..aeb9686 100644
--- a/mysqlc/source/mysqlc_connection.hxx
+++ b/mysqlc/source/mysqlc_connection.hxx
@@ -118,8 +118,6 @@ namespace connectivity
 boolm_bUseCatalog;  // should we use the catalog on filebased 
databases
 boolm_bUseOldDateFormat;
 
-
-voidbuildTypeInfo() throw(SQLException);
 public:
 rtl::OUString getMysqlVariable(const char *varname)
 
throw(SQLException, RuntimeException);
@@ -133,9 +131,6 @@ namespace connectivity
 OConnection(MysqlCDriver& _rDriver, sql::Driver * cppDriver);
 virtual ~OConnection();
 
-void closeAllStatements ()  
throw(SQLException);
-
-
 rtl_TextEncoding getConnectionEncoding() { return 
m_settings.encoding; }
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Build dependency on external cppunit

2015-05-08 Thread Miklos Vajna
Hi Richard,

On Fri, May 08, 2015 at 02:12:45PM +0200, Richard Cochran 
 wrote:
> Can't I just force cppunit to build manually beforehand?

make cppunit.all

Should do that, though you just hide the root cause with that. :-)

Regards,

Miklos


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2015-05-08 Thread Stephan Bergmann
 sfx2/source/menu/mnuitem.cxx |   45 ---
 1 file changed, 45 deletions(-)

New commits:
commit 8a051cb9543b49cc70f5e6728df3387b128d3daf
Author: Stephan Bergmann 
Date:   Fri May 8 14:51:27 2015 +0200

loplugin:unreffun

Change-Id: I85ed112b1bfb44d47b8bd59e211b5b691b3fe02c

diff --git a/sfx2/source/menu/mnuitem.cxx b/sfx2/source/menu/mnuitem.cxx
index 9d10b93..6cbd552 100644
--- a/sfx2/source/menu/mnuitem.cxx
+++ b/sfx2/source/menu/mnuitem.cxx
@@ -299,8 +299,6 @@ PopupMenu* SfxMenuControl::GetPopup () const
 return 0;
 }
 
-sal_IntPtr Select_Impl( void* pHdl, void* pVoid );
-
 SfxUnoMenuControl* SfxMenuControl::CreateControl( const OUString& rCmd,
 sal_uInt16 nId, Menu& rMenu, const OUString& sItemText,
 SfxBindings& rBindings, SfxVirtualMenu* pVirt)
@@ -336,49 +334,6 @@ struct MenuExecuteInfo
 DECL_STATIC_LINK( MenuExecuteInfo, ExecuteHdl_Impl, MenuExecuteInfo* );
 };
 
-sal_IntPtr Select_Impl( void* /*pHdl*/, void* pVoid )
-{
-Menu* pMenu = static_cast(pVoid);
-OUString aURL( pMenu->GetItemCommand( pMenu->GetCurItemId() ) );
-
-if( aURL.isEmpty() )
-return 0;
-
-Reference < ::com::sun::star::frame::XDesktop2 > xDesktop =
-::com::sun::star::frame::Desktop::create( 
::comphelper::getProcessComponentContext() );
-
-URL aTargetURL;
-aTargetURL.Complete = aURL;
-Reference < XURLTransformer > xTrans( URLTransformer::create( 
::comphelper::getProcessComponentContext() ) );
-xTrans->parseStrict( aTargetURL );
-
-Reference < XDispatch > xDisp;
-if (aTargetURL.Protocol == "slot:")
-xDisp = xDesktop->queryDispatch( aTargetURL, OUString(), 0 );
-else
-{
-OUString aTargetFrame( "_blank" );
-::framework::MenuAttributes* pMenuAttributes =
-reinterpret_cast< 
::framework::MenuAttributes*>(pMenu->GetUserValue( pMenu->GetCurItemId() ));
-
-if ( pMenuAttributes )
-aTargetFrame = pMenuAttributes->aTargetFrame;
-
-xDisp = xDesktop->queryDispatch( aTargetURL, aTargetFrame , 0 );
-}
-
-if ( xDisp.is() )
-{
-MenuExecuteInfo* pExecuteInfo = new MenuExecuteInfo;
-pExecuteInfo->xDispatch = xDisp;
-pExecuteInfo->aTargetURL= aTargetURL;
-pExecuteInfo->aArgs = Sequence< PropertyValue >();
-Application::PostUserEvent( LINK( 0, MenuExecuteInfo, 
ExecuteHdl_Impl), pExecuteInfo );
-}
-
-return sal_IntPtr(true);
-}
-
 IMPL_STATIC_LINK_NOINSTANCE( MenuExecuteInfo, ExecuteHdl_Impl, 
MenuExecuteInfo*, pExecuteInfo )
 {
 pExecuteInfo->xDispatch->dispatch( pExecuteInfo->aTargetURL, 
pExecuteInfo->aArgs );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: 5 commits - chart2/qa oox/inc oox/source

2015-05-08 Thread Markus Mohrhard
 chart2/qa/extras/chart2import.cxx |   73 
++
 chart2/qa/extras/data/xlsx/axis_title_default_rotation.xlsx   |binary
 chart2/qa/extras/data/xlsx/axis_title_rotated.xlsx|binary
 chart2/qa/extras/data/xlsx/secondary_axis_title_default_rotation.xlsx |binary
 oox/inc/drawingml/chart/objectformatter.hxx   |8 -
 oox/inc/drawingml/chart/titlemodel.hxx|3 
 oox/source/drawingml/chart/axiscontext.cxx|   12 +
 oox/source/drawingml/chart/objectformatter.cxx|4 
 oox/source/drawingml/chart/titleconverter.cxx |2 
 oox/source/drawingml/chart/titlemodel.cxx |5 
 10 files changed, 90 insertions(+), 17 deletions(-)

New commits:
commit bc4f6677a0d307fb19ad4fdfb627c80e59fd6835
Author: Markus Mohrhard 
Date:   Fri May 8 14:53:04 2015 +0200

add test for xlsx rotated axis title import

Change-Id: Ibfcf7cffe661efc1ce2063e87d38c45d943df69d

diff --git a/chart2/qa/extras/chart2import.cxx 
b/chart2/qa/extras/chart2import.cxx
index e20a5c2..7082077 100644
--- a/chart2/qa/extras/chart2import.cxx
+++ b/chart2/qa/extras/chart2import.cxx
@@ -87,6 +87,7 @@ public:
 
 void testAxisTitleDefaultRotationXLSX();
 void testSecondaryAxisTitleDefaultRotationXLSX();
+void testAxisTitleRotationXLSX();
 
 CPPUNIT_TEST_SUITE(Chart2ImportTest);
 CPPUNIT_TEST(Fdo60083);
@@ -135,6 +136,7 @@ public:
 CPPUNIT_TEST(testMinorTickMarksDefaultValue2013XLSX);
 CPPUNIT_TEST(testAxisTitleDefaultRotationXLSX);
 CPPUNIT_TEST(testSecondaryAxisTitleDefaultRotationXLSX);
+CPPUNIT_TEST(testAxisTitleRotationXLSX);
 CPPUNIT_TEST_SUITE_END();
 
 private:
@@ -1061,6 +1063,38 @@ void 
Chart2ImportTest::testSecondaryAxisTitleDefaultRotationXLSX()
 CPPUNIT_ASSERT_EQUAL(90.0, nRotation);
 }
 
+void Chart2ImportTest::testAxisTitleRotationXLSX()
+{
+load("/chart2/qa/extras/data/xlsx/", "axis_title_rotated.xlsx");
+Reference xChartDoc = getChartDocFromSheet(0, 
mxComponent);
+CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChartDoc.is());
+{
+Reference xYAxis = getAxisFromDoc(xChartDoc, 0, 1, 0);
+CPPUNIT_ASSERT(xYAxis.is());
+Reference xTitled(xYAxis, uno::UNO_QUERY_THROW);
+Reference xTitle = xTitled->getTitleObject();
+CPPUNIT_ASSERT(xTitle.is());
+Reference xPropSet(xTitle, uno::UNO_QUERY_THROW);
+uno::Any aAny = xPropSet->getPropertyValue("TextRotation");
+double nRotation = 0;
+CPPUNIT_ASSERT(aAny >>= nRotation);
+CPPUNIT_ASSERT_EQUAL(340.0, nRotation);
+}
+{
+Reference xYAxis = getAxisFromDoc(xChartDoc, 0, 1, 1);
+CPPUNIT_ASSERT(xYAxis.is());
+Reference xTitled(xYAxis, uno::UNO_QUERY_THROW);
+Reference xTitle = xTitled->getTitleObject();
+CPPUNIT_ASSERT(xTitle.is());
+Reference xPropSet(xTitle, uno::UNO_QUERY_THROW);
+uno::Any aAny = xPropSet->getPropertyValue("TextRotation");
+double nRotation = 0;
+CPPUNIT_ASSERT(aAny >>= nRotation);
+CPPUNIT_ASSERT_EQUAL(270.0, nRotation);
+}
+
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(Chart2ImportTest);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/chart2/qa/extras/data/xlsx/axis_title_rotated.xlsx 
b/chart2/qa/extras/data/xlsx/axis_title_rotated.xlsx
new file mode 100644
index 000..29e42d8
Binary files /dev/null and b/chart2/qa/extras/data/xlsx/axis_title_rotated.xlsx 
differ
commit 13ede60a9604564339647cff6193d9343ea2fd48
Author: Markus Mohrhard 
Date:   Fri May 8 14:52:14 2015 +0200

also add test for secondary axis, related tdf#75316

Change-Id: I88f46f7724296e1c58cf7604a0c514de91b5ae2a

diff --git a/chart2/qa/extras/chart2import.cxx 
b/chart2/qa/extras/chart2import.cxx
index a25449e..e20a5c2 100644
--- a/chart2/qa/extras/chart2import.cxx
+++ b/chart2/qa/extras/chart2import.cxx
@@ -86,6 +86,7 @@ public:
 void testMinorTickMarksDefaultValue2013XLSX();
 
 void testAxisTitleDefaultRotationXLSX();
+void testSecondaryAxisTitleDefaultRotationXLSX();
 
 CPPUNIT_TEST_SUITE(Chart2ImportTest);
 CPPUNIT_TEST(Fdo60083);
@@ -133,6 +134,7 @@ public:
 CPPUNIT_TEST(testMajorTickMarksDefaultValue2013XLSX);
 CPPUNIT_TEST(testMinorTickMarksDefaultValue2013XLSX);
 CPPUNIT_TEST(testAxisTitleDefaultRotationXLSX);
+CPPUNIT_TEST(testSecondaryAxisTitleDefaultRotationXLSX);
 CPPUNIT_TEST_SUITE_END();
 
 private:
@@ -1042,6 +1044,23 @@ void Chart2ImportTest::testAxisTitleDefaultRotationXLSX()
 CPPUNIT_ASSERT_EQUAL(90.0, nRotation);
 }
 
+void Chart2ImportTest::testSecondaryAxisTitleDefaultRotationXLSX()
+{
+load("/chart2/qa/extras/data/xlsx/", 
"secondary_axis_title_default_rotation.xlsx");
+Reference xChartDoc = getChartDocFromSheet(0, 
mxComponent);
+CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChart

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-4.4' - translations

2015-05-08 Thread Christian Lohmaier
 translations |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4f658fe5d48d592d6bb63dee9c079169b189a268
Author: Christian Lohmaier 
Date:   Tue Apr 28 21:52:01 2015 +0200

Updated core
Project: translations  d0c3d50b2bf7169cc3966289ad99db2405605fc8

update translations for 4.4.3 rc2

and force-fix errors using pocheck

Change-Id: I7bd9d4e48824ac8583778d76c38b7d64206f553b

diff --git a/translations b/translations
index 0790015..d0c3d50 16
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit 0790015275c5309a4bf44e3819ba81aaff70fd57
+Subproject commit d0c3d50b2bf7169cc3966289ad99db2405605fc8
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-4.4' - 9 commits - i18npool/source icon-themes/sifr include/vcl officecfg/registry sc/inc sc/source svx/uiconfig

2015-05-08 Thread Caolán McNamara
 i18npool/source/characterclassification/cclass_unicode.cxx |   56 
++
 i18npool/source/localedata/data/es_CR.xml  |   42 +--
 icon-themes/sifr/cmd/lc_autopilotmenu.png  |binary
 icon-themes/sifr/cmd/lc_conditionalformatdialog.png|binary
 icon-themes/sifr/cmd/lc_conditionalformatmenu.png  |binary
 icon-themes/sifr/cmd/sc_autopilotmenu.png  |binary
 icon-themes/sifr/cmd/sc_conditionalformatdialog.png|binary
 icon-themes/sifr/cmd/sc_conditionalformatmenu.png  |binary
 icon-themes/sifr/links.txt |5 
 include/vcl/window.hxx |3 
 officecfg/registry/schema/org/openoffice/Office/Linguistic.xcs |2 
 sc/inc/refupdatecontext.hxx|9 +
 sc/source/core/data/documen2.cxx   |4 
 sc/source/core/data/document.cxx   |8 -
 sc/source/core/data/refupdatecontext.cxx   |   12 +-
 sc/source/core/data/table3.cxx |9 -
 sc/source/core/tool/token.cxx  |   32 -
 sc/source/ui/docshell/dbdocfun.cxx |   13 +-
 svx/uiconfig/ui/sidebararea.ui |   31 +
 19 files changed, 140 insertions(+), 86 deletions(-)

New commits:
commit f5b5d92a28cc9c62a3c4752be5bd7b5fcc31a5a8
Author: Caolán McNamara 
Date:   Thu May 7 10:23:13 2015 +0100

Resolves: tdf#91057 transliterateChar2Char throws 
MultipleCharsOutputException

for ß, but toTitle only allows RuntimeException, which is our usual
awesomeness

Change-Id: Ib5618a55a369fa5cd1d323f657f0798776828386
(cherry picked from commit d0a0da717682a0e57f733d75d9d0700cfb198823)
Reviewed-on: https://gerrit.libreoffice.org/15659
Reviewed-by: Stephan Bergmann 
Tested-by: Stephan Bergmann 

diff --git a/i18npool/source/characterclassification/cclass_unicode.cxx 
b/i18npool/source/characterclassification/cclass_unicode.cxx
index e58598e..637d75c 100644
--- a/i18npool/source/characterclassification/cclass_unicode.cxx
+++ b/i18npool/source/characterclassification/cclass_unicode.cxx
@@ -21,8 +21,10 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
+#include 
 #include 
 #include 
 
@@ -79,27 +81,41 @@ cclass_Unicode::toLower( const OUString& Text, sal_Int32 
nPos, sal_Int32 nCount,
 
 OUString SAL_CALL
 cclass_Unicode::toTitle( const OUString& Text, sal_Int32 nPos, sal_Int32 
nCount, const Locale& rLocale ) throw(RuntimeException, std::exception) {
-sal_Int32 len = Text.getLength();
-if (nPos >= len)
-return OUString();
-if (nCount + nPos > len)
-nCount = len - nPos;
-
-trans->setMappingType(MappingTypeToTitle, rLocale);
-rtl_uString* pStr = rtl_uString_alloc(nCount);
-sal_Unicode* out = pStr->buffer;
-BreakIteratorImpl brk(m_xContext);
-Boundary bdy = brk.getWordBoundary(Text, nPos, rLocale,
-WordType::ANYWORD_IGNOREWHITESPACES, sal_True);
-for (sal_Int32 i = nPos; i < nCount + nPos; i++, out++) {
-if (i >= bdy.endPos)
-bdy = brk.nextWord(Text, bdy.endPos, rLocale,
-WordType::ANYWORD_IGNOREWHITESPACES);
-*out = (i == bdy.startPos) ?
-trans->transliterateChar2Char(Text[i]) : Text[i];
+try
+{
+sal_Int32 len = Text.getLength();
+if (nPos >= len)
+return OUString();
+if (nCount + nPos > len)
+nCount = len - nPos;
+
+trans->setMappingType(MappingTypeToTitle, rLocale);
+rtl_uString* pStr = rtl_uString_alloc(nCount);
+sal_Unicode* out = pStr->buffer;
+BreakIteratorImpl brk(m_xContext);
+Boundary bdy = brk.getWordBoundary(Text, nPos, rLocale,
+WordType::ANYWORD_IGNOREWHITESPACES, sal_True);
+for (sal_Int32 i = nPos; i < nCount + nPos; i++, out++) {
+if (i >= bdy.endPos)
+bdy = brk.nextWord(Text, bdy.endPos, rLocale,
+WordType::ANYWORD_IGNOREWHITESPACES);
+*out = (i == bdy.startPos) ?
+trans->transliterateChar2Char(Text[i]) : Text[i];
+}
+*out = 0;
+return OUString( pStr, SAL_NO_ACQUIRE );
+}
+catch (const RuntimeException&)
+{
+throw;
+}
+catch (const Exception& e)
+{
+uno::Any a(cppu::getCaughtException());
+throw lang::WrappedTargetRuntimeException(
+"wrapped Exception " + e.Message,
+uno::Reference(), a);
 }
-*out = 0;
-return OUString( pStr, SAL_NO_ACQUIRE );
 }
 
 sal_Int16 SAL_CALL
commit f88025d6fd26c8fb2eaf50937b2dc6e25f389d0f
Author: Eike Rathke 
Date:   Mon May 4 20:45:45 2015 +0200

Resolves tdf#90757 ensure start row / end row order makes sense

[Libreoffice-commits] core.git: sw/inc sw/source

2015-05-08 Thread Miklos Vajna
 sw/inc/dbmgr.hxx|4 
 sw/source/core/doc/doc.cxx  |4 
 sw/source/uibase/dbui/dbmgr.cxx |   14 ++
 3 files changed, 22 insertions(+)

New commits:
commit 358a7ca728dced8ca41ad79a7c54a6c2408807b1
Author: Miklos Vajna 
Date:   Fri May 8 14:58:55 2015 +0200

Add SwDBManager::LoadAndRegisterEmbeddedDataSource

With this, if a .odt document has an embedded data source definition,
referred as EmbeddedDatabaseName in settings.xml, then that data source
gets registered when opening the document.

Change-Id: Ibd836fe11c0e74e8ea10e357886e6266e9ba0db0

diff --git a/sw/inc/dbmgr.hxx b/sw/inc/dbmgr.hxx
index d420a8a..e5f719c 100644
--- a/sw/inc/dbmgr.hxx
+++ b/sw/inc/dbmgr.hxx
@@ -77,6 +77,7 @@ class SwXMailMerge;
 class SwMailMergeConfigItem;
 class SwCalc;
 class INetURLObject;
+class SwDocShell;
 
 enum DBManagerOptions
 {
@@ -369,6 +370,9 @@ public:
 static OUStringLoadAndRegisterDataSource(const OUString& rURI, 
const OUString *pPrefix = 0, const OUString *pDestDir = 0,
  const 
::com::sun::star::uno::Reference < ::com::sun::star::beans::XPropertySet > 
*pSettings = 0);
 
+/// Load the embedded data source of the document and also register it.
+void LoadAndRegisterEmbeddedDataSource(const SwDBData& rData, const 
SwDocShell& rDocShell);
+
 /** try to get the data source from the given connection through the 
XChild interface.
 If this is not possible, the data source will be created through its 
name.
 @param _xConnection
diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index 80de11e..4886e29 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -38,6 +38,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -493,6 +494,9 @@ void SwDoc::ChgDBData(const SwDBData& rNewData)
 {
 if( rNewData != maDBData )
 {
+if (maDBData.sEmbeddedName != rNewData.sEmbeddedName && GetDocShell())
+mpDBManager->LoadAndRegisterEmbeddedDataSource(rNewData, 
*GetDocShell());
+
 maDBData = rNewData;
 getIDocumentState().SetModified();
 }
diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index 0574eb4..042a0bd 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -2624,6 +2624,20 @@ OUString SwDBManager::LoadAndRegisterDataSource(const 
OUString &rURI, const OUSt
 return LoadAndRegisterDataSource( type, aURLAny, pSettings, rURI, pPrefix, 
pDestDir );
 }
 
+void SwDBManager::LoadAndRegisterEmbeddedDataSource(const SwDBData& rData, 
const SwDocShell& rDocShell)
+{
+uno::Reference xDatabaseContext = 
sdb::DatabaseContext::create(comphelper::getProcessComponentContext());
+
+if (xDatabaseContext->hasByName(rData.sDataSource))
+xDatabaseContext->revokeObject(rData.sDataSource);
+
+INetURLObject aURLObject(rDocShell.GetMedium()->GetURLObject());
+aURLObject.SetMark(rData.sEmbeddedName);
+OUString aURL = aURLObject.GetMainURL(INetURLObject::DECODE_WITH_CHARSET);
+uno::Reference 
xDataSource(xDatabaseContext->getByName(aURL), uno::UNO_QUERY);
+xDatabaseContext->registerObject(rData.sDataSource, xDataSource);
+}
+
 void SwDBManager::ExecuteFormLetter( SwWrtShell& rSh,
 const Sequence& rProperties,
 bool bWithDataSourceBrowser)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: four changes of suspicious code (connectivity, sc, sw, editeng)

2015-05-08 Thread Lionel Elie Mamane
On Fri, May 08, 2015 at 01:01:40PM +0200, Lionel Elie Mamane wrote:
> On Fri, May 08, 2015 at 10:23:37AM +0200, Stephan Bergmann wrote:

>> One is in connectivity (Lionel, do you happen to know how to trigger that
>> code?):

> I uploaded a trigger case to
> http://people.freedesktop.org/~lmamane/trigger-java_io_Reader::available.odb

> Enable macros and run the macro "Main" in "Module1" in that file.

I tried it, and it doesn't work. In my tests, HSQLDB's
Clob.getCharacterStream().ready() returns true even at end-of-file.

So we might return "1" although we should return "0". Since the
documentation says: "Note: This method offers no information on
whether the EOF has been reached.", I suggest to just let it slide and
be like that: we return 1 even at EOF.

> This whole class is a mess. It confuses the notion of byte and the
> notion of character. In Java, and also in LibreOffice, a character is
> *two* bytes.

> I'm hesitating between:

> 1) "Unimplementing" getCharacterStream in the SDBC<->JDBC driver

> 2) Having it just call getBinaryStream (which uses java_io_InputStream)

> 3) Fixing java_io_Reader to properly handle the bytes <-> character
>conversion, (which is annoying because it will have to do its own
>buffering for when an odd number of bytes is read...).

I took option 3. Pushing soon.

-- 
Lionel
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Build dependency on external cppunit

2015-05-08 Thread Richard Cochran
On Fri, May 08, 2015 at 02:48:53PM +0200, Miklos Vajna wrote:
> Hi Richard,
> 
> On Fri, May 08, 2015 at 02:12:45PM +0200, Richard Cochran 
>  wrote:
> > Can't I just force cppunit to build manually beforehand?
> 
> make cppunit.all

Tried that already, too.  Here is what I got:

PARALLELISM=1 make cppunit.all GMAKE_OPTIONS='VERBOSE=1'

make[1]: Entering directory '/mnt/storage/git/libreoffice'
...
mkdir -p 
/mnt/storage/git/libreoffice/workdir/Dep/CxxObject/UnoControls/source/base/
mkdir -p 
/mnt/storage/git/libreoffice/workdir/Dep/CxxObject/UnoControls/source/controls/
[build MOD] cppunit
S=/mnt/storage/git/libreoffice && I=$S/instdir && W=$S/workdir &&  mkdir -p 
$W/Module/ && touch $W/Module/cppunit
make[1]: Leaving directory '/mnt/storage/git/libreoffice'

The 'touch' is the only result!

I should probably add that I am trying to cross compile LO (I know, I
know, don't ask why), and it is clear that building cross is not fully
implemented, but in this case I think it should still work.

> Should do that, though you just hide the root cause with that. :-)

Yep.  Unfortunately I am having a hard time understanding how this
build system is supposed to work, otherwise I would fix it and send a
patch!

Thanks,
Richard
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: sc/source

2015-05-08 Thread Katarina Behrens
 sc/source/ui/pagedlg/scuitphfedit.cxx |6 ++
 1 file changed, 6 insertions(+)

New commits:
commit c1405651f6c0c8e519e0aed3f12473499d8ed942
Author: Katarina Behrens 
Date:   Fri May 8 15:18:34 2015 +0200

tdf#90257: Prevent dialog from growing out of the screen

when large font sizes are used. Set size request on 1 edit widget
(+- match what used to be in the old .src file), the remaining two
are in the same grid, so this will hopefull do the trick

Change-Id: I3ca27ea4d037cf8877f022c1ee5ed7f348b0cfdd

diff --git a/sc/source/ui/pagedlg/scuitphfedit.cxx 
b/sc/source/ui/pagedlg/scuitphfedit.cxx
index f5c4fe8..5bfa114 100644
--- a/sc/source/ui/pagedlg/scuitphfedit.cxx
+++ b/sc/source/ui/pagedlg/scuitphfedit.cxx
@@ -132,6 +132,12 @@ ScHFEditPage::ScHFEditPage( vcl::Window* 
pParent,
 m_pWndCenter->SetFont( aPatAttr );
 m_pWndRight->SetFont( aPatAttr );
 
+// Set size request of 1 widget, the other two will follow as they are
+// in the same grid
+Size aSize = LogicToPixel(Size(80, 120), MAP_APPFONT);
+m_pWndLeft->set_width_request(aSize.Width());
+m_pWndLeft->set_height_request(aSize.Height());
+
 m_pWndLeft->SetObjectSelectHdl( LINK(this,ScHFEditPage,ObjectSelectHdl) );
 m_pWndCenter->SetObjectSelectHdl( LINK(this,ScHFEditPage,ObjectSelectHdl) 
);
 m_pWndRight->SetObjectSelectHdl( LINK(this,ScHFEditPage,ObjectSelectHdl) );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: connectivity/source

2015-05-08 Thread Lionel Elie Mamane
 connectivity/source/drivers/jdbc/Reader.cxx |   98 +++-
 connectivity/source/inc/java/io/Reader.hxx  |2 
 2 files changed, 85 insertions(+), 15 deletions(-)

New commits:
commit 3af5437e2adf00793404957f30237ba4b9a31772
Author: Lionel Elie Mamane 
Date:   Fri May 8 15:31:06 2015 +0200

jdbc character stream: don't mix up bytes and characters

Change-Id: I59352edd887982faa792b02adbb55c3f67f1d78d

diff --git a/connectivity/source/drivers/jdbc/Reader.cxx 
b/connectivity/source/drivers/jdbc/Reader.cxx
index 20db510..f5f7034 100644
--- a/connectivity/source/drivers/jdbc/Reader.cxx
+++ b/connectivity/source/drivers/jdbc/Reader.cxx
@@ -20,6 +20,7 @@
 #include "java/io/Reader.hxx"
 #include 
 using namespace connectivity;
+using ::com::sun::star::uno::Sequence;
 
 
 // Class: java.io.Reader
@@ -52,11 +53,31 @@ sal_Int32 SAL_CALL java_io_Reader::readSomeBytes( 
::com::sun::star::uno::Sequenc
 void SAL_CALL java_io_Reader::skipBytes( sal_Int32 nBytesToSkip ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::BufferSizeExceededException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)
 {
 static jmethodID mID(NULL);
-callIntMethodWithIntArg_ThrowRuntime("skip",mID,nBytesToSkip);
+if(nBytesToSkip <= 0)
+return;
+
+if(m_buf != boost::none)
+{
+m_buf = boost::none;
+--nBytesToSkip;
+}
+
+static_assert(sizeof(jchar) == 2, "I thought Java characters were UTF16 
code units?");
+sal_Int32 nCharsToSkip = nBytesToSkip / sizeof(jchar);
+callIntMethodWithIntArg_ThrowRuntime("skip",mID,nCharsToSkip);
+if(nBytesToSkip % sizeof(jchar) != 0)
+{
+assert(nBytesToSkip % sizeof(jchar) == 1);
+Sequence< sal_Int8 > aData(1);
+assert(m_buf == boost::none);
+readBytes(aData, 1);
+}
 }
 
 sal_Int32 SAL_CALL java_io_Reader::available(  ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)
 {
+if(m_buf != boost::none)
+return 1;
 jboolean out;
 SDBThreadAttach t; OSL_ENSURE(t.pEnv,"Java Enviroment geloescht worden!");
 
@@ -69,7 +90,7 @@ sal_Int32 SAL_CALL java_io_Reader::available(  ) 
throw(::com::sun::star::io::Not
 out = t.pEnv->CallBooleanMethod( object, mID);
 ThrowRuntimeException(t.pEnv,*this);
 } //t.pEnv
-return out ? 1 : 0; // no way to tell *how much* is ready
+return (m_buf != boost::none) + (out ? 1 : 0); // no way to tell *how 
much* is ready
 }
 
 void SAL_CALL java_io_Reader::closeInput(  ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)
@@ -80,31 +101,78 @@ void SAL_CALL java_io_Reader::closeInput(  ) 
throw(::com::sun::star::io::NotConn
 
 sal_Int32 SAL_CALL java_io_Reader::readBytes( ::com::sun::star::uno::Sequence< 
sal_Int8 >& aData, sal_Int32 nBytesToRead ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::BufferSizeExceededException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)
 {
-OSL_ENSURE(aData.getLength() < nBytesToRead," Sequence is smaller than 
BytesToRead");
-jint out(0);
+OSL_ENSURE(aData.getLength() >= nBytesToRead," Sequence is smaller than 
BytesToRead");
+
+if(nBytesToRead == 0)
+return 0;
+
+sal_Int8 *dst(aData.getArray());
+sal_Int32 nBytesWritten(0);
+
+if(m_buf != boost::none)
+{
+if(aData.getLength() == 0)
+{
+aData.realloc(1);
+dst = aData.getArray();
+}
+*dst = *m_buf;
+m_buf = boost::none;
+++nBytesWritten;
+++dst;
+--nBytesToRead;
+}
+
+if(nBytesToRead == 0)
+return 0;
+
+sal_Int32 nCharsToRead = (nBytesToRead + 1)/2;
+
+jint outChars(0);
 SDBThreadAttach t; OSL_ENSURE(t.pEnv,"Java Enviroment geloescht worden!");
 
 {
-jcharArray pCharArray = t.pEnv->NewCharArray(nBytesToRead);
+jcharArray pCharArray = t.pEnv->NewCharArray(nCharsToRead);
 static const char * cSignature = "([CII)I";
 static const char * cMethodName = "read";
 // Java-Call
 static jmethodID mID(NULL);
 obtainMethodId_throwRuntime(t.pEnv, cMethodName,cSignature, mID);
-out = t.pEnv->CallIntMethod( object, mID, pCharArray, 0, nBytesToRead 
);
-if ( !out )
-ThrowRuntimeException(t.pEnv,*this);
-if(out > 0)
+outChars = t.pEnv->CallIntMethod( object, mID, pCharArray, 0, 
nCharsToRead );
+if ( !outChars )
+{
+if(nBytesWritten==0)
+ThrowRuntimeException(t.pEnv,*this);
+else
+return 1;
+}
+if(outChars > 0)
 {
-jboolean p = sal_False;
-if

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

2015-05-08 Thread Stephan Bergmann
 sfx2/source/menu/mnuitem.cxx |   16 
 1 file changed, 16 deletions(-)

New commits:
commit e1c6c850b7c478a672dc914e60e87bc0ce4506fc
Author: Stephan Bergmann 
Date:   Fri May 8 15:41:23 2015 +0200

Remove dead code

Change-Id: I3684210a180a3044ac52c3cd92a3184fc349e40d

diff --git a/sfx2/source/menu/mnuitem.cxx b/sfx2/source/menu/mnuitem.cxx
index 6cbd552..8ff9a78 100644
--- a/sfx2/source/menu/mnuitem.cxx
+++ b/sfx2/source/menu/mnuitem.cxx
@@ -325,20 +325,4 @@ SfxUnoMenuControl::~SfxUnoMenuControl()
 pUnoCtrl->release();
 }
 
-struct MenuExecuteInfo
-{
-::com::sun::star::uno::Reference< ::com::sun::star::frame::XDispatch > 
xDispatch;
-::com::sun::star::util::URL
aTargetURL;
-::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >  
aArgs;
-
-DECL_STATIC_LINK( MenuExecuteInfo, ExecuteHdl_Impl, MenuExecuteInfo* );
-};
-
-IMPL_STATIC_LINK_NOINSTANCE( MenuExecuteInfo, ExecuteHdl_Impl, 
MenuExecuteInfo*, pExecuteInfo )
-{
-pExecuteInfo->xDispatch->dispatch( pExecuteInfo->aTargetURL, 
pExecuteInfo->aArgs );
-delete pExecuteInfo;
-return 0;
-}
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2015-05-08 Thread Stephan Bergmann
 sfx2/source/inc/virtmenu.hxx   |2 +-
 sfx2/source/menu/virtmenu.cxx  |3 ++-
 sfx2/source/sidebar/SidebarToolBox.cxx |6 --
 3 files changed, 7 insertions(+), 4 deletions(-)

New commits:
commit 7314fc7b9436ac44dbf0e5fece8c156a19ef3861
Author: Stephan Bergmann 
Date:   Fri May 8 15:41:52 2015 +0200

loplugin:staticmethods

Change-Id: I9b661dc67ccbdcb757d661168b4c3fa4b6f5b1fa

diff --git a/sfx2/source/inc/virtmenu.hxx b/sfx2/source/inc/virtmenu.hxx
index 48b5064..c71c9c0 100644
--- a/sfx2/source/inc/virtmenu.hxx
+++ b/sfx2/source/inc/virtmenu.hxx
@@ -69,7 +69,7 @@ protected:
 SfxBindings &rBind, bool bOLEServer=false, bool 
bRes=false, bool bIsAddonMenu=false );
 
 voidCreateFromSVMenu();
-DECL_LINK_TYPED( Highlight, Menu *, bool );
+DECL_STATIC_LINK_TYPED( SfxVirtualMenu, Highlight, Menu *, bool );
 DECL_LINK_TYPED( Activate, Menu *, bool );
 DECL_LINK_TYPED( Deactivate, Menu *, bool );
 DECL_LINK( SettingsChanged, void* );
diff --git a/sfx2/source/menu/virtmenu.cxx b/sfx2/source/menu/virtmenu.cxx
index 93e729e..1161585 100644
--- a/sfx2/source/menu/virtmenu.cxx
+++ b/sfx2/source/menu/virtmenu.cxx
@@ -483,7 +483,8 @@ void SfxVirtualMenu::CreateFromSVMenu()
 
 // called on activation of the SV-Menu
 
-IMPL_LINK_NOARG_TYPED( SfxVirtualMenu, Highlight, Menu *, bool )
+IMPL_STATIC_LINK_NOINSTANCE_NOARG_TYPED(
+SfxVirtualMenu, Highlight, Menu *, bool )
 {
 
 return true;
diff --git a/sfx2/source/sidebar/SidebarToolBox.cxx 
b/sfx2/source/sidebar/SidebarToolBox.cxx
index ce0c7bd..18c3b29 100644
--- a/sfx2/source/sidebar/SidebarToolBox.cxx
+++ b/sfx2/source/sidebar/SidebarToolBox.cxx
@@ -273,10 +273,12 @@ IMPL_LINK_TYPED(SidebarToolBox, SelectHandler, ToolBox*, 
pToolBox, void)
 xController->execute((sal_Int16)pToolBox->GetModifier());
 }
 
-IMPL_LINK_NOARG_TYPED(SidebarToolBox, ActivateToolBox, ToolBox*, void)
+IMPL_STATIC_LINK_NOINSTANCE_NOARG_TYPED(
+SidebarToolBox, ActivateToolBox, ToolBox*, void)
 {}
 
-IMPL_LINK_NOARG_TYPED(SidebarToolBox, DeactivateToolBox, ToolBox*, void)
+IMPL_STATIC_LINK_NOINSTANCE_NOARG_TYPED(
+SidebarToolBox, DeactivateToolBox, ToolBox*, void)
 {}
 
 } } // end of namespace sfx2::sidebar
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2015-05-08 Thread Stephan Bergmann
 include/sfx2/sidebar/SidebarToolBox.hxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 9d74271f742b06306ed10c6a9a7385c75d48fe14
Author: Stephan Bergmann 
Date:   Fri May 8 15:42:37 2015 +0200

Missing from previous commit

Change-Id: Ic4ba1f85575047cd03ccca8987b411f6ad2a809a

diff --git a/include/sfx2/sidebar/SidebarToolBox.hxx 
b/include/sfx2/sidebar/SidebarToolBox.hxx
index 32db84e..bf1663f 100644
--- a/include/sfx2/sidebar/SidebarToolBox.hxx
+++ b/include/sfx2/sidebar/SidebarToolBox.hxx
@@ -82,8 +82,8 @@ private:
 DECL_LINK_TYPED(ClickHandler, ToolBox*, void);
 DECL_LINK_TYPED(DoubleClickHandler, ToolBox*, void);
 DECL_LINK_TYPED(SelectHandler, ToolBox*, void);
-DECL_LINK_TYPED(ActivateToolBox, ToolBox*, void);
-DECL_LINK_TYPED(DeactivateToolBox, ToolBox*, void);
+DECL_STATIC_LINK_TYPED(SidebarToolBox, ActivateToolBox, ToolBox*, void);
+DECL_STATIC_LINK_TYPED(SidebarToolBox, DeactivateToolBox, ToolBox*, void);
 
 void CreateController (
 const sal_uInt16 nItemId,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Build dependency on external cppunit

2015-05-08 Thread Richard Cochran
On Fri, May 08, 2015 at 03:31:39PM +0200, Richard Cochran wrote:
> I should probably add that I am trying to cross compile LO (I know, I
> know, don't ask why), and it is clear that building cross is not fully
> implemented, but in this case I think it should still work.

Ok, it is somehow related to the cross compile configuration.  The
'make cppunit.all' works as expected with a native build.

Sigh,
Richard
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: connectivity/source

2015-05-08 Thread Stephan Bergmann
 connectivity/source/drivers/jdbc/Reader.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 8f90336948770350c75c445d478c04107e5cef6e
Author: Stephan Bergmann 
Date:   Fri May 8 15:54:02 2015 +0200

loplugin:implicitboolconversion

Change-Id: Iec38fdf8c165d1121e74f7221b49ca49f808ac03

diff --git a/connectivity/source/drivers/jdbc/Reader.cxx 
b/connectivity/source/drivers/jdbc/Reader.cxx
index f5f7034..cd4 100644
--- a/connectivity/source/drivers/jdbc/Reader.cxx
+++ b/connectivity/source/drivers/jdbc/Reader.cxx
@@ -90,7 +90,7 @@ sal_Int32 SAL_CALL java_io_Reader::available(  ) 
throw(::com::sun::star::io::Not
 out = t.pEnv->CallBooleanMethod( object, mID);
 ThrowRuntimeException(t.pEnv,*this);
 } //t.pEnv
-return (m_buf != boost::none) + (out ? 1 : 0); // no way to tell *how 
much* is ready
+return (m_buf != boost::none && out) ? 1 : 0; // no way to tell *how much* 
is ready
 }
 
 void SAL_CALL java_io_Reader::closeInput(  ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: connectivity/source

2015-05-08 Thread Stephan Bergmann
 connectivity/source/drivers/jdbc/Reader.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 2c70139d6a8d8fabd671455d3edd32117783d4d7
Author: Stephan Bergmann 
Date:   Fri May 8 16:16:35 2015 +0200

...or rather, like this

Change-Id: I87b547b76f6e214730757bec375b1d7b3d5d8f41

diff --git a/connectivity/source/drivers/jdbc/Reader.cxx 
b/connectivity/source/drivers/jdbc/Reader.cxx
index cd4..be913dd 100644
--- a/connectivity/source/drivers/jdbc/Reader.cxx
+++ b/connectivity/source/drivers/jdbc/Reader.cxx
@@ -90,7 +90,7 @@ sal_Int32 SAL_CALL java_io_Reader::available(  ) 
throw(::com::sun::star::io::Not
 out = t.pEnv->CallBooleanMethod( object, mID);
 ThrowRuntimeException(t.pEnv,*this);
 } //t.pEnv
-return (m_buf != boost::none && out) ? 1 : 0; // no way to tell *how much* 
is ready
+return (m_buf != boost::none ? 1 : 0) + (out ? 1 : 0); // no way to tell 
*how much* is ready
 }
 
 void SAL_CALL java_io_Reader::closeInput(  ) 
throw(::com::sun::star::io::NotConnectedException, 
::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, 
std::exception)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: solenv/bin

2015-05-08 Thread Andras Timar
 solenv/bin/modules/installer/simplepackage.pm |5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

New commits:
commit 81802cfa7cb04f770e57413dbeb2c852c2431e65
Author: Andras Timar 
Date:   Fri May 8 16:46:12 2015 +0200

OS X SDK.app build fix

Change-Id: Ib6f34f833a6fbaa8038796d86accd385b2a21a44

diff --git a/solenv/bin/modules/installer/simplepackage.pm 
b/solenv/bin/modules/installer/simplepackage.pm
index d470b4e..d70394e 100644
--- a/solenv/bin/modules/installer/simplepackage.pm
+++ b/solenv/bin/modules/installer/simplepackage.pm
@@ -393,7 +393,7 @@ sub create_package
 
 chdir $localfrom;
 }
-else
+elsif ($volume_name_classic_app eq 'LibreOffice' || 
$volume_name_classic_app eq 'LibreOfficeDev')
 {
 my $subdir = 
"$tempdir/$packagename/$volume_name_classic_app.app/Contents/Resources";
 if ( ! -d $subdir ) { 
installer::systemactions::create_directory($subdir); }
@@ -402,8 +402,7 @@ sub create_package
 {
 installer::systemactions::create_directory($subdir . "/" . 
$lang . ".lproj");
 }
-if (($volume_name_classic_app eq 'LibreOffice' || 
$volume_name_classic_app eq 'LibreOfficeDev') &&
-defined($ENV{'MACOSX_CODESIGNING_IDENTITY'}) && 
$ENV{'MACOSX_CODESIGNING_IDENTITY'} ne "" )
+if ( defined($ENV{'MACOSX_CODESIGNING_IDENTITY'}) && 
$ENV{'MACOSX_CODESIGNING_IDENTITY'} ne "" )
 {
 $systemcall = 
"$ENV{'SRCDIR'}/solenv/bin/macosx-codesign-app-bundle 
$localtempdir/$folder/$volume_name_classic_app.app";
 print "... $systemcall ...\n";
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2015-05-08 Thread Caolán McNamara
 sd/source/ui/app/sdxfer.cxx |   18 --
 1 file changed, 16 insertions(+), 2 deletions(-)

New commits:
commit 7b2367f868778739fba382a68a35248904cc9565
Author: Caolán McNamara 
Date:   Fri May 8 15:49:08 2015 +0100

misspell some words, copy and paste slide to gimp

and we don't want to see the mis-spelt underlines

Change-Id: Ib3ae29297a1697e0f7b0caa816504da7edf721d1

diff --git a/sd/source/ui/app/sdxfer.cxx b/sd/source/ui/app/sdxfer.cxx
index 044f680..587ead7 100644
--- a/sd/source/ui/app/sdxfer.cxx
+++ b/sd/source/ui/app/sdxfer.cxx
@@ -518,13 +518,27 @@ bool SdTransferable::GetData( const DataFlavor& rFlavor, 
const OUString& rDestDo
 }
 else if( nFormat == SotClipboardFormatId::GDIMETAFILE )
 {
-if( mpSdViewIntern )
+if (mpSdViewIntern)
+{
+const bool bToggleOnlineSpell = mpSdDrawDocumentIntern && 
mpSdDrawDocumentIntern->GetOnlineSpell();
+if (bToggleOnlineSpell)
+mpSdDrawDocumentIntern->SetOnlineSpell(false);
 bOK = SetGDIMetaFile( mpSdViewIntern->GetMarkedObjMetaFile( 
true ), rFlavor );
+if (bToggleOnlineSpell)
+mpSdDrawDocumentIntern->SetOnlineSpell(true);
+}
 }
 else if( SotClipboardFormatId::BITMAP == nFormat || 
SotClipboardFormatId::PNG == nFormat )
 {
-if( mpSdViewIntern )
+if (mpSdViewIntern)
+{
+const bool bToggleOnlineSpell = mpSdDrawDocumentIntern && 
mpSdDrawDocumentIntern->GetOnlineSpell();
+if (bToggleOnlineSpell)
+mpSdDrawDocumentIntern->SetOnlineSpell(false);
 bOK = SetBitmapEx( mpSdViewIntern->GetMarkedObjBitmapEx(true), 
rFlavor );
+if (bToggleOnlineSpell)
+mpSdDrawDocumentIntern->SetOnlineSpell(true);
+}
 }
 else if( ( nFormat == SotClipboardFormatId::STRING ) && mpBookmark )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Build dependency on external cppunit

2015-05-08 Thread Miklos Vajna
On Fri, May 08, 2015 at 03:55:35PM +0200, Richard Cochran 
 wrote:
> Ok, it is somehow related to the cross compile configuration.  The
> 'make cppunit.all' works as expected with a native build.

Isn't the very point of cross-compilation that the resulting binary is
not something you can run? If so, I find it a feature that unit tests
are not built / executed when cross-compiling. :-)

In any case:

if test "$cross_compiling" != "yes"; then
libo_CHECK_SYSTEM_MODULE([cppunit],[CPPUNIT],[cppunit >= 1.12.0])
fi

in configure.ac where cppunit is disabled in case of cross-compiling.


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: 3 commits - compilerplugins/clang sd/source sw/inc sw/source

2015-05-08 Thread Stephan Bergmann
 compilerplugins/clang/staticmethods.cxx |2 +-
 sd/source/ui/dlg/navigatr.cxx   |3 ++-
 sd/source/ui/inc/navigatr.hxx   |2 +-
 sw/inc/dbmgr.hxx|2 +-
 sw/source/core/doc/doc.cxx  |2 +-
 5 files changed, 6 insertions(+), 5 deletions(-)

New commits:
commit aa50b1c03f18a10c281786c69e24d8255613ac5a
Author: Stephan Bergmann 
Date:   Fri May 8 16:57:23 2015 +0200

Enable loplugin:staticmethods

Change-Id: Ic0062eddebf9225d298569bb4900047a0ee0b112

diff --git a/compilerplugins/clang/staticmethods.cxx 
b/compilerplugins/clang/staticmethods.cxx
index a0d6099..decb3ff 100644
--- a/compilerplugins/clang/staticmethods.cxx
+++ b/compilerplugins/clang/staticmethods.cxx
@@ -206,7 +206,7 @@ bool StaticMethods::TraverseCXXMethodDecl(const 
CXXMethodDecl * pCXXMethodDecl)
 return true;
 }
 
-loplugin::Plugin::Registration X("staticmethods", false);
+loplugin::Plugin::Registration X("staticmethods");
 
 }
 
commit 516d3007444fe2dd07b2cde24066637281c2a217
Author: Stephan Bergmann 
Date:   Fri May 8 16:57:03 2015 +0200

loplugin:staticmethods

Change-Id: I0041724d340bf75a184910805f7f927efb3b2131

diff --git a/sw/inc/dbmgr.hxx b/sw/inc/dbmgr.hxx
index e5f719c..dfcd231 100644
--- a/sw/inc/dbmgr.hxx
+++ b/sw/inc/dbmgr.hxx
@@ -371,7 +371,7 @@ public:
  const 
::com::sun::star::uno::Reference < ::com::sun::star::beans::XPropertySet > 
*pSettings = 0);
 
 /// Load the embedded data source of the document and also register it.
-void LoadAndRegisterEmbeddedDataSource(const SwDBData& rData, const 
SwDocShell& rDocShell);
+static void LoadAndRegisterEmbeddedDataSource(const SwDBData& rData, const 
SwDocShell& rDocShell);
 
 /** try to get the data source from the given connection through the 
XChild interface.
 If this is not possible, the data source will be created through its 
name.
diff --git a/sw/source/core/doc/doc.cxx b/sw/source/core/doc/doc.cxx
index 4886e29..9c3e75f 100644
--- a/sw/source/core/doc/doc.cxx
+++ b/sw/source/core/doc/doc.cxx
@@ -495,7 +495,7 @@ void SwDoc::ChgDBData(const SwDBData& rNewData)
 if( rNewData != maDBData )
 {
 if (maDBData.sEmbeddedName != rNewData.sEmbeddedName && GetDocShell())
-mpDBManager->LoadAndRegisterEmbeddedDataSource(rNewData, 
*GetDocShell());
+SwDBManager::LoadAndRegisterEmbeddedDataSource(rNewData, 
*GetDocShell());
 
 maDBData = rNewData;
 getIDocumentState().SetModified();
commit 7fabc2300bc7255c839eb42c2185cad92029009d
Author: Stephan Bergmann 
Date:   Fri May 8 16:57:00 2015 +0200

loplugin:staticmethods

Change-Id: I33d722c27d85732d23510ebaaaba0b8792d0d61d

diff --git a/sd/source/ui/dlg/navigatr.cxx b/sd/source/ui/dlg/navigatr.cxx
index ec19ebf..1f891e5 100644
--- a/sd/source/ui/dlg/navigatr.cxx
+++ b/sd/source/ui/dlg/navigatr.cxx
@@ -313,7 +313,8 @@ IMPL_LINK_NOARG_TYPED(SdNavigatorWin, SelectToolboxHdl, 
ToolBox *, void)
 }
 }
 
-IMPL_LINK_NOARG_TYPED(SdNavigatorWin, ClickToolboxHdl, ToolBox *, void)
+IMPL_STATIC_LINK_NOINSTANCE_NOARG_TYPED(
+SdNavigatorWin, ClickToolboxHdl, ToolBox *, void)
 {}
 
 IMPL_LINK_TYPED( SdNavigatorWin, DropdownClickToolBoxHdl, ToolBox*, pBox, void 
)
diff --git a/sd/source/ui/inc/navigatr.hxx b/sd/source/ui/inc/navigatr.hxx
index 77b7a7e..e16e21e 100644
--- a/sd/source/ui/inc/navigatr.hxx
+++ b/sd/source/ui/inc/navigatr.hxx
@@ -146,7 +146,7 @@ private:
 
 DECL_LINK( GetFocusObjectsHdl, void * );
 DECL_LINK_TYPED( SelectToolboxHdl, ToolBox *, 
void );
-DECL_LINK_TYPED(ClickToolboxHdl, ToolBox *, 
void);
+DECL_STATIC_LINK_TYPED(SdNavigatorWin, 
ClickToolboxHdl, ToolBox *, void);
 DECL_LINK_TYPED( DropdownClickToolBoxHdl, 
ToolBox *, void );
 DECL_LINK( ClickPageHdl, void * );
 DECL_LINK( ClickObjectHdl, void * );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: four changes of suspicious code (connectivity, sc, sw, editeng)

2015-05-08 Thread Miklos Vajna
Hi Stephan,

On Fri, May 08, 2015 at 10:23:37AM +0200, Stephan Bergmann 
 wrote:
> >diff --git a/sw/source/core/doc/DocumentStylePoolManager.cxx 
> >b/sw/source/core/doc/DocumentStylePoolManager.cxx
> >index 3276b9f4..8d4fe0e 100644
> >--- a/sw/source/core/doc/DocumentStylePoolManager.cxx
> >+++ b/sw/source/core/doc/DocumentStylePoolManager.cxx
> >@@ -1318,7 +1318,7 @@ SwFmt* DocumentStylePoolManager::GetFmtFromPool( 
> >sal_uInt16 nId )
> > aSet.Put( SwFmtAnchor( FLY_AT_PAGE ));
> > aSet.Put( SwFmtHoriOrient( 0, text::HoriOrientation::CENTER, 
> > text::RelOrientation::FRAME ));
> > aSet.Put( SwFmtVertOrient( 0, text::VertOrientation::CENTER, 
> > text::RelOrientation::FRAME ));
> >-aSet.Put( SvxOpaqueItem( sal_False ));
> >+aSet.Put( SvxOpaqueItem( RES_OPAQUE, false ));

That's correct. The authorative source about which pool item should have
what which id in case of sw is sw/source/core/bastyp/init.cxx AFAIK, and
that has:

aAttrTab[ RES_OPAQUE- POOLATTR_BEGIN ] =new SvxOpaqueItem( 
RES_OPAQUE );

Regards,

Miklos


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: libreofficekit/qa

2015-05-08 Thread Pranav Kant
 libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx |   11 ---
 1 file changed, 8 insertions(+), 3 deletions(-)

New commits:
commit 40ad68bbe7cd1c86a8ebefb1539fb7b403506792
Author: Pranav Kant 
Date:   Fri May 8 19:19:57 2015 +0530

gtktiledviewer: Stop event propagation to GtkToolbar when in edit mode

If not stopped, key-press events are interpreted by both LOKDocView and
GtkToolbar leading to poor editing experience.

Change-Id: Ie878d168e202a0f3e1d52191aa3fd7cc00a7cbfd
Reviewed-on: https://gerrit.libreoffice.org/15677
Tested-by: Miklos Vajna 
Reviewed-by: Miklos Vajna 

diff --git a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx 
b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
index 14cf767..cb84ee7 100644
--- a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
+++ b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
@@ -132,12 +132,17 @@ void toggleFindbar(GtkWidget* /*pButton*/, gpointer 
/*pItem*/)
 }
 
 /// Handles the key-press-event of the window.
-static void signalKey(GtkWidget* pWidget, GdkEventKey* pEvent, gpointer pData)
+static gboolean signalKey(GtkWidget* pWidget, GdkEventKey* pEvent, gpointer 
pData)
 {
+LOKDocView* pLOKDocView = LOK_DOCVIEW(pDocView);
 #if GTK_CHECK_VERSION(2,18,0) // we need gtk_widget_get_visible()
-if (!gtk_widget_get_visible(pFindbar))
-lok_docview_post_key(pWidget, pEvent, pData);
+if (!gtk_widget_get_visible(pFindbar) && 
bool(lok_docview_get_edit(pLOKDocView)))
+{
+lok_docview_post_key(pWidget, pEvent, pData);
+return TRUE;
+}
 #endif
+return FALSE;
 }
 
 /// Searches for the next or previous text of pFindbarEntry.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Build dependency on external cppunit

2015-05-08 Thread Richard Cochran
On Fri, May 08, 2015 at 04:53:49PM +0200, Miklos Vajna wrote:
> On Fri, May 08, 2015 at 03:55:35PM +0200, Richard Cochran 
>  wrote:
> > Ok, it is somehow related to the cross compile configuration.  The
> > 'make cppunit.all' works as expected with a native build.
> 
> Isn't the very point of cross-compilation that the resulting binary is
> not something you can run? If so, I find it a feature that unit tests
> are not built / executed when cross-compiling. :-)

Yes, *I* would say so, but the LO build thinks otherwise!

I specifically did 'make build' in order to avoid the tests, but the
build system compiles the tests anyhow.  There are LOTS of other ways
in which cross compile is broken.  It seems clear that it really isn't
supported or tested, and so I don't expect too much.  My goal is just
to get it working, somehow, for a particular setup.

> In any case:
> 
> if test "$cross_compiling" != "yes"; then
> libo_CHECK_SYSTEM_MODULE([cppunit],[CPPUNIT],[cppunit >= 1.12.0])
> fi
> 
> in configure.ac where cppunit is disabled in case of cross-compiling.

Ok, I'll take a look.

Thanks,
Richard

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: dbaccess/source sw/source

2015-05-08 Thread Miklos Vajna
 dbaccess/source/core/dataaccess/databasecontext.cxx |   16 +++-
 sw/source/uibase/dbui/dbmgr.cxx |9 ++---
 2 files changed, 17 insertions(+), 8 deletions(-)

New commits:
commit 12bb6a054d697efddee76269605ed2450a2fae9c
Author: Miklos Vajna 
Date:   Fri May 8 16:49:06 2015 +0200

dbaccess, sw: use vnd.sun.star.pkg:// for embedded data source handling

Change-Id: I69eaf2e4dd051d62f56caef962d40889cc3a3876

diff --git a/dbaccess/source/core/dataaccess/databasecontext.cxx 
b/dbaccess/source/core/dataaccess/databasecontext.cxx
index 4e6c185..2332ced 100644
--- a/dbaccess/source/core/dataaccess/databasecontext.cxx
+++ b/dbaccess/source/core/dataaccess/databasecontext.cxx
@@ -315,9 +315,15 @@ Reference< XInterface > 
ODatabaseContext::loadObjectFromURL(const OUString& _rNa
 OUString _sURL(rURL);
 INetURLObject aURL( _sURL );
 
-OUString aMark = aURL.GetMark(INetURLObject::DECODE_WITH_CHARSET);
-if (!aMark.isEmpty())
-_sURL = aURL.GetURLNoMark();
+OUString sStreamRelPath;
+if (_sURL.startsWithIgnoreAsciiCase("vnd.sun.star.pkg:"))
+{
+// In this case the host contains the real path, and the the path is 
the embedded stream name.
+_sURL = aURL.GetHost(INetURLObject::DECODE_WITH_CHARSET);
+sStreamRelPath = aURL.GetURLPath(INetURLObject::DECODE_WITH_CHARSET);
+if (sStreamRelPath.startsWith("/"))
+sStreamRelPath = sStreamRelPath.copy(1);
+}
 
 if ( aURL.GetProtocol() == INetProtocol::NotValid )
 throw NoSuchElementException( _rName, *this );
@@ -367,8 +373,8 @@ Reference< XInterface > 
ODatabaseContext::loadObjectFromURL(const OUString& _rNa
 aArgs.put( "URL", _sURL );
 aArgs.put( "MacroExecutionMode", MacroExecMode::USE_CONFIG );
 aArgs.put( "InteractionHandler", 
task::InteractionHandler::createWithParent(m_aContext, 0) );
-if (!aMark.isEmpty())
-aArgs.put("StreamRelPath", aMark);
+if (!sStreamRelPath.isEmpty())
+aArgs.put("StreamRelPath", sStreamRelPath);
 
 Sequence< PropertyValue > aResource( aArgs.getPropertyValues() );
 xLoad->load( aResource );
diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index 042a0bd..3f81f2e 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -2631,9 +2631,12 @@ void 
SwDBManager::LoadAndRegisterEmbeddedDataSource(const SwDBData& rData, const
 if (xDatabaseContext->hasByName(rData.sDataSource))
 xDatabaseContext->revokeObject(rData.sDataSource);
 
-INetURLObject aURLObject(rDocShell.GetMedium()->GetURLObject());
-aURLObject.SetMark(rData.sEmbeddedName);
-OUString aURL = aURLObject.GetMainURL(INetURLObject::DECODE_WITH_CHARSET);
+// Encode the stream name and the real path into a single URL.
+const INetURLObject& rURLObject = rDocShell.GetMedium()->GetURLObject();
+OUString aURL = "vnd.sun.star.pkg://";
+aURL += 
INetURLObject::encode(rURLObject.GetMainURL(INetURLObject::DECODE_WITH_CHARSET),
 INetURLObject::PART_AUTHORITY, INetURLObject::ENCODE_ALL);
+aURL += "/" + INetURLObject::encode(rData.sEmbeddedName, 
INetURLObject::PART_FPATH, INetURLObject::ENCODE_ALL);
+
 uno::Reference 
xDataSource(xDatabaseContext->getByName(aURL), uno::UNO_QUERY);
 xDatabaseContext->registerObject(rData.sDataSource, xDataSource);
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-4' - solenv/bin

2015-05-08 Thread Andras Timar
 solenv/bin/modules/installer/simplepackage.pm |   12 +---
 1 file changed, 9 insertions(+), 3 deletions(-)

New commits:
commit b4d2b39cb9e46cb0b09d5c1f3d3dadfeb16c30d2
Author: Andras Timar 
Date:   Fri May 8 11:38:56 2015 +0200

tdf#78834 enable localized system dialogs on OS X

Change-Id: I37f5b183b36f2a3077f591162402ddd83e4a46d4
Reviewed-on: https://gerrit.libreoffice.org/15673
Reviewed-by: Andras Timar 
Tested-by: Andras Timar 
(cherry picked from commit 2df138b483f60ffdcd3b62c8c2884d2f5cc076af)
Reviewed-on: https://gerrit.libreoffice.org/15674
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/solenv/bin/modules/installer/simplepackage.pm 
b/solenv/bin/modules/installer/simplepackage.pm
index ae91d0c..d70394e 100644
--- a/solenv/bin/modules/installer/simplepackage.pm
+++ b/solenv/bin/modules/installer/simplepackage.pm
@@ -393,10 +393,16 @@ sub create_package
 
 chdir $localfrom;
 }
-else
+elsif ($volume_name_classic_app eq 'LibreOffice' || 
$volume_name_classic_app eq 'LibreOfficeDev')
 {
-if (($volume_name_classic_app eq 'LibreOffice' || 
$volume_name_classic_app eq 'LibreOfficeDev') &&
-defined($ENV{'MACOSX_CODESIGNING_IDENTITY'}) && 
$ENV{'MACOSX_CODESIGNING_IDENTITY'} ne "" )
+my $subdir = 
"$tempdir/$packagename/$volume_name_classic_app.app/Contents/Resources";
+if ( ! -d $subdir ) { 
installer::systemactions::create_directory($subdir); }
+# iterate over OS X localizations
+foreach $lang ("ca", "cs", "da", "de", "el", "en", "es", "fi", 
"fr", "hr", "hu", "id", "it", "ja", "ko", "ms", "nl", "no", "pl", "pt", 
"pt_PT", "ro", "ru", "sk", "sv", "th", "tr", "uk", "vi", "zh_CN", "zh_TW")
+{
+installer::systemactions::create_directory($subdir . "/" . 
$lang . ".lproj");
+}
+if ( defined($ENV{'MACOSX_CODESIGNING_IDENTITY'}) && 
$ENV{'MACOSX_CODESIGNING_IDENTITY'} ne "" )
 {
 $systemcall = 
"$ENV{'SRCDIR'}/solenv/bin/macosx-codesign-app-bundle 
$localtempdir/$folder/$volume_name_classic_app.app";
 print "... $systemcall ...\n";
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: canvas/source forms/source jvmfwk/source xmloff/source

2015-05-08 Thread Takeshi Abe
 canvas/source/directx/dx_spritecanvashelper.cxx |8 
 forms/source/xforms/binding.cxx |6 +++---
 jvmfwk/source/framework.cxx |4 ++--
 xmloff/source/forms/layerimport.cxx |   10 --
 4 files changed, 13 insertions(+), 15 deletions(-)

New commits:
commit 99e60d8d62b69d8b0b22d54e3f55c5151e7a2c2f
Author: Takeshi Abe 
Date:   Fri May 8 17:29:01 2015 +0900

std::ptr_fun became deprecated since C++11

Change-Id: If93609d032c9864e0251230bf9ed76e6b6741a62
Reviewed-on: https://gerrit.libreoffice.org/15672
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/canvas/source/directx/dx_spritecanvashelper.cxx 
b/canvas/source/directx/dx_spritecanvashelper.cxx
index db7f935..67f0d81 100644
--- a/canvas/source/directx/dx_spritecanvashelper.cxx
+++ b/canvas/source/directx/dx_spritecanvashelper.cxx
@@ -235,7 +235,7 @@ namespace dxcanvas
 mpBackBuffer->draw(aUpdateArea);
 
 // redraw sprites
-mpRedrawManager->forEachSprite(::std::ptr_fun( &spriteRedraw ) );
+mpRedrawManager->forEachSprite( &spriteRedraw );
 
 // flip primary surface to screen
 // ==
@@ -290,7 +290,7 @@ namespace dxcanvas
 // are avoided.
 ::std::for_each( rUpdateArea.maComponentList.begin(),
  rUpdateArea.maComponentList.end(),
- ::std::ptr_fun( &spriteRedrawStub2 ) );
+ &spriteRedrawStub2 );
 
 // repaint uncovered areas from backbuffer - take the
 // _rounded_ rectangles from above, to have the update
@@ -328,7 +328,7 @@ namespace dxcanvas
 // buffer.
 ::std::for_each( rSortedUpdateSprites.begin(),
  rSortedUpdateSprites.end(),
- ::std::ptr_fun( &spriteRedrawStub ) );
+ &spriteRedrawStub );
 
 // TODO(E1): Use numeric_cast to catch overflow here
 ::basegfx::B2IRange aActualArea( 0, 0,
@@ -364,7 +364,7 @@ namespace dxcanvas
 
 ::std::for_each( rSortedUpdateSprites.begin(),
  rSortedUpdateSprites.end(),
- ::std::ptr_fun( &spriteRedrawStub ) );
+ &spriteRedrawStub );
 
 // add given update area to the 'blit to foreground' rect
 maUpdateRect.expand( aActualArea );
diff --git a/forms/source/xforms/binding.cxx b/forms/source/xforms/binding.cxx
index b7312cb..96487e3 100644
--- a/forms/source/xforms/binding.cxx
+++ b/forms/source/xforms/binding.cxx
@@ -712,13 +712,13 @@ void Binding::valueModified()
 Reference xSource = static_cast( this );
 ::std::for_each( maModifyListeners.begin(),
   maModifyListeners.end(),
-  ::std::bind2nd( ::std::ptr_fun( lcl_modified ), xSource ) );
+ ::std::bind( lcl_modified, std::placeholders::_1, xSource 
) );
 ::std::for_each( maListEntryListeners.begin(),
   maListEntryListeners.end(),
-  ::std::bind2nd( ::std::ptr_fun( lcl_listentry ), xSource ) );
+ ::std::bind( lcl_listentry, std::placeholders::_1, 
xSource ) );
 ::std::for_each( maValidityListeners.begin(),
   maValidityListeners.end(),
-  ::std::bind2nd( ::std::ptr_fun( lcl_validate ), xSource ) );
+ ::std::bind( lcl_validate, std::placeholders::_1, xSource 
) );
 
 // now distribute MIPs to children
 if( xNode.is() )
diff --git a/jvmfwk/source/framework.cxx b/jvmfwk/source/framework.cxx
index ddfc4bf..7035bba 100644
--- a/jvmfwk/source/framework.cxx
+++ b/jvmfwk/source/framework.cxx
@@ -136,7 +136,7 @@ javaFrameworkError SAL_CALL jfw_findAllJREs(JavaInfo 
***pparInfo, sal_Int32 *pSi
 //the same JRE
 it_info it_duplicate =
 std::find_if(vecInfoManual.begin(), 
vecInfoManual.end(),
-std::bind2nd(std::ptr_fun(areEqualJavaInfo), 
aInfo));
+ std::bind(areEqualJavaInfo, 
std::placeholders::_1, aInfo));
 if (it_duplicate == vecInfoManual.end())
 vecInfoManual.push_back(aInfo);
 }
@@ -165,7 +165,7 @@ javaFrameworkError SAL_CALL jfw_findAllJREs(JavaInfo 
***pparInfo, sal_Int32 *pSi
 {
 it_info it_duplicate =
 std::find_if(vecInfoManual2.begin(), vecInfoManual2.end(),
-std::bind2nd(std::ptr_fun(areEqualJavaInfo), *j));
+ std::bind(areEqualJavaInfo, 
std::placeholders::_1, *j));
 if (it_duplicate != vecInfoManual2.end())
 vecInfoManual2.erase(it_duplicate);
 }
diff --git a/xmloff/source/forms/layerimport.cxx 
b/xmloff/source/forms/layerimport.cxx
index 33459eb..453c490 100644
--- a/xmloff/source/forms/laye

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

2015-05-08 Thread Caolán McNamara
 sw/source/core/inc/frame.hxx   |5 +
 sw/source/core/layout/calcmove.cxx |2 ++
 sw/source/core/layout/wsfrm.cxx|1 +
 sw/source/core/text/frmform.cxx|2 ++
 4 files changed, 10 insertions(+)

New commits:
commit 068c4df48fd1d9f4c42864733b80e7cbd7f5d006
Author: Caolán McNamara 
Date:   Fri May 8 16:46:48 2015 +0100

Resolves: ooo#119155 don't crash with odd content in footnotes

hit it with a large and simple hammer

Change-Id: Ib0e55ad64780efc7664ccd9a2684fbe7dba87498

diff --git a/sw/source/core/inc/frame.hxx b/sw/source/core/inc/frame.hxx
index bc729ca..165a94e 100644
--- a/sw/source/core/inc/frame.hxx
+++ b/sw/source/core/inc/frame.hxx
@@ -358,6 +358,7 @@ protected:
 bool mbColLocked : 1;  // lock Grow/Shrink for column-wise section
   // or fly frames, will be set in Format
 bool m_isInDestroy : 1;
+bool mbForbidDelete : 1;
 
 void ColLock()  { mbColLocked = true; }
 void ColUnlock(){ mbColLocked = false; }
@@ -808,6 +809,7 @@ public:
 bool IsProtected() const;
 
 bool IsColLocked()  const { return mbColLocked; }
+bool IsDeleteForbidden()  const { return mbForbidDelete; }
 
 /// this is the only way to delete a SwFrm instance
 static void DestroyFrm(SwFrm *const pFrm);
@@ -858,6 +860,9 @@ public:
 void RegisterToFormat( SwFmt& rFmt );
 void ValidateThisAndAllLowers( const sal_uInt16 nStage );
 
+void ForbidDelete()  { mbForbidDelete = true; }
+void AllowDelete(){ mbForbidDelete = false; }
+
 //
 drawinglayer::attribute::SdrAllFillAttributesHelperPtr 
getSdrAllFillAttributesHelper() const;
 bool supportsFullDrawingLayerFillAttributeSet() const;
diff --git a/sw/source/core/layout/calcmove.cxx 
b/sw/source/core/layout/calcmove.cxx
index d808f5c..2a82263 100644
--- a/sw/source/core/layout/calcmove.cxx
+++ b/sw/source/core/layout/calcmove.cxx
@@ -1045,6 +1045,7 @@ void SwCntntFrm::MakeAll()
 return;
 }
 
+ForbidDelete();
 LockJoin();
 long nFormatCount = 0;
 // - loop prevention
@@ -1674,6 +1675,7 @@ void SwCntntFrm::MakeAll()
 delete pSaveFtn;
 
 UnlockJoin();
+AllowDelete();
 if ( bMovedFwd || bMovedBwd )
 pNotify->SetInvaKeep();
 // OD 2004-02-26 #i25029#
diff --git a/sw/source/core/layout/wsfrm.cxx b/sw/source/core/layout/wsfrm.cxx
index 57f81cc..caf63ca 100644
--- a/sw/source/core/layout/wsfrm.cxx
+++ b/sw/source/core/layout/wsfrm.cxx
@@ -78,6 +78,7 @@ SwFrm::SwFrm( SwModify *pMod, SwFrm* pSib ) :
 mbValidPos = mbValidPrtArea = mbValidSize = mbValidLineNum = mbRetouche =
 mbFixSize = mbColLocked = false;
 mbCompletePaint = mbInfInvalid = true;
+mbForbidDelete = false;
 }
 
 const IDocumentDrawModelAccess* SwFrm::getIDocumentDrawModelAccess()
diff --git a/sw/source/core/text/frmform.cxx b/sw/source/core/text/frmform.cxx
index 3df7347..802a131 100644
--- a/sw/source/core/text/frmform.cxx
+++ b/sw/source/core/text/frmform.cxx
@@ -561,6 +561,8 @@ void SwTxtFrm::_AdjustFollow( SwTxtFormatter &rLine,
 OSL_FAIL( "+SwTxtFrm::JoinFrm: Follow is locked." );
 return;
 }
+if (GetFollow()->IsDeleteForbidden())
+return;
 JoinFrm();
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: dbaccess/source

2015-05-08 Thread Miklos Vajna
 dbaccess/source/core/dataaccess/databasecontext.cxx |   18 +++---
 dbaccess/source/filter/xml/xmlfilter.cxx|   12 +++-
 2 files changed, 14 insertions(+), 16 deletions(-)

New commits:
commit 5c430093a301b31174a81ad4437f0361c86cfe3c
Author: Miklos Vajna 
Date:   Fri May 8 17:35:37 2015 +0200

dbaccess: move vnd.sun.star.pkg: handling from ODatabaseContext to ODBFilter

This way the data source's URL will be the vnd.sun.star.pkg: URL, that
gets stored in the user profile, and the data source will be usable when
we connect to the data source next time, too.

Change-Id: Ie2f45af453bfad4f813a1ea492edb633c148d08b

diff --git a/dbaccess/source/core/dataaccess/databasecontext.cxx 
b/dbaccess/source/core/dataaccess/databasecontext.cxx
index 2332ced..6dd2efe 100644
--- a/dbaccess/source/core/dataaccess/databasecontext.cxx
+++ b/dbaccess/source/core/dataaccess/databasecontext.cxx
@@ -310,28 +310,18 @@ Reference< XInterface >  
ODatabaseContext::getRegisteredObject(const OUString& _
 return loadObjectFromURL( _rName, sURL );
 }
 
-Reference< XInterface > ODatabaseContext::loadObjectFromURL(const OUString& 
_rName,const OUString& rURL)
+Reference< XInterface > ODatabaseContext::loadObjectFromURL(const OUString& 
_rName,const OUString& _sURL)
 {
-OUString _sURL(rURL);
 INetURLObject aURL( _sURL );
 
-OUString sStreamRelPath;
-if (_sURL.startsWithIgnoreAsciiCase("vnd.sun.star.pkg:"))
-{
-// In this case the host contains the real path, and the the path is 
the embedded stream name.
-_sURL = aURL.GetHost(INetURLObject::DECODE_WITH_CHARSET);
-sStreamRelPath = aURL.GetURLPath(INetURLObject::DECODE_WITH_CHARSET);
-if (sStreamRelPath.startsWith("/"))
-sStreamRelPath = sStreamRelPath.copy(1);
-}
-
 if ( aURL.GetProtocol() == INetProtocol::NotValid )
 throw NoSuchElementException( _rName, *this );
 
 try
 {
 ::ucbhelper::Content aContent( _sURL, NULL, 
comphelper::getProcessComponentContext() );
-if ( !aContent.isDocument() )
+bool bEmbeddedDataSource = 
_sURL.startsWithIgnoreAsciiCase("vnd.sun.star.pkg:");
+if ( !aContent.isDocument() && !bEmbeddedDataSource )
 throw InteractiveIOException(
 _sURL, *this, InteractionClassification_ERROR, 
IOErrorCode_NO_FILE
 );
@@ -373,8 +363,6 @@ Reference< XInterface > 
ODatabaseContext::loadObjectFromURL(const OUString& _rNa
 aArgs.put( "URL", _sURL );
 aArgs.put( "MacroExecutionMode", MacroExecMode::USE_CONFIG );
 aArgs.put( "InteractionHandler", 
task::InteractionHandler::createWithParent(m_aContext, 0) );
-if (!sStreamRelPath.isEmpty())
-aArgs.put("StreamRelPath", sStreamRelPath);
 
 Sequence< PropertyValue > aResource( aArgs.getPropertyValues() );
 xLoad->load( aResource );
diff --git a/dbaccess/source/filter/xml/xmlfilter.cxx 
b/dbaccess/source/filter/xml/xmlfilter.cxx
index 60fd9f3..6b1e16b 100644
--- a/dbaccess/source/filter/xml/xmlfilter.cxx
+++ b/dbaccess/source/filter/xml/xmlfilter.cxx
@@ -453,12 +453,22 @@ bool ODBFilter::implImport( const Sequence< PropertyValue 
>& rDescriptor )
 SfxMediumRef pMedium(0);
 if (!xStorage.is())
 {
+OUString sStreamRelPath;
+if (sFileName.startsWithIgnoreAsciiCase("vnd.sun.star.pkg:"))
+{
+// In this case the host contains the real path, and the the 
path is the embedded stream name.
+INetURLObject aURL(sFileName);
+sFileName = aURL.GetHost(INetURLObject::DECODE_WITH_CHARSET);
+sStreamRelPath = 
aURL.GetURLPath(INetURLObject::DECODE_WITH_CHARSET);
+if (sStreamRelPath.startsWith("/"))
+sStreamRelPath = sStreamRelPath.copy(1);
+}
+
 pMedium = new SfxMedium(sFileName, (StreamMode::READ | 
StreamMode::NOCREATE));
 try
 {
 xStorage.set(pMedium->GetStorage(false), UNO_QUERY_THROW);
 
-OUString sStreamRelPath = 
aMediaDescriptor.getOrDefault("StreamRelPath", OUString());
 if (!sStreamRelPath.isEmpty())
 xStorage = xStorage->openStorageElement(sStreamRelPath, 
embed::ElementModes::READ);
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: 2 commits - include/tools include/vcl vcl/inc vcl/source

2015-05-08 Thread Michael Meeks
 include/tools/link.hxx |1 +
 include/vcl/svapp.hxx  |4 +++-
 include/vcl/window.hxx |2 +-
 vcl/inc/svdata.hxx |1 +
 vcl/source/app/svapp.cxx   |   12 +++-
 vcl/source/window/event.cxx|   11 ++-
 vcl/source/window/floatwin.cxx |2 +-
 7 files changed, 28 insertions(+), 5 deletions(-)

New commits:
commit 127625e8efc64dfbc3f2c53db84a3c919823b0a5
Author: Michael Meeks 
Date:   Fri May 8 17:35:54 2015 +0100

vcl: hold reference during user event posting for floatwin.

Change-Id: Ibb0f717ae21cd80386b26e078ee7eb2a873b4092

diff --git a/vcl/source/window/floatwin.cxx b/vcl/source/window/floatwin.cxx
index 1060021..0e2f5cc 100644
--- a/vcl/source/window/floatwin.cxx
+++ b/vcl/source/window/floatwin.cxx
@@ -590,7 +590,7 @@ void FloatingWindow::ImplCallPopupModeEnd()
 
 // call Handler asynchronously.
 if ( mpImplData && !mnPostId )
-mnPostId = Application::PostUserEvent( LINK( this, FloatingWindow, 
ImplEndPopupModeHdl ) );
+mnPostId = Application::PostUserEvent( LINK( this, FloatingWindow, 
ImplEndPopupModeHdl ), NULL, true );
 }
 
 void FloatingWindow::PopupModeEnd()
commit a738606d48d6678aaabf68a6ba748f79d5c6b9b8
Author: Michael Meeks 
Date:   Thu May 7 22:08:21 2015 +0100

PostUserEvent - instrument to allow holding a VclPtr reference.

This helps avoid things dying during emission in a robust manner.
Bit of an unpleasant 3rd optional parameter; better names appreciated.

Change-Id: I27571823f9d96caef1d07602785a02390d3a3591

diff --git a/include/tools/link.hxx b/include/tools/link.hxx
index 55dfbae..4c2c32c 100644
--- a/include/tools/link.hxx
+++ b/include/tools/link.hxx
@@ -153,6 +153,7 @@ public:
 { return function_ == other.function_ && instance_ == other.instance_; };
 
 bool operator !=(Link const & other) const { return !operator ==(other); };
+void *GetInstance() const { return instance_; }
 
 private:
 Stub * function_;
diff --git a/include/vcl/svapp.hxx b/include/vcl/svapp.hxx
index a576a2c..78f758c 100644
--- a/include/vcl/svapp.hxx
+++ b/include/vcl/svapp.hxx
@@ -865,10 +865,12 @@ public:
 
  @param rLink   Link to event callback function
  @param pCaller Pointer to data sent to the event by the 
caller. Optional.
+ @param bReferenceLink  If true - hold a VclPtr<> reference on the 
Link's instance.
 
  @return the event ID used to post the event.
 */
-static ImplSVEvent * PostUserEvent( const Link<>& rLink, void* pCaller = 
NULL );
+static ImplSVEvent * PostUserEvent( const Link<>& rLink, void* pCaller = 
NULL,
+bool bReferenceLink = false );
 
 /** Remove user event based on event ID
 
diff --git a/include/vcl/window.hxx b/include/vcl/window.hxx
index 3209906..9c2526d 100644
--- a/include/vcl/window.hxx
+++ b/include/vcl/window.hxx
@@ -728,7 +728,7 @@ public:
 voidAddChildEventListener( const Link<>& 
rEventListener );
 voidRemoveChildEventListener( const 
Link<>& rEventListener );
 
-ImplSVEvent *   PostUserEvent( const Link<>& rLink, 
void* pCaller = NULL );
+ImplSVEvent *   PostUserEvent( const Link<>& rLink, 
void* pCaller = NULL, bool bReferenceLink = false );
 voidRemoveUserEvent( ImplSVEvent * 
nUserEvent );
 
 voidIncrementLockCount();
diff --git a/vcl/inc/svdata.hxx b/vcl/inc/svdata.hxx
index 932ebe5..a54f6cc 100644
--- a/vcl/inc/svdata.hxx
+++ b/vcl/inc/svdata.hxx
@@ -400,6 +400,7 @@ struct ImplSVEvent
 {
 void*   mpData;
 Link<>* mpLink;
+VclPtr mpInstanceRef;
 VclPtr mpWindow;
 ImplDelData maDelData;
 boolmbCall;
diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index 5a397f4..32949fb 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -897,13 +897,23 @@ void Application::RemoveMouseAndKeyEvents( vcl::Window* 
pWin )
 }
 }
 
-ImplSVEvent * Application::PostUserEvent( const Link<>& rLink, void* pCaller )
+ImplSVEvent * Application::PostUserEvent( const Link<>& rLink, void* pCaller,
+  bool bReferenceLink )
 {
 ImplSVEvent* pSVEvent = new ImplSVEvent;
 pSVEvent->mpData= pCaller;
 pSVEvent->mpLink= new Link<>( rLink );
 pSVEvent->mpWindow  = NULL;
 pSVEvent->mbCall= true;
+if (bReferenceLink)
+{
+// Double check that this is indeed a vcl::Window instance.
+assert(dynamic_cast(
+reinterpret_cast(rLink.GetInstance())) 
==
+   reinterpret_cast(rLink.GetInstance()));
+pSVEvent->mpInstanceRef = reinterpret_cast(rLink.GetInstance());
+}
+
 vcl::Window* pDefWindow = ImplGetDefaultWindow();
 if ( pDef

Re: Build dependency on external cppunit

2015-05-08 Thread Tor Lillqvist
> There are LOTS of other ways
> in which cross compile is broken.


Well, we have tinderbox slaves that cross-compile for Android and iOS
constantly, so it can't be totally broken.

So you need to be more specific. Also whether something is considered
"broken" or not depends somewhat on whether it is even promised anywhere to
work, don't you think? As you should have noticed, LibreOffice is far from
some "typical" small Open Source library using GNU auto everything that
would be cross-compilable by simple passing --host and --build options to
the configure script. LibreOffice's configury and build system is quite
complex. (But then, so is the build system of most *large* Open Source
software packages.) We don't promise anywhere that arbitrary
cross-compilation would work. You don't even tell what the host platform
for which you are cross-compiling is.

Sure, we don't have anything testing cross-compilation from one Unix to
another Unix, for instance (like from x86_64 Linux to MIPS Linux, etc), so
if that is broken, that is not surprising. I think at some stage a few of
us managed to cross-compile from x86 (or x86_64) Linux to Raspberry Pi ARM
Linux, but that was last year and many things might have bit-rotted since.

--tml
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Build dependency on external cppunit

2015-05-08 Thread Miklos Vajna
On Fri, May 08, 2015 at 05:09:54PM +0200, Richard Cochran 
 wrote:
> Yes, *I* would say so, but the LO build thinks otherwise!
> 
> I specifically did 'make build' in order to avoid the tests, but the
> build system compiles the tests anyhow.  There are LOTS of other ways
> in which cross compile is broken.  It seems clear that it really isn't
> supported or tested, and so I don't expect too much.  My goal is just
> to get it working, somehow, for a particular setup.

What's your cross-compilation target?

http://tinderbox.libreoffice.org/MASTER/status.html says that the
Android and iOS cross-compilation targets work fine (those columns are
green), as far as I see.

The root cause may be that for some reason configure does not recognize
that you're cross-compiling. :-)


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: 2 commits - avmedia/inc avmedia/source basctl/source basic/source chart2/source compilerplugins/clang cui/source desktop/inc desktop/source extensions/source filter/sou

2015-05-08 Thread Stephan Bergmann
 avmedia/inc/mediacontrol.hxx|2 +-
 avmedia/source/framework/mediacontrol.cxx   |2 +-
 basctl/source/basicide/baside3.cxx  |3 ++-
 basctl/source/basicide/iderdll.cxx  |2 +-
 basctl/source/basicide/iderdll2.hxx |2 +-
 basctl/source/inc/baside3.hxx   |2 +-
 basic/source/classes/sbxmod.cxx |4 ++--
 chart2/source/controller/dialogs/dlg_DataEditor.cxx |2 +-
 chart2/source/controller/dialogs/tp_Scale.cxx   |3 ++-
 chart2/source/controller/dialogs/tp_Scale.hxx   |2 +-
 chart2/source/controller/inc/dlg_DataEditor.hxx |2 +-
 compilerplugins/clang/staticmethods.cxx |   18 --
 cui/source/dialogs/hlmailtp.cxx |2 +-
 cui/source/dialogs/scriptdlg.cxx|3 ++-
 cui/source/inc/chardlg.hxx  |2 +-
 cui/source/inc/cuitabarea.hxx   |2 +-
 cui/source/inc/hlmailtp.hxx |3 ++-
 cui/source/inc/paragrph.hxx |2 +-
 cui/source/inc/scriptdlg.hxx|2 +-
 cui/source/inc/treeopt.hxx  |2 +-
 cui/source/options/optinet2.cxx |6 +++---
 cui/source/options/optinet2.hxx |6 +++---
 cui/source/options/treeopt.cxx  |3 ++-
 cui/source/tabpages/chardlg.cxx |2 +-
 cui/source/tabpages/paragrph.cxx|2 +-
 cui/source/tabpages/tparea.cxx  |3 ++-
 desktop/inc/app.hxx |4 ++--
 desktop/source/app/app.cxx  |4 ++--
 extensions/source/plugin/unx/npwrap.cxx |1 +
 filter/source/pdf/impdialog.cxx |2 +-
 filter/source/pdf/impdialog.hxx |2 +-
 filter/source/xsltdialog/xmlfiltertabdialog.cxx |7 ---
 filter/source/xsltdialog/xmlfiltertabdialog.hxx |2 +-
 framework/inc/services/layoutmanager.hxx|2 +-
 framework/source/layoutmanager/layoutmanager.cxx|2 +-
 include/sfx2/dinfdlg.hxx|4 ++--
 include/svtools/addresstemplate.hxx |2 +-
 include/svx/float3d.hxx |2 +-
 include/svx/fmobjfac.hxx|2 +-
 include/svx/galmisc.hxx |2 +-
 include/svx/objfac3d.hxx|2 +-
 reportdesign/source/ui/inc/dlgedfac.hxx |2 +-
 reportdesign/source/ui/report/dlgedfac.cxx  |3 ++-
 sc/inc/externalrefmgr.hxx   |2 +-
 sc/inc/userdat.hxx  |2 +-
 sc/source/core/data/userdat.cxx |3 ++-
 sc/source/ui/condformat/condformatdlg.cxx   |2 +-
 sc/source/ui/docshell/externalrefmgr.cxx|2 +-
 sc/source/ui/inc/acredlin.hxx   |2 +-
 sc/source/ui/inc/condformatdlg.hxx  |2 +-
 sc/source/ui/inc/opredlin.hxx   |2 +-
 sc/source/ui/inc/scuitphfedit.hxx   |2 +-
 sc/source/ui/inc/viewdata.hxx   |4 ++--
 sc/source/ui/miscdlgs/acredlin.cxx  |2 +-
 sc/source/ui/optdlg/calcoptionsdlg.cxx  |3 ++-
 sc/source/ui/optdlg/calcoptionsdlg.hxx  |2 +-
 sc/source/ui/optdlg/opredlin.cxx|2 +-
 sc/source/ui/pagedlg/scuitphfedit.cxx   |2 +-
 sc/source/ui/view/viewdata.cxx  |2 +-
 sd/inc/sdmod.hxx|2 +-
 sd/source/ui/annotations/annotationwindow.cxx   |2 +-
 sd/source/ui/annotations/annotationwindow.hxx   |2 +-
 sd/source/ui/app/sdmod1.cxx |2 +-
 sfx2/source/dialog/dinfdlg.cxx  |7 ---
 svtools/source/contnr/imivctl.hxx   |2 +-
 svtools/source/contnr/imivctl1.cxx  |2 +-
 svtools/source/dialogs/addresstemplate.cxx  |3 ++-
 svx/source/engine3d/float3d.cxx |2 +-
 svx/source/engine3d/objfac3d.cxx|3 ++-
 svx/source/form/fmobjfac.cxx|3 ++-
 svx/source/gallery2/galmisc.cxx |3 ++-
 sw/inc/dobjfac.hxx  |2 +-
 sw/source/core/draw/dobjfac.cxx |3 ++-
 sw/source/ui/dialog/uiregionsw.cxx  |3 ++-
 sw/source/ui/dialog/wordcountdialog.cxx |2 +-
 sw/source/ui/table/tabledlg.cxx |3 ++-
 sw/source/uibase/app/apphdl.cxx |7 +--
 sw/source/uibase/dbui/dbui.cxx  |2 +-
 sw/source/uibase/env

[Libreoffice-commits] core.git: dbaccess/source

2015-05-08 Thread Miklos Vajna
 dbaccess/source/core/dataaccess/ModelImpl.cxx |   22 ++
 1 file changed, 14 insertions(+), 8 deletions(-)

New commits:
commit 66f866d2f5f65a677f3721b7d6c482bf724c97a7
Author: Miklos Vajna 
Date:   Fri May 8 18:57:46 2015 +0200

dbaccess: avoid exceptions during loading embedded data sources

Situation before/after the patch is the same, just silence lots of
harmless warnings for now.

Change-Id: I00428bdfd939d8cdd3bfd447339e0417e70f4689

diff --git a/dbaccess/source/core/dataaccess/ModelImpl.cxx 
b/dbaccess/source/core/dataaccess/ModelImpl.cxx
index 936ba5c..4788df6 100644
--- a/dbaccess/source/core/dataaccess/ModelImpl.cxx
+++ b/dbaccess/source/core/dataaccess/ModelImpl.cxx
@@ -824,21 +824,27 @@ Reference< XStorage > 
ODatabaseModelImpl::getOrCreateRootStorage()
 aStorageCreationArgs[1] <<= ElementModes::READWRITE;
 
 Reference< XStorage > xDocumentStorage;
-try
-{
-xDocumentStorage.set( 
xStorageFactory->createInstanceWithArguments( aStorageCreationArgs ), 
UNO_QUERY_THROW );
-}
-catch( const Exception& )
+OUString sURL;
+aSource >>= sURL;
+// Don't try to load a meta-URL as-is.
+if (!sURL.startsWithIgnoreAsciiCase("vnd.sun.star.pkg:"))
 {
-m_bDocumentReadOnly = true;
-aStorageCreationArgs[1] <<= ElementModes::READ;
 try
 {
 xDocumentStorage.set( 
xStorageFactory->createInstanceWithArguments( aStorageCreationArgs ), 
UNO_QUERY_THROW );
 }
 catch( const Exception& )
 {
-DBG_UNHANDLED_EXCEPTION();
+m_bDocumentReadOnly = true;
+aStorageCreationArgs[1] <<= ElementModes::READ;
+try
+{
+xDocumentStorage.set( 
xStorageFactory->createInstanceWithArguments( aStorageCreationArgs ), 
UNO_QUERY_THROW );
+}
+catch( const Exception& )
+{
+DBG_UNHANDLED_EXCEPTION();
+}
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: framework/inc framework/source

2015-05-08 Thread Tor Lillqvist
 framework/inc/helper/statusindicator.hxx|2 ++
 framework/source/helper/statusindicator.cxx |7 ++-
 2 files changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 3842967e5276aabdf28e8eb047803389a41793c7
Author: Tor Lillqvist 
Date:   Fri May 8 13:17:45 2015 +0300

Ensure progress bar LibreOfficeKit callbacks don't repeat the same 
percentage

Gets rid of superfluous sequential callbacks with the same percentage when
loading large documents.

This reverts commit cec72eff99d1d683f2236c8a86a2814b34ad861e.

Change-Id: I70f43f7e3a650c76cbcbbc60ebb2d47efaca06a5

diff --git a/framework/inc/helper/statusindicator.hxx 
b/framework/inc/helper/statusindicator.hxx
index d52216e..6043cf2 100644
--- a/framework/inc/helper/statusindicator.hxx
+++ b/framework/inc/helper/statusindicator.hxx
@@ -69,6 +69,8 @@ class StatusIndicator : public  ::cppu::WeakImplHelper1< 
css::task::XStatusIndic
 css::uno::WeakReference< css::task::XStatusIndicatorFactory > 
m_xFactory;
 
 sal_Int32 m_nRange;
+// We want the callback percentages to increase monotonically
+int m_nLastCallbackPercent;
 
 // c++ interface
 public:
diff --git a/framework/source/helper/statusindicator.cxx 
b/framework/source/helper/statusindicator.cxx
index 88c247e..6c78d0a 100644
--- a/framework/source/helper/statusindicator.cxx
+++ b/framework/source/helper/statusindicator.cxx
@@ -38,6 +38,7 @@ void SAL_CALL StatusIndicator::start(const OUString& sText ,
 if (comphelper::LibreOfficeKit::isActive())
 {
 m_nRange = nRange;
+m_nLastCallbackPercent = -1;
 
 comphelper::LibreOfficeKit::statusIndicatorStart();
 return;
@@ -102,7 +103,11 @@ void SAL_CALL StatusIndicator::setValue(sal_Int32 nValue)
 if (comphelper::LibreOfficeKit::isActive())
 {
 int nPercent = (100*nValue)/m_nRange;
-comphelper::LibreOfficeKit::statusIndicatorSetValue(nPercent);
+if (nPercent != m_nLastCallbackPercent)
+{
+comphelper::LibreOfficeKit::statusIndicatorSetValue(nPercent);
+m_nLastCallbackPercent = nPercent;
+}
 return;
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


QA Meeting Minutes - 2015-05-06

2015-05-08 Thread Robinson Tryon
Hi all,

Thanks for the great meeting on Wednesday! Meeting minutes are available here:
https://wiki.documentfoundation.org/QA/Meetings/2015/May_06

Our next meeting is taking place in two weeks
https://wiki.documentfoundation.org/QA/Meetings/2015/May_20

Interestingly, May 20th also happens to be Metrology Day, dedicated to
"the worldwide uniformity of measurement":
https://en.wikipedia.org/wiki/World_Metrology_Day

Goodness knows that QA testing is very non-uniform at times, but we
can definitely strive for consistency and repeatability in all that we
do!

Best,
--R

-- 
Robinson Tryon
QA Engineer - The Document Foundation
LibreOffice Community Outreach Herald
qu...@libreoffice.org
802-379-9482 | IRC: colonelqubit on Freenode
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[GSOC] Improve user experience with CMIS - introduction

2015-05-08 Thread Szymon Kłos
Hi everyone!

My name is Szymon and  I've been accepted at Google Summer of Code 2015.
Last Year I was working with LibreOffice too and  my project was 'Dialog
Widget Conversion'.

This Year my project is titled 'Improve user experience with CMIS'.
Cedric Bosdonnat and Jan Holesovsky will be my mentors.

The main goal of my work is provide an easy way to access to the remote
documents. Now it is possible to use different online services, but this
isn't easy and for average user this feature is not visible (to see this
you must use LibreOffice's custom dialogs).

I want to implement new dialog for creating new connections and
accessing the old. User will be able to open this dialog from start
center and toolbars.

Second part of my project is implementing PreviewHandler library for
Windows to provide preview of the .odf files in Windows Explorer.

Regards,
Szymon Kłos

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Crash test update

2015-05-08 Thread Crashtest VM
New crashtest update available at 
http://dev-builds.libreoffice.org/crashtest/e658cb4d5ce49d3a3c6acc63155974b5ff8490c7/


exportCrashes.csv
Description: Binary data


importCrash.csv
Description: Binary data


validationErrors.csv
Description: Binary data
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: libreofficekit/qa

2015-05-08 Thread Pranav Kant
 libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx |   24 ++--
 1 file changed, 12 insertions(+), 12 deletions(-)

New commits:
commit 92361b81d46b0c4cea71cf8643130d636f1821b6
Author: Pranav Kant 
Date:   Fri May 8 23:07:52 2015 +0530

gtktiledviewer: Make all functions static

These functions are only being used inside this file.

Change-Id: I473b33f794cfbaff590d00f22d2832456482d15a
Reviewed-on: https://gerrit.libreoffice.org/15680
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx 
b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
index cb84ee7..7509b2f 100644
--- a/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
+++ b/libreofficekit/qa/gtktiledviewer/gtktiledviewer.cxx
@@ -59,7 +59,7 @@ static void lcl_registerToolItem(GtkToolItem* pItem, const 
std::string& rName)
 
 const float fZooms[] = { 0.25, 0.5, 0.75, 1.0, 1.5, 2.0, 3.0, 5.0 };
 
-void changeZoom( GtkWidget* pButton, gpointer /* pItem */ )
+static void changeZoom( GtkWidget* pButton, gpointer /* pItem */ )
 {
 const char *sName = gtk_tool_button_get_stock_id( GTK_TOOL_BUTTON(pButton) 
);
 
@@ -107,7 +107,7 @@ void changeZoom( GtkWidget* pButton, gpointer /* pItem */ )
 }
 
 /// User clicked on the button -> inform LOKDocView.
-void toggleEditing(GtkWidget* /*pButton*/, gpointer /*pItem*/)
+static void toggleEditing(GtkWidget* /*pButton*/, gpointer /*pItem*/)
 {
 LOKDocView* pLOKDocView = LOK_DOCVIEW(pDocView);
 bool bActive = 
gtk_toggle_tool_button_get_active(GTK_TOGGLE_TOOL_BUTTON(pEnableEditing));
@@ -116,7 +116,7 @@ void toggleEditing(GtkWidget* /*pButton*/, gpointer 
/*pItem*/)
 }
 
 /// Toggle the visibility of the findbar.
-void toggleFindbar(GtkWidget* /*pButton*/, gpointer /*pItem*/)
+static void toggleFindbar(GtkWidget* /*pButton*/, gpointer /*pItem*/)
 {
 #if GTK_CHECK_VERSION(2,18,0) // we need gtk_widget_get_visible()
 if (gtk_widget_get_visible(pFindbar))
@@ -146,7 +146,7 @@ static gboolean signalKey(GtkWidget* pWidget, GdkEventKey* 
pEvent, gpointer pDat
 }
 
 /// Searches for the next or previous text of pFindbarEntry.
-void doSearch(bool bBackwards)
+static void doSearch(bool bBackwards)
 {
 GtkEntry* pEntry = GTK_ENTRY(pFindbarEntry);
 const char* pText = gtk_entry_get_text(pEntry);
@@ -163,19 +163,19 @@ void doSearch(bool bBackwards)
 }
 
 /// Click handler for the search next button.
-void signalSearchNext(GtkWidget* /*pButton*/, gpointer /*pItem*/)
+static void signalSearchNext(GtkWidget* /*pButton*/, gpointer /*pItem*/)
 {
 doSearch(/*bBackwards=*/false);
 }
 
 /// Click handler for the search previous button.
-void signalSearchPrev(GtkWidget* /*pButton*/, gpointer /*pItem*/)
+static void signalSearchPrev(GtkWidget* /*pButton*/, gpointer /*pItem*/)
 {
 doSearch(/*bBackwards=*/true);
 }
 
 /// Handles the key-press-event of the search entry widget.
-gboolean signalFindbar(GtkWidget* /*pWidget*/, GdkEventKey* pEvent, gpointer 
/*pData*/)
+static gboolean signalFindbar(GtkWidget* /*pWidget*/, GdkEventKey* pEvent, 
gpointer /*pData*/)
 {
 switch(pEvent->keyval)
 {
@@ -231,7 +231,7 @@ static void signalCommand(LOKDocView* /*pLOKDocView*/, 
char* pPayload, gpointer
 }
 
 /// User clicked on a cmmand button -> inform LOKDocView.
-void toggleToolItem(GtkWidget* pWidget, gpointer /*pData*/)
+static void toggleToolItem(GtkWidget* pWidget, gpointer /*pData*/)
 {
 if (g_bToolItemBroadcast)
 {
@@ -245,7 +245,7 @@ void toggleToolItem(GtkWidget* pWidget, gpointer /*pData*/)
 
 // GtkComboBox requires gtk 2.24 or later
 #if ( GTK_MAJOR_VERSION == 2 && GTK_MINOR_VERSION >= 24 ) || GTK_MAJOR_VERSION 
> 2
-void populatePartSelector()
+static void populatePartSelector()
 {
 gtk_list_store_clear( GTK_LIST_STORE(
   gtk_combo_box_get_model(
@@ -273,7 +273,7 @@ void populatePartSelector()
   lok_docview_get_part( LOK_DOCVIEW(pDocView) ) );
 }
 
-void changePart( GtkWidget* pSelector, gpointer /* pItem */ )
+static void changePart( GtkWidget* pSelector, gpointer /* pItem */ )
 {
 int nPart = gtk_combo_box_get_active( GTK_COMBO_BOX(pSelector) );
 
@@ -283,7 +283,7 @@ void changePart( GtkWidget* pSelector, gpointer /* pItem */ 
)
 }
 }
 
-void populatePartModeSelector( GtkComboBoxText* pSelector )
+static void populatePartModeSelector( GtkComboBoxText* pSelector )
 {
 gtk_combo_box_text_append_text( pSelector, "Default" );
 gtk_combo_box_text_append_text( pSelector, "Slide" );
@@ -293,7 +293,7 @@ void populatePartModeSelector( GtkComboBoxText* pSelector )
 gtk_combo_box_set_active( GTK_COMBO_BOX(pSelector), 0 );
 }
 
-void changePartMode( GtkWidget* pSelector, gpointer /* pItem */ )
+static void changePartMode( GtkWidget* pSelector, gpointer /* pItem */ )
 {
 // Just convert directly back to the LibreOfficeKitPartMode enum.
 // I.e. the ordering above should match the enum member ordering.

[Libreoffice-commits] core.git: vcl/source

2015-05-08 Thread Stephan Bergmann
 vcl/source/window/event.cxx |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 16660664879cfad128d4f1e562d30b0565b9b5de
Author: Stephan Bergmann 
Date:   Fri May 8 22:58:55 2015 +0200

loplugin:redundantcast

Change-Id: I2931de2cc2a9916dae785d0cc130ce2aa73cf54e

diff --git a/vcl/source/window/event.cxx b/vcl/source/window/event.cxx
index 4a8d7e2..1a14dd1 100644
--- a/vcl/source/window/event.cxx
+++ b/vcl/source/window/event.cxx
@@ -274,9 +274,9 @@ ImplSVEvent * Window::PostUserEvent( const Link<>& rLink, 
void* pCaller, bool bR
 {
 // Double check that this is indeed a vcl::Window instance.
 assert(dynamic_cast(
-reinterpret_cast(rLink.GetInstance())) 
==
-   reinterpret_cast(rLink.GetInstance()));
-pSVEvent->mpInstanceRef = reinterpret_cast(rLink.GetInstance());
+static_cast(rLink.GetInstance())) ==
+   static_cast(rLink.GetInstance()));
+pSVEvent->mpInstanceRef = static_cast(rLink.GetInstance());
 }
 
 ImplAddDel( &(pSVEvent->maDelData) );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: vcl/source

2015-05-08 Thread Stephan Bergmann
 vcl/source/app/svapp.cxx |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 56e9755d75e5faae9765c3be4b8936e5867cef08
Author: Stephan Bergmann 
Date:   Fri May 8 23:03:14 2015 +0200

loplugin:redundantcast

Change-Id: I50154e2deb66a77fc4354b1db0e4cd8e1b1ffd2e

diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index 32949fb..0796ded 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -909,9 +909,9 @@ ImplSVEvent * Application::PostUserEvent( const Link<>& 
rLink, void* pCaller,
 {
 // Double check that this is indeed a vcl::Window instance.
 assert(dynamic_cast(
-reinterpret_cast(rLink.GetInstance())) 
==
-   reinterpret_cast(rLink.GetInstance()));
-pSVEvent->mpInstanceRef = reinterpret_cast(rLink.GetInstance());
+static_cast(rLink.GetInstance())) ==
+   static_cast(rLink.GetInstance()));
+pSVEvent->mpInstanceRef = static_cast(rLink.GetInstance());
 }
 
 vcl::Window* pDefWindow = ImplGetDefaultWindow();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: vcl/source

2015-05-08 Thread Michael Meeks
 vcl/source/app/svapp.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit e953cb1a3c2c240a385608658ffc481e33c6854b
Author: Michael Meeks 
Date:   Fri May 8 22:09:02 2015 +0100

Take SolarMutex when pushing app events that need a VclPtr.

Change-Id: Ice91c9e698d99d9674a7c7b3c688faa07603bf95

diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index 0796ded..3a56cd9 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -907,6 +907,7 @@ ImplSVEvent * Application::PostUserEvent( const Link<>& 
rLink, void* pCaller,
 pSVEvent->mbCall= true;
 if (bReferenceLink)
 {
+SolarMutexGuard aGuard;
 // Double check that this is indeed a vcl::Window instance.
 assert(dynamic_cast(
 static_cast(rLink.GetInstance())) ==
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-4' - editeng/source

2015-05-08 Thread David Tardon
 editeng/source/editeng/impedit3.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 4fb7ff0dfde0f5163a148c6f9e542352a1528b12
Author: David Tardon 
Date:   Mon Apr 27 16:38:23 2015 +0200

rhbz#1215443 avoid null pointer dereference

Change-Id: I0a7986703a6997c756d583d0e46907691f807b16
Signed-off-by: Michael Meeks 

diff --git a/editeng/source/editeng/impedit3.cxx 
b/editeng/source/editeng/impedit3.cxx
index c68520d..c8c50a5 100644
--- a/editeng/source/editeng/impedit3.cxx
+++ b/editeng/source/editeng/impedit3.cxx
@@ -3473,7 +3473,8 @@ void ImpEditEngine::Paint( OutputDevice* pOutDev, 
Rectangle aClipRect, Point aSt
 }
 }
 
-if ( GetStatus().DoOnlineSpelling() && 
!pPortion->GetNode()->GetWrongList()->empty() && pTextPortion->GetLen() )
+const WrongList* const pWrongList = 
pPortion->GetNode()->GetWrongList();
+if ( GetStatus().DoOnlineSpelling() && 
pWrongList && !pWrongList->empty() && pTextPortion->GetLen() )
 {
 {//#105750# adjust LinePos for 
superscript or subscript text
 short _nEsc = 
aTmpFont.GetEscapement();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: cui/source dbaccess/source vcl/source vcl/unx

2015-05-08 Thread Michael Meeks
 cui/source/customize/cfg.cxx|2 +-
 cui/source/dialogs/SpellDialog.cxx  |4 ++--
 cui/source/dialogs/cuigaldlg.cxx|4 ++--
 cui/source/dialogs/thesdlg.cxx  |2 +-
 cui/source/options/optlingu.cxx |2 +-
 dbaccess/source/ext/macromigration/macromigrationdialog.cxx |2 +-
 dbaccess/source/ui/app/AppDetailPageHelper.cxx  |2 +-
 dbaccess/source/ui/app/AppSwapWindow.cxx|2 +-
 dbaccess/source/ui/browser/sbagrid.cxx  |2 +-
 vcl/source/window/dialog.cxx|2 +-
 vcl/source/window/dockmgr.cxx   |2 +-
 vcl/source/window/dockwin.cxx   |2 +-
 vcl/source/window/mouse.cxx |2 +-
 vcl/source/window/syschild.cxx  |2 +-
 vcl/source/window/toolbox.cxx   |2 +-
 vcl/source/window/toolbox2.cxx  |2 +-
 vcl/source/window/winproc.cxx   |4 ++--
 vcl/unx/generic/app/i18n_status.cxx |2 +-
 18 files changed, 21 insertions(+), 21 deletions(-)

New commits:
commit 8372b3c3d1c3e8a787e174cc31dca55627b74b15
Author: Michael Meeks 
Date:   Fri May 8 22:13:08 2015 +0100

PostUserEvent - first cut at keeping a VclPtr for posted UserEvents.

This should eventually enable more certainty that they are still
live by the time we emit the event later.

Change-Id: I7c9eb4c000753d4efe8c59a9e13ef3e11c93b2fa

diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index 89d5b4c..f902a15 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -2001,7 +2001,7 @@ SvTreeListEntry* SvxConfigPage::AddFunction(
 {
 // asynchronous error message, because of MsgBoxes
 PostUserEvent(
-LINK( this, SvxConfigPage, AsyncInfoMsg ) );
+LINK( this, SvxConfigPage, AsyncInfoMsg ), NULL, true );
 delete pNewEntryData;
 return NULL;
 }
diff --git a/cui/source/dialogs/SpellDialog.cxx 
b/cui/source/dialogs/SpellDialog.cxx
index c1238be..10bc499 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -238,8 +238,8 @@ SpellDialog::SpellDialog(SpellDialogChildWindow* 
pChildWindow,
 //InitHdl wants to use virtual methods, so it
 //can't be called during the ctor, so init
 //it on next event cycle post-ctor
-Application::PostUserEvent( LINK(
-this, SpellDialog, InitHdl ) );
+Application::PostUserEvent(
+LINK( this, SpellDialog, InitHdl ), NULL, true );
 }
 
 
diff --git a/cui/source/dialogs/cuigaldlg.cxx b/cui/source/dialogs/cuigaldlg.cxx
index 7f4abcb..4eafd49 100644
--- a/cui/source/dialogs/cuigaldlg.cxx
+++ b/cui/source/dialogs/cuigaldlg.cxx
@@ -110,7 +110,7 @@ void SearchThread::execute()
 ImplSearch( maStartURL, aFormats, mpBrowser->bSearchRecursive );
 }
 
-Application::PostUserEvent( LINK( mpProgress, SearchProgress, CleanUpHdl ) 
);
+Application::PostUserEvent( LINK( mpProgress, SearchProgress, CleanUpHdl 
), NULL, true );
 }
 
 
@@ -343,7 +343,7 @@ void TakeThread::execute()
 delete pStatusProgress;
 }
 
-Application::PostUserEvent( LINK( mpProgress, TakeProgress, CleanUpHdl ) );
+Application::PostUserEvent( LINK( mpProgress, TakeProgress, CleanUpHdl ), 
NULL, true );
 }
 
 // - TakeProgress -
diff --git a/cui/source/dialogs/thesdlg.cxx b/cui/source/dialogs/thesdlg.cxx
index a71456e..26808a1 100644
--- a/cui/source/dialogs/thesdlg.cxx
+++ b/cui/source/dialogs/thesdlg.cxx
@@ -442,7 +442,7 @@ IMPL_LINK( SvxThesaurusDialog, 
AlternativesDoubleClickHdl_Impl, SvxCheckListBox
 
 //! workaround to set the selection since calling SelectEntryPos within
 //! the double click handler does not work
-Application::PostUserEvent( LINK( this, SvxThesaurusDialog, 
SelectFirstHdl_Impl ), pBox );
+Application::PostUserEvent( LINK( this, SvxThesaurusDialog, 
SelectFirstHdl_Impl ), pBox, true );
 return 0;
 }
 
diff --git a/cui/source/options/optlingu.cxx b/cui/source/options/optlingu.cxx
index 1f780e4..12ef876 100644
--- a/cui/source/options/optlingu.cxx
+++ b/cui/source/options/optlingu.cxx
@@ -1530,7 +1530,7 @@ IMPL_LINK( SvxLinguTabPage, BoxDoubleClickHdl_Impl, 
SvTreeListBox *, pBox )
 //! on a module entry and exiting the "Edit Modules" dialog
 //! after that.
 Application::PostUserEvent( LINK(
-this, SvxLinguTabPage, PostDblClickHdl_Impl ) );
+this, SvxLinguTabPage, PostDblClickHdl_Impl ), NULL, true);
 }
 else if (pBox == m_pLinguOptionsCLB)
 {
diff --git a/dbaccess/source

[Libreoffice-commits] core.git: include/vcl

2015-05-08 Thread Michael Meeks
 include/vcl/outdev.hxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 9a744dea1dccb73d77e38ed06d1275f00425a65b
Author: Michael Meeks 
Date:   Fri May 8 22:15:07 2015 +0100

vclptr: assert that we have a >0 ref-count in acquire as well.

Change-Id: Ia2286661a8f62e8a46c44c390ab1a8a5dffe81d0

diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index 66bcccb..a5673ea 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -274,6 +274,7 @@ private:
 
 inline void acquire() const
 {
+assert(mnRefCnt>0);
 mnRefCnt++;
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: 8 commits - vcl/inc vcl/osx vcl/quartz vcl/source

2015-05-08 Thread Stephan Bergmann
 vcl/inc/osx/salmenu.h   |1 -
 vcl/inc/osx/salprn.h|2 +-
 vcl/inc/quartz/salgdi.h |6 +-
 vcl/osx/DropTarget.cxx  |5 +++--
 vcl/osx/DropTarget.hxx  |2 +-
 vcl/osx/salmenu.cxx |   32 ++--
 vcl/osx/salprn.cxx  |4 ++--
 vcl/quartz/ctfonts.cxx  |5 -
 vcl/quartz/salgdi.cxx   |5 +
 vcl/quartz/salgdicommon.cxx |6 +-
 vcl/source/opengl/OpenGLContext.cxx |3 +++
 vcl/source/outdev/outdev.cxx|1 +
 12 files changed, 36 insertions(+), 36 deletions(-)

New commits:
commit 6183a945de03dcd5fe0b967d5814a0add954a8c8
Author: Stephan Bergmann 
Date:   Fri May 8 23:46:54 2015 +0200

False loplugin:staticmethods

Change-Id: Icc026ebb422c299caca6c24d6a56416076589fc8

diff --git a/vcl/source/opengl/OpenGLContext.cxx 
b/vcl/source/opengl/OpenGLContext.cxx
index 8d298a4..9beed93 100644
--- a/vcl/source/opengl/OpenGLContext.cxx
+++ b/vcl/source/opengl/OpenGLContext.cxx
@@ -1330,6 +1330,7 @@ bool OpenGLContext::isCurrent()
 return (wglGetCurrentContext() == m_aGLWin.hRC &&
 wglGetCurrentDC() == m_aGLWin.hDC);
 #elif defined( MACOSX )
+(void) this; // loplugin:staticmethods
 return false;
 #elif defined( IOS ) || defined( ANDROID ) || defined(LIBO_HEADLESS)
 return false;
@@ -1409,6 +1410,7 @@ void OpenGLContext::resetCurrent()
 #if defined( WNT )
 wglMakeCurrent( m_aGLWin.hDC, 0 );
 #elif defined( MACOSX )
+(void) this; // loplugin:staticmethods
 OpenGLWrapper::resetCurrent();
 #elif defined( IOS ) || defined( ANDROID ) || defined(LIBO_HEADLESS)
 // nothing
@@ -1436,6 +1438,7 @@ void OpenGLContext::sync()
 #if defined( WNT )
 // nothing
 #elif defined( MACOSX ) || defined( IOS ) || defined( ANDROID ) || 
defined(LIBO_HEADLESS)
+(void) this; // loplugin:staticmethods
 // nothing
 #elif defined( UNX )
 glXWaitGL();
diff --git a/vcl/source/outdev/outdev.cxx b/vcl/source/outdev/outdev.cxx
index 855a2d4..e9e6228 100644
--- a/vcl/source/outdev/outdev.cxx
+++ b/vcl/source/outdev/outdev.cxx
@@ -335,6 +335,7 @@ bool OutputDevice::SupportsCairo() const
 
 return mpGraphics->SupportsCairo();
 #else
+(void) this; // loplugin:staticmethods
 return false;
 #endif
 }
commit deca1830c8b2446fde35a443248638354b37239b
Author: Stephan Bergmann 
Date:   Fri May 8 23:46:26 2015 +0200

loplugin:staticmethods

Change-Id: I186c81923857d06ac7a87caf9d5961f44b89b559

diff --git a/vcl/osx/DropTarget.cxx b/vcl/osx/DropTarget.cxx
index 28843b2..b52e433 100644
--- a/vcl/osx/DropTarget.cxx
+++ b/vcl/osx/DropTarget.cxx
@@ -99,7 +99,8 @@ namespace /* private */
 
 -(BOOL)prepareForDragOperation:(id )sender
 {
-return mDropTarget->prepareForDragOperation(sender);
+(void) sender;
+return DropTarget::prepareForDragOperation();
 }
 
 -(BOOL)performDragOperation:(id )sender
@@ -282,7 +283,7 @@ void DropTarget::draggingExited(id /*sender*/)
 [[NSCursor arrowCursor] set];
 }
 
-BOOL DropTarget::prepareForDragOperation(id /*sender*/)
+BOOL DropTarget::prepareForDragOperation()
 {
 return 1;
 }
diff --git a/vcl/osx/DropTarget.hxx b/vcl/osx/DropTarget.hxx
index d67b647..09f4ee8 100644
--- a/vcl/osx/DropTarget.hxx
+++ b/vcl/osx/DropTarget.hxx
@@ -124,7 +124,7 @@ public:
   NSDragOperation draggingEntered(id sender);
   NSDragOperation draggingUpdated(id sender);
   void draggingExited(id sender);
-  BOOL prepareForDragOperation(id sender);
+  static BOOL prepareForDragOperation();
   BOOL performDragOperation(id sender);
   void concludeDragOperation(id sender);
 
commit 8d66fe43a1c6ee197517135bd34b51654d0cd7f8
Author: Stephan Bergmann 
Date:   Fri May 8 23:45:53 2015 +0200

loplugin:staticmethods

Change-Id: I9fa42eeeabb4a6c7ee18b52d24c480a3f7a6a753

diff --git a/vcl/inc/quartz/salgdi.h b/vcl/inc/quartz/salgdi.h
index 35fd6b8..12c3144 100644
--- a/vcl/inc/quartz/salgdi.h
+++ b/vcl/inc/quartz/salgdi.h
@@ -433,7 +433,7 @@ private:
 voidPattern50Fill();
 UInt32  getState( ControlState nState );
 UInt32  getTrackState( ControlState nState );
-boolGetRawFontData( const PhysicalFontFace* pFontData,
+static bool GetRawFontData( const PhysicalFontFace* pFontData,
 std::vector& rBuffer,
 bool* pJustCFF );
 };
commit 91cfdc9fbd84d1e7f2103efb702f52ccfd9993e5
Author: Stephan Bergmann 
Date:   Fri May 8 23:45:18 2015 +0200

loplugin:staticmethods

Change-Id: Iafb48b20496924c64f9aaa3ec0965b023aef6a07

diff --git a/vcl/inc/quartz/salgdi.h b/vcl/inc/quartz/salgdi.h
index 346602c..35fd6b8 100644
--- a/vcl/inc/quartz/salgdi.h
+++ b/vcl/inc/quartz/salgdi.h
@@ -298,7 +298,6 @@ public:
 virtual booldrawAlphaRect( long nX, long nY, long nWidth,
  

[Libreoffice-commits] core.git: sc/source

2015-05-08 Thread Henry Castro
 sc/source/ui/view/viewfun2.cxx |   16 
 1 file changed, 16 insertions(+)

New commits:
commit 4048311aae6993357c2d0be1f1968a8c57dd4e85
Author: Henry Castro 
Date:   Wed May 6 21:20:06 2015 -0400

sc tiled editing: Highlight the search result

Change-Id: Ib46e3d484f931cbdebf21ea38488313748942b3b

diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx
index 070b109..5b5ec3b 100644
--- a/sc/source/ui/view/viewfun2.cxx
+++ b/sc/source/ui/view/viewfun2.cxx
@@ -85,6 +85,7 @@
 #include "tokenarray.hxx"
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -1815,6 +1816,21 @@ bool ScViewFunc::SearchAndReplace( const SvxSearchItem* 
pSearchItem,
 AlignToCursor( nCol, nRow, SC_FOLLOW_JUMP );
 SetCursor( nCol, nRow, true );
 
+if (rDoc.GetDrawLayer()->isTiledRendering())
+{
+Point aCurPos = GetViewData().GetScrPos(nCol, nRow, 
GetViewData().GetActivePart());
+
+// just update the cell selection
+ScGridWindow* pGridWindow = GetViewData().GetActiveWin();
+if (pGridWindow)
+{
+// move the cell selection handles
+pGridWindow->SetCellSelectionPixel(LOK_SETTEXTSELECTION_START, 
aCurPos.X(), aCurPos.Y());
+pGridWindow->SetCellSelectionPixel(LOK_SETTEXTSELECTION_END, 
aCurPos.X(), aCurPos.Y());
+pGridWindow->SetCellSelectionPixel(LOK_SETTEXTSELECTION_RESET, 
aCurPos.X(), aCurPos.Y());
+}
+}
+
 if (   nCommand == SvxSearchCmd::REPLACE
 || nCommand == SvxSearchCmd::REPLACE_ALL )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


LibreOffice Gerrit News for core on 2015-05-09

2015-05-08 Thread gerrit
Moin!

* Open changes on master for project core changed in the last 25 hours:

 First time contributors doing great things! 
+ tdf#90672: PPTX table cell border color is not exported.
  in https://gerrit.libreoffice.org/15364 from Yogesh Bharate
  about module oox, sd
+ tdf#66353: fix converting relative sw table formula back to box
  in https://gerrit.libreoffice.org/15678 from Mike Kaganski
  about module sw
+ tdf#90190 PPTX table cell border width is not exported.
  in https://gerrit.libreoffice.org/15350 from Yogesh Bharate
  about module include, oox, sd
+ tdf#90828 FILESAVE:XLSX export of underline color for text inside textbox
  in https://gerrit.libreoffice.org/15514 from Priyanka Gaikwad
  about module oox, sc
+ tdf#74932 FILESAVE: Shapes appear when saving a .XLSX file with filter
  in https://gerrit.libreoffice.org/15662 from Priyanka Gaikwad
  about module oox, sc
+ Unit test for tdf#83366
  in https://gerrit.libreoffice.org/15670 from Henry Castro
  about module sc
 End of freshness 

+ Update HarfBuzz to 0.9.40
  in https://gerrit.libreoffice.org/15643 from Khaled Hosny
  about module build, external
+ convert SYMBOL_DRAW constants to scoped enum
  in https://gerrit.libreoffice.org/15676 from Noel Grandin
  about module include, sc, svtools, vcl
+ convert CURSOR_DIRECTION constants to scoped enum
  in https://gerrit.libreoffice.org/15675 from Noel Grandin
  about module editeng, include, sw, vcl
+ convert COMMAND_ constants to scoped enum
  in https://gerrit.libreoffice.org/15671 from Noel Grandin
  about module basctl, chart2, cui, dbaccess, desktop, editeng, extensions, 
forms, framework, include, reportdesign, sc, sd, sfx2, starmath, svtools, svx, 
sw, toolkit, vcl
+ tdf#90235 stop double code in ScInterpreter::ScSum and ScInterpreter::Ite
  in https://gerrit.libreoffice.org/15362 from Winfried Donkers
  about module sc
+ Do not write v:fill properties on export of imagedata
  in https://gerrit.libreoffice.org/15668 from Joren De Cuyper
  about module oox


* Merged changes on master for project core changed in the last 25 hours:

+ gtktiledviewer: Make all functions static
  in https://gerrit.libreoffice.org/15680 from Pranav Kant
+ gtktiledviewer: Stop event propagation to GtkToolbar when in edit mode
  in https://gerrit.libreoffice.org/15677 from Pranav Kant
+ std::ptr_fun became deprecated since C++11
  in https://gerrit.libreoffice.org/15672 from Takeshi Abe
+ tdf#78834 enable localized system dialogs on OS X
  in https://gerrit.libreoffice.org/15673 from Andras Timar
+ convert MEDIA_COMMAND constants to scoped enum
  in https://gerrit.libreoffice.org/15652 from Noel Grandin
+ convert SHOWDIALOG_ID constants to scoped enum
  in https://gerrit.libreoffice.org/15651 from Noel Grandin


* Abandoned changes on master for project core changed in the last 25 hours:

None

* Open changes needing tweaks, but being untouched for more than a week:

+ tdf#69701 use Calc's GCD() function instead of add-in GCD and
  in https://gerrit.libreoffice.org/15185 from Winfried Donkers
+ Fixed two strings in the context menu for consistency with other entries
  in https://gerrit.libreoffice.org/15537 from Yousuf Philips
+ tdf#90494-Add new Attribute for exporting gradient angle diagonally
  in https://gerrit.libreoffice.org/15323 from Heena Gupta
+ preserve whitespaces here, tdf#88137, tdf#89254
  in https://gerrit.libreoffice.org/15375 from Markus Mohrhard
+ add kde5 build of vcl
  in https://gerrit.libreoffice.org/15327 from Jonathan Riddell
+ added currency dropdown menu may have some erors
  in https://gerrit.libreoffice.org/15274 from rajat vijay
+ Remove compiler Warnings
  in https://gerrit.libreoffice.org/15260 from Delveri Chick
+ Init
  in https://gerrit.libreoffice.org/15259 from Delveri Chick
+ tdf#90222: replace ScaList in scaddins with a std container
  in https://gerrit.libreoffice.org/15012 from Pieter Adriaensen
+ replace ScaList in scaddins with a std container tdf#90222
  in https://gerrit.libreoffice.org/15177 from Pieter Adriaensen
+ fdo#82335.
  in https://gerrit.libreoffice.org/11555 from Sudarshan Rao
+ tdf#64575 Photo Album: Better Image Layout
  in https://gerrit.libreoffice.org/14912 from Enes Ateş
+ WIP fdo#72987 Use firebird backup format for .odb no need for rebuild ind
  in https://gerrit.libreoffice.org/14968 from Popa Adrian Marius
+ Upgrade firebird to 2.5.3 , a few patches are already applied upstream
  in https://gerrit.libreoffice.org/15026 from Popa Adrian Marius
+ Fixed all  postfix operator++ and operator--
  in https://gerrit.libreoffice.org/14975 from Ahmad Samir
+ tdf#39468 Translate German Comments - sc/source/core/data/
  in https://gerrit.libreoffice.org/14866 from Christian M. Heller
+ tdf#49893: final fix for blank rectangle problem
  in https://gerrit.libreoffice.org/14584 from Vasily Melenchuk
+ xmloff: convert xof.component to use constructor syntax
  in https://gerrit.libreoffice.org/14820 from Chris Sherlock
+ xmloff: use constructor syn