[Libreoffice-commits] core.git: desktop/qa desktop/source include/LibreOfficeKit include/vcl sw/inc sw/qa sw/source vcl/source
desktop/qa/desktop_lib/test_desktop_lib.cxx|3 +- desktop/source/lib/init.cxx| 19 ++ include/LibreOfficeKit/LibreOfficeKit.h|5 +++ include/LibreOfficeKit/LibreOfficeKit.hxx | 11 include/LibreOfficeKit/LibreOfficeKitEnums.h | 11 include/vcl/ITiledRenderable.hxx |7 + include/vcl/vclevent.hxx |2 + include/vcl/window.hxx |1 sw/inc/unotxdoc.hxx|2 + sw/qa/extras/tiledrendering/tiledrendering.cxx | 33 + sw/source/uibase/uno/unotxdoc.cxx | 22 vcl/source/window/window.cxx | 20 ++- 12 files changed, 134 insertions(+), 2 deletions(-) New commits: commit 7f9f58f3a304733f7089719a5a65eef8c68c2b8d Author: Pranav Kant Date: Wed Feb 7 17:19:58 2018 +0530 sw lok: IME support + unit test Change-Id: I557493db23dfa3529606050c86161628dbd722e7 Reviewed-on: https://gerrit.libreoffice.org/49354 Reviewed-by: pranavk Tested-by: pranavk diff --git a/desktop/qa/desktop_lib/test_desktop_lib.cxx b/desktop/qa/desktop_lib/test_desktop_lib.cxx index 4488aa8c155c..4d2d50644b16 100644 --- a/desktop/qa/desktop_lib/test_desktop_lib.cxx +++ b/desktop/qa/desktop_lib/test_desktop_lib.cxx @@ -2291,10 +2291,11 @@ void DesktopLOKTest::testABI() CPPUNIT_ASSERT_EQUAL(documentClassOffset(37), offsetof(struct _LibreOfficeKitDocumentClass, postWindowKeyEvent)); CPPUNIT_ASSERT_EQUAL(documentClassOffset(38), offsetof(struct _LibreOfficeKitDocumentClass, postWindowMouseEvent)); CPPUNIT_ASSERT_EQUAL(documentClassOffset(39), offsetof(struct _LibreOfficeKitDocumentClass, setViewLanguage)); +CPPUNIT_ASSERT_EQUAL(documentClassOffset(40), offsetof(struct _LibreOfficeKitDocumentClass, postExtTextInputEvent)); // Extending is fine, update this, and add new assert for the offsetof the // new method -CPPUNIT_ASSERT_EQUAL(documentClassOffset(40), sizeof(struct _LibreOfficeKitDocumentClass)); +CPPUNIT_ASSERT_EQUAL(documentClassOffset(41), sizeof(struct _LibreOfficeKitDocumentClass)); } CPPUNIT_TEST_SUITE_REGISTRATION(DesktopLOKTest); diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index ab7b72d526dc..2165a781725a 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -540,6 +540,9 @@ static void doc_postKeyEvent(LibreOfficeKitDocument* pThis, int nType, int nCharCode, int nKeyCode); +static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis, + int nType, + const char* pText); static void doc_postWindowKeyEvent(LibreOfficeKitDocument* pThis, unsigned nLOKWindowId, int nType, @@ -633,6 +636,7 @@ LibLODocument_Impl::LibLODocument_Impl(const uno::Reference initializeForRendering = doc_initializeForRendering; m_pDocumentClass->registerCallback = doc_registerCallback; m_pDocumentClass->postKeyEvent = doc_postKeyEvent; +m_pDocumentClass->postExtTextInputEvent = doc_postExtTextInputEvent; m_pDocumentClass->postWindowKeyEvent = doc_postWindowKeyEvent; m_pDocumentClass->postMouseEvent = doc_postMouseEvent; m_pDocumentClass->postWindowMouseEvent = doc_postWindowMouseEvent; @@ -2288,9 +2292,24 @@ static void doc_postKeyEvent(LibreOfficeKitDocument* pThis, int nType, int nChar gImpl->maLastExceptionMsg = "Document doesn't support tiled rendering"; return; } + pDoc->postKeyEvent(nType, nCharCode, nKeyCode); } +static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis, int nType, const char* pText) +{ +SolarMutexGuard aGuard; + +ITiledRenderable* pDoc = getTiledRenderable(pThis); +if (!pDoc) +{ +gImpl->maLastExceptionMsg = "Document doesn't support tiled rendering"; +return; +} + +pDoc->postExtTextInputEvent(nType, OUString::fromUtf8(OString(pText, strlen(pText; +} + static void doc_postWindowKeyEvent(LibreOfficeKitDocument* /*pThis*/, unsigned nLOKWindowId, int nType, int nCharCode, int nKeyCode) { SolarMutexGuard aGuard; diff --git a/include/LibreOfficeKit/LibreOfficeKit.h b/include/LibreOfficeKit/LibreOfficeKit.h index d42bd3434689..ebc112fb7bd5 100644 --- a/include/LibreOfficeKit/LibreOfficeKit.h +++ b/include/LibreOfficeKit/LibreOfficeKit.h @@ -300,6 +300,11 @@ struct _LibreOfficeKitDocumentClass /// @see lok::Document::setViewLanguage(). void (*setViewLanguage) (LibreOfficeKitDocument* pThis, int nId, const char* language); +/// @see lok::Document::postExtTextInputEvent +void (*postExtTextInputEvent) (LibreOfficeKitDocument* pThis, +
[Libreoffice-commits] core.git: oox/source sc/source
oox/source/drawingml/chart/axisconverter.cxx |7 ++- oox/source/export/chartexport.cxx| 17 ++--- sc/source/filter/excel/xechart.cxx | 13 + sc/source/filter/excel/xichart.cxx | 18 ++ 4 files changed, 39 insertions(+), 16 deletions(-) New commits: commit 274825b4180c81540cd0d1b22c5243f1b39fe4db Author: Bartosz Kosiorek Date: Wed Feb 7 02:57:30 2018 +0100 tdf#114168 If minor axis unit is automatic, then set it to 5 Based on OOXML implementation in MS Excel, if Minor axis Unit is set to automatic, then during chart import, LibreOffice should set Interval Count to 5, to mimic behaviour of MS Excel. Becaues default Interval Count for LibreOffice is 2, we need to override it to 5. With that solution, the Minor axis unit is preserved also after saving to .ods file format. During .xlsx export, if Interval Count is set to 5, then treat is as automatic axis unit. Change-Id: Iab9209fb3950ef73e79229329606363b528d35fe Reviewed-on: https://gerrit.libreoffice.org/49327 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek diff --git a/oox/source/drawingml/chart/axisconverter.cxx b/oox/source/drawingml/chart/axisconverter.cxx index ffefc380fe48..727c0f599489 100644 --- a/oox/source/drawingml/chart/axisconverter.cxx +++ b/oox/source/drawingml/chart/axisconverter.cxx @@ -273,7 +273,7 @@ void AxisConverter::convertFromModel( case cssc2::AxisType::PERCENT: { // scaling algorithm -bool bLogScale = lclIsLogarithmicScale( mrModel ); +const bool bLogScale = lclIsLogarithmicScale( mrModel ); if( bLogScale ) aScaleData.Scaling = LogarithmicScaling::create( comphelper::getProcessComponentContext() ); else @@ -303,6 +303,11 @@ void AxisConverter::convertFromModel( if( (1.0 <= fCount) && (fCount < 1001.0) ) rIntervalCount <<= static_cast< sal_Int32 >( fCount ); } +else if( !mrModel.mofMinorUnit.has() ) +{ +// tdf#114168 If minor unit is not set then set interval to 5, as MS Excel do. +rIntervalCount <<= static_cast< sal_Int32 >( 5 ); +} } break; default: diff --git a/oox/source/export/chartexport.cxx b/oox/source/export/chartexport.cxx index 684a8983503d..8e1a05be1ae0 100644 --- a/oox/source/export/chartexport.cxx +++ b/oox/source/export/chartexport.cxx @@ -2829,9 +2829,20 @@ void ChartExport::_exportAxis( { double dMinorUnit = 0; mAny >>= dMinorUnit; -pFS->singleElement( FSNS( XML_c, XML_minorUnit ), -XML_val, IS( dMinorUnit ), -FSEND ); +if( GetProperty( xAxisProp, "StepHelpCount" ) ) +{ +sal_Int32 dMinorUnitCount = 0; +mAny >>= dMinorUnitCount; +// tdf#114168 Don't save minor unit if number of step help count is 5 (which is default for MS Excel), +// to allow proper .xlsx import. If minorUnit is set and majorUnit not, then it is impossible +// to calculate StepHelpCount. +if( dMinorUnitCount != 5 ) +{ +pFS->singleElement( FSNS( XML_c, XML_minorUnit ), +XML_val, IS( dMinorUnit ), +FSEND ); +} +} } if( nAxisType == XML_valAx && GetProperty( xAxisProp, "DisplayUnits" ) ) diff --git a/sc/source/filter/excel/xechart.cxx b/sc/source/filter/excel/xechart.cxx index 6edc1cb72e42..d9c19c679551 100644 --- a/sc/source/filter/excel/xechart.cxx +++ b/sc/source/filter/excel/xechart.cxx @@ -2747,14 +2747,19 @@ void XclExpChValueRange::Convert( const ScaleData& rScaleData ) // major increment const IncrementData& rIncrementData = rScaleData.IncrementData; -bool bAutoMajor = lclIsAutoAnyOrGetValue( maData.mfMajorStep, rIncrementData.Distance ) || (maData.mfMajorStep <= 0.0); +const bool bAutoMajor = lclIsAutoAnyOrGetValue( maData.mfMajorStep, rIncrementData.Distance ) || (maData.mfMajorStep <= 0.0); ::set_flag( maData.mnFlags, EXC_CHVALUERANGE_AUTOMAJOR, bAutoMajor ); // minor increment const Sequence< SubIncrement >& rSubIncrementSeq = rIncrementData.SubIncrements; sal_Int32 nCount = 0; -bool bAutoMinor = bLogScale || bAutoMajor || (rSubIncrementSeq.getLength() < 1) || -lclIsAutoAnyOrGetValue( nCount, rSubIncrementSeq[ 0 ].IntervalCount ) || (nCount < 1); -if( !bAutoMinor ) + +// tdf#114168 If IntervalCount is 5, then enable automatic minor calculation. +// During import, if minorUnit is set and majorUnit not, then it is impossible +// to calculate IntervalCount. +const bool bAutoMinor = bLogScale || bAutoMajor || (rSubIncrementSeq.getLength() <
[Libreoffice-commits] online.git: 5 commits - loleaflet/reference.html loleaflet/src wsd/ClientSession.cpp wsd/DocumentBroker.cpp wsd/DocumentBroker.hpp wsd/protocol.txt
loleaflet/reference.html | 66 +- loleaflet/src/control/Styles.js | 20 -- loleaflet/src/core/Socket.js | 12 ++ loleaflet/src/map/Map.js |2 - loleaflet/src/map/handler/Map.WOPI.js | 15 +++ wsd/ClientSession.cpp |8 wsd/DocumentBroker.cpp| 11 ++--- wsd/DocumentBroker.hpp|3 + wsd/protocol.txt | 18 + 9 files changed, 116 insertions(+), 39 deletions(-) New commits: commit 1fabfd9fe34815cab54c1417cfc7e541adb6a341 Author: Pranav Kant Date: Fri Feb 2 11:35:29 2018 +0530 Version restore states See documentation Change-Id: Ica3cd3744643157c5a2c6c1e42e0858ad641da16 diff --git a/loleaflet/reference.html b/loleaflet/reference.html index 7894f2a7..51516b44 100644 --- a/loleaflet/reference.html +++ b/loleaflet/reference.html @@ -33,7 +33,7 @@ API Reference - + Map Usage example @@ -2759,17 +2759,20 @@ Editor to WOPI host Status:DocumentLoadedTime: - - If Status is Frame_Ready, loleaflet frame is loaded and UI - can be shown. - When Status is Document_Loaded, document has been completely - loaded and host can also start sending document-specific query - messages using post message API such as Get_Views, - Get_Export_Formats etc. DocumentLoadedTime is specified - only in this case. + Features: + + If Status is Frame_Ready, loleaflet frame is loaded and UI + can be shown. + Accompanying keys: Features: This client's capabilities. + Supported values are: VersionStates. Tells the host that client supports different version states. See Version Restore for more details. + When Status is Document_Loaded, document has been completely + loaded and host can also start using PostMessage API. + Accompanying keys: + DocumentLoadedTime + WOPI host to editor @@ -2986,6 +2989,51 @@ Actions response +Version Restore +WOPI host to editor + + + MessageId + Values + Description + + + Host_VersionRestore + + Status: + + + Only possible value of Status (for now) is Pre_Restore. + This message is sent by the host before actually restoring the document + and after user showed the intent to restore the document. This is so such + that if there are any unsaved changes, Online can save them to storage before + document is restored. + + + +Editor to WOPI host + + + MessageId + Values + Description + + + App_VersionRestore + + Status: + + + This is the reply for the Host_VersionRestore message. Possible values for Status + (for now) is: Pre_Restore_Ack. It means that host can go ahead with restoring the + document to an earlier revision. + + + + +Note +These messages are only emitted if App_LoadingStatus contains VersionStates in Features. Otherwise, host can immediately restore the version to earlier revision. + Miscellaneous WOPI host to editor diff --git a/loleaflet/src/core/Socket.js b/loleaflet/src/core/Socket.js index 6a0cdf17..9cb99c23 100644 --- a/loleaflet/src/core/Socket.js +++ b/loleaflet/src/core/Socket.js @@ -258,6 +258,7 @@ L.Socket = L.Class.extend({ textMsg = textMsg.substring('close: '.length); msg = ''; var postMsgData = {}; + var showMsgAndReload = false; // This is due to document owner terminating the session if (textMsg === 'ownertermination') { msg = _('Session terminated by document owner'); @@ -311,7 +312,18 @@ L.Socket = L.Class.extend({ } else if (textMsg.startsWith('documentconflict')) { msg = _('Document has changed in storage. Loading the new document. Your version is available as revision.'); + showMsgAndReload = true; + } + else if (textMsg.startsWith('versionrestore:')) { + textMsg = textMsg.substring('versionrestore:'.length).trim(); + if (textMsg === 'prerestore_ack') { + msg = _('Restoring older revision. Any unsa
[Libreoffice-commits] core.git: sfx2/source
sfx2/source/dialog/itemconnect.cxx | 20 ++-- sfx2/source/dialog/tabdlg.cxx | 64 + sfx2/source/dialog/templdlg.cxx | 12 +- sfx2/source/dialog/versdlg.cxx |4 sfx2/source/doc/SfxDocumentMetaData.cxx | 28 ++ sfx2/source/doc/docfac.cxx |4 sfx2/source/doc/docinsert.cxx |4 sfx2/source/doc/oleprops.cxx| 26 ++--- sfx2/source/doc/templatedlg.cxx | 23 ++-- sfx2/source/sidebar/Deck.cxx|4 sfx2/source/sidebar/FocusManager.cxx| 36 +++ sfx2/source/sidebar/ResourceManager.cxx | 149 sfx2/source/sidebar/SidebarToolBox.cxx |6 - sfx2/source/sidebar/TabBar.cxx | 76 ++-- sfx2/source/sidebar/UnoDeck.cxx | 24 + sfx2/source/sidebar/UnoPanel.cxx| 37 ++- sfx2/source/uitest/sfx_uiobject.cxx | 20 +--- sfx2/source/view/viewsh.cxx |4 18 files changed, 232 insertions(+), 309 deletions(-) New commits: commit d761be572b6a49dff64db47bbdda309e7b984f95 Author: Julien Nabet Date: Wed Feb 7 21:47:10 2018 +0100 Use for-range loops in sfx2 (part2) Change-Id: Ie13b5836eff2e9b5dfec4bb95935de9560ab4be0 Reviewed-on: https://gerrit.libreoffice.org/49393 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/sfx2/source/dialog/itemconnect.cxx b/sfx2/source/dialog/itemconnect.cxx index 02627738bb7b..217fef3f09c5 100644 --- a/sfx2/source/dialog/itemconnect.cxx +++ b/sfx2/source/dialog/itemconnect.cxx @@ -155,22 +155,26 @@ void MultiControlWrapperHelper::RegisterControlWrapper( ControlWrapperBase& rWra void MultiControlWrapperHelper::ModifyControl( TriState eShow ) { -for( ControlWrpVec::iterator aIt = mxImpl->maVec.begin(), aEnd = mxImpl->maVec.end(); aIt != aEnd; ++aIt ) -(*aIt)->ModifyControl( eShow ); +for (auto const& elem : mxImpl->maVec) +elem->ModifyControl( eShow ); } bool MultiControlWrapperHelper::IsControlDontKnow() const { -bool bIs = !mxImpl->maVec.empty(); -for( ControlWrpVec::const_iterator aIt = mxImpl->maVec.begin(), aEnd = mxImpl->maVec.end(); bIs && (aIt != aEnd); ++aIt ) -bIs &= (*aIt)->IsControlDontKnow(); -return bIs; +if (mxImpl->maVec.empty()) +return false; +for (auto const& elem : mxImpl->maVec) +{ +if (!elem->IsControlDontKnow()) +return false; +} +return true; } void MultiControlWrapperHelper::SetControlDontKnow( bool bSet ) { -for( ControlWrpVec::iterator aIt = mxImpl->maVec.begin(), aEnd = mxImpl->maVec.end(); aIt != aEnd; ++aIt ) -(*aIt)->SetControlDontKnow( bSet ); +for (auto const& elem : mxImpl->maVec) +elem->SetControlDontKnow(bSet); } diff --git a/sfx2/source/dialog/tabdlg.cxx b/sfx2/source/dialog/tabdlg.cxx index 4eb7a29d1c49..22d03b7073af 100644 --- a/sfx2/source/dialog/tabdlg.cxx +++ b/sfx2/source/dialog/tabdlg.cxx @@ -342,34 +342,32 @@ void SfxTabDialog::dispose() { SavePosAndId(); -for ( SfxTabDlgData_Impl::const_iterator it = m_pImpl->aData.begin(); it != m_pImpl->aData.end(); ++it ) +for (auto & elem : m_pImpl->aData) { -Data_Impl* pDataObject = *it; - -if ( pDataObject->pTabPage ) +if ( elem->pTabPage ) { // save settings of all pages (user data) -pDataObject->pTabPage->FillUserData(); -OUString aPageData( pDataObject->pTabPage->GetUserData() ); +elem->pTabPage->FillUserData(); +OUString aPageData( elem->pTabPage->GetUserData() ); if ( !aPageData.isEmpty() ) { // save settings of all pages (user data) -OUString sConfigId = OStringToOUString(pDataObject->pTabPage->GetConfigId(), +OUString sConfigId = OStringToOUString(elem->pTabPage->GetConfigId(), RTL_TEXTENCODING_UTF8); if (sConfigId.isEmpty()) { SAL_WARN("sfx.dialog", "Tabpage needs to be converted to .ui format"); -sConfigId = OUString::number(pDataObject->nId); +sConfigId = OUString::number(elem->nId); } SvtViewOptions aPageOpt(EViewType::TabPage, sConfigId); aPageOpt.SetUserItem( USERITEM_NAME, makeAny( aPageData ) ); } -pDataObject->pTabPage.disposeAndClear(); +elem->pTabPage.disposeAndClear(); } -delete pDataObject; -pDataObject = nullptr; +delete elem; +elem = nullptr; } m_pImpl.reset(); @@ -785,10 +783,9 @@ short SfxTabDialog::Ok() } bool bModified = false; -for ( SfxTabDlgData_Impl::const_iterator it = m_pImpl->aData.begin(); it != m_pImpl->aData.end(); ++it ) +for (auto const& elem : m_pImpl->aData) { -Data_Impl* pDataObject =
[Libreoffice-commits] core.git: include/vcl vcl/source vcl/workben
include/vcl/bitmap.hxx |2 +- include/vcl/bitmapex.hxx |6 +- vcl/source/filter/igif/gifread.cxx |2 -- vcl/source/gdi/animate.cxx |2 -- vcl/workben/outdevgrind.cxx|5 + 5 files changed, 11 insertions(+), 6 deletions(-) New commits: commit 7daa249981e0d0b69f4f7564bfb6bc643f375039 Author: Noel Grandin Date: Wed Feb 7 14:48:53 2018 +0200 sprinkle SAL_WARN_UNUSED over Bitmap/BitmapEx Change-Id: If6fe5f05ecfc26c38890efde0f5e61edb7c3fbc5 Reviewed-on: https://gerrit.libreoffice.org/49359 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/include/vcl/bitmap.hxx b/include/vcl/bitmap.hxx index 2f74b71dd7b3..d4f290e35793 100644 --- a/include/vcl/bitmap.hxx +++ b/include/vcl/bitmap.hxx @@ -212,7 +212,7 @@ struct BitmapSystemData int mnHeight; }; -class VCL_DLLPUBLIC Bitmap +class SAL_WARN_UNUSED VCL_DLLPUBLIC Bitmap { public: diff --git a/include/vcl/bitmapex.hxx b/include/vcl/bitmapex.hxx index 1857e7608314..31b008a081b2 100644 --- a/include/vcl/bitmapex.hxx +++ b/include/vcl/bitmapex.hxx @@ -40,7 +40,7 @@ enum class TransparentType Bitmap }; -class VCL_DLLPUBLIC BitmapEx +class SAL_WARN_UNUSED VCL_DLLPUBLIC BitmapEx { public: @@ -371,6 +371,7 @@ public: @param bSmooth Defines if pixel interpolation is to be used to create the result */ +SAL_WARN_UNUSED_RESULT BitmapExTransformBitmapEx( double fWidth, double fHeight, @@ -398,6 +399,7 @@ public: @return The transformed bitmap */ +SAL_WARN_UNUSED_RESULT BitmapExgetTransformed( const basegfx::B2DHomMatrix& rTransformation, const basegfx::B2DRange& rVisibleRange, @@ -409,8 +411,10 @@ public: @param rBColorModifierStack A ColrModifierStack which defines how each pixel has to be modified */ +SAL_WARN_UNUSED_RESULT BitmapExModifyBitmapEx( const basegfx::BColorModifierStack& rBColorModifierStack) const; +SAL_WARN_UNUSED_RESULT static BitmapEx AutoScaleBitmap( BitmapEx const & aBitmap, const long aStandardSize ); /// populate from a canvas implementation diff --git a/vcl/source/filter/igif/gifread.cxx b/vcl/source/filter/igif/gifread.cxx index f24414f7e634..208e2f84c029 100644 --- a/vcl/source/filter/igif/gifread.cxx +++ b/vcl/source/filter/igif/gifread.cxx @@ -683,8 +683,6 @@ Graphic GIFReader::GetIntermediateGraphic() // but graphic still not completely read if ( bImGraphicReady && !aAnimation.Count() ) { -Bitmap aBmp; - pAcc8.reset(); if ( bGCTransparent ) diff --git a/vcl/source/gdi/animate.cxx b/vcl/source/gdi/animate.cxx index f226b9d699c5..7898fda187b4 100644 --- a/vcl/source/gdi/animate.cxx +++ b/vcl/source/gdi/animate.cxx @@ -688,7 +688,6 @@ SvStream& WriteAnimation( SvStream& rOStm, const Animation& rAnimation ) SvStream& ReadAnimation( SvStream& rIStm, Animation& rAnimation ) { -Bitmap aBmp; sal_uLong nStmPos; sal_uInt32 nAnimMagic1, nAnimMagic2; SvStreamEndian nOldFormat = rIStm.GetEndian(); @@ -722,7 +721,6 @@ SvStream& ReadAnimation( SvStream& rIStm, Animation& rAnimation ) if( bReadAnimations ) { AnimationBitmap aAnimBmp; -BitmapExaBmpEx; sal_uInt32 nTmp32; sal_uInt16 nTmp16; bool cTmp; diff --git a/vcl/workben/outdevgrind.cxx b/vcl/workben/outdevgrind.cxx index 79e025ad3b79..277a370486a8 100644 --- a/vcl/workben/outdevgrind.cxx +++ b/vcl/workben/outdevgrind.cxx @@ -133,10 +133,15 @@ void setupMethodStubs( functor_vector_type& res ) #endif const BitmapExaBitmapEx( aBitmap, aBitmapBW ); +(void)aBitmapEx; const BitmapExaBitmapExBW( aBitmapBW, aBitmapBW ); +(void)aBitmapExBW; const BitmapExaBitmapExAlien( aBitmapAlien, aBitmapBW ); +(void)aBitmapExAlien; const BitmapExaBitmapExAlpha( aBitmap, aBitmapAlien ); +(void)aBitmapExAlpha; const BitmapExaBitmapExAlphaAlien( aBitmapAlien, aBitmapAlien ); +(void)aBitmapExAlphaAlien; #ifdef NEEDS_QUALITY_PARAMETER const Image aImage( aBitmapEx ); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: postprocess/signing
postprocess/signing/no_signing.txt |2 ++ 1 file changed, 2 insertions(+) New commits: commit f19f8d1a3c175045fa43a8a5e2a12dd55fedb4b8 Author: Mike Kaganski Date: Wed Feb 7 20:27:46 2018 +0100 Don't re-sign vc_redist packages Change-Id: I62f55463c04f9bab1dd37f80fe6e15e0296d10bf Reviewed-on: https://gerrit.libreoffice.org/49388 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/postprocess/signing/no_signing.txt b/postprocess/signing/no_signing.txt index 53aaac652c2b..2fa129a80bab 100644 --- a/postprocess/signing/no_signing.txt +++ b/postprocess/signing/no_signing.txt @@ -8,3 +8,5 @@ policy.1.0.cli_oootypes.dll policy.1.0.cli_ure.dll policy.1.0.cli_cppuhelper.dll policy.1.0.cli_basetypes.dll +vc_redist.x64.exe +vc_redist.x86.exe ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: uui/source
uui/source/openlocked.cxx |8 1 file changed, 8 deletions(-) New commits: commit aa593b6dc0c72d2b7b67b8254b6ff4dfb80f1b16 Author: Mike Kaganski Date: Wed Feb 7 19:18:15 2018 +0100 Remove a workaround to bring certain dialog to front Since commits 8d1d82dd63eada8faa2f6eb43ef900764a5fda62 and 3b57cb72ec8b47f033be5a516617ed8c752517b0, it's no longer necessary to keep this hack from commit c385e76c10b173b9820967825f0ce0c6fb71e9dd. Change-Id: I8f38b4c61451d53890eab8ffe8af476c73826a1c Reviewed-on: https://gerrit.libreoffice.org/49386 Tested-by: Jenkins Reviewed-by: Mike Kaganski diff --git a/uui/source/openlocked.cxx b/uui/source/openlocked.cxx index 156e28b6a368..074242b964b8 100644 --- a/uui/source/openlocked.cxx +++ b/uui/source/openlocked.cxx @@ -37,14 +37,6 @@ OpenLockedQueryBox::OpenLockedQueryBox( vcl::Window* pParent, const std::locale& SetButtonHelpText( RET_YES, OUString() ); SetButtonHelpText( RET_NO, OUString() ); -#ifdef _WIN32 -// bnc#656566 -// Yes, it is silly to do this only for this dialog but not the -// other similar ones. But hey, it was about this dialog that the -// customer complained. You who read this and feel the itch, feel -// free to fix the problem in a better way. -EnableAlwaysOnTop(); -#endif } OpenLockedQueryBox::~OpenLockedQueryBox() ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: starmath/inc starmath/source
starmath/inc/parse.hxx| 10 +- starmath/source/parse.cxx | 42 ++ 2 files changed, 31 insertions(+), 21 deletions(-) New commits: commit 609888f3c8d6c0fe72c41ac26de431a12ad3fdd0 Author: Takeshi Abe Date: Wed Feb 7 17:10:44 2018 +0900 starmath: Make SmParser::DoAttribut() etc. return std::unique_ptr Change-Id: I9693cf15abf202657f5be478bfebd1272dc261dd Reviewed-on: https://gerrit.libreoffice.org/49339 Tested-by: Jenkins Reviewed-by: Takeshi Abe diff --git a/starmath/inc/parse.hxx b/starmath/inc/parse.hxx index ef51bcc61bdc..6b8e7d8cd85b 100644 --- a/starmath/inc/parse.hxx +++ b/starmath/inc/parse.hxx @@ -94,11 +94,11 @@ class SmParser std::unique_ptr DoOper(); SmStructureNode *DoUnOper(); std::unique_ptr DoAlign(bool bUseExtraSpaces = true); -SmStructureNode *DoFontAttribut(); -SmAttributNode *DoAttribut(); -SmStructureNode *DoFont(); -SmStructureNode *DoFontSize(); -SmStructureNode *DoColor(); +std::unique_ptr DoFontAttribut(); +std::unique_ptr DoAttribut(); +std::unique_ptr DoFont(); +std::unique_ptr DoFontSize(); +std::unique_ptr DoColor(); SmStructureNode *DoBrace(); SmBracebodyNode *DoBracebody(bool bIsLeftRight); SmTextNode *DoFunction(); diff --git a/starmath/source/parse.cxx b/starmath/source/parse.cxx index a7c1a8a0d6d2..6c5414e25d50 100644 --- a/starmath/source/parse.cxx +++ b/starmath/source/parse.cxx @@ -1500,7 +1500,7 @@ SmNode *SmParser::DoTerm(bool bGroupNumberIdent) boolbIsAttr; while ( (bIsAttr = TokenInGroup(TG::Attribute)) || TokenInGroup(TG::FontAttr)) -aStack.push(std::unique_ptr(bIsAttr ? DoAttribut() : DoFontAttribut())); +aStack.push(bIsAttr ? DoAttribut() : DoFontAttribut()); auto xFirstNode = DoPower(); while (!aStack.empty()) @@ -1730,7 +1730,7 @@ SmStructureNode *SmParser::DoUnOper() return xSNode.release(); } -SmAttributNode *SmParser::DoAttribut() +std::unique_ptr SmParser::DoAttribut() { DepthProtect aDepthGuard(m_nParseDepth); if (aDepthGuard.TooDeep()) @@ -1766,10 +1766,10 @@ SmAttributNode *SmParser::DoAttribut() xSNode->SetSubNodes(xAttr.release(), nullptr); // the body will be filled later xSNode->SetScaleMode(eScaleMode); -return xSNode.release(); +return std::move(xSNode); // this explicit move can be omitted since C++14 } -SmStructureNode *SmParser::DoFontAttribut() +std::unique_ptr SmParser::DoFontAttribut() { DepthProtect aDepthGuard(m_nParseDepth); if (aDepthGuard.TooDeep()) @@ -1787,7 +1787,7 @@ SmStructureNode *SmParser::DoFontAttribut() { auto pNode = o3tl::make_unique(m_aCurToken); NextToken(); -return pNode.release(); +return std::move(pNode); // this explicit move can be omitted since C++14 } case TSIZE : @@ -1801,11 +1801,11 @@ SmStructureNode *SmParser::DoFontAttribut() default : assert(false); -return nullptr; +return {}; } } -SmStructureNode *SmParser::DoColor() +std::unique_ptr SmParser::DoColor() { DepthProtect aDepthGuard(m_nParseDepth); if (aDepthGuard.TooDeep()) @@ -1813,6 +1813,7 @@ SmStructureNode *SmParser::DoColor() assert(m_aCurToken.eType == TCOLOR); +std::unique_ptr xNode; // last color rules, get that one SmToken aToken; do @@ -1823,13 +1824,17 @@ SmStructureNode *SmParser::DoColor() NextToken(); } else -return DoError(SmParseError::ColorExpected); +{ +xNode.reset(DoError(SmParseError::ColorExpected)); +return xNode; +} } while (m_aCurToken.eType == TCOLOR); -return new SmFontNode(aToken); +xNode.reset(new SmFontNode(aToken)); +return xNode; } -SmStructureNode *SmParser::DoFont() +std::unique_ptr SmParser::DoFont() { DepthProtect aDepthGuard(m_nParseDepth); if (aDepthGuard.TooDeep()) @@ -1837,6 +1842,7 @@ SmStructureNode *SmParser::DoFont() assert(m_aCurToken.eType == TFONT); +std::unique_ptr xNode; // last font rules, get that one SmToken aToken; do @@ -1847,10 +1853,14 @@ SmStructureNode *SmParser::DoFont() NextToken(); } else -return DoError(SmParseError::FontExpected); +{ +xNode.reset(DoError(SmParseError::FontExpected)); +return xNode; +} } while (m_aCurToken.eType == TFONT); -return new SmFontNode(aToken); +xNode.reset(new SmFontNode(aToken)); +return xNode; } @@ -1876,7 +1886,7 @@ static bool lcl_IsNumber(const OUString& rText) return true; } -SmStructureNode *SmParser::DoFontSize() +std::unique_ptr SmParser::DoFontSize() { DepthProt
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.1' - configure.ac
configure.ac |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 10050210dda6672f95539c86c0ff643ab1c069e2 Author: Andras Timar Date: Thu Feb 8 01:00:02 2018 +0100 Bump version to 5.1-26 Change-Id: Ic1421c1c7d9f39618bd890e510c6359ffc42d356 diff --git a/configure.ac b/configure.ac index 6b003c4fc545..93eef1348603 100644 --- a/configure.ac +++ b/configure.ac @@ -9,7 +9,7 @@ dnl in order to create a configure script. # several non-alphanumeric characters, those are split off and used only for the # ABOUTBOXPRODUCTVERSIONSUFFIX in openoffice.lst. Why that is necessary, no idea. -AC_INIT([Collabora Office],[5.1.10.25],[],[],[https://collaboraoffice.com/]) +AC_INIT([Collabora Office],[5.1.10.26],[],[],[https://collaboraoffice.com/]) AC_PREREQ([2.59]) ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Changes to 'refs/tags/cp-5.1-26'
Tag 'cp-5.1-26' created by Andras Timar at 2018-02-08 00:01 + cp-5.1-26 Changes since cp-5.1-25-56: --- 0 files changed --- ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.1' - 3 commits - sc/inc sc/Library_sc.mk sc/source
sc/Library_sc.mk |1 sc/inc/document.hxx |6 - sc/inc/documentlinkmgr.hxx|6 - sc/source/core/data/documen2.cxx |2 sc/source/core/data/formulacell.cxx |8 +- sc/source/core/inc/webservicelink.hxx | 49 + sc/source/core/tool/interpr2.cxx |8 +- sc/source/core/tool/interpr7.cxx | 105 ++--- sc/source/core/tool/webservicelink.cxx| 106 ++ sc/source/ui/docshell/docsh4.cxx |4 - sc/source/ui/docshell/documentlinkmgr.cxx | 20 - sc/source/ui/view/tabvwsh4.cxx|2 12 files changed, 272 insertions(+), 45 deletions(-) New commits: commit a0e4112792fe83ad3c399a8ca52bdccf60d62060 Author: Caolán McNamara Date: Thu Jan 11 20:43:28 2018 + handle ocWebservice similarly to ocDde might have too much in here seeing as we don't need to worry about ocWebservice calling into itself Reviewed-on: https://gerrit.libreoffice.org/47819 Tested-by: Jenkins Reviewed-by: Eike Rathke (cherry picked from commit e1946d75a1095c2596d7815600454ff01fcd3270) Signed-off-by: Andras Timar (cherry picked from commit 78c1ae24007d8098ee4f4add6d72e84411181785) (cherry picked from commit a09ca6b29b16f29e21ea65658c112eaf1cf7d819) Change-Id: I0145f38cc1c1f9ff514a496f7101d81cde9e7c67 diff --git a/sc/Library_sc.mk b/sc/Library_sc.mk index 60ff9845bd6c..a22b4850665a 100644 --- a/sc/Library_sc.mk +++ b/sc/Library_sc.mk @@ -283,6 +283,7 @@ $(eval $(call gb_Library_add_exception_objects,sc,\ sc/source/core/tool/unitconv \ sc/source/core/tool/userlist \ sc/source/core/tool/viewopti \ +sc/source/core/tool/webservicelink \ sc/source/core/tool/zforauto \ sc/source/filter/xml/datastreamimport \ sc/source/filter/xml/XMLCalculationSettingsContext \ diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx index 8f55a068a4e4..450a3d581395 100644 --- a/sc/inc/document.hxx +++ b/sc/inc/document.hxx @@ -440,7 +440,7 @@ private: // for detective update, is set for each change of a formula boolbDetectiveDirty; -boolbLinkFormulaNeedingCheck; // valid only after loading, for ocDde +boolbLinkFormulaNeedingCheck; // valid only after loading, for ocDde and ocWebservice sal_uInt8 nAsianCompression; sal_uInt8 nAsianKerning; diff --git a/sc/inc/documentlinkmgr.hxx b/sc/inc/documentlinkmgr.hxx index a50175fb25cc..498fd43b6c83 100644 --- a/sc/inc/documentlinkmgr.hxx +++ b/sc/inc/documentlinkmgr.hxx @@ -54,9 +54,9 @@ public: bool idleCheckLinks(); bool hasDdeLinks() const; -bool hasDdeOrOleLinks() const; +bool hasDdeOrOleOrWebServiceLinks() const; -bool updateDdeOrOleLinks(vcl::Window* pWin); +bool updateDdeOrOleOrWebServiceLinks(vcl::Window* pWin); bool updateDdeLink( const OUString& rAppl, const OUString& rTopic, const OUString& rItem ); @@ -64,7 +64,7 @@ public: void disconnectDdeLinks(); private: -bool hasDdeOrOleLinks(bool bDde, bool bOle) const; +bool hasDdeOrOleOrWebServiceLinks(bool bDde, bool bOle, bool bWebService) const; }; } diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx index 3e332b7fba90..5458cb5335b4 100644 --- a/sc/source/core/data/formulacell.cxx +++ b/sc/source/core/data/formulacell.cxx @@ -1412,9 +1412,9 @@ void ScFormulaCell::CompileXML( sc::CompileFormulaContext& rCxt, ScProgress& rPr bChanged = true; } -// After loading, it must be known if ocDde is in any formula +// After loading, it must be known if ocDde/ocWebservice is in any formula // (for external links warning, CompileXML is called at the end of loading XML file) -if (!pDocument->HasLinkFormulaNeedingCheck() && pCode->HasOpCodeRPN(ocDde)) +if (!pDocument->HasLinkFormulaNeedingCheck() && (pCode->HasOpCodeRPN(ocDde) || pCode->HasOpCodeRPN(ocWebservice))) pDocument->SetLinkFormulaNeedingCheck(true); //volatile cells must be added here for import diff --git a/sc/source/core/inc/webservicelink.hxx b/sc/source/core/inc/webservicelink.hxx new file mode 100644 index ..e61ebfdb4347 --- /dev/null +++ b/sc/source/core/inc/webservicelink.hxx @@ -0,0 +1,49 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#ifndef INCLUDED_SC_SOURCE_CORE_INC_WEBSERVICE_HXX +#define INCLUDED_SC_SOURCE_CORE_INC_WEBSERVICE_HXX + +#include +#include +#include +#include + +class ScDocument; +
[Libreoffice-commits] core.git: sc/source
sc/source/core/tool/compiler.cxx |9 + 1 file changed, 9 insertions(+) New commits: commit 30083601334279f33a3021dfe7d22970d02c8e9e Author: Eike Rathke Date: Wed Feb 7 22:21:51 2018 +0100 tdf#115493 postpone name resolution after unsuccessful IsNamedRange() ... for names used in named expressions when compiling during import and collecting named expressions, to not match an arbitrary other name. Change-Id: I02a92747a1485b46873281de98879a89385d4622 diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx index b029b560e5d5..68e814e23c44 100644 --- a/sc/source/core/tool/compiler.cxx +++ b/sc/source/core/tool/compiler.cxx @@ -4275,6 +4275,15 @@ bool ScCompiler::NextNewToken( bool bInArray ) if (IsNamedRange( aUpper )) return true; + +// Compiling a named expression during collecting them in import shall +// not match arbitrary names that otherwise if all named expressions +// were present would be recognized as named expression. Such name will +// flag an error below and will be recompiled in a second step later +// with ScRangeData::CompileUnresolvedXML() +if (meExtendedErrorDetection == EXTENDED_ERROR_DETECTION_NAME_NO_BREAK && pDoc->IsImportingXML()) +break; // while + // Preserve case of file names in external references. bool bInvalidExternalNameRange; if (IsExternalNamedRange( aOrg, bInvalidExternalNameRange )) ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: sc/source
sc/source/ui/app/transobj.cxx | 22 -- 1 file changed, 16 insertions(+), 6 deletions(-) New commits: commit 1fcf76b8f33ddca3f00256e3c41104314988a9f4 Author: Henry Castro Date: Tue Feb 6 17:16:03 2018 -0400 tdf#115020: Cutting a large dataset is very slow since 6.1.0.0.alpha0+ Change-Id: Icc26224055c00bd826019bd728c3f74d2ebba535 Reviewed-on: https://gerrit.libreoffice.org/49320 Tested-by: Jenkins Reviewed-by: Henry Castro diff --git a/sc/source/ui/app/transobj.cxx b/sc/source/ui/app/transobj.cxx index c1d4f00b6a4d..9089f7875812 100644 --- a/sc/source/ui/app/transobj.cxx +++ b/sc/source/ui/app/transobj.cxx @@ -23,6 +23,7 @@ #include #include +#include #include #include @@ -201,13 +202,22 @@ ScTransferObj::~ScTransferObj() ScTransferObj* ScTransferObj::GetOwnClipboard( vcl::Window* pUIWin ) { ScTransferObj* pObj = nullptr; -TransferableDataHelper aDataHelper( TransferableDataHelper::CreateFromSystemClipboard( pUIWin ) ); -uno::Reference xTunnel( aDataHelper.GetTransferable(), uno::UNO_QUERY ); -if ( xTunnel.is() ) +uno::Reference xTransferable; +uno::Reference xClipboard; + +if( pUIWin ) +xClipboard = pUIWin->GetClipboard(); + +if( xClipboard.is() ) { -sal_Int64 nHandle = xTunnel->getSomething( getUnoTunnelId() ); -if ( nHandle ) -pObj = dynamic_cast(reinterpret_cast( static_cast(nHandle) )); +xTransferable = xClipboard->getContents(); +uno::Reference xTunnel( xTransferable, uno::UNO_QUERY ); +if ( xTunnel.is() ) +{ +sal_Int64 nHandle = xTunnel->getSomething( getUnoTunnelId() ); +if ( nHandle ) +pObj = dynamic_cast(reinterpret_cast( static_cast(nHandle) )); +} } return pObj; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: lotuswordpro/source
lotuswordpro/source/filter/lwptablelayout.cxx |5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) New commits: commit 5dfe9e93fa4ea8e41dfedf1e8f168c54d28ae2d9 Author: Caolán McNamara Date: Wed Feb 7 15:40:53 2018 + ofz#6092 Null-dereference Change-Id: Ic9a31b4819c07e82f6b90c4db1903ec5e27044be Reviewed-on: https://gerrit.libreoffice.org/49364 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/lotuswordpro/source/filter/lwptablelayout.cxx b/lotuswordpro/source/filter/lwptablelayout.cxx index 924da8b7ab08..f8793328cd9b 100644 --- a/lotuswordpro/source/filter/lwptablelayout.cxx +++ b/lotuswordpro/source/filter/lwptablelayout.cxx @@ -330,9 +330,8 @@ void LwpSuperTableLayout::ApplyWatermark(XFTableStyle *pTableStyle) void LwpSuperTableLayout::ApplyAlignment(XFTableStyle * pTableStyle) { LwpPoint aPoint; -if (GetGeometry()) -aPoint = GetGeometry()->GetOrigin(); -//LwpPoint aPoint = GetOrigin(); +if (LwpLayoutGeometry* pGeometry = GetGeometry()) +aPoint = pGeometry->GetOrigin(); double dXOffset = LwpTools::ConvertFromUnitsToMetric(aPoint.GetX()); // add left padding to alignment distance ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: lotuswordpro/source
lotuswordpro/source/filter/lwptablelayout.cxx |3 +++ 1 file changed, 3 insertions(+) New commits: commit d9bb43a31df7d92118713a7f7d09879285a991ac Author: Caolán McNamara Date: Wed Feb 7 13:03:32 2018 + ofz#6088 Null-dereference Change-Id: I5854e27b4322f4e9b3dd8c976d619e98cc0ee3cc Reviewed-on: https://gerrit.libreoffice.org/49351 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/lotuswordpro/source/filter/lwptablelayout.cxx b/lotuswordpro/source/filter/lwptablelayout.cxx index 0a3078cf697a..924da8b7ab08 100644 --- a/lotuswordpro/source/filter/lwptablelayout.cxx +++ b/lotuswordpro/source/filter/lwptablelayout.cxx @@ -547,6 +547,9 @@ void LwpTableLayout::RegisterColumns() m_aColumns[i] = nullptr; } +if (!pTable) +throw std::range_error("corrupt LwpTableLayout"); + double dDefaultColumn = pTable->GetWidth(); sal_uInt16 nJustifiableColumn = nCols; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
Minutes from the design meeting 2018-Feb-07
Present: Thomas, Jay, Stuart, Heiko Organization * Design session on font handling + f'up to FOSDEM https://de.slideshare.net/HeikoTietze/improvements-to-font-handling-in-libreoffice + fine, good as 2nd * Design session on shortcut customization + tdf#115052 & co + a waste of time (jay, stuart) + UI part was part of last year's customization dialog that Muhammet didnt have time to work on (jay) https://bugs.documentfoundation.org/show_bug.cgi?id=115527 + also good, lets do it 1st + tentative Friday 8pm GMT+1, ask on the ML GSoC * GSoC project "100 paper cuts" + top 10 of UX nitpicks to fix in a gsoc project + http://nabble.documentfoundation.org/Re-Minutes-of-the-design-meeting-2018-Jan-31-td4232034.html + tdf#53300 (Pedro) + good idea, could be a bit more difficult than easyhack but not a full project (samuel on IRC) + we could ask on ML for everyone's top 10 issues and vote for it + perhaps restrict to a certain module (Jay) + go ahead? no objection Last week(')s todo's * Standard palette rework + https://bugs.documentfoundation.org/show_bug.cgi?id=114719 => take this palette and submit AI Stuart + https://gerrit.libreoffice.org/#/c/48887/ + objection? (1 yes vs. 3 no) => submit * Paragraph selection with or without breaks + https://bugs.documentfoundation.org/show_bug.cgi?id=68271 + comparison done (Jay), workflow test pending (Stuart) + don't change (cor, stuart, thomas) + consistency with other programs is a plus (jay) => WONTFIX * New bitmaps for the Gallery + https://bugs.documentfoundation.org/show_bug.cgi?id=114817 + ideally we get the new and old bitmaps into some kind of voting + https://docs.google.com/spreadsheets/d/1O0-09bhr0dHQ3VQTED2wFM9WBgEY5v-4VM7iMSS4BVY + 10 replies so far, let's see if more people vote => 16 replies, patch should get prepared -> Andreas? Tickets * Bypassing import dialogs + https://bugs.documentfoundation.org/show_bug.cgi?id=74580 + load a CSV in Calc shows always the import dialog + not too special workflow to read many documents + asked some people, most are against the idea as command line and macro exists + special uno:command are an option + checkbox in open dialog to bypass import dialog (jay) + use or to bypass dialog when it is intended to appear (jay) in the file dialog when pressing open button, clicked the file in start center, or drag and drop + should be a generic idea meaning pressing shift on open, or whatever, works also when implemented in for instance the export to png dialog (heiko) + rather improve the import dialog with use of parser settings saved to profile (stuart) + introduce some kind of heuristics that detects the format and only asks if unsure (csongor) + simplest heuristic would be the URL and after first time reading file from this place the dialog doesnt pops-up again (jay) perhaps plus a filename comparison (./file1.csv=./file2.csv) => comment ticket with ideas and remove keyword * Template changer (continued from previous meetings) + ... + suggest to make the tc working as loading a template with the exception to not override what the user modified (Heiko) + document themes are worth to consider as alternative solution (stuart) => double-check MSO (Thomas) signature.asc Description: OpenPGP digital signature ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] core.git: sd/qa sd/source
sd/qa/unit/data/ppt/tdf115394.ppt |binary sd/qa/unit/export-tests.cxx | 39 ++ sd/qa/unit/import-tests.cxx | 25 sd/source/filter/eppt/eppt.cxx| 24 +-- sd/source/filter/ppt/pptin.cxx|6 ++--- 5 files changed, 89 insertions(+), 5 deletions(-) New commits: commit ba9a42009a6e712aea8646956bd711afb058db24 Author: Szymon Kłos Date: Wed Feb 7 12:22:52 2018 +0100 tdf#115394 export correct slide transition time in PPT Change-Id: Ie293dd4cc128c256e39d54fdcd83bb5e13484662 Reviewed-on: https://gerrit.libreoffice.org/49345 Tested-by: Jenkins Reviewed-by: Szymon Kłos diff --git a/sd/qa/unit/data/ppt/tdf115394.ppt b/sd/qa/unit/data/ppt/tdf115394.ppt new file mode 100644 index ..1fd299a5e4be Binary files /dev/null and b/sd/qa/unit/data/ppt/tdf115394.ppt differ diff --git a/sd/qa/unit/export-tests.cxx b/sd/qa/unit/export-tests.cxx index b27c55b55ba8..73d8bb5c49c6 100644 --- a/sd/qa/unit/export-tests.cxx +++ b/sd/qa/unit/export-tests.cxx @@ -93,6 +93,7 @@ public: void testTdf100926(); void testPageWithTransparentBackground(); void testTextRotation(); +void testTdf115394PPT(); CPPUNIT_TEST_SUITE(SdExportTest); @@ -113,6 +114,7 @@ public: CPPUNIT_TEST(testTdf100926); CPPUNIT_TEST(testPageWithTransparentBackground); CPPUNIT_TEST(testTextRotation); +CPPUNIT_TEST(testTdf115394PPT); CPPUNIT_TEST_SUITE_END(); @@ -843,6 +845,43 @@ void SdExportTest::testTextRotation() xDocShRef->DoClose(); } +void SdExportTest::testTdf115394PPT() +{ +sd::DrawDocShellRef xDocShRef = loadURL(m_directories.getURLFromSrc("sd/qa/unit/data/ppt/tdf115394.ppt"), PPT); + +// Export the document and import again for a check +uno::Reference< lang::XComponent > xComponent(xDocShRef->GetModel(), uno::UNO_QUERY); +uno::Reference xStorable(xComponent, uno::UNO_QUERY); +utl::MediaDescriptor aMediaDescriptor; +aMediaDescriptor["FilterName"] <<= OStringToOUString(OString(aFileFormats[PPT].pFilterName), RTL_TEXTENCODING_UTF8); + +utl::TempFile aTempFile; +aTempFile.EnableKillingFile(); +xStorable->storeToURL(aTempFile.GetURL(), aMediaDescriptor.getAsConstPropertyValueList()); +xComponent.set(xStorable, uno::UNO_QUERY); +xComponent->dispose(); +xDocShRef = loadURL(aTempFile.GetURL(), PPT); + +double fTransitionDuration; + +// Fast +SdPage* pPage1 = xDocShRef->GetDoc()->GetSdPage(0, PageKind::Standard); +fTransitionDuration = pPage1->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(0.5, fTransitionDuration); + +// Medium +SdPage* pPage2 = xDocShRef->GetDoc()->GetSdPage(1, PageKind::Standard); +fTransitionDuration = pPage2->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(0.75, fTransitionDuration); + +// Slow +SdPage* pPage3 = xDocShRef->GetDoc()->GetSdPage(2, PageKind::Standard); +fTransitionDuration = pPage3->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(1.0, fTransitionDuration); + +xDocShRef->DoClose(); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SdExportTest); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx index 652b6ace8626..101131de259b 100644 --- a/sd/qa/unit/import-tests.cxx +++ b/sd/qa/unit/import-tests.cxx @@ -175,6 +175,7 @@ public: void testTdf114913(); void testTdf114821(); void testTdf115394(); +void testTdf115394PPT(); bool checkPattern(sd::DrawDocShellRef const & rDocRef, int nShapeNumber, std::vector& rExpected); void testPatternImport(); @@ -253,6 +254,7 @@ public: CPPUNIT_TEST(testTdf114913); CPPUNIT_TEST(testTdf114821); CPPUNIT_TEST(testTdf115394); +CPPUNIT_TEST(testTdf115394PPT); CPPUNIT_TEST_SUITE_END(); }; @@ -2414,6 +2416,29 @@ void SdImportTest::testTdf115394() xDocShRef->DoClose(); } +void SdImportTest::testTdf115394PPT() +{ +sd::DrawDocShellRef xDocShRef = loadURL(m_directories.getURLFromSrc("/sd/qa/unit/data/ppt/tdf115394.ppt"), PPT); +double fTransitionDuration; + +// Fast +SdPage* pPage1 = xDocShRef->GetDoc()->GetSdPage(0, PageKind::Standard); +fTransitionDuration = pPage1->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(0.5, fTransitionDuration); + +// Medium +SdPage* pPage2 = xDocShRef->GetDoc()->GetSdPage(1, PageKind::Standard); +fTransitionDuration = pPage2->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(0.75, fTransitionDuration); + +// Slow +SdPage* pPage3 = xDocShRef->GetDoc()->GetSdPage(2, PageKind::Standard); +fTransitionDuration = pPage3->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(1.0, fTransitionDuration); + +xDocShRef->DoClose(); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SdImportTest); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/sd/source/filter/eppt/eppt.cxx b/sd/source/filter/eppt/eppt.cxx index 81938bc66ecf..217bb4221317 10064
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - sw/qa writerfilter/source
sw/qa/extras/ooxmlimport/data/tdf114217.docx |binary sw/qa/extras/ooxmlimport/ooxmlimport.cxx |8 writerfilter/source/dmapper/DomainMapperTableHandler.cxx |4 +++- writerfilter/source/dmapper/DomainMapper_Impl.hxx|6 -- writerfilter/source/dmapper/PropertyMap.cxx |5 + 5 files changed, 20 insertions(+), 3 deletions(-) New commits: commit a34f87f8f97aa6aafd4098cffd214e8d2c3a0ba3 Author: Mike Kaganski Date: Wed Feb 7 01:03:32 2018 +0300 tdf#114217: Consider relative width when importing floating table Unit test included Change-Id: I8e3338d7df431bd016caa4e06e684fbd189127c4 Reviewed-on: https://gerrit.libreoffice.org/49324 Tested-by: Jenkins Reviewed-by: Mike Kaganski (cherry picked from commit 76d6fcd05c630a928dd3bd028d560792d9c904ca) Reviewed-on: https://gerrit.libreoffice.org/49333 Reviewed-by: Christian Lohmaier diff --git a/sw/qa/extras/ooxmlimport/data/tdf114217.docx b/sw/qa/extras/ooxmlimport/data/tdf114217.docx new file mode 100644 index ..49f1ce164cbe Binary files /dev/null and b/sw/qa/extras/ooxmlimport/data/tdf114217.docx differ diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx index 449dae04ac59..61ef9aeaeb63 100644 --- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx +++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx @@ -1574,6 +1574,14 @@ DECLARE_OOXMLIMPORT_TEST(testTdf113946, "tdf113946.docx") CPPUNIT_ASSERT_EQUAL( OUString("1696"), aTop ); } +DECLARE_OOXMLIMPORT_TEST(testTdf114217, "tdf114217.docx") +{ +uno::Reference xDrawPageSupplier(mxComponent, uno::UNO_QUERY); +uno::Reference xDrawPage = xDrawPageSupplier->getDrawPage(); +// This was 1, multi-page table was imported as a floating one. +CPPUNIT_ASSERT_EQUAL(static_cast(0), xDrawPage->getCount()); +} + // tests should only be added to ooxmlIMPORT *if* they fail round-tripping in ooxmlEXPORT CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx index a6e6947d9491..2f254be9c67c 100644 --- a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx +++ b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx @@ -1151,8 +1151,10 @@ void DomainMapperTableHandler::endTable(unsigned int nestedTableLevel, bool bTab // table is not in the body text. sal_Int32 nTableWidth = 0; m_aTableProperties->getValue(TablePropertyMap::TABLE_WIDTH, nTableWidth); +sal_Int32 nTableWidthType = text::SizeType::FIX; +m_aTableProperties->getValue(TablePropertyMap::TABLE_WIDTH_TYPE, nTableWidthType); if (m_rDMapper_Impl.GetSectionContext() && nestedTableLevel <= 1 && !m_rDMapper_Impl.IsInHeaderFooter()) -m_rDMapper_Impl.m_aPendingFloatingTables.emplace_back(xStart, xEnd, comphelper::containerToSequence(aFrameProperties), nTableWidth); +m_rDMapper_Impl.m_aPendingFloatingTables.emplace_back(xStart, xEnd, comphelper::containerToSequence(aFrameProperties), nTableWidth, nTableWidthType); else { // m_xText points to the body text, get the current xText from m_rDMapper_Impl, in case e.g. we would be in a header. diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.hxx b/writerfilter/source/dmapper/DomainMapper_Impl.hxx index 589a79953f13..cf51e7fac46c 100644 --- a/writerfilter/source/dmapper/DomainMapper_Impl.hxx +++ b/writerfilter/source/dmapper/DomainMapper_Impl.hxx @@ -356,17 +356,19 @@ struct FloatingTableInfo css::uno::Reference m_xEnd; css::uno::Sequence m_aFrameProperties; sal_Int32 m_nTableWidth; +sal_Int32 m_nTableWidthType; /// Break type of the section that contains this table. sal_Int32 m_nBreakType = -1; FloatingTableInfo(css::uno::Reference const& xStart, css::uno::Reference const& xEnd, const css::uno::Sequence& aFrameProperties, -sal_Int32 nTableWidth) +sal_Int32 nTableWidth, sal_Int32 nTableWidthType) : m_xStart(xStart), m_xEnd(xEnd), m_aFrameProperties(aFrameProperties), -m_nTableWidth(nTableWidth) +m_nTableWidth(nTableWidth), +m_nTableWidthType(nTableWidthType) { } css::uno::Any getPropertyValue(const OUString &propertyName); diff --git a/writerfilter/source/dmapper/PropertyMap.cxx b/writerfilter/source/dmapper/PropertyMap.cxx index c416ba52ba69..b1ee1fd971a3 100644 --- a/writerfilter/source/dmapper/PropertyMap.cxx +++ b/writerfilter/source/dmapper/PropertyMap.cxx @@ -37,6 +37,7 @@ #include #include #include +#include #include #include #include @@ -1030,6 +1031,10 @@ bool SectionPropertyMap::FloatingTableConversion( DomainMapper_Impl& rDM_Impl, F sal_Int32 nTextAreaWidth = nPageWidth - GetLeftMargin() - Ge
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - embeddedobj/source
embeddedobj/source/general/docholder.cxx |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit 19bfffcf3a89fd2fd070e1a878ac628e93d06cc7 Author: Szymon Kłos Date: Sun Jan 28 18:18:32 2018 +0100 tdf#114677 Correct title in Base forms Change-Id: I07bdb46cce88e876583e1d4217dff3f77f2f3814 Reviewed-on: https://gerrit.libreoffice.org/48801 Tested-by: Jenkins Reviewed-by: Szymon Kłos (cherry picked from commit 5426a14e39660bde0dece27cf5ec26b9938bd962) Reviewed-on: https://gerrit.libreoffice.org/48810 Reviewed-by: Julien Nabet Reviewed-by: Christian Lohmaier diff --git a/embeddedobj/source/general/docholder.cxx b/embeddedobj/source/general/docholder.cxx index 18fbd91641c8..798b4c3c59f5 100644 --- a/embeddedobj/source/general/docholder.cxx +++ b/embeddedobj/source/general/docholder.cxx @@ -969,11 +969,11 @@ bool DocumentHolder::LoadDocToFrame( bool bInPlace ) // set document title to show in the title bar css::uno::Reference< css::frame::XTitle > xModelTitle( xDoc, css::uno::UNO_QUERY ); -if( xModelTitle.is() ) +if( xModelTitle.is() && m_pEmbedObj && !m_pEmbedObj->getContainerName().isEmpty() ) { std::locale aResLoc = Translate::Create("sfx"); OUString sEmbedded = Translate::get(STR_EMBEDDED_TITLE, aResLoc); -xModelTitle->setTitle( m_pEmbedObj->getContainerName() + sEmbedded); +xModelTitle->setTitle( m_pEmbedObj->getContainerName() + sEmbedded ); m_aContainerName = m_pEmbedObj->getContainerName(); // TODO: get real m_aDocumentNamePart m_aDocumentNamePart = sEmbedded; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: include/svl sc/CppunitTest_sc_subsequent_export_test.mk sc/inc sc/qa sc/source svl/source sw/CppunitTest_sw_odfexport.mk sw/qa xmloff/source
include/svl/PasswordHelper.hxx |7 + sc/CppunitTest_sc_subsequent_export_test.mk |2 sc/inc/tabprotection.hxx|2 sc/qa/unit/data/fods/protection-key1.fods | 20 sc/qa/unit/data/fods/protection-key2.fods | 20 sc/qa/unit/data/fods/protection-key3.fods | 20 sc/qa/unit/data/fods/protection-key4.fods | 20 sc/qa/unit/data/fods/protection-key5.fods | 20 sc/qa/unit/subsequent_export-test.cxx | 118 +++- sc/source/core/data/tabprotection.cxx | 27 + sc/source/filter/xml/xmlexprt.cxx | 25 + sc/source/ui/docshell/docsh.cxx |4 svl/source/misc/PasswordHelper.cxx | 52 +- sw/CppunitTest_sw_odfexport.mk |1 sw/qa/extras/odfexport/data/protection-key.fodt | 48 + sw/qa/extras/odfexport/odfexport.cxx| 32 ++ xmloff/source/text/XMLSectionExport.cxx |8 + 17 files changed, 416 insertions(+), 10 deletions(-) New commits: commit 398275ba9f4d65bebcc78864e70eee6212a84397 Author: Michael Stahl Date: Tue Feb 6 17:35:36 2018 +0100 tdf#115483 svl xmloff sc sw: verify all ODF 1.2 protection-key hashes ODF 1.2 has added some mandatory requirements for protection-key hashes which did not exist in ODF 1.1. This affects sections and indexes in ODT documents, as well as spreadsheets and sheets in ODS documents. 1. Accept the following hashed passwords: * UTF16 LE/BE encoded StarOffice-SHA1, OOo legacy and allowed by ODF 1.1 * UTF8 encoded proper SHA1, as required by ODF 1.2 * UTF8 encoded SHA256, as required by ODF 1.2 - specified either with the wrong URL used in the ODF 1.2 spec or the correct URL from the W3C spec, see OFFICE-3702 * Excel+SHA1 double-hash, only in Calc, see OFFICE-2112 2. Round-trip any of the above as-is * for SHA256 only write the URL from the ODF 1.2 spec 3. Generate only UTF16 LE encoded SHA1 for now, so that older LO releases can still verify the password * some time in the future, switch to generating some valid ODF 1.2 hash More changes are necessary in Calc, which can actually preserve different hashes for the same passwords in its runtime data model, whereas Writer just has a single buffer without even any metadata. For the Calc unit tests we need one document per hash because the protection-key attribute can be set on the entire spreadsheet, which is an unique element in the document. There are further uses of SvlPasswordHelper for change-tracking passwords, but apparently those are stored in settings.xml, so ODF has no requirements for them, so let's leave that as it is. Change-Id: Icb720b14ae9c0d9c04d2e082769ae2b74e3af8aa Reviewed-on: https://gerrit.libreoffice.org/49352 Tested-by: Jenkins Reviewed-by: Michael Stahl diff --git a/include/svl/PasswordHelper.hxx b/include/svl/PasswordHelper.hxx index ca048ed85924..a71f2ca7c172 100644 --- a/include/svl/PasswordHelper.hxx +++ b/include/svl/PasswordHelper.hxx @@ -33,10 +33,15 @@ public: SVL_DLLPUBLIC static void GetHashPassword(css::uno::Sequence & rPassHash, const sal_Char* pPass, sal_uInt32 nLen); SVL_DLLPUBLIC static void GetHashPassword(css::uno::Sequence& rPassHash, const OUString& sPass); +SVL_DLLPUBLIC static void GetHashPasswordSHA1UTF8(css::uno::Sequence& rPassHash, const OUString& sPass); +SVL_DLLPUBLIC static void GetHashPasswordSHA256(css::uno::Sequence& rPassHash, const OUString& sPass); /** Use this method to compare a given string with another given Hash value. This is necessary, because in older versions exists different hashes of the same string. They were endian dependent. -We need this to handle old files. This method will compare against big and little endian. See #101326# +We need this to handle old files. This method will compare against big and +little endian UTF-16. +tdf#115483: also check 2 different new ways of hashing that were added in +ODF 1.2, requiring UTF-8 encoding. */ SVL_DLLPUBLIC static bool CompareHashPassword(const css::uno::Sequence& rOldPassHash, const OUString& sNewPass); }; diff --git a/sc/CppunitTest_sc_subsequent_export_test.mk b/sc/CppunitTest_sc_subsequent_export_test.mk index b97423e27f89..cf6125f6ef04 100644 --- a/sc/CppunitTest_sc_subsequent_export_test.mk +++ b/sc/CppunitTest_sc_subsequent_export_test.mk @@ -72,6 +72,8 @@ $(eval $(call gb_CppunitTest_use_components,sc_subsequent_export_test,\ embeddedobj/util/embobj \ eventattacher/source/evtatt \ filter/source/config/cache/filterconfig1 \ + filter/source/odfflatxml/odfflatxml \ + filter/source/xmlfilteradaptor/xmlfa \ forms/
[Libreoffice-commits] core.git: sw/qa vbahelper/source
sw/qa/extras/ooxmlimport/ooxmlimport.cxx |2 +- vbahelper/source/vbahelper/vbaglobalbase.cxx |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) New commits: commit 9430abb0dcc9fb1facd498c88da44e3dbb9bd25b Author: Andrea Gelmini Date: Wed Feb 7 17:04:10 2018 +0100 Fix typos Change-Id: I90e3a9b3c1b8053362ff938374dd781d30618279 Reviewed-on: https://gerrit.libreoffice.org/49368 Reviewed-by: Julien Nabet Tested-by: Julien Nabet diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx index 61ef9aeaeb63..8bac0ed0c5c3 100644 --- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx +++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx @@ -195,7 +195,7 @@ DECLARE_OOXMLIMPORT_TEST(testN757890, "n757890.docx") xPara->getPropertyValue("ParaStyleName") >>= aValue; CPPUNIT_ASSERT_EQUAL(OUString("Heading 1"), aValue); -// This wan't centered +// This wasn't centered uno::Reference xTextFramesSupplier(mxComponent, uno::UNO_QUERY); uno::Reference xIndexAccess(xTextFramesSupplier->getTextFrames(), uno::UNO_QUERY); uno::Reference xFrame(xIndexAccess->getByIndex(0), uno::UNO_QUERY); diff --git a/vbahelper/source/vbahelper/vbaglobalbase.cxx b/vbahelper/source/vbahelper/vbaglobalbase.cxx index 6e238fe1e53b..8212816dee0a 100644 --- a/vbahelper/source/vbahelper/vbaglobalbase.cxx +++ b/vbahelper/source/vbahelper/vbaglobalbase.cxx @@ -89,7 +89,7 @@ VbaGlobalsBase::~VbaGlobalsBase() uno::Reference< container::XNameContainer > xNameContainer( mxContext, uno::UNO_QUERY ); if ( xNameContainer.is() ) { -// release document reference ( we don't wan't the component context trying to dispose that ) +// release document reference (we don't want the component context trying to dispose that) xNameContainer->removeByName( msDocCtxName ); // release application reference, as it is holding onto the context xNameContainer->removeByName( msApplication ); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: bin/check-elf-dynamic-objects
bin/check-elf-dynamic-objects |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit f38064cb0583c2cc0a84347ea9175491e105d926 Author: Andrea Gelmini Date: Wed Feb 7 14:17:34 2018 +0100 Fix typo Change-Id: Iaa48657cdffc12b0e7bf1e39476e84445ea6fc3b Reviewed-on: https://gerrit.libreoffice.org/49353 Reviewed-by: Julien Nabet Tested-by: Julien Nabet diff --git a/bin/check-elf-dynamic-objects b/bin/check-elf-dynamic-objects index 885ef9ce857f..62fe040dc01a 100755 --- a/bin/check-elf-dynamic-objects +++ b/bin/check-elf-dynamic-objects @@ -134,7 +134,7 @@ local file="$1" */libvcllo.so) whitelist="${whitelist} ${x11whitelist} ${openglwhitelist} ${giowhitelist} libcups.so.2" if [ "$ENABLE_QT5" = TRUE ]; then -#TOOD: is inclusion of vcl/qt5/Qt5Font.cxx in Library_vcl really wanted? +#TODO: is inclusion of vcl/qt5/Qt5Font.cxx in Library_vcl really wanted? whitelist="${whitelist} ${qt5whitelist}" fi ;; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: sc/source
sc/source/ui/condformat/condformatdlgentry.cxx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit e7c0684216f5d6ba01a30099829b9248756b5b62 Author: Katarina Behrens Date: Wed Feb 7 10:07:42 2018 +0100 tdf#115040: selected condition is now Tab-reachable this also prevents Tab focus from jumping out of the condition list unexpectedly Change-Id: I03247e49eee3bd6ee34a758e01578e821f7f9742 Reviewed-on: https://gerrit.libreoffice.org/49343 Tested-by: Jenkins Reviewed-by: Katarina Behrens diff --git a/sc/source/ui/condformat/condformatdlgentry.cxx b/sc/source/ui/condformat/condformatdlgentry.cxx index 230deaa5df6a..48e77718a9c0 100644 --- a/sc/source/ui/condformat/condformatdlgentry.cxx +++ b/sc/source/ui/condformat/condformatdlgentry.cxx @@ -39,7 +39,7 @@ #include ScCondFrmtEntry::ScCondFrmtEntry(vcl::Window* pParent, ScDocument* pDoc, const ScAddress& rPos) -: VclContainer(pParent, WB_CLIPCHILDREN | WB_BORDER) +: VclContainer(pParent, WB_CLIPCHILDREN | WB_BORDER | WB_CHILDDLGCTRL) , mbActive(false) , maStrCondition(ScResId(SCSTR_CONDITION)) , mpDoc(pDoc) ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: vcl/workben
vcl/workben/fftester.cxx |8 1 file changed, 8 insertions(+) New commits: commit 5b2b1ee3f3036c64f1343e4544bf7fb7d4ccdfed Author: Caolán McNamara Date: Wed Feb 7 15:31:10 2018 + add basic font parsing to fftester Change-Id: Iaeebbe5dc569450ca1a47dbda15f168fb3b45ac4 Reviewed-on: https://gerrit.libreoffice.org/49362 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/vcl/workben/fftester.cxx b/vcl/workben/fftester.cxx index 0b44e408cce6..e5bd5dbcd9d4 100644 --- a/vcl/workben/fftester.cxx +++ b/vcl/workben/fftester.cxx @@ -669,6 +669,14 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv) SvFileStream aFileStream(out, StreamMode::READ); ret = static_cast((*pfnImport)(aFileStream)); } +else if (strcmp(argv[2], "sft") == 0) +{ +SvFileStream aFileStream(out, StreamMode::READ); +std::vector aData(aFileStream.remainingSize()); +aFileStream.ReadBytes(aData.data(), aData.size()); +(void)vcl::Font::identifyFont(aData.data(), aData.size()); +} + #endif } catch (...) ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: sw/source
sw/source/filter/html/htmlsect.cxx |3 +++ 1 file changed, 3 insertions(+) New commits: commit 7b9228660f9d7c99caccc17f8cc4dd0e9b5048e2 Author: Caolán McNamara Date: Wed Feb 7 10:52:41 2018 + ofz#6064 clear footnotes from tobe-deleted paragraph Change-Id: I33f75adab35d43a4bbf51e33a0abcb5daeca93a3 Reviewed-on: https://gerrit.libreoffice.org/49344 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/sw/source/filter/html/htmlsect.cxx b/sw/source/filter/html/htmlsect.cxx index 1f838edd054c..818f90652f36 100644 --- a/sw/source/filter/html/htmlsect.cxx +++ b/sw/source/filter/html/htmlsect.cxx @@ -199,7 +199,10 @@ void SwHTMLParser::NewDivision( HtmlTokenId nToken ) aDelPam.GetPoint()->nNode = pStNd->EndOfSectionIndex() - 1; if (!PendingObjectsInPaM(aDelPam)) +{ +ClearFootnotesInRange(aDelPam.GetMark()->nNode, aDelPam.GetPoint()->nNode); m_xDoc->getIDocumentContentOperations().DelFullPara(aDelPam); +} // update page style for( size_t i=0; i < m_xDoc->GetPageDescCnt(); i++ ) ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: vcl/source
vcl/source/fontsubset/sft.cxx |6 ++ 1 file changed, 6 insertions(+) New commits: commit bb5faa16aa61a927eea3507eeeb7a35ec1c7a7b7 Author: Caolán McNamara Date: Wed Feb 7 12:29:32 2018 + sanity check cmap table size Change-Id: I010c2fd221bcd86a62efd9996a0c34930828cb6d Reviewed-on: https://gerrit.libreoffice.org/49348 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/vcl/source/fontsubset/sft.cxx b/vcl/source/fontsubset/sft.cxx index 58cfb6a57e1d..21ffb3c13255 100644 --- a/vcl/source/fontsubset/sft.cxx +++ b/vcl/source/fontsubset/sft.cxx @@ -1225,6 +1225,12 @@ static void FindCmap(TrueTypeFont *ttf) { const sal_uInt8* table = getTable(ttf, O_cmap); sal_uInt32 table_size = getTableSize(ttf, O_cmap); +if (table_size < 4) +{ +SAL_WARN("vcl.fonts", "Parsing error in " << OUString::createFromAscii(ttf->fname) << + "cmap table size too short"); +return; +} sal_uInt16 ncmaps = GetUInt16(table, 2); sal_uInt32 AppleUni = 0; // Apple Unicode sal_uInt32 ThreeZero = 0; /* MS Symbol*/ ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] help.git: help3xsl/get_url.xsl help3xsl/index2.html
help3xsl/get_url.xsl |2 +- help3xsl/index2.html |5 - 2 files changed, 5 insertions(+), 2 deletions(-) New commits: commit fd1e80bca4d05e1dac45fb226dff318e87b81ead Author: Olivier Hallot Date: Tue Feb 6 14:45:29 2018 +0100 Add anchor to branch bookmarks in hid-to-file Add the id="bm_nn" as anchor to get the html file displayed in the right position. Change-Id: Icf50119d7b4f7846abc2a128ccdf9d3ab77a50c2 Reviewed-on: https://gerrit.libreoffice.org/49299 Reviewed-by: Olivier Hallot Tested-by: Olivier Hallot diff --git a/help3xsl/get_url.xsl b/help3xsl/get_url.xsl index f7a032749..0f9a3f1a5 100644 --- a/help3xsl/get_url.xsl +++ b/help3xsl/get_url.xsl @@ -57,7 +57,7 @@ parameters in URLS--> ':' -', + ', diff --git a/help3xsl/index2.html b/help3xsl/index2.html index f30348b98..578acbbd2 100644 --- a/help3xsl/index2.html +++ b/help3xsl/index2.html @@ -41,7 +41,10 @@ if (file === undefined){ file = defaultFile; } -var newURL = lang + '/' + file + '?System=' + system + '&DbPAR=' + module; +var indx = file.indexOf('#'); +var bm = file.substr(indx,file.length); +file = file.substr(0,indx); +var newURL = lang + '/' + file + '?System=' + system + '&DbPAR=' + module + bm; window.open(newURL,'_self'); }else{ // URL came from elsewhere, direct access to webroot, we redirect to main Help page ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: helpcontent2
helpcontent2 |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 4066654f7a92ddd9307fb221e3e2f3eed261769f Author: Olivier Hallot Date: Tue Feb 6 14:45:29 2018 +0100 Updated core Project: help fd1e80bca4d05e1dac45fb226dff318e87b81ead Add anchor to branch bookmarks in hid-to-file Add the id="bm_nn" as anchor to get the html file displayed in the right position. Change-Id: Icf50119d7b4f7846abc2a128ccdf9d3ab77a50c2 Reviewed-on: https://gerrit.libreoffice.org/49299 Reviewed-by: Olivier Hallot Tested-by: Olivier Hallot diff --git a/helpcontent2 b/helpcontent2 index 0f7a354db93f..fd1e80bca4d0 16 --- a/helpcontent2 +++ b/helpcontent2 @@ -1 +1 @@ -Subproject commit 0f7a354db93f0affe218cae7e0ea294a4efe5891 +Subproject commit fd1e80bca4d05e1dac45fb226dff318e87b81ead ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - vcl/source
vcl/source/fontsubset/sft.cxx |6 ++ 1 file changed, 6 insertions(+) New commits: commit a94ff76521463e7d37840c422c6350edef40bf6b Author: Caolán McNamara Date: Wed Feb 7 12:29:32 2018 + sanity check cmap table size Change-Id: I010c2fd221bcd86a62efd9996a0c34930828cb6d Reviewed-on: https://gerrit.libreoffice.org/49349 Tested-by: Jenkins Reviewed-by: Michael Stahl diff --git a/vcl/source/fontsubset/sft.cxx b/vcl/source/fontsubset/sft.cxx index 098d54b41b2d..1a4f5f16e4ef 100644 --- a/vcl/source/fontsubset/sft.cxx +++ b/vcl/source/fontsubset/sft.cxx @@ -1225,6 +1225,12 @@ static void FindCmap(TrueTypeFont *ttf) { const sal_uInt8* table = getTable(ttf, O_cmap); sal_uInt32 table_size = getTableSize(ttf, O_cmap); +if (table_size < 4) +{ +SAL_WARN("vcl.fonts", "Parsing error in " << OUString::createFromAscii(ttf->fname) << + "cmap table size too short"); +return; +} sal_uInt16 ncmaps = GetUInt16(table, 2); sal_uInt32 AppleUni = 0; // Apple Unicode sal_uInt32 ThreeZero = 0; /* MS Symbol*/ ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - vcl/source
vcl/source/fontsubset/sft.cxx |6 ++ 1 file changed, 6 insertions(+) New commits: commit a39e2684d48046d18bd486d145b9d4a3d2044e8a Author: Caolán McNamara Date: Wed Feb 7 12:29:32 2018 + sanity check cmap table size Change-Id: I010c2fd221bcd86a62efd9996a0c34930828cb6d Reviewed-on: https://gerrit.libreoffice.org/49350 Tested-by: Jenkins Reviewed-by: Michael Stahl diff --git a/vcl/source/fontsubset/sft.cxx b/vcl/source/fontsubset/sft.cxx index 0f031d055ae3..2170acd08d1c 100644 --- a/vcl/source/fontsubset/sft.cxx +++ b/vcl/source/fontsubset/sft.cxx @@ -1231,6 +1231,12 @@ static void FindCmap(TrueTypeFont *ttf) { const sal_uInt8* table = getTable(ttf, O_cmap); sal_uInt32 table_size = getTableSize(ttf, O_cmap); +if (table_size < 4) +{ +SAL_WARN("vcl.fonts", "Parsing error in " << OUString::createFromAscii(ttf->fname) << + "cmap table size too short"); +return; +} sal_uInt16 ncmaps = GetUInt16(table, 2); sal_uInt32 AppleUni = 0; // Apple Unicode sal_uInt32 ThreeZero = 0; /* MS Symbol*/ ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] online.git: wsd/README
wsd/README | 11 +++ 1 file changed, 11 insertions(+) New commits: commit 35ccd70681ea3220ec33a19efa41575c4df8bcb2 Author: Miklos Vajna Date: Wed Feb 7 14:58:23 2018 +0100 wsd: document when to use 'auto' Change-Id: I376c8d159bc8e087315de29fd3289b45b36d4b76 Reviewed-on: https://gerrit.libreoffice.org/49356 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky diff --git a/wsd/README b/wsd/README index c696a42c..cb52706f 100644 --- a/wsd/README +++ b/wsd/README @@ -391,3 +391,14 @@ The style is roughly as follows, in rough order of importance: - return - is not a function; but a statement - it doesn't need extra () +- Use 'auto' in the following cases only: + + - iterators + + - range-based for loops + + - the type is spelled out in the same line already (e.g. initializing from a +cast or a function that has a single type parameter) + + In other cases it makes the code more readable to still spell out the type + explicitly. ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
Re: m68k UnoApiTarget/udkapi.rdb build fails ("Bad input")
Hi! On 02/06/2018 10:29 PM, Rene Engelhard wrote: > Don't have (and yes, I saw the build failure and your bug report). > > Quickly looked at the file, but tbh don't see why it should fail only on > m68k (no idea about arch-specifics which can cause that, though). > > The latest round of m68k fixes (-mmlong-jump-table-offsets..) was done by > John Paul Adrian Glaubitz, though, maybe he has an idea. Yes, I will have a look at it at some point. Please bear with me as I am very busy with many projects I am hacking on to fix such bugs. We are still actively maintaining m68k in Debian and these issues are being looked at. It sometimes takes a bit time, so please do not put any pressure on us in the sense that you are going to remove the m68k code altogether. Thanks, Adrian -- .''`. John Paul Adrian Glaubitz : :' : Debian Developer - glaub...@debian.org `. `' Freie Universitaet Berlin - glaub...@physik.fu-berlin.de `-GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice-commits] core.git: Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5
Am 07.02.2018 um 14:21 schrieb Stephan Bergmann: > On 07.02.2018 11:46, Rene Engelhard wrote: >> On Wed, Feb 07, 2018 at 09:57:46AM +0100, Stephan Bergmann wrote: >>> On 07.02.2018 09:33, Stephan Bergmann wrote: commit bf23fe3a4a3eebe3d08fa26341a486b83d80c1c7 Author: Stephan Bergmann Date: Wed Feb 7 09:11:35 2018 +0100 Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5 The dependency of Library_vcl on qt5 libraries (via vcl/qt5/Qt5Font.cxx) is there ever since b66a7cbd8491fe436126e11975c360f47ae346ed "QT5 first stab on implementing CommonSalLayout", but no idea whether that is by design or is a hack that should eventually be cleaned up. >>> >>> Any thoughts on the above? It might e.g. by undesirable for distros >>> that do >>> --enable-qt5 but split libvclplug_qt5lo.so into a Qt5-dependent >>> package of >>> its own (and don't want the base vcl package to depend on Qt5). >> >> Yes, I already "complained" about this, jmux had a look/wanted to have >> a look. This is a blocker for me enabling qt5. I am so not making -core >> depending on qt5. > > So whoever will eventually fix that, please remember to revert the > relevant part of this bf23fe3a4a3eebe3d08fa26341a486b83d80c1c7, too. There are two commits to fix this: https://gerrit.libreoffice.org/#/c/47279/ https://gerrit.libreoffice.org/#/c/47408/ I simply didn't have enough time to test these. They compile and "work for me". But this eventually breaks embedded font handling and some code I changed didn't made much sense. There were some reinterpret_cast stuff to fit those embedded font handling into the normal font handling in some obscure way, I don't yet grok. Then there is the hb_font handling on Windows, which - I guess for some resource handling - is places in the PhysicalFontFace instead of the LogicalFontInstance. But currently I don't have time to test this with all the stuff (AKA a Windows and Mac build, embedded font handling). Probably it would be easier to just move the Qt5 stuff; but then I wanted to clean this up and move the platform specific code into their respective VCL modules. I also started writing documentation, about the way the font handling works / should work. Fact is I'm currently overwhelmed by non-LO work. If someone else has some time do the testing I would be happy. I can push this, but don't have time to fix regressions. And I would like to mentor some Qt5 GSoC, which I have to replace the KDE stuff on the ideas page. And I have rebased patches, if that helps. Jan-Marek ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: m68k UnoApiTarget/udkapi.rdb build fails ("Bad input")
Stephan Bergmann writes: > Odd, esp. as 9223372036854775807 is 0x7FFF, not > 0x (aka -1). Smells like an issue with the compilation > toolchain. Entirely possible, as there was in fact an intervening GCC upgrade, with the following ChangeLog stanza: gcc-7 (7.2.0-19) unstable; urgency=medium * Update to SVN 20180107 (r256317) from the gcc-7-branch. - Fix PR libstdc++/82522, PR debug/83550, PR middle-end/83608, PR middle-end/83609, PR middle-end/83623, PR c++/83553, PR lto/82027, PR c/83448, PR rtl-optimization/80747, PR rtl-optimization/83512, PR tree-optimization/83523, PR tree-optimization/83521, PR ipa/82801, PR ipa/83346, PR target/83467 (x86), PR tree-optimization/82726, PR tree-optimization/70754, PR target/83387 (PPC), PR c++/83556, PR c++/83116, PR Fortran/83679, PR fortran/83650, PR Fortran/83548, PR libgfortran/83649, PR libgfortran/83613, PR libgfortran/81937, PR libgfortran/78549, PR libstdc++/83600, PR libstdc++/83598, PR libstdc++/83279, PR libstdc++/83626, PR libstdc++/83626, PR preprocessor/83492. * debian/rules2: Fix typo for N32 conditions (YunQiang Su). Closes: #886316. * More libffi mips r6 updates (YunQiang Su). Addresses: #886201. * libgo: Backport upstream sparc64 fix (James Clark). Closes: #884642. * Default to PIE on the hurd (Samuel Thibault). Closes: #885056. * Use internal libunwind for ia64 cross-builds. Closes: #885931. * Strip -z,defs from linker options for internal libunwind (James Clarke). Closes: #885937. * Fix rtlibs stage build with debhelper 10.9.1 (Helmut Grohne). Closes: #879054. -- Matthias Klose Sun, 07 Jan 2018 08:55:48 +0100 Comparing the "Build environment" sections of [1] (good) and [2] (bad) also indicates some other upgrades, though GCC is my prime suspect if this is in fact a toolchain regression. - binutils 2.29.1-2 -> 2.29.1-3, featuring a fix for PR ld/22626. - glibc 2.25-5 -> 2.26-3. - linux-libc-dev (kernel headers) 4.14.2-1 -> 4.14.12-2. - Upgrades to various libraries and utilities outside the central toolchain. Thanks for the analysis, and sorry for the noise if this turns out to be a toolchain bug. [1] https://buildd.debian.org/status/fetch.php?pkg=libreoffice&arch=m68k&ver=1%3A6.0.0%7Erc1-1&stamp=1514303458&raw=0 [2] https://buildd.debian.org/status/fetch.php?pkg=libreoffice&arch=m68k&ver=1%3A6.0.0%7Erc2-1&stamp=1516003390&raw=0 -- Aaron M. Ucko, KB1CJC (amu at alum.mit.edu, ucko at debian.org) http://www.mit.edu/~amu/ | http://stuff.mit.edu/cgi/finger/?a...@monk.mit.edu ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] core.git: cui/source
cui/source/dialogs/hlmarkwn.cxx |4 ++-- cui/source/inc/hlmarkwn.hxx |3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) New commits: commit 765c98d89fb5b682cc6fb106baec32295a4aabca Author: Markus Mohrhard Date: Tue Feb 6 17:48:22 2018 +0100 Don't inherit from ModalDialog for a random UI element Change-Id: I2f734b1f034eaa4203a21968bc8eca455afa7f72 Reviewed-on: https://gerrit.libreoffice.org/49312 Reviewed-by: Markus Mohrhard Tested-by: Markus Mohrhard diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx index cfcda09e2a2c..ee011732a24f 100644 --- a/cui/source/dialogs/hlmarkwn.cxx +++ b/cui/source/dialogs/hlmarkwn.cxx @@ -118,7 +118,7 @@ void SvxHlmarkTreeLBox::Paint(vcl::RenderContext& rRenderContext, const ::tools: //*** Window-Class *** // Constructor / Destructor SvxHlinkDlgMarkWnd::SvxHlinkDlgMarkWnd( SvxHyperlinkTabPageBase *pParent ) -: ModalDialog(pParent, "HyperlinkMark", "cui/ui/hyperlinkmarkdialog.ui") +: FloatingWindow(pParent, "HyperlinkMark", "cui/ui/hyperlinkmarkdialog.ui") , mbUserMoved(false) , mpParent(pParent) , mnError(LERR_NOERROR) @@ -150,7 +150,7 @@ void SvxHlinkDlgMarkWnd::dispose() mpBtClose.clear(); mpLbTree.clear(); mpParent.clear(); -ModalDialog::dispose(); +FloatingWindow::dispose(); } // Set an errorstatus diff --git a/cui/source/inc/hlmarkwn.hxx b/cui/source/inc/hlmarkwn.hxx index 5a879197b3ed..518ac7ce7e8b 100644 --- a/cui/source/inc/hlmarkwn.hxx +++ b/cui/source/inc/hlmarkwn.hxx @@ -23,6 +23,7 @@ #include #include #include +#include #include #include "hlmarkwn_def.hxx" @@ -59,7 +60,7 @@ public: //# # //# Window-Class # //# # -class SvxHlinkDlgMarkWnd : public ModalDialog //FloatingWindow +class SvxHlinkDlgMarkWnd : public FloatingWindow //FloatingWindow { private: friend class SvxHlmarkTreeLBox; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: oox/source sc/qa
oox/source/export/preset-definitions-to-shape-types.pl |3 +- sc/qa/unit/subsequent_export-test.cxx | 21 - 2 files changed, 18 insertions(+), 6 deletions(-) New commits: commit ea7274259a211170ee9f5a8714a2f9acd8bed6d8 Author: Bartosz Kosiorek Date: Fri Jan 12 17:12:18 2018 +0100 tdf#114842 Fix comment shape export for Calc When we have shape definition for commend, eg.: After that fix, comments are displayed correctly. I also added unit test, to make sure that shape is using already defined "shapetype". Change-Id: I8faf1befe7573aa33ee8a294eb192e5e255f37a1 Reviewed-on: https://gerrit.libreoffice.org/47821 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek diff --git a/oox/source/export/preset-definitions-to-shape-types.pl b/oox/source/export/preset-definitions-to-shape-types.pl index b41dd58953e8..e36e97a808a9 100644 --- a/oox/source/export/preset-definitions-to-shape-types.pl +++ b/oox/source/export/preset-definitions-to-shape-types.pl @@ -1187,8 +1187,9 @@ parse( $file ); close( $file ); if ( !defined( $result_shapes{'textBox'} ) ) { +# tdf#114842 shapetype id of the textbox, must be the same as defined $result_shapes{'textBox'} = -"\n" . "\n" . "\n" . diff --git a/sc/qa/unit/subsequent_export-test.cxx b/sc/qa/unit/subsequent_export-test.cxx index aaf82ae88c88..6865897d0318 100644 --- a/sc/qa/unit/subsequent_export-test.cxx +++ b/sc/qa/unit/subsequent_export-test.cxx @@ -564,14 +564,25 @@ void ScExportTest::testCommentExportXLSX() CPPUNIT_ASSERT(xShell.is()); std::shared_ptr pXPathFile = ScBootstrapFixture::exportTo(&(*xShell), FORMAT_XLSX); -xmlDocPtr pSheet = XPathHelper::parseExport(pXPathFile, m_xSFactory, "xl/comments1.xml"); -CPPUNIT_ASSERT(pSheet); +const xmlDocPtr pComments = XPathHelper::parseExport(pXPathFile, m_xSFactory, "xl/comments1.xml"); +CPPUNIT_ASSERT(pComments); + +assertXPath(pComments, "/x:comments/x:authors/x:author[1]", "BAKO"); +assertXPath(pComments, "/x:comments/x:authors/x:author", 1); + +assertXPath(pComments, "/x:comments/x:commentList/x:comment/x:text/x:r/x:t", "Komentarz"); -assertXPath(pSheet, "/x:comments/x:authors/x:author[1]", "BAKO"); -assertXPath(pSheet, "/x:comments/x:authors/x:author", 1); +const xmlDocPtr pVmlDrawing = XPathHelper::parseExport(pXPathFile, m_xSFactory, "xl/drawings/vmlDrawing1.vml"); +CPPUNIT_ASSERT(pVmlDrawing); -assertXPath(pSheet, "/x:comments/x:commentList/x:comment/x:text/x:r/x:t", "Komentarz"); +//assertXPath(pVmlDrawing, "/xml/v:shapetype", "coordsize", "21600,21600"); +assertXPath(pVmlDrawing, "/xml/v:shapetype", "spt", "202"); +assertXPath(pVmlDrawing, "/xml/v:shapetype/v:stroke", "joinstyle", "miter"); +const OUString sShapeTypeId = "#" + getXPath(pVmlDrawing, "/xml/v:shapetype", "id"); +assertXPath(pVmlDrawing, "/xml/v:shape", "type", sShapeTypeId); +assertXPath(pVmlDrawing, "/xml/v:shape/v:shadow", "color", "black"); +assertXPath(pVmlDrawing, "/xml/v:shape/v:shadow", "obscured", "t"); } #if HAVE_MORE_FONTS ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] online.git: wsd/ClientSession.cpp
wsd/ClientSession.cpp |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit bd7b2b833c064a64d830d1b032cb8c98e85cd2a9 Author: Pranav Kant Date: Fri Feb 2 13:08:25 2018 +0530 wsd: Don't request closing here, just stop the broker Asking the doc broker to close means that it will save the current document to storage before shutting down. But we don't want that because storing the current document to storage means overwriting the document which has been changed underneath us. Change-Id: I8df45d2f0cf3f65936dc3030f483e52fd1703146 Reviewed-on: https://gerrit.libreoffice.org/49134 Reviewed-by: pranavk Tested-by: pranavk diff --git a/wsd/ClientSession.cpp b/wsd/ClientSession.cpp index 8d727247..d94a8467 100644 --- a/wsd/ClientSession.cpp +++ b/wsd/ClientSession.cpp @@ -190,7 +190,7 @@ bool ClientSession::_handleInput(const char *buffer, int length) LOG_DBG("Document marked as changed in storage and user [" << getUserId() << ", " << getUserName() << "] wants to refresh the document for all."); -docBroker->closeDocument("documentconflict " + getUserName()); +docBroker->stop("documentconflict " + getUserName()); } return true; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: package/source
package/source/zipapi/MemoryByteGrabber.hxx |2 ++ 1 file changed, 2 insertions(+) New commits: commit 37413f569ad557cc08ea625ce18a6570eb00f075 Author: Stephan Bergmann Date: Wed Feb 7 14:30:56 2018 +0100 Prevent MemoryByteGrabber from ever taking temporaries again ...after c99527385acf367c748b3dcf3e6a3bb8103f5eee "MemoryByteGrabber sequence has to exist for Grabber lifetime" Change-Id: Idcb7548aaa7741e8e535024ba36c7a171a6c2fb4 diff --git a/package/source/zipapi/MemoryByteGrabber.hxx b/package/source/zipapi/MemoryByteGrabber.hxx index 7f3c42485876..9b1c096ae056 100644 --- a/package/source/zipapi/MemoryByteGrabber.hxx +++ b/package/source/zipapi/MemoryByteGrabber.hxx @@ -34,6 +34,8 @@ public: , mnEnd ( rBuffer.getLength() ) { } +MemoryByteGrabber(css::uno::Sequence &&) = delete; + const sal_Int8 * getCurrentPos () { return mpBuffer + mnCurrent; } sal_Int32 remainingSize() const { return mnEnd - mnCurrent; } ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] online.git: test/Makefile.am test/UnitWopiOwnertermination.cpp test/WopiTestServer.hpp wsd/DocumentBroker.cpp wsd/DocumentBroker.hpp
test/Makefile.am |6 +- test/UnitWopiOwnertermination.cpp | 89 ++ test/WopiTestServer.hpp |1 wsd/DocumentBroker.cpp| 14 +++-- wsd/DocumentBroker.hpp|1 5 files changed, 104 insertions(+), 7 deletions(-) New commits: commit 5476774af1510751127cdb0c605149f05d43394b Author: Pranav Kant Date: Fri Feb 2 09:58:20 2018 +0530 wsd: Use a close request flag to break out of doc broker poll thread ... instead of directly stop()ing it. The close request approach also makes sure that outgoing document is saved to storage. Change-Id: I44f61db00dbd326dec80f59f4a2cbb617048aa94 Reviewed-on: https://gerrit.libreoffice.org/49122 Reviewed-by: Ashod Nakashian Tested-by: Ashod Nakashian diff --git a/test/Makefile.am b/test/Makefile.am index 98426f72..d7894bd9 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -17,7 +17,7 @@ noinst_LTLIBRARIES = \ unit-storage.la unit-client.la \ unit-admin.la unit-tilecache.la \ unit-fuzz.la unit-oob.la unit-oauth.la \ - unit-wopi.la unit-wopi-saveas.la + unit-wopi.la unit-wopi-saveas.la unit-wopi-ownertermination.la MAGIC_TO_FORCE_SHLIB_CREATION = -rpath /dummy AM_LDFLAGS = -pthread -module $(MAGIC_TO_FORCE_SHLIB_CREATION) $(ZLIB_LIBS) @@ -83,6 +83,8 @@ unit_wopi_la_SOURCES = UnitWOPI.cpp unit_wopi_la_LIBADD = $(CPPUNIT_LIBS) unit_wopi_saveas_la_SOURCES = UnitWOPISaveAs.cpp unit_wopi_saveas_la_LIBADD = $(CPPUNIT_LIBS) +unit_wopi_ownertermination_la_SOURCES = UnitWopiOwnertermination.cpp +unit_wopi_ownertermination_la_LIBADD = $(CPPUNIT_LIBS) if HAVE_LO_PATH SYSTEM_STAMP = @SYSTEMPLATE_PATH@/system_stamp @@ -96,7 +98,7 @@ check-local: ./run_unit.sh --log-file test.log --trs-file test.trs # FIXME 2: unit-oob.la fails with symbol undefined: # UnitWSD::testHandleRequest(UnitWSD::TestRequest, UnitHTTPServerRequest&, UnitHTTPServerResponse&) , -TESTS = unit-prefork.la unit-tilecache.la unit-timeout.la unit-oauth.la unit-wopi.la unit-wopi-saveas.la +TESTS = unit-prefork.la unit-tilecache.la unit-timeout.la unit-oauth.la unit-wopi.la unit-wopi-saveas.la unit-wopi-ownertermination.la # TESTS = unit-client.la # TESTS += unit-admin.la # TESTS += unit-storage.la diff --git a/test/UnitWopiOwnertermination.cpp b/test/UnitWopiOwnertermination.cpp new file mode 100644 index ..8ddb02a4 --- /dev/null +++ b/test/UnitWopiOwnertermination.cpp @@ -0,0 +1,89 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#include "config.h" + +#include "WopiTestServer.hpp" +#include "Log.hpp" +#include "Unit.hpp" +#include "UnitHTTP.hpp" +#include "helpers.hpp" +#include +#include + +class UnitWopiOwnertermination : public WopiTestServer +{ +enum class Phase +{ +Load, +Modify, +OwnerTermination, +Polling +} _phase; + +public: +UnitWopiOwnertermination() : +_phase(Phase::Load) +{ +} + +void assertPutFileRequest(const Poco::Net::HTTPRequest& /*request*/) override +{ +if (_phase == Phase::Polling) +{ +// Document got saved, that's what we wanted +exitTest(TestResult::Ok); +} +} + +void invokeTest() override +{ +constexpr char testName[] = "UnitWopiOwnertermination"; + +switch (_phase) +{ +case Phase::Load: +{ +initWebsocket("/wopi/files/0?access_token=anything"); + +helpers::sendTextFrame(*_ws->getLOOLWebSocket(), "load url=" + _wopiSrc, testName); + +_phase = Phase::Modify; +break; +} +case Phase::Modify: +{ +helpers::sendTextFrame(*_ws->getLOOLWebSocket(), "key type=input char=97 key=0", testName); +helpers::sendTextFrame(*_ws->getLOOLWebSocket(), "key type=up char=0 key=512", testName); + +_phase = Phase::OwnerTermination; +SocketPoll::wakeupWorld(); +break; +} + case Phase::OwnerTermination: +{ +_phase = Phase::Polling; +helpers::sendTextFrame(*_ws->getLOOLWebSocket(), "closedocument", testName); +break; +} +case Phase::Polling: +{ +// just wait for the results +break; +} +} +} +}; + +UnitBase *unit_create_wsd(void) +{ +return new UnitWopiOwnertermination(); +} + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/test/WopiTestServe
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.3' - sw/qa writerfilter/source
sw/qa/extras/ooxmlimport/data/tdf114217.docx |binary sw/qa/extras/ooxmlimport/ooxmlimport.cxx |8 writerfilter/source/dmapper/DomainMapperTableHandler.cxx |5 - writerfilter/source/dmapper/DomainMapper_Impl.hxx|6 -- writerfilter/source/dmapper/PropertyMap.cxx |5 + 5 files changed, 21 insertions(+), 3 deletions(-) New commits: commit 561f2a32966ff68bdf0d30a33b90fe95ee7e48cb Author: Mike Kaganski Date: Wed Feb 7 01:03:32 2018 +0300 tdf#114217: Consider relative width when importing floating table Unit test included Change-Id: I8e3338d7df431bd016caa4e06e684fbd189127c4 Reviewed-on: https://gerrit.libreoffice.org/49324 Tested-by: Jenkins Reviewed-by: Mike Kaganski Reviewed-on: https://gerrit.libreoffice.org/49335 Reviewed-by: Aron Budea Tested-by: Aron Budea diff --git a/sw/qa/extras/ooxmlimport/data/tdf114217.docx b/sw/qa/extras/ooxmlimport/data/tdf114217.docx new file mode 100644 index ..49f1ce164cbe Binary files /dev/null and b/sw/qa/extras/ooxmlimport/data/tdf114217.docx differ diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx index a45d1c8469e3..b8920caf2976 100644 --- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx +++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx @@ -1587,6 +1587,14 @@ DECLARE_OOXMLIMPORT_TEST(testTdf111550, "tdf111550.docx") getCell(innerTable, "A1", "[outer:A2]\n[inner:A1]"); } +DECLARE_OOXMLIMPORT_TEST(testTdf114217, "tdf114217.docx") +{ +uno::Reference xDrawPageSupplier(mxComponent, uno::UNO_QUERY); +uno::Reference xDrawPage = xDrawPageSupplier->getDrawPage(); +// This was 1, multi-page table was imported as a floating one. +CPPUNIT_ASSERT_EQUAL(static_cast(0), xDrawPage->getCount()); +} + // tests should only be added to ooxmlIMPORT *if* they fail round-tripping in ooxmlEXPORT CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx index 4c8365f0ad6f..a872ecb16c6a 100644 --- a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx +++ b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx @@ -1136,8 +1136,11 @@ void DomainMapperTableHandler::endTable(unsigned int nestedTableLevel, bool bTab // table is not in the body text. sal_Int32 nTableWidth = 0; m_aTableProperties->getValue(TablePropertyMap::TABLE_WIDTH, nTableWidth); +sal_Int32 nTableWidthType = text::SizeType::FIX; +m_aTableProperties->getValue(TablePropertyMap::TABLE_WIDTH_TYPE, nTableWidthType); if (m_rDMapper_Impl.GetSectionContext() && nestedTableLevel <= 1 && !m_rDMapper_Impl.IsInHeaderFooter()) - m_rDMapper_Impl.m_aPendingFloatingTables.push_back(FloatingTableInfo(xStart, xEnd, comphelper::containerToSequence(aFrameProperties), nTableWidth)); +m_rDMapper_Impl.m_aPendingFloatingTables.push_back( +FloatingTableInfo(xStart, xEnd, comphelper::containerToSequence(aFrameProperties), nTableWidth, nTableWidthType)); else { // m_xText points to the body text, get the current xText from m_rDMapper_Impl, in case e.g. we would be in a header. diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.hxx b/writerfilter/source/dmapper/DomainMapper_Impl.hxx index 44a2be003c30..9d51754bd1ef 100644 --- a/writerfilter/source/dmapper/DomainMapper_Impl.hxx +++ b/writerfilter/source/dmapper/DomainMapper_Impl.hxx @@ -310,17 +310,19 @@ struct FloatingTableInfo css::uno::Reference m_xEnd; css::uno::Sequence m_aFrameProperties; sal_Int32 m_nTableWidth; +sal_Int32 m_nTableWidthType; /// Break type of the section that contains this table. sal_Int32 m_nBreakType = -1; FloatingTableInfo(css::uno::Reference const& xStart, css::uno::Reference const& xEnd, const css::uno::Sequence& aFrameProperties, -sal_Int32 nTableWidth) +sal_Int32 nTableWidth, sal_Int32 nTableWidthType) : m_xStart(xStart), m_xEnd(xEnd), m_aFrameProperties(aFrameProperties), -m_nTableWidth(nTableWidth) +m_nTableWidth(nTableWidth), +m_nTableWidthType(nTableWidthType) { } css::uno::Any getPropertyValue(const OUString &propertyName); diff --git a/writerfilter/source/dmapper/PropertyMap.cxx b/writerfilter/source/dmapper/PropertyMap.cxx index 91528c7967ce..70d9c3fcbf32 100644 --- a/writerfilter/source/dmapper/PropertyMap.cxx +++ b/writerfilter/source/dmapper/PropertyMap.cxx @@ -37,6 +37,7 @@ #include #include #include +#include #include #include #include @@ -1074,6 +1075,10 @@ bool SectionPropertyMap::FloatingTableConversion(DomainMapper_Impl& rDM_Impl, Fl sal_Int32 nTextAreaWidth = nPageWidth - GetLeftMargin
Re: [Libreoffice-commits] core.git: Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5
On 07.02.2018 11:46, Rene Engelhard wrote: On Wed, Feb 07, 2018 at 09:57:46AM +0100, Stephan Bergmann wrote: On 07.02.2018 09:33, Stephan Bergmann wrote: commit bf23fe3a4a3eebe3d08fa26341a486b83d80c1c7 Author: Stephan Bergmann Date: Wed Feb 7 09:11:35 2018 +0100 Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5 The dependency of Library_vcl on qt5 libraries (via vcl/qt5/Qt5Font.cxx) is there ever since b66a7cbd8491fe436126e11975c360f47ae346ed "QT5 first stab on implementing CommonSalLayout", but no idea whether that is by design or is a hack that should eventually be cleaned up. Any thoughts on the above? It might e.g. by undesirable for distros that do --enable-qt5 but split libvclplug_qt5lo.so into a Qt5-dependent package of its own (and don't want the base vcl package to depend on Qt5). Yes, I already "complained" about this, jmux had a look/wanted to have a look. This is a blocker for me enabling qt5. I am so not making -core depending on qt5. So whoever will eventually fix that, please remember to revert the relevant part of this bf23fe3a4a3eebe3d08fa26341a486b83d80c1c7, too. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] core.git: sw/inc sw/qa sw/source
sw/inc/unotxdoc.hxx|5 ++ sw/qa/extras/uiwriter/uiwriter.cxx | 21 sw/source/uibase/uno/unotxdoc.cxx | 64 + 3 files changed, 90 insertions(+) New commits: commit da0815e8a2e89c02c530fe6fcf7233f241e529c6 Author: Mike Kaganski Date: Tue Jan 9 22:54:21 2018 +0300 Implement XDrawPagesSupplier in SwXTextDocument Text documents only exposed deprecated XDrawPageSupplier interface (see https://api.libreoffice.org/docs/idl/ref/deprecated.html). Other documents (spreadsheets, Draw and Impress documents) only expose XDrawPagesSupplier interface. Implementing the latter for text documents (which would only provide a single page) allows for uniform handling of draw pages across all modules. Change-Id: Ib9e719c6130bc3c968d92c6864fa413ad2c0e3b9 Reviewed-on: https://gerrit.libreoffice.org/47681 Tested-by: Jenkins Reviewed-by: Miklos Vajna diff --git a/sw/inc/unotxdoc.hxx b/sw/inc/unotxdoc.hxx index 4e2161af805b..770cf0c1d1d0 100644 --- a/sw/inc/unotxdoc.hxx +++ b/sw/inc/unotxdoc.hxx @@ -45,6 +45,7 @@ #include #include #include +#include #include #include #include @@ -112,6 +113,7 @@ typedef cppu::WeakImplHelper css::style::XAutoStylesSupplier, css::lang::XServiceInfo, css::drawing::XDrawPageSupplier, +css::drawing::XDrawPagesSupplier, css::text::XDocumentIndexesSupplier, css::beans::XPropertySet, css::beans::XPropertyState, @@ -325,6 +327,9 @@ public: // css::drawing::XDrawPageSupplier virtual css::uno::Reference< css::drawing::XDrawPage > SAL_CALL getDrawPage() override; +// css::drawing::XDrawPagesSupplier +virtual css::uno::Reference< css::drawing::XDrawPages > SAL_CALL getDrawPages() override; + // css::text::XDocumentIndexesSupplier virtual css::uno::Reference< css::container::XIndexAccess > SAL_CALL getDocumentIndexes() override; diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx index 37bd5e2b2ca0..8dee21388fbe 100644 --- a/sw/qa/extras/uiwriter/uiwriter.cxx +++ b/sw/qa/extras/uiwriter/uiwriter.cxx @@ -301,6 +301,7 @@ public: void testTdf114536(); void testTdf115065(); void testTdf115132(); +void testXDrawPagesSupplier(); CPPUNIT_TEST_SUITE(SwUiWriterTest); CPPUNIT_TEST(testReplaceForward); @@ -481,6 +482,7 @@ public: CPPUNIT_TEST(testTdf114536); CPPUNIT_TEST(testTdf115065); CPPUNIT_TEST(testTdf115132); +CPPUNIT_TEST(testXDrawPagesSupplier); CPPUNIT_TEST_SUITE_END(); private: @@ -5943,6 +5945,25 @@ void SwUiWriterTest::testTdf115132() } } +void SwUiWriterTest::testXDrawPagesSupplier() +{ +createDoc(); +uno::Reference xDrawPagesSupplier(mxComponent, uno::UNO_QUERY); +CPPUNIT_ASSERT_MESSAGE("XDrawPagesSupplier interface is unavailable", xDrawPagesSupplier.is()); +uno::Reference xDrawPages = xDrawPagesSupplier->getDrawPages(); +CPPUNIT_ASSERT(xDrawPages.is()); +CPPUNIT_ASSERT_EQUAL_MESSAGE("There must be only a single DrawPage in Writer documents", +sal_Int32(1), xDrawPages->getCount()); +uno::Any aDrawPage = xDrawPages->getByIndex(0); +uno::Reference xDrawPageFromXDrawPages(aDrawPage, uno::UNO_QUERY); +CPPUNIT_ASSERT(xDrawPageFromXDrawPages.is()); + +uno::Reference xDrawPageSupplier(mxComponent, uno::UNO_QUERY); +uno::Reference xDrawPage = xDrawPageSupplier->getDrawPage(); +CPPUNIT_ASSERT_EQUAL_MESSAGE("The DrawPage accessed using XDrawPages must be the same as using XDrawPageSupplier", +xDrawPage.get(), xDrawPageFromXDrawPages.get()); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SwUiWriterTest); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/sw/source/uibase/uno/unotxdoc.cxx b/sw/source/uibase/uno/unotxdoc.cxx index 950973c58555..aa6e3395270b 100644 --- a/sw/source/uibase/uno/unotxdoc.cxx +++ b/sw/source/uibase/uno/unotxdoc.cxx @@ -91,6 +91,8 @@ #include #include #include +#include +#include #include #include #include @@ -1378,6 +1380,68 @@ Reference< drawing::XDrawPage > SwXTextDocument::getDrawPage() return mxXDrawPage; } +class SwDrawPagesObj : public cppu::WeakImplHelper< +css::drawing::XDrawPages, +css::lang::XServiceInfo> +{ +private: +css::uno::Reference< css::drawing::XDrawPageSupplier > m_xDoc; +public: +SwDrawPagesObj(const css::uno::Reference< css::drawing::XDrawPageSupplier >& rxDoc) : m_xDoc(rxDoc) {} + +// XDrawPages +virtual css::uno::Reference< css::drawing::XDrawPage > SAL_CALL +insertNewByIndex(sal_Int32 /*nIndex*/) override { throw css::lang::NoSupportException(); } + +virtual void SAL_CALL remove(const css::uno::Reference< css::drawing::XDrawPage >& /*xPage*/) override +{ +throw css::lang::NoSupportException(); +} + +// XIndexAccess +virtual sal_Int32 SAL_CALL getCount() override { return 1; } + +virtual css::uno::Any SAL_CALL g
[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - package/source
package/source/zipapi/ZipFile.cxx |8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) New commits: commit a224d33cbf098c361a7244569d5088044561f3ee Author: Caolán McNamara Date: Tue Feb 6 21:21:30 2018 + MemoryByteGrabber sequence has to exist for Grabber lifetime it just takes a c++ ref, so a temp is an unsuitable arg Change-Id: I40490e94d977df91b985bc4ae458b68ee85d5dfe Reviewed-on: https://gerrit.libreoffice.org/49323 Tested-by: Jenkins Reviewed-by: Michael Stahl diff --git a/package/source/zipapi/ZipFile.cxx b/package/source/zipapi/ZipFile.cxx index 547be25ed23a..cb85ecd655ae 100644 --- a/package/source/zipapi/ZipFile.cxx +++ b/package/source/zipapi/ZipFile.cxx @@ -866,7 +866,7 @@ sal_Int32 ZipFile::readCEN() if ( static_cast < sal_Int64 > ( nCenLen ) != nRead ) throw ZipException ("Error reading CEN into memory buffer!" ); -MemoryByteGrabber aMemGrabber ( aCENBuffer ); +MemoryByteGrabber aMemGrabber(aCENBuffer); ZipEntry aEntry; sal_Int16 nCommentLen; @@ -980,7 +980,8 @@ void ZipFile::recover() if ( nPos < nBufSize - 30 && pBuffer[nPos] == 'P' && pBuffer[nPos+1] == 'K' && pBuffer[nPos+2] == 3 && pBuffer[nPos+3] == 4 ) { ZipEntry aEntry; -MemoryByteGrabber aMemGrabber ( Sequence< sal_Int8 >( &(pBuffer[nPos+4]), 26 ) ); +Sequence aTmpBuffer(&(pBuffer[nPos+4]), 26); +MemoryByteGrabber aMemGrabber(aTmpBuffer); aEntry.nVersion = aMemGrabber.ReadInt16(); if ( ( aEntry.nVersion & 1 ) != 1 ) @@ -1050,7 +1051,8 @@ void ZipFile::recover() else if (pBuffer[nPos] == 'P' && pBuffer[nPos+1] == 'K' && pBuffer[nPos+2] == 7 && pBuffer[nPos+3] == 8 ) { sal_Int64 nCompressedSize, nSize; -MemoryByteGrabber aMemGrabber ( Sequence< sal_Int8 >( &(pBuffer[nPos+4]), 12 ) ); +Sequence aTmpBuffer(&(pBuffer[nPos+4]), 12); +MemoryByteGrabber aMemGrabber(aTmpBuffer); sal_Int32 nCRC32 = aMemGrabber.ReadInt32(); sal_uInt32 nCompressedSize32 = aMemGrabber.ReadUInt32(); sal_uInt32 nSize32 = aMemGrabber.ReadUInt32(); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - package/source
package/source/zipapi/ZipFile.cxx |8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) New commits: commit 52f549cc523e6dcf27da5a3a1ee6be89c041bdda Author: Caolán McNamara Date: Tue Feb 6 21:21:30 2018 + MemoryByteGrabber sequence has to exist for Grabber lifetime it just takes a c++ ref, so a temp is an unsuitable arg Change-Id: I40490e94d977df91b985bc4ae458b68ee85d5dfe Reviewed-on: https://gerrit.libreoffice.org/49322 Tested-by: Jenkins Reviewed-by: Stephan Bergmann Reviewed-by: Michael Stahl diff --git a/package/source/zipapi/ZipFile.cxx b/package/source/zipapi/ZipFile.cxx index 1d10a56aaf9c..6e9351c69f1a 100644 --- a/package/source/zipapi/ZipFile.cxx +++ b/package/source/zipapi/ZipFile.cxx @@ -902,7 +902,7 @@ sal_Int32 ZipFile::readCEN() if ( static_cast < sal_Int64 > ( nCenLen ) != nRead ) throw ZipException ("Error reading CEN into memory buffer!" ); -MemoryByteGrabber aMemGrabber ( aCENBuffer ); +MemoryByteGrabber aMemGrabber(aCENBuffer); ZipEntry aEntry; sal_Int16 nCommentLen; @@ -1015,7 +1015,8 @@ void ZipFile::recover() if ( nPos < nBufSize - 30 && pBuffer[nPos] == 'P' && pBuffer[nPos+1] == 'K' && pBuffer[nPos+2] == 3 && pBuffer[nPos+3] == 4 ) { ZipEntry aEntry; -MemoryByteGrabber aMemGrabber ( Sequence< sal_Int8 >( &(pBuffer[nPos+4]), 26 ) ); +Sequence aTmpBuffer(&(pBuffer[nPos+4]), 26); +MemoryByteGrabber aMemGrabber(aTmpBuffer); aEntry.nVersion = aMemGrabber.ReadInt16(); if ( ( aEntry.nVersion & 1 ) != 1 ) @@ -1084,7 +1085,8 @@ void ZipFile::recover() else if (pBuffer[nPos] == 'P' && pBuffer[nPos+1] == 'K' && pBuffer[nPos+2] == 7 && pBuffer[nPos+3] == 8 ) { sal_Int64 nCompressedSize, nSize; -MemoryByteGrabber aMemGrabber ( Sequence< sal_Int8 >( &(pBuffer[nPos+4]), 12 ) ); +Sequence aTmpBuffer(&(pBuffer[nPos+4]), 12); +MemoryByteGrabber aMemGrabber(aTmpBuffer); sal_Int32 nCRC32 = aMemGrabber.ReadInt32(); sal_uInt32 nCompressedSize32 = aMemGrabber.ReadUInt32(); sal_uInt32 nSize32 = aMemGrabber.ReadUInt32(); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - writerfilter/source
writerfilter/source/dmapper/NumberingManager.cxx | 51 +-- 1 file changed, 30 insertions(+), 21 deletions(-) New commits: commit 8da5ac0dafda4aca5c221b165bfe65125ff30f17 Author: Caolán McNamara Date: Tue Feb 6 21:12:48 2018 + rtf: null-deref Change-Id: I9c4510cb91e2572a3ab2b62497dc4dd9fd1119c8 Reviewed-on: https://gerrit.libreoffice.org/49341 Tested-by: Jenkins Reviewed-by: Miklos Vajna diff --git a/writerfilter/source/dmapper/NumberingManager.cxx b/writerfilter/source/dmapper/NumberingManager.cxx index 273501e6ccc6..108ce7f5c2ce 100644 --- a/writerfilter/source/dmapper/NumberingManager.cxx +++ b/writerfilter/source/dmapper/NumberingManager.cxx @@ -871,6 +871,7 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) } break; case NS_ooxml::LN_CT_Lvl_lvlPicBulletId: +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { uno::Reference xShape; for (std::vector::iterator it = m_aNumPicBullets.begin(); it != m_aNumPicBullets.end(); ++it) @@ -887,15 +888,15 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) try { uno::Any aAny = xPropertySet->getPropertyValue("GraphicURL"); -if (aAny.has()) - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicURL(aAny.get()); +if (aAny.has() && pCurrentLevel) +pCurrentLevel->SetGraphicURL(aAny.get()); } catch(const beans::UnknownPropertyException&) {} try { uno::Reference< graphic::XGraphic > gr; xPropertySet->getPropertyValue("Bitmap") >>= gr; - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicBitmap( gr ); +pCurrentLevel->SetGraphicBitmap( gr ); } catch(const beans::UnknownPropertyException&) {} @@ -910,12 +911,12 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) int nWidth = (nHeight * aPrefSize.Width) / aPrefSize.Height; awt::Size aSize( convertMm100ToTwip(nWidth), convertMm100ToTwip(nHeight) ); - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicSize( aSize ); +pCurrentLevel->SetGraphicSize( aSize ); } else { awt::Size aSize( convertMm100ToTwip(aPrefSize.Width), convertMm100ToTwip(aPrefSize.Height) ); - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicSize( aSize ); +pCurrentLevel->SetGraphicSize( aSize ); } } } @@ -946,26 +947,26 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) } break; case NS_ooxml::LN_CT_Lvl_start: -if (m_pCurrentDefinition->GetCurrentLevel().get()) -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( nSprmId, nIntValue ); +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) +pCurrentLevel->SetValue( nSprmId, nIntValue ); bIsStartVisited = true; break; case NS_ooxml::LN_CT_Lvl_numFmt: case NS_ooxml::LN_CT_Lvl_isLgl: case NS_ooxml::LN_CT_Lvl_legacy: -if (m_pCurrentDefinition->GetCurrentLevel().get()) +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( nSprmId, nIntValue ); +pCurrentLevel->SetValue( nSprmId, nIntValue ); if( !bIsStartVisited ) { -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( NS_ooxml::LN_CT_Lvl_start, 0 ); +pCurrentLevel->SetValue( NS_ooxml::LN_CT_Lvl_start, 0 ); bIsStartVisited = true; } } break; case NS_ooxml::LN_CT_Lvl_suff: { -if (m_pCurrentDefinition->GetCurrentLevel().get()) +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { SvxNumberFormat::LabelFollowedBy value = SvxNumberFormat::LISTTAB; if( rSprm.getValue()->getString() == "tab" ) @@ -977,7 +978,7 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) else SAL_WARN( "writerfilter", "Unknown ST_LevelSuffix value " << rSprm.getValue()->getString()); -m_pC
[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - writerfilter/source
writerfilter/source/dmapper/NumberingManager.cxx | 51 +-- 1 file changed, 30 insertions(+), 21 deletions(-) New commits: commit 437af3bf0bea4f9dd5d7a555deb631d2e4e42597 Author: Caolán McNamara Date: Tue Feb 6 21:12:48 2018 + rtf: null-deref Change-Id: I9c4510cb91e2572a3ab2b62497dc4dd9fd1119c8 Reviewed-on: https://gerrit.libreoffice.org/49342 Tested-by: Jenkins Reviewed-by: Miklos Vajna diff --git a/writerfilter/source/dmapper/NumberingManager.cxx b/writerfilter/source/dmapper/NumberingManager.cxx index d608fac48c68..e5295f80b1ee 100644 --- a/writerfilter/source/dmapper/NumberingManager.cxx +++ b/writerfilter/source/dmapper/NumberingManager.cxx @@ -869,6 +869,7 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) } break; case NS_ooxml::LN_CT_Lvl_lvlPicBulletId: +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { uno::Reference xShape; for (std::vector::iterator it = m_aNumPicBullets.begin(); it != m_aNumPicBullets.end(); ++it) @@ -885,15 +886,15 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) try { uno::Any aAny = xPropertySet->getPropertyValue("GraphicURL"); -if (aAny.has()) - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicURL(aAny.get()); +if (aAny.has() && pCurrentLevel) +pCurrentLevel->SetGraphicURL(aAny.get()); } catch(const beans::UnknownPropertyException&) {} try { uno::Reference< graphic::XGraphic > gr; xPropertySet->getPropertyValue("Bitmap") >>= gr; - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicBitmap( gr ); +pCurrentLevel->SetGraphicBitmap( gr ); } catch(const beans::UnknownPropertyException&) {} @@ -908,12 +909,12 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) int nWidth = (nHeight * aPrefSize.Width) / aPrefSize.Height; awt::Size aSize( convertMm100ToTwip(nWidth), convertMm100ToTwip(nHeight) ); - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicSize( aSize ); +pCurrentLevel->SetGraphicSize( aSize ); } else { awt::Size aSize( convertMm100ToTwip(aPrefSize.Width), convertMm100ToTwip(aPrefSize.Height) ); - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicSize( aSize ); +pCurrentLevel->SetGraphicSize( aSize ); } } } @@ -944,26 +945,26 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) } break; case NS_ooxml::LN_CT_Lvl_start: -if (m_pCurrentDefinition->GetCurrentLevel().get()) -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( nSprmId, nIntValue ); +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) +pCurrentLevel->SetValue( nSprmId, nIntValue ); bIsStartVisited = true; break; case NS_ooxml::LN_CT_Lvl_numFmt: case NS_ooxml::LN_CT_Lvl_isLgl: case NS_ooxml::LN_CT_Lvl_legacy: -if (m_pCurrentDefinition->GetCurrentLevel().get()) +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( nSprmId, nIntValue ); +pCurrentLevel->SetValue( nSprmId, nIntValue ); if( !bIsStartVisited ) { -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( NS_ooxml::LN_CT_Lvl_start, 0 ); +pCurrentLevel->SetValue( NS_ooxml::LN_CT_Lvl_start, 0 ); bIsStartVisited = true; } } break; case NS_ooxml::LN_CT_Lvl_suff: { -if (m_pCurrentDefinition->GetCurrentLevel().get()) +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { SvxNumberFormat::LabelFollowedBy value = SvxNumberFormat::LISTTAB; if( rSprm.getValue()->getString() == "tab" ) @@ -975,7 +976,7 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) else SAL_WARN( "writerfilter", "Unknown ST_LevelSuffix value " << rSprm.getValue()->getString()); -m_pC
[Libreoffice-commits] core.git: vcl/README
vcl/README | 16 +++- 1 file changed, 11 insertions(+), 5 deletions(-) New commits: commit 6394c89fbb07713ce04608ffd031f91a890bb853 Author: Michael Stahl Date: Wed Feb 7 13:51:05 2018 +0100 vcl: adapt README to reality diff --git a/vcl/README b/vcl/README index b122e8218410..d7d36044630a 100644 --- a/vcl/README +++ b/vcl/README @@ -26,22 +26,28 @@ quartz/ win/ + Windows backend +qt5/ + + Qt5 (under construction) + unx/ + X11 backend and its sub-platforms - plugadapt/ - + pluggable framework to select correct unx backend gtk/ + GTK2 support gtk3/ - + GTK3.2+ support - kde/ - + KDE3 support + + GTK3 support kde4/ + KDE4 support + kde5/ + + KDE5 support (under construction) + gtk3_kde5/ + + GTK3 support with KDE5 file pickers (until kde5 is finished) generic/ + raw X11 support + plugadapt/ + + pluggable framework to select correct unx backend + dtrans/ + "data transfer" - clipboard handling + http://stackoverflow.com/questions/3261379/getting-html-source-or-rich-text-from-the-x-clipboard ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: sw/source
sw/source/core/doc/tblrwcl.cxx |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit e5e201c87e3f7a3f0a0b6595cd235b697a310705 Author: Miklos Vajna Date: Wed Feb 7 14:04:25 2018 +0100 Revert "sw android: fix -Werror,-Wsign-compare" This helped Android, looked innocent, but breaks other platforms. It is necessary to find out later how to address this while keeping everyone else happy as well. This reverts commit b64bf854909ce72fa6ea2db05c3aef8995cf32d6. diff --git a/sw/source/core/doc/tblrwcl.cxx b/sw/source/core/doc/tblrwcl.cxx index 500791920e84..889aea171ce1 100644 --- a/sw/source/core/doc/tblrwcl.cxx +++ b/sw/source/core/doc/tblrwcl.cxx @@ -3435,7 +3435,7 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, TableChgWidthHeightType eType, if( GetFrameFormat()->getIDocumentSettingAccess().get(DocumentSettingId::BROWSE_MODE) && !rSz.GetWidthPercent() ) { -bRet = static_cast(rSz.GetWidth()) < USHRT_MAX - nRelDiff; +bRet = rSz.GetWidth() < USHRT_MAX - nRelDiff; bChgLRSpace = bLeft ? rLR.GetLeft() >= nAbsDiff : rLR.GetRight() >= nAbsDiff; } @@ -3506,7 +3506,7 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, TableChgWidthHeightType eType, if( bBigger ) { // If the Table does not have any room to grow, we need to create some! -if( static_cast(aSz.GetWidth()) + nRelDiff > USHRT_MAX ) +if( aSz.GetWidth() + nRelDiff > USHRT_MAX ) { // Break down to USHRT_MAX / 2 CR_SetBoxWidth aTmpPara( TableChgWidthHeightType::ColLeft, aSz.GetWidth() / 2, ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: sc/source
sc/source/ui/view/cellsh1.cxx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 915ed57850aae12aed96bc66164bb15a6131f0f8 Author: Marco Cecchetti Date: Sun Feb 4 17:26:54 2018 +0100 lok: calc: grouping - workaround no more needed Now the dialog for selecting row/column group works fine Change-Id: I88660e8f49cf41ae45926a1d7299b1370bf54b93 Reviewed-on: https://gerrit.libreoffice.org/49206 Tested-by: Jenkins Reviewed-by: Marco Cecchetti diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx index eb1f270ce73a..99227a5dbd7f 100644 --- a/sc/source/ui/view/cellsh1.cxx +++ b/sc/source/ui/view/cellsh1.cxx @@ -1174,7 +1174,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) bColumns = true; else if ( !GetViewData()->SimpleColMarked() && GetViewData()->SimpleRowMarked() ) bColumns = false; -else if ( !comphelper::LibreOfficeKit::isActive() ) // TODO: handle this case in LOK too +else { ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); OSL_ENSURE(pFact, "ScAbstractFactory create fail!"); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.3' - sc/source
sc/source/ui/view/cellsh1.cxx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit a2277fddf3495ee75236b8ac167ec8cef0440cce Author: Marco Cecchetti Date: Sun Feb 4 17:26:54 2018 +0100 lok: calc: grouping - workaround no more needed Now the dialog for selecting row/column group works fine Change-Id: I88660e8f49cf41ae45926a1d7299b1370bf54b93 Reviewed-on: https://gerrit.libreoffice.org/49212 Reviewed-by: Marco Cecchetti Tested-by: Marco Cecchetti diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx index bbce79c3564a..e8a5fecaf609 100644 --- a/sc/source/ui/view/cellsh1.cxx +++ b/sc/source/ui/view/cellsh1.cxx @@ -1169,7 +1169,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) bColumns = true; else if ( !GetViewData()->SimpleColMarked() && GetViewData()->SimpleRowMarked() ) bColumns = false; -else if ( !comphelper::LibreOfficeKit::isActive() ) // TODO: handle this case in LOK too +else { ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); OSL_ENSURE(pFact, "ScAbstractFactory create fail!"); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - sysui/desktop
sysui/desktop/apparmor/program.soffice.bin |5 - 1 file changed, 4 insertions(+), 1 deletion(-) New commits: commit 36aeb9c7a361e37433b6db280eac99eb5ab93891 Author: Rene Engelhard Date: Sun Jan 21 14:48:02 2018 +0100 apparmor: fix @{HOME}/.mozilla/firefox access for XML signing the #include bringing "audit deny @{HOME}/.mozilla/** mrwkl," in actually denies everything here. Use just and allow profiles.ini, secmod.db and cert8.db. At least opening the Digital Signatures dialog doesn't log apparmor DENIED now... Change-Id: Id557626fc26745841f0cca005d483fd1e6ac922d Reviewed-on: https://gerrit.libreoffice.org/48264 Tested-by: Jenkins Reviewed-by: Michael Stahl Reviewed-on: https://gerrit.libreoffice.org/49253 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/sysui/desktop/apparmor/program.soffice.bin b/sysui/desktop/apparmor/program.soffice.bin index 84c4d543c48d..74320a6ff5ee 100644 --- a/sysui/desktop/apparmor/program.soffice.bin +++ b/sysui/desktop/apparmor/program.soffice.bin @@ -63,7 +63,7 @@ #include profile libreoffice-soffice INSTDIR-program/soffice.bin { - #include + #include #include #include @@ -165,6 +165,9 @@ profile libreoffice-soffice INSTDIR-program/soffice.bin { /usr/share/*-fonts/conf.avail/*.conf r, /usr/share/fonts-config/conf.avail/*.conf r, + owner @{HOME}/.mozilla/firefox/profiles.ini r, + owner @{HOME}/.mozilla/firefox/*/secmod.db r, + owner @{HOME}/.mozilla/firefox/*/cert8.db r, # there is abstractions/gnupg but that's just for gpg1... profile gpg { #include ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - sw/qa
sw/qa/extras/ww8export/ww8export.cxx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 315f452229ab8c0eb1c8a5964ed7108c877d6f13 Author: Michael Stahl Date: Mon Feb 5 16:53:03 2018 +0100 sw: disable testTableKeep on WNT Fails from time to time, like so: https://tinderbox.libreoffice.org/cgi-bin/gunzip.cgi?tree=MASTER&brief-log=1517842001.29090#err2 Change-Id: Ia33193fbfa05da58d31bcc5008beea32c1feb2fe (cherry picked from commit b2a053160c4c8eb0acd66b74c52dbda23a654bda) Reviewed-on: https://gerrit.libreoffice.org/49288 Tested-by: Jenkins Reviewed-by: Noel Grandin Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/sw/qa/extras/ww8export/ww8export.cxx b/sw/qa/extras/ww8export/ww8export.cxx index 825ba6be7cf0..bcbaad089c59 100644 --- a/sw/qa/extras/ww8export/ww8export.cxx +++ b/sw/qa/extras/ww8export/ww8export.cxx @@ -1295,7 +1295,7 @@ DECLARE_WW8EXPORT_TEST(testCommentExport, "comment-export.odt") } } -#if !defined(MACOSX) +#if !defined(MACOSX) && !defined(_WIN32) #if !TEST_FONTS_MISSING DECLARE_WW8EXPORT_TEST(testTableKeep, "tdf91083.odt") { ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - sw/qa
sw/qa/extras/ww8export/ww8export.cxx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 5e2680ebda010ac3f10e2e972e68b831c12c1e93 Author: Michael Stahl Date: Mon Feb 5 16:53:03 2018 +0100 sw: disable testTableKeep on WNT Fails from time to time, like so: https://tinderbox.libreoffice.org/cgi-bin/gunzip.cgi?tree=MASTER&brief-log=1517842001.29090#err2 Change-Id: Ia33193fbfa05da58d31bcc5008beea32c1feb2fe (cherry picked from commit b2a053160c4c8eb0acd66b74c52dbda23a654bda) Reviewed-on: https://gerrit.libreoffice.org/49289 Tested-by: Jenkins Reviewed-by: Noel Grandin Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/sw/qa/extras/ww8export/ww8export.cxx b/sw/qa/extras/ww8export/ww8export.cxx index ebb49f6ae2d1..a7079660be73 100644 --- a/sw/qa/extras/ww8export/ww8export.cxx +++ b/sw/qa/extras/ww8export/ww8export.cxx @@ -1273,7 +1273,7 @@ DECLARE_WW8EXPORT_TEST(testCommentExport, "comment-export.odt") } } -#if !defined(MACOSX) +#if !defined(MACOSX) && !defined(_WIN32) #if !TEST_FONTS_MISSING DECLARE_WW8EXPORT_TEST(testTableKeep, "tdf91083.odt") { ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: svx/source
svx/source/inc/svdoutlinercache.hxx|5 +++-- svx/source/svdraw/svdoutlinercache.cxx | 21 - 2 files changed, 7 insertions(+), 19 deletions(-) New commits: commit ef83e5fba10187a0ec50dab6d381ff2d4ecdc5d2 Author: Noel Grandin Date: Mon Feb 5 11:23:35 2018 +0200 loplugin:useuniqueptr in SdrOutlinerCache Change-Id: Ie34f1bd9e46bf767ec2e1918c2b88cf289f4b410 Reviewed-on: https://gerrit.libreoffice.org/49330 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/svx/source/inc/svdoutlinercache.hxx b/svx/source/inc/svdoutlinercache.hxx index f3aa9ec43107..30f5c6699e11 100644 --- a/svx/source/inc/svdoutlinercache.hxx +++ b/svx/source/inc/svdoutlinercache.hxx @@ -21,6 +21,7 @@ #define INCLUDED_SVX_SOURCE_INC_SVDOUTLINERCACHE_HXX #include +#include #include #include @@ -32,8 +33,8 @@ class SdrOutlinerCache { private: SdrModel*mpModel; -std::vector< SdrOutliner* > maModeOutline; -std::vector< SdrOutliner* > maModeText; +std::vector< std::unique_ptr > maModeOutline; +std::vector< std::unique_ptr > maModeText; std::set< SdrOutliner* > maActiveOutliners; public: diff --git a/svx/source/svdraw/svdoutlinercache.cxx b/svx/source/svdraw/svdoutlinercache.cxx index bd95f359fe1a..419837070d4f 100644 --- a/svx/source/svdraw/svdoutlinercache.cxx +++ b/svx/source/svdraw/svdoutlinercache.cxx @@ -36,12 +36,12 @@ SdrOutliner* SdrOutlinerCache::createOutliner( OutlinerMode nOutlinerMode ) if( (OutlinerMode::OutlineObject == nOutlinerMode) && !maModeOutline.empty() ) { -pOutliner = maModeOutline.back(); +pOutliner = maModeOutline.back().release(); maModeOutline.pop_back(); } else if( (OutlinerMode::TextObject == nOutlinerMode) && !maModeText.empty() ) { -pOutliner = maModeText.back(); +pOutliner = maModeText.back().release(); maModeText.pop_back(); } else @@ -57,19 +57,6 @@ SdrOutliner* SdrOutlinerCache::createOutliner( OutlinerMode nOutlinerMode ) SdrOutlinerCache::~SdrOutlinerCache() { -for( auto candA : maModeOutline ) -{ -delete candA; -} - -maModeOutline.clear(); - -for( auto candB : maModeText ) -{ -delete candB; -} - -maModeText.clear(); } void SdrOutlinerCache::disposeOutliner( SdrOutliner* pOutliner ) @@ -80,7 +67,7 @@ void SdrOutlinerCache::disposeOutliner( SdrOutliner* pOutliner ) if( OutlinerMode::OutlineObject == nOutlMode ) { -maModeOutline.push_back(pOutliner); +maModeOutline.emplace_back(pOutliner); pOutliner->Clear(); pOutliner->SetVertical( false ); @@ -89,7 +76,7 @@ void SdrOutlinerCache::disposeOutliner( SdrOutliner* pOutliner ) } else if( OutlinerMode::TextObject == nOutlMode ) { -maModeText.push_back(pOutliner); +maModeText.emplace_back(pOutliner); pOutliner->Clear(); pOutliner->SetVertical( false ); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: solenv/bin
solenv/bin/native-code.py |4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) New commits: commit 420d2c48bc2afc262d04d20ecab90517d07f3aa8 Author: Miklos Vajna Date: Wed Feb 7 12:58:15 2018 +0100 solenv: adapt native-code.py to recent xmlsecurity changes /tmp/native-code-95f2b3.o:native-code.cxx:lo_get_factory_map::map: error: undefined reference to 'xmlsecurity_component_getFactory' clang++: error: linker command failed with exit code 1 (use -v to see invocation) ../Bootstrap/Makefile.shared:61: recipe for target 'obj/local/armeabi-v7a/liblo-native-code.so' failed make[2]: *** [obj/local/armeabi-v7a/liblo-native-code.so] Error 1 /home/vmiklos/git/libreoffice/master-android/android/CustomTarget_lo_android.mk:17: recipe for target '/home/vmiklos/git/libreoffice/master-android/workdir/CustomTarget/android/source/done' failed Change-Id: Idd63986122216c0fb1822ea7a3fbec00d00b444b diff --git a/solenv/bin/native-code.py b/solenv/bin/native-code.py index 0cab8a26e096..8499a94e13e9 100755 --- a/solenv/bin/native-code.py +++ b/solenv/bin/native-code.py @@ -48,7 +48,6 @@ core_factory_list = [ ("libunordflo.a", "unordf_component_getFactory"), ("libunoxmllo.a", "unoxml_component_getFactory"), ("libutllo.a", "utl_component_getFactory"), -("libxmlsecurity.a", "xmlsecurity_component_getFactory", "#if HAVE_FEATURE_NSS"), ("libxoflo.a", "xof_component_getFactory"), ("libxolo.a", "xo_component_getFactory"), ("libxsec_xmlsec.a", "xsec_xmlsec_component_getFactory", "#if HAVE_FEATURE_NSS"), @@ -242,6 +241,9 @@ core_constructor_list = [ "com_sun_star_comp_xmlscript_XMLBasicImporter", "com_sun_star_comp_xmlscript_XMLOasisBasicExporter", "com_sun_star_comp_xmlscript_XMLOasisBasicImporter", +# xmlsecurity/util/xmlsecurity.component +"com_sun_star_security_CertificateContainer_get_implementation", +"com_sun_star_security_DocumentDigitalSignatures_get_implementation", ] # edit group for apps, where you can edit documents ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: sw/source
sw/source/core/doc/tblrwcl.cxx |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit b64bf854909ce72fa6ea2db05c3aef8995cf32d6 Author: Miklos Vajna Date: Wed Feb 7 12:18:07 2018 +0100 sw android: fix -Werror,-Wsign-compare Change-Id: If30b939685aa3dfc79707f0d7d65b92a43a1cd03 diff --git a/sw/source/core/doc/tblrwcl.cxx b/sw/source/core/doc/tblrwcl.cxx index 889aea171ce1..500791920e84 100644 --- a/sw/source/core/doc/tblrwcl.cxx +++ b/sw/source/core/doc/tblrwcl.cxx @@ -3435,7 +3435,7 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, TableChgWidthHeightType eType, if( GetFrameFormat()->getIDocumentSettingAccess().get(DocumentSettingId::BROWSE_MODE) && !rSz.GetWidthPercent() ) { -bRet = rSz.GetWidth() < USHRT_MAX - nRelDiff; +bRet = static_cast(rSz.GetWidth()) < USHRT_MAX - nRelDiff; bChgLRSpace = bLeft ? rLR.GetLeft() >= nAbsDiff : rLR.GetRight() >= nAbsDiff; } @@ -3506,7 +3506,7 @@ bool SwTable::SetColWidth( SwTableBox& rAktBox, TableChgWidthHeightType eType, if( bBigger ) { // If the Table does not have any room to grow, we need to create some! -if( aSz.GetWidth() + nRelDiff > USHRT_MAX ) +if( static_cast(aSz.GetWidth()) + nRelDiff > USHRT_MAX ) { // Break down to USHRT_MAX / 2 CR_SetBoxWidth aTmpPara( TableChgWidthHeightType::ColLeft, aSz.GetWidth() / 2, ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
Re: Help needed for GSoC 2018 preparation
Hi, On Sun, Jan 28, 2018 at 1:53 PM, Saurav Chirania wrote: > > 1) Where can I find the manual UI tests (The given link, > https://manual-test.libreoffice.org/ , requires some log in details, which I > don’t have) See https://wiki.documentfoundation.org/TestLink for some info about the system we use. It already uses our sso setup, so you need to create an account at https://user.documentfoundation.org and can then use those credentials to login to testlink. ciao Christian ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice-commits] core.git: Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5
Hi, On Wed, Feb 07, 2018 at 09:57:46AM +0100, Stephan Bergmann wrote: > On 07.02.2018 09:33, Stephan Bergmann wrote: > > commit bf23fe3a4a3eebe3d08fa26341a486b83d80c1c7 > > Author: Stephan Bergmann > > Date: Wed Feb 7 09:11:35 2018 +0100 > > > > Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5 > > The dependency of Library_vcl on qt5 libraries (via > > vcl/qt5/Qt5Font.cxx) is > > there ever since b66a7cbd8491fe436126e11975c360f47ae346ed "QT5 first > > stab on > > implementing CommonSalLayout", but no idea whether that is by design > > or is a > > hack that should eventually be cleaned up. > > Any thoughts on the above? It might e.g. by undesirable for distros that do > --enable-qt5 but split libvclplug_qt5lo.so into a Qt5-dependent package of > its own (and don't want the base vcl package to depend on Qt5). Yes, I already "complained" about this, jmux had a look/wanted to have a look. This is a blocker for me enabling qt5. I am so not making -core depending on qt5. (Or I unmerge it and do some dpkg-divert hacks. That is awful and error-prone, though and doesn't scale...) Regards, Rene ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] core.git: sc/source
sc/source/ui/vba/vbaglobals.cxx | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) New commits: commit 403d52a66085db8109024bfe07f2bfc2c4ccdc03 Author: Tor Lillqvist Date: Wed Feb 7 00:58:08 2018 +0200 Don't crash if aArgs is empty Change-Id: I6a6495ab5729bc45a0049fcbab884752267570be Reviewed-on: https://gerrit.libreoffice.org/49336 Tested-by: Jenkins Reviewed-by: Tor Lillqvist diff --git a/sc/source/ui/vba/vbaglobals.cxx b/sc/source/ui/vba/vbaglobals.cxx index 189fe708f2f0..c4636c7bf1f0 100644 --- a/sc/source/ui/vba/vbaglobals.cxx +++ b/sc/source/ui/vba/vbaglobals.cxx @@ -40,12 +40,14 @@ using namespace ::ooo::vba; ScVbaGlobals::ScVbaGlobals( uno::Sequence< uno::Any > const& aArgs, uno::Reference< uno::XComponentContext >const& rxContext ) : ScVbaGlobals_BASE( uno::Reference< XHelperInterface >(), rxContext, "ExcelDocumentContext" ) { -uno::Sequence< beans::PropertyValue > aInitArgs( 2 ); +uno::Sequence< beans::PropertyValue > aInitArgs( aArgs.getLength() + 1 ); aInitArgs[ 0 ].Name = "Application"; aInitArgs[ 0 ].Value <<= getApplication(); -aInitArgs[ 1 ].Name = "ExcelDocumentContext"; -aInitArgs[ 1 ].Value <<= getXSomethingFromArgs< frame::XModel >( aArgs, 0 ); - +if ( aArgs.getLength() > 0 ) +{ +aInitArgs[ 1 ].Name = "ExcelDocumentContext"; +aInitArgs[ 1 ].Value <<= getXSomethingFromArgs< frame::XModel >( aArgs, 0 ); +} init( aInitArgs ); } ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: avmedia/source include/vcl vcl/source
avmedia/source/gstreamer/gstframegrabber.cxx |5 +-- include/vcl/BitmapTools.hxx | 11 include/vcl/bitmap.hxx | 10 --- vcl/source/bitmap/BitmapTools.cxx| 34 +++ vcl/source/gdi/bitmap4.cxx | 26 5 files changed, 47 insertions(+), 39 deletions(-) New commits: commit e1d1bce72be34eb7ea4e3c72642736b378388c98 Author: Noel Grandin Date: Tue Feb 6 12:00:16 2018 +0200 move Bitmap::SetToData to BitmapTools Change-Id: I0fc62d29d2044c2aa8af3742d4aeb9d782793713 Reviewed-on: https://gerrit.libreoffice.org/49280 Reviewed-by: Tomaž Vajngerl Tested-by: Tomaž Vajngerl diff --git a/avmedia/source/gstreamer/gstframegrabber.cxx b/avmedia/source/gstreamer/gstframegrabber.cxx index 60aed4206ac1..def1018baeed 100644 --- a/avmedia/source/gstreamer/gstframegrabber.cxx +++ b/avmedia/source/gstreamer/gstframegrabber.cxx @@ -27,7 +27,7 @@ #include #include -#include +#include #include @@ -173,8 +173,7 @@ uno::Reference< graphic::XGraphic > SAL_CALL FrameGrabber::grabFrame( double fMe #endif int nStride = GST_ROUND_UP_4( nWidth * 3 ); -Bitmap aBmp( Size( nWidth, nHeight ), 24 ); -aBmp.SetToData( pData, nStride ); +BitmapEx aBmp = vcl::bitmap::CreateFromData(pData, nWidth, nHeight, nStride, 24 ); #ifndef AVMEDIA_GST_0_10 gst_buffer_unmap( pBuf, &aMapInfo ); diff --git a/include/vcl/BitmapTools.hxx b/include/vcl/BitmapTools.hxx index 3517a9d0dd5c..ed448dfa0e1c 100644 --- a/include/vcl/BitmapTools.hxx +++ b/include/vcl/BitmapTools.hxx @@ -22,6 +22,17 @@ BitmapEx VCL_DLLPUBLIC loadFromName(const OUString& rFileName, const ImageLoadFl void loadFromSvg(SvStream& rStream, const OUString& sPath, BitmapEx& rBitmapEx, double fScaleFactor); +/** Copy block of image data into the bitmap. +Assumes that the Bitmap has been constructed with the desired size. + +@param pData +The block of data to copy +@param nStride +The number of bytes in a scanline, must >= width +*/ +BitmapEx VCL_DLLPUBLIC CreateFromData( sal_uInt8 const *pData, sal_Int32 nWidth, sal_Int32 nHeight, sal_Int32 nStride, sal_uInt16 nBitCount ); + + }} // end vcl::bitmap #endif // INCLUDED_VCL_BITMAP_TOOLS_HXX diff --git a/include/vcl/bitmap.hxx b/include/vcl/bitmap.hxx index 04cc0cbca83d..2f74b71dd7b3 100644 --- a/include/vcl/bitmap.hxx +++ b/include/vcl/bitmap.hxx @@ -650,16 +650,6 @@ public: BmpFilter eFilter, const BmpFilterParam* pFilterParam = nullptr ); -/** Copy block of image data into the bitmap. -Assumes that the Bitmap has been constructed with the desired size. - -@param pData -The block of data to copy -@param nStride -The number of bytes in a scanline, must >= width - */ -voidSetToData( sal_uInt8 const *pData, sal_Int32 nStride ); - public: SAL_DLLPRIVATE void ImplMakeUnique(); diff --git a/vcl/source/bitmap/BitmapTools.cxx b/vcl/source/bitmap/BitmapTools.cxx index f0aa8ccecf33..94974f57746d 100644 --- a/vcl/source/bitmap/BitmapTools.cxx +++ b/vcl/source/bitmap/BitmapTools.cxx @@ -24,6 +24,8 @@ #include #include #include +#include +#include using namespace css; @@ -101,6 +103,38 @@ void loadFromSvg(SvStream& rStream, const OUString& sPath, BitmapEx& rBitmapEx, } +/** Copy block of image data into the bitmap. +Assumes that the Bitmap has been constructed with the desired size. + +@param pData +The block of data to copy +@param nStride +The number of bytes in a scanline, must >= width +*/ +BitmapEx CreateFromData( sal_uInt8 const *pData, sal_Int32 nWidth, sal_Int32 nHeight, sal_Int32 nStride, sal_uInt16 nBitCount ) +{ +assert(nStride >= nWidth); +Bitmap aBmp( Size( nWidth, nHeight ), nBitCount ); + +Bitmap::ScopedWriteAccess pWrite(aBmp); +assert(pWrite.get()); +if( pWrite.get() ) +{ +for( long y = 0; y < nHeight; ++y ) +{ +sal_uInt8 const *p = pData + y * nStride; +Scanline pScanline = pWrite->GetScanline(y); +for (long x = 0; x < nWidth; ++x) +{ +BitmapColor col(p[0], p[1], p[2]); +pWrite->SetPixelOnData(pScanline, x, col); +p += 3; +} +} +} +return aBmp; +} + }} // end vcl::bitmap /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/source/gdi/bitmap4.cxx b/vcl/source/gdi/bitmap4.cxx index f71f48f31bbf..118fdf8916c4 100644 --- a/vcl/source/gdi/bitmap4.cxx +++ b/vcl/source/gdi/bitmap4.cxx @@ -112,32 +112,6 @@ bool Bitmap::Filter( BmpFilter eFilter, const BmpFilterParam* pFilterParam ) return bRet; } -void Bitmap::SetToData( sal_uInt8 const *pData, sal_Int32 nStride ) -{ -assert(mxImpBmp); -auto nWidth = mxImpBmp->Im
[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - cui/source
cui/source/tabpages/border.cxx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 01f19aba638860db54ca9a60e30ce6f21ee0ea5a Author: Caolán McNamara Date: Fri Feb 2 21:12:31 2018 + Resolves: tdf#115369 wrong cell shadow icons regression from... commit 910f91a3e5228f26f0692f870a3fd3919835eb27 Author: Caolán McNamara Date: Wed Dec 21 13:04:30 2016 + unwind IL_SDW_BITMAPS ImageList Change-Id: I9ecb5c45c240af0214666c56401abb07eb99e5f1 Reviewed-on: https://gerrit.libreoffice.org/49168 Tested-by: Jenkins Reviewed-by: Katarina Behrens diff --git a/cui/source/tabpages/border.cxx b/cui/source/tabpages/border.cxx index 1e5c5937d326..03a8c9acb0b2 100644 --- a/cui/source/tabpages/border.cxx +++ b/cui/source/tabpages/border.cxx @@ -169,8 +169,8 @@ SvxBorderTabPage::SvxBorderTabPage(vcl::Window* pParent, const SfxItemSet& rCore { RID_SVXBMP_SHADOWNONE, RID_SVXBMP_SHADOW_BOT_RIGHT, -RID_SVXBMP_SHADOW_BOT_LEFT, RID_SVXBMP_SHADOW_TOP_RIGHT, +RID_SVXBMP_SHADOW_BOT_LEFT, RID_SVXBMP_SHADOW_TOP_LEFT }; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - sw/source
sw/source/core/layout/tabfrm.cxx | 18 -- 1 file changed, 12 insertions(+), 6 deletions(-) New commits: commit f00070deee9ff550d6ee370eae1402af71928265 Author: Manfred Blume Date: Wed Jan 31 16:37:55 2018 +0100 tdf#114306 fix crash caused by special document 2 Regression from 18765b9fa739337d2d891513f6e2fb7c3ce23b50 Change-Id: Ic4205777077e4e3d93bdddf743c51abba8950eaf Reviewed-on: https://gerrit.libreoffice.org/49031 Tested-by: Jenkins Reviewed-by: Thorsten Behrens (cherry picked from commit d30eefb677b446886f7b5bab6de93d489ba63529) Reviewed-on: https://gerrit.libreoffice.org/49310 Reviewed-by: Katarina Behrens diff --git a/sw/source/core/layout/tabfrm.cxx b/sw/source/core/layout/tabfrm.cxx old mode 100644 new mode 100755 index ca245b65599d..911ab3380da2 --- a/sw/source/core/layout/tabfrm.cxx +++ b/sw/source/core/layout/tabfrm.cxx @@ -173,7 +173,7 @@ void SwTabFrame::RegistFlys() } void SwInvalidateAll( SwFrame *pFrame, long nBottom ); -static void lcl_RecalcRow( SwRowFrame* pRow, long nBottom ); +static bool lcl_RecalcRow( SwRowFrame* pRow, long nBottom ); static bool lcl_ArrangeLowers( SwLayoutFrame *pLay, long lYStart, bool bInva ); // #i26945# - add parameter <_bOnlyRowsAndCells> to control // that only row and cell frames are formatted. @@ -1565,7 +1565,8 @@ static bool lcl_InnerCalcLayout( SwFrame *pFrame, return bRet; } -static void lcl_RecalcRow( SwRowFrame* pRow, long nBottom ) +// returns false if pRow is invalid +static bool lcl_RecalcRow( SwRowFrame* pRow, long nBottom ) { // FME 2007-08-30 #i81146# new loop control int nLoopControlRuns_1 = 0; @@ -1623,7 +1624,7 @@ static void lcl_RecalcRow( SwRowFrame* pRow, long nBottom ) if (!bRowStillExists) { SAL_WARN("sw.layout", "no row anymore at " << pRow); -return; +return false; } // NEW TABLES @@ -1667,7 +1668,8 @@ static void lcl_RecalcRow( SwRowFrame* pRow, long nBottom ) } } break; -} while( true ); +} while (true); +return true; } static void lcl_RecalcTable( SwTabFrame& rTab, @@ -2354,7 +2356,7 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext) // 1. Try: bTryToSplit = true => Try to split the row. // 2. Try: bTryToSplit = false => Split the table between the rows. -if ( pFirstNonHeadlineRow->GetNext() || bTryToSplit ) +if ((pFirstNonHeadlineRow && pFirstNonHeadlineRow->GetNext()) || bTryToSplit ) { SwTwips nDeadLine = aRectFnSet.GetPrtBottom(*GetUpper()); if( IsInSct() || GetUpper()->IsInTab() ) // TABLE IN TABLE) @@ -2363,7 +2365,11 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext) { SetInRecalcLowerRow( true ); -::lcl_RecalcRow( static_cast(Lower()), nDeadLine ); +SwRowFrame* pRow = static_cast(Lower()); +if (!lcl_RecalcRow(pRow, nDeadLine)) +{ +pFirstNonHeadlineRow = GetFirstNonHeadlineRow(); +} SetInRecalcLowerRow( false ); } m_bLowersFormatted = true; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: sd/qa sd/source
sd/qa/unit/export-tests-ooxml2.cxx | 36 +++ sd/source/filter/eppt/pptx-epptooxml.cxx | 150 ++- 2 files changed, 145 insertions(+), 41 deletions(-) New commits: commit fa85592c0efba65f4a1b09fea950ec1c311bdd4c Author: Szymon Kłos Date: Mon Feb 5 12:41:58 2018 +0100 tdf#115394 export custom transition time in PPTX Change-Id: Ib8f4cef713895029dc18f68a07baa4b65e4260c0 Reviewed-on: https://gerrit.libreoffice.org/49245 Tested-by: Jenkins Reviewed-by: Szymon Kłos diff --git a/sd/qa/unit/export-tests-ooxml2.cxx b/sd/qa/unit/export-tests-ooxml2.cxx index b530790b038a..6b2f34f49a05 100644 --- a/sd/qa/unit/export-tests-ooxml2.cxx +++ b/sd/qa/unit/export-tests-ooxml2.cxx @@ -128,6 +128,7 @@ public: void testTdf90626(); void testTdf107608(); void testTdf111786(); +void testTdf115394(); CPPUNIT_TEST_SUITE(SdOOXMLExportTest2); @@ -181,6 +182,7 @@ public: CPPUNIT_TEST(testTdf90626); CPPUNIT_TEST(testTdf107608); CPPUNIT_TEST(testTdf111786); +CPPUNIT_TEST(testTdf115394); CPPUNIT_TEST_SUITE_END(); @@ -1402,6 +1404,40 @@ void SdOOXMLExportTest2::testTdf111786() xDocShRef->DoClose(); } +void SdOOXMLExportTest2::testTdf115394() +{ +sd::DrawDocShellRef xDocShRef = loadURL(m_directories.getURLFromSrc("/sd/qa/unit/data/pptx/tdf115394.pptx"), PPTX); +utl::TempFile tempFile; +xDocShRef = saveAndReload(xDocShRef.get(), PPTX, &tempFile); +double fTransitionDuration; + +// Slow in MS formats +SdPage* pPage1 = xDocShRef->GetDoc()->GetSdPage(0, PageKind::Standard); +fTransitionDuration = pPage1->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(1.0, fTransitionDuration); + +// Medium in MS formats +SdPage* pPage2 = xDocShRef->GetDoc()->GetSdPage(1, PageKind::Standard); +fTransitionDuration = pPage2->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(0.75, fTransitionDuration); + +// Fast in MS formats +SdPage* pPage3 = xDocShRef->GetDoc()->GetSdPage(2, PageKind::Standard); +fTransitionDuration = pPage3->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(0.5, fTransitionDuration); + +// Custom values +SdPage* pPage4 = xDocShRef->GetDoc()->GetSdPage(3, PageKind::Standard); +fTransitionDuration = pPage4->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(0.25, fTransitionDuration); + +SdPage* pPage5 = xDocShRef->GetDoc()->GetSdPage(4, PageKind::Standard); +fTransitionDuration = pPage5->getTransitionDuration(); +CPPUNIT_ASSERT_EQUAL(4.25, fTransitionDuration); + +xDocShRef->DoClose(); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SdOOXMLExportTest2); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx index 6b0c8fc5d0d5..bcf9b0e145ea 100644 --- a/sd/source/filter/eppt/pptx-epptooxml.cxx +++ b/sd/source/filter/eppt/pptx-epptooxml.cxx @@ -650,7 +650,42 @@ void PowerPointExport::WriteTransition(const FSHelperPtr& pFS) sal_Int32 advanceTiming = -1; sal_Int32 changeType = 0; -if (GETA(Speed)) +sal_Int32 nTransitionDuration = -1; +bool isTransitionDurationSet = false; + +// try to use TransitionDuration instead of old Speed property +if (GETA(TransitionDuration)) +{ +double fTransitionDuration = -1.0; +mAny >>= fTransitionDuration; +if (fTransitionDuration >= 0) +{ +nTransitionDuration = fTransitionDuration * 1000.0; + +// override values because in MS formats meaning of fast/medium/slow is different +if (nTransitionDuration <= 500) +{ +// fast is default +speed = nullptr; +} +else if (nTransitionDuration >= 1000) +{ +speed = "slow"; +} +else +{ +speed = "med"; +} + +bool isStandardValue = nTransitionDuration == 500 +|| nTransitionDuration == 750 +|| nTransitionDuration == 1000; + +if(!isStandardValue) +isTransitionDurationSet = true; +} +} +else if (GETA(Speed)) { mAny >>= animationSpeed; @@ -670,50 +705,12 @@ void PowerPointExport::WriteTransition(const FSHelperPtr& pFS) if (GETA(Change)) mAny >>= changeType; +bool isAdvanceTimingSet = advanceTiming != -1; // 1 means automatic, 2 half automatic - not sure what it means - at least I don't see it in UI if (changeType == 1 && GETA(Duration)) mAny >>= advanceTiming; -if (nTransition14 || pPresetTransition) -{ -const char* pRequiresNS = nTransition14 ? "p14" : "p15"; - -pFS->startElement(FSNS(XML_mc, XML_AlternateContent), FSEND); -pFS->startElement(FSNS(XML_mc, XML_Choice), XML_Requires, pRequiresNS, FSEND); - - -pFS->startElementNS(XML_p, XML_transition, -
[Libreoffice-commits] core.git: include/oox offapi/com oox/source sd/qa sd/source
include/oox/ppt/slidetransition.hxx |4 +++ offapi/com/sun/star/presentation/DrawPage.idl |9 +- oox/source/ppt/slidetransition.cxx| 22 +--- oox/source/ppt/slidetransitioncontext.cxx |6 oox/source/token/properties.txt |1 sd/qa/unit/data/pptx/tdf115394.pptx |binary sd/qa/unit/import-tests.cxx | 34 ++ sd/source/ui/inc/unoprnms.hxx |1 sd/source/ui/unoidl/unopage.cxx |2 - 9 files changed, 72 insertions(+), 7 deletions(-) New commits: commit a8a3e6a7fee5ac23bc2155b9391ead9402211147 Author: Szymon Kłos Date: Fri Feb 2 10:21:50 2018 +0100 tdf#115394 import custom slide transition time in PPTX * custom values are imported correctly * standard (fast, slow, medium) values are changed to match values in the MSO Change-Id: I004242afbbf641fe414abc8df248a2844c104502 Reviewed-on: https://gerrit.libreoffice.org/49139 Tested-by: Jenkins Reviewed-by: Szymon Kłos diff --git a/include/oox/ppt/slidetransition.hxx b/include/oox/ppt/slidetransition.hxx index 8986016f30aa..5a31b158334b 100644 --- a/include/oox/ppt/slidetransition.hxx +++ b/include/oox/ppt/slidetransition.hxx @@ -43,7 +43,10 @@ namespace oox { namespace ppt { void setSlideProperties( PropertyMap& props ); void setTransitionFilterProperties( const css::uno::Reference< css::animations::XTransitionFilter > & xFilter ); +/// Set one of standard values for slide transition duration void setOoxTransitionSpeed( sal_Int32 nToken ); +/// Set slide transition time directly +void setOoxTransitionSpeed( double fDuration ); void setMode( bool bMode ) { mbMode = bMode; } void setOoxAdvanceTime( sal_Int32 nAdvanceTime ) @@ -66,6 +69,7 @@ namespace oox { namespace ppt { ::sal_Int16 mnTransitionSubType; bool mbTransitionDirectionNormal; css::presentation::AnimationSpeed mnAnimationSpeed; +double mfTransitionDurationInSeconds; bool mbMode; /**< http://api.libreoffice.org/docs/common/ref/com/sun/star/animations/XTransitionFilter.html Mode property */ ::sal_Int32 mnAdvanceTime; }; diff --git a/offapi/com/sun/star/presentation/DrawPage.idl b/offapi/com/sun/star/presentation/DrawPage.idl index 18e499e81420..0e070470ad25 100644 --- a/offapi/com/sun/star/presentation/DrawPage.idl +++ b/offapi/com/sun/star/presentation/DrawPage.idl @@ -79,11 +79,11 @@ published service DrawPage [property] short Layout; -/** defines the speed of the fade-in effect of this page. +/** Defines the speed of the fade-in effect of this page. +@see TransitionSpeed */ [property] com::sun::star::presentation::AnimationSpeed Speed; - /** defines if a header presentation shape from the master page is visible on this page. */ @@ -142,6 +142,11 @@ published service DrawPage */ [optional, property] long DateTimeFormat; +/** Specifies slide transition time in seconds. +@since LibreOffice 6.1 +@see Speed + */ +[property, optional] double TransitionDuration; }; diff --git a/oox/source/ppt/slidetransition.cxx b/oox/source/ppt/slidetransition.cxx index e609e6709c2f..7c1555b7dc80 100644 --- a/oox/source/ppt/slidetransition.cxx +++ b/oox/source/ppt/slidetransition.cxx @@ -45,6 +45,7 @@ namespace oox { namespace ppt { , mnTransitionSubType( 0 ) , mbTransitionDirectionNormal( true ) , mnAnimationSpeed( AnimationSpeed_FAST ) +, mfTransitionDurationInSeconds( -1.0 ) , mbMode( true ) , mnAdvanceTime( -1 ) { @@ -56,6 +57,7 @@ namespace oox { namespace ppt { , mnTransitionSubType( 0 ) , mbTransitionDirectionNormal( true ) , mnAnimationSpeed( AnimationSpeed_FAST ) +, mfTransitionDurationInSeconds( -1.0 ) , mbMode( true ) , mnAdvanceTime( -1 ) { @@ -76,6 +78,8 @@ namespace oox { namespace ppt { aProps.setProperty( PROP_TransitionSubtype, mnTransitionSubType); aProps.setProperty( PROP_TransitionDirection, mbTransitionDirectionNormal); aProps.setProperty( PROP_Speed, mnAnimationSpeed); +if( mfTransitionDurationInSeconds >= 0.0 ) +aProps.setProperty( PROP_TransitionDuration, mfTransitionDurationInSeconds); aProps.setProperty( PROP_TransitionFadeColor, sal_Int32(0)); if( mnAdvanceTime != -1 ) { aProps.setProperty( PROP_Duration, mnAdvanceTime/1000); @@ -110,19 +114,21 @@ namespace oox { namespace ppt { { switch( nToken ) { -/* In case you want to use time values in second, - * the speed values are located in the PPT97 importer - * sd/source/filter/ppt/ppt97animations.cxx:664 -
[Libreoffice-commits] core.git: include/o3tl sot/qa sot/source
include/o3tl/sorted_vector.hxx |5 + sot/qa/cppunit/data/pass/badchain-1.compound |binary sot/qa/cppunit/test_sot.cxx |1 sot/source/sdstor/stgdir.cxx |3 sot/source/sdstor/stgstrms.cxx | 94 +++ sot/source/sdstor/stgstrms.hxx | 12 ++- 6 files changed, 68 insertions(+), 47 deletions(-) New commits: commit e89964ebb3ba3bd7d694695c004c5f976d8d9616 Author: Caolán McNamara Date: Tue Feb 6 15:36:07 2018 + ofz: Pos2Page returns true on same value that returned false previously a failed position returns false, but stays at the failed position, so next time its called without moving it then it returns true store what we return for a given position for reuse if the position doesn't change Change-Id: I404c65ac89eb6f5c867f62a62028b87effdbcbf8 Reviewed-on: https://gerrit.libreoffice.org/49308 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/include/o3tl/sorted_vector.hxx b/include/o3tl/sorted_vector.hxx index 7a9ca4568032..9141c592ffd8 100644 --- a/include/o3tl/sorted_vector.hxx +++ b/include/o3tl/sorted_vector.hxx @@ -86,6 +86,11 @@ public: m_vector.clear(); } +void reserve(size_type amount) +{ +m_vector.reserve(amount); +} + // ACCESSORS size_type size() const diff --git a/sot/qa/cppunit/data/pass/badchain-1.compound b/sot/qa/cppunit/data/pass/badchain-1.compound new file mode 100644 index ..4c70faf207fd Binary files /dev/null and b/sot/qa/cppunit/data/pass/badchain-1.compound differ diff --git a/sot/qa/cppunit/test_sot.cxx b/sot/qa/cppunit/test_sot.cxx index c4e961271801..0ffbe758a1ec 100644 --- a/sot/qa/cppunit/test_sot.cxx +++ b/sot/qa/cppunit/test_sot.cxx @@ -63,7 +63,6 @@ namespace // Read as much as we can, a corrupted FAT chain can cause real grief here nReadableSize = xStream->ReadBytes(static_cast(pData), nSize); -//fprintf(stderr, "readable size %d vs size %d remaining %d\n", nReadableSize, nSize, nReadableSize); } { // Read the data backwards as well tools::SvRef xStream( xObjStor->OpenSotStream( rStreamName ) ); diff --git a/sot/source/sdstor/stgdir.cxx b/sot/source/sdstor/stgdir.cxx index 253fb4399d05..b2e64967c436 100644 --- a/sot/source/sdstor/stgdir.cxx +++ b/sot/source/sdstor/stgdir.cxx @@ -839,7 +839,8 @@ bool StgDirStrm::Store() sal_Int32 nOldStart = m_nStart; // save for later deletion sal_Int32 nOldSize = m_nSize; m_nStart = m_nPage = STG_EOF; -m_nSize = m_nPos = 0; +m_nSize = 0; +SetPos(0, true); m_nOffset = 0; // Delete all temporary entries m_pRoot->DelTemp( false ); diff --git a/sot/source/sdstor/stgstrms.cxx b/sot/source/sdstor/stgstrms.cxx index 8e5093fe9a91..a9e7217a3a21 100644 --- a/sot/source/sdstor/stgstrms.cxx +++ b/sot/source/sdstor/stgstrms.cxx @@ -322,11 +322,12 @@ bool StgFAT::FreePages( sal_Int32 nStart, bool bAll ) // FAT class for the page allocations. StgStrm::StgStrm( StgIo& r ) -: m_rIo(r), +: m_nPos(0), + m_bBytePosValid(true), + m_rIo(r), m_pEntry(nullptr), m_nStart(STG_EOF), m_nSize(0), - m_nPos(0), m_nPage(STG_EOF), m_nOffset(0), m_nPageSize(m_rIo.GetPhysPageSize()) @@ -356,7 +357,10 @@ void StgStrm::SetEntry( StgDirEntry& r ) sal_Int32 StgStrm::scanBuildPageChainCache() { if (m_nSize > 0) +{ m_aPagesCache.reserve(m_nSize/m_nPageSize); +m_aUsedPageNumbers.reserve(m_nSize/m_nPageSize); +} bool bError = false; sal_Int32 nBgn = m_nStart; @@ -364,8 +368,6 @@ sal_Int32 StgStrm::scanBuildPageChainCache() // Track already scanned PageNumbers here and use them to // see if an already counted page is re-visited -std::set< sal_Int32 > nUsedPageNumbers; - while( nBgn >= 0 && !bError ) { if( nBgn >= 0 ) @@ -373,7 +375,7 @@ sal_Int32 StgStrm::scanBuildPageChainCache() nBgn = m_pFat->GetNextPage( nBgn ); //returned second is false if it already exists -if (!nUsedPageNumbers.insert(nBgn).second) +if (!m_aUsedPageNumbers.insert(nBgn).second) { SAL_WARN ("sot", "Error: page number " << nBgn << " already in chain for stream"); bError = true; @@ -386,6 +388,7 @@ sal_Int32 StgStrm::scanBuildPageChainCache() SAL_WARN("sot", "returning wrong format error"); m_rIo.SetError( ERRCODE_IO_WRONGFORMAT ); m_aPagesCache.clear(); +m_aUsedPageNumbers.clear(); } return nOptSize; } @@ -408,8 +411,8 @@ bool StgStrm::Pos2Page( sal_Int32 nBytePos ) sal_Int32 nNew = nBytePos & nMask; m_nOffset = static_cast( nBytePos & ~nMask ); m_nPos = nBytePos; -if( nOld == nNew ) -return true; +if (nOld == nNew) +
[Libreoffice-commits] core.git: writerfilter/source
writerfilter/source/dmapper/NumberingManager.cxx | 51 +-- 1 file changed, 30 insertions(+), 21 deletions(-) New commits: commit 469430a7d36fc1e860b4b68137261ec0833386c0 Author: Caolán McNamara Date: Tue Feb 6 21:12:48 2018 + rtf: null-deref Change-Id: I9c4510cb91e2572a3ab2b62497dc4dd9fd1119c8 Reviewed-on: https://gerrit.libreoffice.org/49319 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/writerfilter/source/dmapper/NumberingManager.cxx b/writerfilter/source/dmapper/NumberingManager.cxx index 2e5794c31495..b406c44a6152 100644 --- a/writerfilter/source/dmapper/NumberingManager.cxx +++ b/writerfilter/source/dmapper/NumberingManager.cxx @@ -863,6 +863,7 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) } break; case NS_ooxml::LN_CT_Lvl_lvlPicBulletId: +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { uno::Reference xShape; for (std::vector::iterator it = m_aNumPicBullets.begin(); it != m_aNumPicBullets.end(); ++it) @@ -879,15 +880,15 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) try { uno::Any aAny = xPropertySet->getPropertyValue("GraphicURL"); -if (aAny.has()) - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicURL(aAny.get()); +if (aAny.has() && pCurrentLevel) +pCurrentLevel->SetGraphicURL(aAny.get()); } catch(const beans::UnknownPropertyException&) {} try { uno::Reference< graphic::XGraphic > gr; xPropertySet->getPropertyValue("Bitmap") >>= gr; - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicBitmap( gr ); +pCurrentLevel->SetGraphicBitmap( gr ); } catch(const beans::UnknownPropertyException&) {} @@ -902,12 +903,12 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) int nWidth = (nHeight * aPrefSize.Width) / aPrefSize.Height; awt::Size aSize( convertMm100ToTwip(nWidth), convertMm100ToTwip(nHeight) ); - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicSize( aSize ); +pCurrentLevel->SetGraphicSize( aSize ); } else { awt::Size aSize( convertMm100ToTwip(aPrefSize.Width), convertMm100ToTwip(aPrefSize.Height) ); - m_pCurrentDefinition->GetCurrentLevel()->SetGraphicSize( aSize ); +pCurrentLevel->SetGraphicSize( aSize ); } } } @@ -938,26 +939,26 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) } break; case NS_ooxml::LN_CT_Lvl_start: -if (m_pCurrentDefinition->GetCurrentLevel().get()) -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( nSprmId, nIntValue ); +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) +pCurrentLevel->SetValue( nSprmId, nIntValue ); bIsStartVisited = true; break; case NS_ooxml::LN_CT_Lvl_numFmt: case NS_ooxml::LN_CT_Lvl_isLgl: case NS_ooxml::LN_CT_Lvl_legacy: -if (m_pCurrentDefinition->GetCurrentLevel().get()) +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( nSprmId, nIntValue ); +pCurrentLevel->SetValue( nSprmId, nIntValue ); if( !bIsStartVisited ) { -m_pCurrentDefinition->GetCurrentLevel( )->SetValue( NS_ooxml::LN_CT_Lvl_start, 0 ); +pCurrentLevel->SetValue( NS_ooxml::LN_CT_Lvl_start, 0 ); bIsStartVisited = true; } } break; case NS_ooxml::LN_CT_Lvl_suff: { -if (m_pCurrentDefinition->GetCurrentLevel().get()) +if (ListLevel::Pointer pCurrentLevel = m_pCurrentDefinition->GetCurrentLevel()) { SvxNumberFormat::LabelFollowedBy value = SvxNumberFormat::LISTTAB; if( rSprm.getValue()->getString() == "tab" ) @@ -969,7 +970,7 @@ void ListsManager::lcl_sprm( Sprm& rSprm ) else SAL_WARN( "writerfilter", "Unknown ST_LevelSuffix value " << rSprm.getValue()->getS
[Libreoffice-commits] dev-tools.git: clang/find-harmful-auto.cxx clang/Makefile
clang/Makefile |5 - clang/find-harmful-auto.cxx | 203 2 files changed, 207 insertions(+), 1 deletion(-) New commits: commit 9014b9b7827fa04a96847bfbd845d42d797806ff Author: Miklos Vajna Date: Wed Feb 7 10:21:53 2018 +0100 clang: add a find-harmful-auto tool I used this one in online.git recently to find auto usage where it's helpful to still spell out the type (i.e. non-iterator, type info is not available in the same line anyway). diff --git a/clang/Makefile b/clang/Makefile index 7bdbec8..482a9c9 100644 --- a/clang/Makefile +++ b/clang/Makefile @@ -8,7 +8,7 @@ ifneq ($(GCOV),) CLANGFLAGS += --coverage endif -all: bin/rename bin/find-unprefixed-members +all: bin/rename bin/find-unprefixed-members bin/find-harmful-auto bin/rename: rename.cxx Makefile clang++ $(CLANGFLAGS) $(CLANGLIBS) -ldl -lpthread -o $@ $< @@ -16,6 +16,9 @@ bin/rename: rename.cxx Makefile bin/find-unprefixed-members: find-unprefixed-members.cxx Makefile clang++ $(CLANGFLAGS) $(CLANGLIBS) -ldl -lpthread -o $@ $< +bin/find-harmful-auto: find-harmful-auto.cxx Makefile + clang++ $(CLANGFLAGS) $(CLANGLIBS) -ldl -lpthread -o $@ $< + test: test.cxx test.hxx Makefile clang++ -o test test.cxx diff --git a/clang/find-harmful-auto.cxx b/clang/find-harmful-auto.cxx new file mode 100644 index 000..a635ef2 --- /dev/null +++ b/clang/find-harmful-auto.cxx @@ -0,0 +1,203 @@ +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +class Context +{ +clang::ASTContext* m_pContext; + + public: +Context() : m_pContext(nullptr) {} + +void setASTContext(clang::ASTContext& rContext) { m_pContext = &rContext; } + +clang::ASTContext* getASTContext() const { return m_pContext; } + +bool ignoreLocation(const clang::SourceLocation& rLocation) +{ +clang::SourceLocation aLocation = +m_pContext->getSourceManager().getExpansionLoc(rLocation); +return m_pContext->getSourceManager().isInSystemHeader(aLocation); +} + +clang::DiagnosticBuilder report(llvm::StringRef aString, +clang::SourceLocation aLocation) const +{ +clang::DiagnosticsEngine& rEngine = m_pContext->getDiagnostics(); +return rEngine.Report(aLocation, + rEngine.getDiagnosticIDs()->getCustomDiagID( + clang::DiagnosticIDs::Level::Error, aString)); +} +}; + +/** + * Finds auto usage which is not readable (type info not in the same line, nor + * an iterator). + */ +class Visitor : public clang::RecursiveASTVisitor +{ +Context& m_rContext; +std::string m_aDeclRefName; + + public: +Visitor(Context& rContext, clang::ASTContext& rASTContext) +: m_rContext(rContext) +{ +m_rContext.setASTContext(rASTContext); +} + +bool hasTemplateArguments(clang::Expr* pExpr) +{ +if (!pExpr) +return false; + +auto pCallExpr = clang::dyn_cast(pExpr); +if (!pCallExpr) +{ +auto pExprWithCleanups = +clang::dyn_cast(pExpr); +if (!pExprWithCleanups) +return false; + +pCallExpr = clang::dyn_cast( +pExprWithCleanups->getSubExpr()); +if (!pCallExpr) +{ +auto pCXXConstructExpr = +clang::dyn_cast( +pExprWithCleanups->getSubExpr()); +if (!pCXXConstructExpr || pCXXConstructExpr->getNumArgs() < 1) +return false; + +auto pMaterializeTemporaryExpr = +clang::dyn_cast( +pCXXConstructExpr->getArg(0)); +if (!pMaterializeTemporaryExpr) +return false; + +auto pCXXBindTemporaryExpr = +clang::dyn_cast( +pMaterializeTemporaryExpr->GetTemporaryExpr()); +if (!pCXXBindTemporaryExpr) +return false; + +pCallExpr = clang::dyn_cast( +pCXXBindTemporaryExpr->getSubExpr()); +} +} + +if (!pCallExpr || !pCallExpr->getCalleeDecl()) +return false; + +auto pFunctionDecl = +clang::dyn_cast(pCallExpr->getCalleeDecl()); +if (!pFunctionDecl) +return false; + +return pFunctionDecl->getTemplateSpecializationArgs() != nullptr; +} + +bool VisitVarDecl(clang::VarDecl* pDecl) +{ +if (m_rContext.ignoreLocation(pDecl->getLocation())) +return true; + +clang::QualType aType = pDecl->getType(); +std::string aTypeName = aType.getAsString(); +if (aTypeName.find("iterator") != std::string::npos || +aTypeName.find("Iterato
[Libreoffice-commits] online.git: 6 commits - common/Common.hpp common/FileUtil.cpp common/IoUtil.cpp common/Message.hpp common/MessageQueue.cpp common/MessageQueue.hpp common/Png.hpp common/Protocol.
common/Common.hpp| 12 - common/FileUtil.cpp |2 common/IoUtil.cpp| 12 - common/Message.hpp |8 - common/MessageQueue.cpp | 22 +-- common/MessageQueue.hpp |6 common/Png.hpp |2 common/Protocol.cpp |6 common/Protocol.hpp | 16 +- common/Session.cpp |2 common/SigUtil.cpp |4 common/Util.cpp | 10 - common/Util.hpp | 12 - kit/ChildSession.cpp | 34 ++-- kit/ChildSession.hpp |4 kit/ForKit.cpp | 10 - kit/Kit.cpp | 92 ++--- kit/KitHelper.hpp|6 net/WebSocketHandler.hpp |8 - test/TileCacheTests.cpp | 124 - test/UnitFuzz.cpp|4 test/UnitPrefork.cpp |2 test/countloolkits.hpp | 10 - test/helpers.hpp | 10 - test/httpcrashtest.cpp | 20 +- test/httpwserror.cpp | 20 +- test/httpwstest.cpp | 270 +++ test/integration-http-server.cpp |2 tools/Replay.hpp | 24 +-- tools/Stress.cpp | 30 ++-- tools/map.cpp|8 - wsd/Admin.cpp| 14 +- wsd/AdminModel.cpp |8 - wsd/ClientSession.cpp| 24 +-- wsd/ClientSession.hpp|2 wsd/DocumentBroker.cpp | 62 wsd/FileServer.cpp | 16 +- wsd/LOOLWSD.cpp | 96 ++--- wsd/LOOLWSD.hpp |2 wsd/SenderQueue.hpp |6 wsd/Storage.cpp | 28 ++-- wsd/TileCache.cpp| 14 +- wsd/TileDesc.hpp | 12 - wsd/TraceFile.hpp| 10 - wsd/UserMessages.hpp |4 45 files changed, 545 insertions(+), 545 deletions(-) New commits: commit 1dde430bcf9b9cd6febd18547c3d3992d76cef61 Author: Miklos Vajna Date: Wed Feb 7 10:17:59 2018 +0100 wsd: spell out non-trivial autos to improve readability Change-Id: I0e1f169fc39e5c722704e1cae487147d929f7350 diff --git a/wsd/Admin.cpp b/wsd/Admin.cpp index 2c4dbc72..74b7542f 100644 --- a/wsd/Admin.cpp +++ b/wsd/Admin.cpp @@ -73,7 +73,7 @@ void AdminSocketHandler::handleMessage(bool /* fin */, WSOpCode /* code */, std::string jwtToken; LOOLProtocol::getTokenString(tokens[1], "jwt", jwtToken); const auto& config = Application::instance().config(); -const auto sslKeyPath = config.getString("ssl.key_file_path", ""); +const std::string sslKeyPath = config.getString("ssl.key_file_path", ""); LOG_INF("Verifying JWT token: " << jwtToken); JWTAuth authAgent(sslKeyPath, "admin", "admin", "admin"); @@ -158,7 +158,7 @@ void AdminSocketHandler::handleMessage(bool /* fin */, WSOpCode /* code */, { try { -const auto pid = std::stoi(tokens[1]); +const int pid = std::stoi(tokens[1]); LOG_INF("Admin request to kill PID: " << pid); SigUtil::killChild(pid); } @@ -291,10 +291,10 @@ bool AdminSocketHandler::handleInitialRequest( const std::weak_ptr &socketWeak, const Poco::Net::HTTPRequest& request) { -auto socket = socketWeak.lock(); +std::shared_ptr socket = socketWeak.lock(); // Different session id pool for admin sessions (?) -const auto sessionId = Util::decodeId(LOOLWSD::GenSessionId()); +const size_t sessionId = Util::decodeId(LOOLWSD::GenSessionId()); const std::string& requestURI = request.getURI(); StringTokenizer pathTokens(requestURI, "/", StringTokenizer::TOK_IGNORE_EMPTY | StringTokenizer::TOK_TRIM); @@ -349,7 +349,7 @@ Admin::Admin() : LOG_TRC("Total available memory: " << _totalAvailMemKb << " KB (memproportion: " << memLimit << "%)."); -const auto totalMem = getTotalMemoryUsage(); +const size_t totalMem = getTotalMemoryUsage(); LOG_TRC("Total memory used: " << totalMem << " KB."); _model.addMemStats(totalMem); } @@ -378,7 +378,7 @@ void Admin::pollingThread() if (cpuWait <= MinStatsIntervalMs / 2) // Close enough { const size_t currentJiffies = getTotalCpuUsage(); -auto cpuPercent = 100 * 1000 * currentJiffies / (sysconf (_SC_CLK_TCK) * _cpuStatsTaskIntervalMs); +size_t cpuPercent = 100 * 1000 * currentJiffies / (sysconf (_SC_CLK_TCK) * _cpuStatsTaskIntervalMs); _model.addCpuStats(cpuPercent); lastCPU = now; @@ -389,7 +389,7 @@ void Admin::pollingThread() std::chrono::duration_cast(now - lastMem).count(); if (memWait <= MinStatsIntervalMs / 2) // Close enough { -const auto totalMem = get
[Libreoffice-commits] core.git: canvas/source emfio/source filter/source forms/source include/vcl sc/source sd/qa svtools/source svx/source vcl/source vcl/workben
canvas/source/vcl/canvasbitmaphelper.cxx |3 emfio/source/reader/mtftools.cxx | 21 +++-- filter/source/flash/swfwriter1.cxx |3 filter/source/graphicfilter/egif/egif.cxx|3 filter/source/graphicfilter/eps/eps.cxx | 24 -- filter/source/graphicfilter/etiff/etiff.cxx | 14 ++- filter/source/graphicfilter/ipsd/ipsd.cxx|3 filter/source/msfilter/msdffimp.cxx |5 - filter/source/msfilter/svdfppt.cxx |6 + forms/source/component/imgprod.cxx | 18 +++- include/vcl/bitmapaccess.hxx |5 + sc/source/filter/excel/xeescher.cxx |3 sd/qa/unit/import-tests.cxx |3 svtools/source/graphic/grfmgr2.cxx | 10 +- svtools/source/graphic/transformer.cxx |3 svx/source/svdraw/svdfmtf.cxx|6 - svx/source/xoutdev/_xoutbmp.cxx | 29 --- vcl/source/bitmap/BitmapProcessor.cxx| 10 +- vcl/source/bitmap/BitmapScaleConvolution.cxx |5 - vcl/source/bitmap/BitmapSymmetryCheck.cxx| 11 +- vcl/source/bitmap/bitmapscalesuper.cxx |6 + vcl/source/filter/jpeg/JpegWriter.cxx| 11 +- vcl/source/gdi/alpha.cxx |5 - vcl/source/gdi/bitmap.cxx| 100 - vcl/source/gdi/bitmap3.cxx | 108 ++- vcl/source/gdi/bitmap4.cxx | 26 -- vcl/source/gdi/bmpacc.cxx|3 vcl/source/gdi/dibtools.cxx | 29 --- vcl/source/gdi/impvect.cxx | 10 +- vcl/source/gdi/octree.cxx|6 + vcl/source/gdi/pngwrite.cxx | 30 --- vcl/source/helper/canvasbitmap.cxx |3 vcl/source/outdev/bitmap.cxx |7 + vcl/source/outdev/transparent.cxx|8 +- vcl/workben/vcldemo.cxx |6 + 35 files changed, 349 insertions(+), 194 deletions(-) New commits: commit e5012e53b919ae4921d6d35660bde323a6f28417 Author: Noel Grandin Date: Wed Feb 7 09:49:10 2018 +0200 use scanline when reading pixel data extracts code from the innermost part of fairly hot loops And add a GetIndexFromData method to make the call sites a little easier to read. Change-Id: I4ce5c5a687ecdb6982562a0aafce8513d86f9107 Reviewed-on: https://gerrit.libreoffice.org/49337 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/canvas/source/vcl/canvasbitmaphelper.cxx b/canvas/source/vcl/canvasbitmaphelper.cxx index bdb016fd..869957546498 100644 --- a/canvas/source/vcl/canvasbitmaphelper.cxx +++ b/canvas/source/vcl/canvasbitmaphelper.cxx @@ -156,6 +156,7 @@ namespace vclcanvas yGetScanline( y ); if( pAlphaReadAccess.get() != nullptr ) { for( long x=rect.X1; @@ -165,7 +166,7 @@ namespace vclcanvas pRes[ nCurrPos++ ] = pReadAccess->GetColor( y, x ).GetRed(); pRes[ nCurrPos++ ] = pReadAccess->GetColor( y, x ).GetGreen(); pRes[ nCurrPos++ ] = pReadAccess->GetColor( y, x ).GetBlue(); -pRes[ nCurrPos++ ] = pAlphaReadAccess->GetPixel( y, x ).GetIndex(); +pRes[ nCurrPos++ ] = pAlphaReadAccess->GetIndexFromData( pScanlineReadAlpha, x ); } } else diff --git a/emfio/source/reader/mtftools.cxx b/emfio/source/reader/mtftools.cxx index 79f7efc90abd..efbfe52364f7 100644 --- a/emfio/source/reader/mtftools.cxx +++ b/emfio/source/reader/mtftools.cxx @@ -1666,17 +1666,22 @@ namespace emfio const long nWidth(std::min(pR->Width(), pW->Width())); const long nHeight(std::min(pR->Height(), pW->Height())); -for(long nY(0); nY < nHeight; nY++) for(long nX(0); nX < nWidth; nX++) +for(long nY(0); nY < nHeight; nY++) { -const sal_uInt8 nIndR(pR->GetPixelIndex(nY, nX)); -const sal_uInt8 nIndW(pW->GetPixelIndex(nY, nX)); +Scanline pScanlineR = pR->GetScanline( nY ); +Scanline pScanlineW = pW->GetScanline( nY ); +for(long nX(0); nX < nWidth; nX++) +{ +const sal_uInt8 nIndR(pR->GetIndexFromData(pScanlineR, nX)); +const sal_uInt8 nIndW(pW->GetIndexFromData(pScanlineW, nX)); -// these values represent transparency (0 == no, 255 == fully transparent), -// so to blend these we have to multiply the inverse (opacity) -// and re-invert the result to transparence -cons
[Libreoffice-commits] core.git: package/source
package/source/zipapi/ZipFile.cxx |8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) New commits: commit c99527385acf367c748b3dcf3e6a3bb8103f5eee Author: Caolán McNamara Date: Tue Feb 6 21:21:30 2018 + MemoryByteGrabber sequence has to exist for Grabber lifetime it just takes a c++ ref, so a temp is an unsuitable arg Change-Id: I40490e94d977df91b985bc4ae458b68ee85d5dfe Reviewed-on: https://gerrit.libreoffice.org/49321 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara diff --git a/package/source/zipapi/ZipFile.cxx b/package/source/zipapi/ZipFile.cxx index 1d10a56aaf9c..6e9351c69f1a 100644 --- a/package/source/zipapi/ZipFile.cxx +++ b/package/source/zipapi/ZipFile.cxx @@ -902,7 +902,7 @@ sal_Int32 ZipFile::readCEN() if ( static_cast < sal_Int64 > ( nCenLen ) != nRead ) throw ZipException ("Error reading CEN into memory buffer!" ); -MemoryByteGrabber aMemGrabber ( aCENBuffer ); +MemoryByteGrabber aMemGrabber(aCENBuffer); ZipEntry aEntry; sal_Int16 nCommentLen; @@ -1015,7 +1015,8 @@ void ZipFile::recover() if ( nPos < nBufSize - 30 && pBuffer[nPos] == 'P' && pBuffer[nPos+1] == 'K' && pBuffer[nPos+2] == 3 && pBuffer[nPos+3] == 4 ) { ZipEntry aEntry; -MemoryByteGrabber aMemGrabber ( Sequence< sal_Int8 >( &(pBuffer[nPos+4]), 26 ) ); +Sequence aTmpBuffer(&(pBuffer[nPos+4]), 26); +MemoryByteGrabber aMemGrabber(aTmpBuffer); aEntry.nVersion = aMemGrabber.ReadInt16(); if ( ( aEntry.nVersion & 1 ) != 1 ) @@ -1084,7 +1085,8 @@ void ZipFile::recover() else if (pBuffer[nPos] == 'P' && pBuffer[nPos+1] == 'K' && pBuffer[nPos+2] == 7 && pBuffer[nPos+3] == 8 ) { sal_Int64 nCompressedSize, nSize; -MemoryByteGrabber aMemGrabber ( Sequence< sal_Int8 >( &(pBuffer[nPos+4]), 12 ) ); +Sequence aTmpBuffer(&(pBuffer[nPos+4]), 12); +MemoryByteGrabber aMemGrabber(aTmpBuffer); sal_Int32 nCRC32 = aMemGrabber.ReadInt32(); sal_uInt32 nCompressedSize32 = aMemGrabber.ReadUInt32(); sal_uInt32 nSize32 = aMemGrabber.ReadUInt32(); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: include/svx svx/source
include/svx/textchainflow.hxx |5 +++-- svx/source/svdraw/textchainflow.cxx | 12 ++-- 2 files changed, 9 insertions(+), 8 deletions(-) New commits: commit d4e1802c620e3cddb2e7a9f6a573a5a4770bc7a4 Author: Noel Grandin Date: Mon Feb 5 11:25:59 2018 +0200 loplugin:useuniqueptr in TextChainFlow Change-Id: Iad96df43c9c7ae6d5fd4f3aa9c2c5c721711da30 Reviewed-on: https://gerrit.libreoffice.org/49331 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/include/svx/textchainflow.hxx b/include/svx/textchainflow.hxx index d52e26a86e3d..2c5f5d8c00a5 100644 --- a/include/svx/textchainflow.hxx +++ b/include/svx/textchainflow.hxx @@ -21,6 +21,7 @@ #define INCLUDED_SVX_TEXTCHAINFLOW_HXX #include +#include class SdrTextObj; class SdrOutliner; @@ -56,8 +57,8 @@ protected: ESelection maOverflowPosSel; ESelection maPostChainingSel; -OFlowChainedText *mpOverflChText; -UFlowChainedText *mpUnderflChText; +std::unique_ptr mpOverflChText; +std::unique_ptr mpUnderflChText; void impCheckForFlowEvents(SdrOutliner *, SdrOutliner *); diff --git a/svx/source/svdraw/textchainflow.cxx b/svx/source/svdraw/textchainflow.cxx index b87d2a7f02ed..5cce8877e098 100644 --- a/svx/source/svdraw/textchainflow.cxx +++ b/svx/source/svdraw/textchainflow.cxx @@ -46,8 +46,8 @@ TextChainFlow::TextChainFlow(SdrTextObj *pChainTarget) TextChainFlow::~TextChainFlow() { -delete mpOverflChText; -delete mpUnderflChText; +mpOverflChText.reset(); +mpUnderflChText.reset(); } void TextChainFlow::impSetFlowOutlinerParams(SdrOutliner *, SdrOutliner *) @@ -91,14 +91,14 @@ void TextChainFlow::impCheckForFlowEvents(SdrOutliner *pFlowOutl, SdrOutliner *p // If we had an underflow before we have to deep merge paras anyway bool bMustMergeParaOF = bMustMergeParaAmongLinks || mbOFisUFinduced; -mpOverflChText = bOverflow ? +mpOverflChText.reset( bOverflow ? new OFlowChainedText(pFlowOutl, bMustMergeParaOF) : - nullptr; + nullptr ); // Set current underflowing text (if any) -mpUnderflChText = bUnderflow ? +mpUnderflChText.reset( bUnderflow ? new UFlowChainedText(pFlowOutl, bMustMergeParaAmongLinks) : - nullptr; + nullptr ); // Reset update mode // Reset it here because we use WriteRTF (needing updatemode = true) in the two constructors above if (!bOldUpdateMode) // Reset only if the old value was false ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
Re: [Libreoffice-commits] core.git: Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5
On 07.02.2018 09:33, Stephan Bergmann wrote: commit bf23fe3a4a3eebe3d08fa26341a486b83d80c1c7 Author: Stephan Bergmann Date: Wed Feb 7 09:11:35 2018 +0100 Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5 The dependency of Library_vcl on qt5 libraries (via vcl/qt5/Qt5Font.cxx) is there ever since b66a7cbd8491fe436126e11975c360f47ae346ed "QT5 first stab on implementing CommonSalLayout", but no idea whether that is by design or is a hack that should eventually be cleaned up. Any thoughts on the above? It might e.g. by undesirable for distros that do --enable-qt5 but split libvclplug_qt5lo.so into a Qt5-dependent package of its own (and don't want the base vcl package to depend on Qt5). Change-Id: I4cec702709b37069987ec68c035628b5172b3543 diff --git a/bin/check-elf-dynamic-objects b/bin/check-elf-dynamic-objects index 93fcfa6cc098..1259718b7739 100755 --- a/bin/check-elf-dynamic-objects +++ b/bin/check-elf-dynamic-objects @@ -71,6 +71,7 @@ gstreamerwhitelist="libgstpbutils-1.0.so.0 libgstvideo-1.0.so.0 libgstbase-1.0.s gtk2whitelist="libgtk-x11-2.0.so.0 libgdk-x11-2.0.so.0 libpangocairo-1.0.so.0 libatk-1.0.so.0 libcairo.so.2 libgio-2.0.so.0 libpangoft2-1.0.so.0 libpango-1.0.so.0 libfontconfig.so.1 libfreetype.so.6 libgdk_pixbuf-2.0.so.0 libgobject-2.0.so.0 libglib-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libdbus-glib-1.so.2 libdbus-1.so.3" gtk3whitelist="libgtk-3.so.0 libgdk-3.so.0 libcairo-gobject.so.2 libpangocairo-1.0.so.0 libatk-1.0.so.0 libcairo.so.2 libgio-2.0.so.0 libpangoft2-1.0.so.0 libpango-1.0.so.0 libfontconfig.so.1 libfreetype.so.6 libgdk_pixbuf-2.0.so.0 libgobject-2.0.so.0 libglib-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libdbus-glib-1.so.2 libdbus-1.so.3" kde4whitelist="libkio.so.5 libkfile.so.4 libkdeui.so.5 libkdecore.so.5 libQtNetwork.so.4 libQtGui.so.4 libQtCore.so.4 libglib-2.0.so.0" +qt5whitelist="libQt5Core.so.5 libQt5Gui.so.5 libQt5Network.so.5 libQt5Widgets.so.5 libcairo.so.2 libglib-2.0.so.0" avahiwhitelist="libdbus-glib-1.so.2 libdbus-1.so.3 libgobject-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libglib-2.0.so.0 libavahi-common.so.3 libavahi-client.so.3" kerberoswhitelist="libgssapi_krb5.so.2 libcom_err.so.2 libkrb5.so.3" dconfwhitelist="libdconf.so.1 libgio-2.0.so.0 libglib-2.0.so.0 libgobject-2.0.so.0" @@ -107,13 +108,25 @@ local file="$1" */libvclplug_gtk3lo.so) whitelist="${whitelist} ${x11whitelist} ${gtk3whitelist}" ;; +*/libvclplug_qt5lo.so) +if [ "$ENABLE_QT5" = TRUE ]; then +whitelist="${whitelist} ${qt5whitelist}" +fi +;; */libdesktop_detectorlo.so|*/ui-previewer|*/oosplash|*/gengal.bin) whitelist="${whitelist} ${x11whitelist}" ;; */libvclplug_genlo.so|*/libchartcorelo.so|*/libavmediaogl.so|*/libOGLTranslo.so|*/liboglcanvaslo.so|*/libchartopengllo.so) whitelist="${whitelist} ${x11whitelist} ${openglwhitelist}" ;; -*/libvcllo.so|*/libsofficeapp.so) +*/libvcllo.so) +whitelist="${whitelist} ${x11whitelist} ${openglwhitelist} ${giowhitelist} libcups.so.2" +if [ "$ENABLE_QT5" = TRUE ]; then +#TOOD: is inclusion of vcl/qt5/Qt5Font.cxx in Library_vcl really wanted? +whitelist="${whitelist} ${qt5whitelist}" +fi +;; +*/libsofficeapp.so) whitelist="${whitelist} ${x11whitelist} ${openglwhitelist} ${giowhitelist} libcups.so.2" ;; */liblibreofficekitgtk.so) ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] core.git: include/svx svx/source
include/svx/svdundo.hxx |6 -- svx/source/svdraw/svdundo.cxx | 10 +- 2 files changed, 9 insertions(+), 7 deletions(-) New commits: commit f4b9c35c018ccacd7f8cf71c534863239b0da02c Author: Noel Grandin Date: Mon Feb 5 11:01:07 2018 +0200 loplugin:useuniqueptr in SdrUndoObjSetText Change-Id: Idd1eb8263d679efed0f0be88fb05963fe44f8668 Reviewed-on: https://gerrit.libreoffice.org/49328 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/include/svx/svdundo.hxx b/include/svx/svdundo.hxx index 793782d37ed1..9cb4271d0a86 100644 --- a/include/svx/svdundo.hxx +++ b/include/svx/svdundo.hxx @@ -398,8 +398,10 @@ public: class SVX_DLLPUBLIC SdrUndoObjSetText : public SdrUndoObj { protected: -OutlinerParaObject* pOldText; -OutlinerParaObject* pNewText; +std::unique_ptr +pOldText; +std::unique_ptr +pNewText; boolbNewTextAvailable; boolbEmptyPresObj; sal_Int32 mnText; diff --git a/svx/source/svdraw/svdundo.cxx b/svx/source/svdraw/svdundo.cxx index ba2bff175356..3f607186f87f 100644 --- a/svx/source/svdraw/svdundo.cxx +++ b/svx/source/svdraw/svdundo.cxx @@ -1032,15 +1032,15 @@ SdrUndoObjSetText::SdrUndoObjSetText(SdrObject& rNewObj, sal_Int32 nText) { SdrText* pText = static_cast< SdrTextObj*>( &rNewObj )->getText(mnText); if( pText && pText->GetOutlinerParaObject() ) -pOldText = new OutlinerParaObject(*pText->GetOutlinerParaObject()); +pOldText.reset( new OutlinerParaObject(*pText->GetOutlinerParaObject()) ); bEmptyPresObj = rNewObj.IsEmptyPresObj(); } SdrUndoObjSetText::~SdrUndoObjSetText() { -delete pOldText; -delete pNewText; +pOldText.reset(); +pNewText.reset(); } void SdrUndoObjSetText::AfterSetText() @@ -1049,7 +1049,7 @@ void SdrUndoObjSetText::AfterSetText() { SdrText* pText = static_cast< SdrTextObj*>( pObj )->getText(mnText); if( pText && pText->GetOutlinerParaObject() ) -pNewText = new OutlinerParaObject(*pText->GetOutlinerParaObject()); +pNewText.reset( new OutlinerParaObject(*pText->GetOutlinerParaObject()) ); bNewTextAvailable=true; } } @@ -1172,7 +1172,7 @@ void SdrUndoObjSetText::SdrRepeat(SdrView& rView) if( bUndo ) rView.AddUndo(new SdrUndoObjSetText(*pTextObj,0)); -OutlinerParaObject* pText1=pNewText; +OutlinerParaObject* pText1=pNewText.get(); if (pText1!=nullptr) pText1 = new OutlinerParaObject(*pText1); pTextObj->SetOutlinerParaObject(pText1); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] core.git: 3 commits - bin/check-elf-dynamic-objects
bin/check-elf-dynamic-objects | 33 - 1 file changed, 32 insertions(+), 1 deletion(-) New commits: commit 9b1adb42c97115b3f670f32639dd3f6d80f0d33e Author: Stephan Bergmann Date: Wed Feb 7 09:31:54 2018 +0100 Fix CustomTarget_postprocess/check_dynamic_objects for --enable-gtk3-kde5 Change-Id: Ie8c2389e8e0801b092abcfef751325cdf369b98d diff --git a/bin/check-elf-dynamic-objects b/bin/check-elf-dynamic-objects index 1259718b7739..885ef9ce857f 100755 --- a/bin/check-elf-dynamic-objects +++ b/bin/check-elf-dynamic-objects @@ -71,7 +71,8 @@ gstreamerwhitelist="libgstpbutils-1.0.so.0 libgstvideo-1.0.so.0 libgstbase-1.0.s gtk2whitelist="libgtk-x11-2.0.so.0 libgdk-x11-2.0.so.0 libpangocairo-1.0.so.0 libatk-1.0.so.0 libcairo.so.2 libgio-2.0.so.0 libpangoft2-1.0.so.0 libpango-1.0.so.0 libfontconfig.so.1 libfreetype.so.6 libgdk_pixbuf-2.0.so.0 libgobject-2.0.so.0 libglib-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libdbus-glib-1.so.2 libdbus-1.so.3" gtk3whitelist="libgtk-3.so.0 libgdk-3.so.0 libcairo-gobject.so.2 libpangocairo-1.0.so.0 libatk-1.0.so.0 libcairo.so.2 libgio-2.0.so.0 libpangoft2-1.0.so.0 libpango-1.0.so.0 libfontconfig.so.1 libfreetype.so.6 libgdk_pixbuf-2.0.so.0 libgobject-2.0.so.0 libglib-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libdbus-glib-1.so.2 libdbus-1.so.3" kde4whitelist="libkio.so.5 libkfile.so.4 libkdeui.so.5 libkdecore.so.5 libQtNetwork.so.4 libQtGui.so.4 libQtCore.so.4 libglib-2.0.so.0" -qt5whitelist="libQt5Core.so.5 libQt5Gui.so.5 libQt5Network.so.5 libQt5Widgets.so.5 libcairo.so.2 libglib-2.0.so.0" +qt5whitelist="libQt5Core.so.5 libQt5Gui.so.5 libQt5Network.so.5 libQt5Widgets.so.5 libQt5X11Extras.so.5 libcairo.so.2 libglib-2.0.so.0" +kf5whitelist="libKF5ConfigCore.so.5 libKF5CoreAddons.so.5 libKF5I18n.so.5 libKF5KIOCore.so.5 libKF5KIOFileWidgets.so.5 libKF5KIOWidgets.so.5 libKF5WindowSystem.so.5" avahiwhitelist="libdbus-glib-1.so.2 libdbus-1.so.3 libgobject-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libglib-2.0.so.0 libavahi-common.so.3 libavahi-client.so.3" kerberoswhitelist="libgssapi_krb5.so.2 libcom_err.so.2 libkrb5.so.3" dconfwhitelist="libdconf.so.1 libgio-2.0.so.0 libglib-2.0.so.0 libgobject-2.0.so.0" @@ -113,6 +114,17 @@ local file="$1" whitelist="${whitelist} ${qt5whitelist}" fi ;; +*/libvclplug_gtk3_kde5lo.so) +if [ "$ENABLE_GTK3_KDE5" = TRUE ]; then +whitelist="${whitelist} ${x11whitelist} ${gtk3whitelist}" +fi +;; +*/lo_kde5filepicker) +if [ "$ENABLE_GTK3_KDE5" = TRUE ]; then +whitelist="${whitelist} ${x11whitelist} ${gtk3whitelist} ${qt5whitelist} \ +${kf5whitelist} libxcb.so.1" +fi +;; */libdesktop_detectorlo.so|*/ui-previewer|*/oosplash|*/gengal.bin) whitelist="${whitelist} ${x11whitelist}" ;; commit bf23fe3a4a3eebe3d08fa26341a486b83d80c1c7 Author: Stephan Bergmann Date: Wed Feb 7 09:11:35 2018 +0100 Fix CustomTarget_postprocess/check_dynamic_objects for --enable-qt5 The dependency of Library_vcl on qt5 libraries (via vcl/qt5/Qt5Font.cxx) is there ever since b66a7cbd8491fe436126e11975c360f47ae346ed "QT5 first stab on implementing CommonSalLayout", but no idea whether that is by design or is a hack that should eventually be cleaned up. Change-Id: I4cec702709b37069987ec68c035628b5172b3543 diff --git a/bin/check-elf-dynamic-objects b/bin/check-elf-dynamic-objects index 93fcfa6cc098..1259718b7739 100755 --- a/bin/check-elf-dynamic-objects +++ b/bin/check-elf-dynamic-objects @@ -71,6 +71,7 @@ gstreamerwhitelist="libgstpbutils-1.0.so.0 libgstvideo-1.0.so.0 libgstbase-1.0.s gtk2whitelist="libgtk-x11-2.0.so.0 libgdk-x11-2.0.so.0 libpangocairo-1.0.so.0 libatk-1.0.so.0 libcairo.so.2 libgio-2.0.so.0 libpangoft2-1.0.so.0 libpango-1.0.so.0 libfontconfig.so.1 libfreetype.so.6 libgdk_pixbuf-2.0.so.0 libgobject-2.0.so.0 libglib-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libdbus-glib-1.so.2 libdbus-1.so.3" gtk3whitelist="libgtk-3.so.0 libgdk-3.so.0 libcairo-gobject.so.2 libpangocairo-1.0.so.0 libatk-1.0.so.0 libcairo.so.2 libgio-2.0.so.0 libpangoft2-1.0.so.0 libpango-1.0.so.0 libfontconfig.so.1 libfreetype.so.6 libgdk_pixbuf-2.0.so.0 libgobject-2.0.so.0 libglib-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libdbus-glib-1.so.2 libdbus-1.so.3" kde4whitelist="libkio.so.5 libkfile.so.4 libkdeui.so.5 libkdecore.so.5 libQtNetwork.so.4 libQtGui.so.4 libQtCore.so.4 libglib-2.0.so.0" +qt5whitelist="libQt5Core.so.5 libQt5Gui.so.5 libQt5Network.so.5 libQt5Widgets.so.5 libcairo.so.2 libglib-2.0.so.0" avahiwhitelist="libdbus-glib-1.so.2 libdbus-1.so.3 libgobject-2.0.so.0 libgmodule-2.0.so.0 libgthread-2.0.so.0 libglib-2.0.so.0 libavahi-common.so.3 libavahi-client.so.3" kerberoswhitelist="libgssapi_krb5.so.2 libcom_err.so.2 libkrb5.so.3" dconfwhit
[Libreoffice-commits] core.git: xmlsecurity/Library_xmlsecurity.mk xmlsecurity/source xmlsecurity/util
xmlsecurity/Library_xmlsecurity.mk|1 xmlsecurity/source/component/certificatecontainer.cxx | 70 +--- xmlsecurity/source/component/certificatecontainer.hxx | 78 -- xmlsecurity/source/component/registerservices.cxx | 61 -- xmlsecurity/util/xmlsecurity.component|5 - 5 files changed, 60 insertions(+), 155 deletions(-) New commits: commit 0833bab20bc3a6b7a9842307e4bd62f408ae37d3 Author: Miklos Vajna Date: Tue Feb 6 15:18:52 2018 +0100 xmlsecurity: create CertificateContainer instances with a constructor Change-Id: I42f0218a46c67062ea6eb0845d978f2630793ec0 Reviewed-on: https://gerrit.libreoffice.org/49304 Reviewed-by: Miklos Vajna Tested-by: Jenkins diff --git a/xmlsecurity/Library_xmlsecurity.mk b/xmlsecurity/Library_xmlsecurity.mk index 22d27c717155..1c30ab25817c 100644 --- a/xmlsecurity/Library_xmlsecurity.mk +++ b/xmlsecurity/Library_xmlsecurity.mk @@ -48,7 +48,6 @@ $(eval $(call gb_Library_use_libraries,xmlsecurity,\ $(eval $(call gb_Library_add_exception_objects,xmlsecurity,\ xmlsecurity/source/component/certificatecontainer \ xmlsecurity/source/component/documentdigitalsignatures \ - xmlsecurity/source/component/registerservices \ xmlsecurity/source/dialogs/certificatechooser \ xmlsecurity/source/dialogs/certificateviewer \ xmlsecurity/source/dialogs/digitalsignaturesdialog \ diff --git a/xmlsecurity/source/component/certificatecontainer.cxx b/xmlsecurity/source/component/certificatecontainer.cxx index bdbaa68b0a94..1e6c4facc8b2 100644 --- a/xmlsecurity/source/component/certificatecontainer.cxx +++ b/xmlsecurity/source/component/certificatecontainer.cxx @@ -17,8 +17,15 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include "certificatecontainer.hxx" +#include + +#include +#include +#include +#include + #include +#include #include @@ -26,6 +33,34 @@ using namespace ::com::sun::star; using namespace ::com::sun::star::lang; using namespace ::com::sun::star::uno; +class CertificateContainer +: public ::cppu::WeakImplHelper +{ +private: +typedef std::map Map; +Map certMap; +Map certTrustMap; + +static bool searchMap(const OUString& url, const OUString& certificate_name, Map& _certMap); +/// @throws css::uno::RuntimeException +bool isTemporaryCertificate(const OUString& url, const OUString& certificate_name); +/// @throws css::uno::RuntimeException +bool isCertificateTrust(const OUString& url, const OUString& certificate_name); + +public: +explicit CertificateContainer(const uno::Reference&) {} +virtual sal_Bool SAL_CALL addCertificate(const OUString& url, const OUString& certificate_name, + sal_Bool trust) override; +virtual css::security::CertificateContainerStatus SAL_CALL +hasCertificate(const OUString& url, const OUString& certificate_name) override; + +// XServiceInfo +virtual OUString SAL_CALL getImplementationName() override; +virtual sal_Bool SAL_CALL supportsService(const OUString& ServiceName) override; + +virtual css::uno::Sequence SAL_CALL getSupportedServiceNames() override; +}; + bool CertificateContainer::searchMap( const OUString & url, const OUString & certificate_name, Map &_certMap ) { @@ -86,7 +121,7 @@ CertificateContainer::hasCertificate( const OUString & url, const OUString & cer OUString SAL_CALL CertificateContainer::getImplementationName( ) { -return impl_getStaticImplementationName(); +return OUString("com.sun.star.security.CertificateContainer"); } sal_Bool SAL_CALL @@ -98,25 +133,34 @@ CertificateContainer::supportsService( const OUString& ServiceName ) Sequence< OUString > SAL_CALL CertificateContainer::getSupportedServiceNames( ) { -return impl_getStaticSupportedServiceNames(); -} - -Sequence< OUString > -CertificateContainer::impl_getStaticSupportedServiceNames( ) -{ Sequence< OUString > aRet { "com.sun.star.security.CertificateContainer" }; return aRet; } -OUString -CertificateContainer::impl_getStaticImplementationName() +namespace { -return OUString("com.sun.star.security.CertificateContainer"); +struct Instance +{ +explicit Instance(css::uno::Reference const& context) +: instance(new CertificateContainer(context)) +{ +} + +rtl::Reference instance; +}; + +struct Singleton +: public rtl::StaticWithArg, +Singleton> +{ +}; } -Reference< XInterface > CertificateContainer::impl_createInstance( const Reference< XMultiServiceFactory >& xServiceManager ) +extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* +com_sun_star_security_CertificateContainer_get_implementation( +css::uno::XComponentContext* context, css::uno::Sequence const&) { -return Reference< XInterface >( *new CertificateContainer( xServiceManager ) );
[Libreoffice-commits] core.git: 2 commits - include/svx svx/source
include/svx/svdtext.hxx |3 ++- include/svx/svdundo.hxx |6 +++--- svx/source/svdraw/svdtext.cxx | 22 -- svx/source/svdraw/svdundo.cxx | 19 +++ 4 files changed, 20 insertions(+), 30 deletions(-) New commits: commit c4257244afa0490c18a43ec2039a11f1c48935cc Author: Noel Grandin Date: Mon Feb 5 11:33:20 2018 +0200 loplugin:useuniqueptr in SdrText Change-Id: I23cc319707132c28725acdb8be0bea275025b9e5 Reviewed-on: https://gerrit.libreoffice.org/49332 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/include/svx/svdtext.hxx b/include/svx/svdtext.hxx index f16e16edd4e1..c5c8831841c0 100644 --- a/include/svx/svdtext.hxx +++ b/include/svx/svdtext.hxx @@ -23,6 +23,7 @@ #include #include #include +#include class OutlinerParaObject; @@ -73,7 +74,7 @@ protected: virtual SfxStyleSheet* GetStyleSheet() const; private: -OutlinerParaObject* mpOutlinerParaObject; +std::unique_ptr mpOutlinerParaObject; SdrTextObj& mrObject; SdrModel* mpModel; bool mbPortionInfoChecked; diff --git a/svx/source/svdraw/svdtext.cxx b/svx/source/svdraw/svdtext.cxx index 48621a84560d..a4875dc20a1f 100644 --- a/svx/source/svdraw/svdtext.cxx +++ b/svx/source/svdraw/svdtext.cxx @@ -40,7 +40,6 @@ SdrText::SdrText( SdrTextObj& rObject, OutlinerParaObject* pOutlinerParaObject / SdrText::~SdrText() { clearWeak(); -delete mpOutlinerParaObject; } void SdrText::CheckPortionInfo( SdrOutliner& rOutliner ) @@ -57,8 +56,7 @@ void SdrText::CheckPortionInfo( SdrOutliner& rOutliner ) if(mpOutlinerParaObject!=nullptr && rOutliner.ShouldCreateBigTextObject()) { // #i102062# MemoryLeak closed -delete mpOutlinerParaObject; -mpOutlinerParaObject = rOutliner.CreateParaObject(); +mpOutlinerParaObject.reset( rOutliner.CreateParaObject() ); } } } @@ -76,19 +74,17 @@ const SfxItemSet& SdrText::GetItemSet() const void SdrText::SetOutlinerParaObject( OutlinerParaObject* pTextObject ) { -if( mpOutlinerParaObject != pTextObject ) +if( mpOutlinerParaObject.get() != pTextObject ) { if( mpModel ) { // Update HitTestOutliner const SdrTextObj* pTestObj = mpModel->GetHitTestOutliner().GetTextObj(); -if( pTestObj && pTestObj->GetOutlinerParaObject() == mpOutlinerParaObject ) +if( pTestObj && pTestObj->GetOutlinerParaObject() == mpOutlinerParaObject.get() ) mpModel->GetHitTestOutliner().SetTextObj( nullptr ); } -delete mpOutlinerParaObject; - -mpOutlinerParaObject = pTextObject; +mpOutlinerParaObject.reset(pTextObject); mbPortionInfoChecked = false; } @@ -96,7 +92,7 @@ void SdrText::SetOutlinerParaObject( OutlinerParaObject* pTextObject ) OutlinerParaObject* SdrText::GetOutlinerParaObject() const { -return mpOutlinerParaObject; +return mpOutlinerParaObject.get(); } /** returns the current OutlinerParaObject and removes it from this instance */ @@ -106,13 +102,12 @@ OutlinerParaObject* SdrText::RemoveOutlinerParaObject() { // Update HitTestOutliner const SdrTextObj* pTestObj = mpModel->GetHitTestOutliner().GetTextObj(); -if( pTestObj && pTestObj->GetOutlinerParaObject() == mpOutlinerParaObject ) +if( pTestObj && pTestObj->GetOutlinerParaObject() == mpOutlinerParaObject.get() ) mpModel->GetHitTestOutliner().SetTextObj( nullptr ); } -OutlinerParaObject* pOPO = mpOutlinerParaObject; +OutlinerParaObject* pOPO = mpOutlinerParaObject.release(); -mpOutlinerParaObject = nullptr; mbPortionInfoChecked = false; return pOPO; @@ -151,8 +146,7 @@ void SdrText::SetModel( SdrModel* pNewModel ) // now use the Outliner, etc. so the above SetAttr can work at all SdrOutliner& rOutliner = mrObject.ImpGetDrawOutliner(); rOutliner.SetText(*mpOutlinerParaObject); -delete mpOutlinerParaObject; -mpOutlinerParaObject=nullptr; +mpOutlinerParaObject.reset(); if (bScaleUnitChanged) { Fraction aMetricFactor=GetMapFactor(aOldUnit,aNewUnit).X(); commit afeda72187e69d7bc8d7e37d98cce7601e2ffde8 Author: Noel Grandin Date: Mon Feb 5 11:10:31 2018 +0200 loplugin:useuniqueptr in SdrUndoGeoObj Change-Id: I8b48642a3a6ab4d94c1b58f8dae3589e703612b1 Reviewed-on: https://gerrit.libreoffice.org/49329 Tested-by: Jenkins Reviewed-by: Noel Grandin diff --git a/include/svx/svdundo.hxx b/include/svx/svdundo.hxx index 5fd24db225d5..793782d37ed1 100644 --- a/include/svx/svdundo.hxx +++ b/include/svx/svdundo.hxx @@ -207,10 +207,10 @@ public: class SVX_DLLPUBLIC SdrUndoGeoObj : public SdrUndoObj { protected: -SdrObjGeoData* pUndoGeo; -SdrObjGeoData* pRedoGeo; +std::unique_ptr pUndoGeo; +std::unique_ptr pRedoGeo; // I
Re: CppunitTest_xmlsecurity_signing Unit Test Failure on 32-bit Linux
Sorry this one should be more useful: https://pastebin.com/ZPFJh5Qp And for all backtraces: https://pastebin.com/k280xxEU Let me know if there is anything else I can do to help. -Luke From: t...@libreoffice.org Sent: Sunday, February 4, 2018 9:50 PM To: Luke Benes Cc: Libreoffice Dev List Subject: Re: CppunitTest_xmlsecurity_signing Unit Test Failure on 32-bit Linux Luke Benes wrote: > This was on my 64-bit Ubuntu 17.10 box. Anything useful here? > Hi Luke, no, not really - could you please do the 'catch throw' part, too, from my earlier mail? And then single-step inside appopen.cxx, until you hit an exception? Cheers, -- Thorsten ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice