[Libreoffice-commits] .: Branch 'libreoffice-4-0' - sc/source
sc/source/filter/excel/xiescher.cxx |1 - 1 file changed, 1 deletion(-) New commits: commit a027fdb6280bbe2b0e021e3f008f1c689510582c Author: Markus Mohrhard Date: Sat Dec 22 14:19:38 2012 +0100 storing the chart doc while loading is a bad idea, fdo#57530 There seems to be no obvious reason why we would need to store the chart doc during xls import. The chart test docs don't show any difference without this call. This speeds up xls chart import quite a bit. With the test doc from the bug report I'm able to open the doc nearly instantly now. Change-Id: I0b80462b9d1c405ab1d4cf456e12ebfe4428db98 diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx index d8c79f2..33036c0 100644 --- a/sc/source/filter/excel/xiescher.cxx +++ b/sc/source/filter/excel/xiescher.cxx @@ -1674,7 +1674,6 @@ void XclImpChartObj::DoPostProcessSdrObj( XclImpDffConverter& rDffConv, SdrObjec Reference< XEmbedPersist > xPersist( xEmbObj, UNO_QUERY_THROW ); Reference< XModel > xModel( xEmbObj->getComponent(), UNO_QUERY_THROW ); mxChart->Convert( xModel, rDffConv, xPersist->getEntryName(), rSdrObj.GetLogicRect() ); -xPersist->storeOwn(); } catch( const Exception& ) { ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 2 commits - sc/qa sc/source
sc/qa/unit/rangelst_test.cxx | 33 + sc/source/core/data/conditio.cxx |5 - 2 files changed, 37 insertions(+), 1 deletion(-) New commits: commit ef48f2fd617aad8a19c2d5613db8fa513b2ef455 Author: Markus Mohrhard Date: Wed Dec 26 04:10:50 2012 +0100 add a unit test for new method in ScRangeList Change-Id: Id27973cc82c71daffec62cbaccba30777c08612b diff --git a/sc/qa/unit/rangelst_test.cxx b/sc/qa/unit/rangelst_test.cxx index b5381ec..62d9002 100644 --- a/sc/qa/unit/rangelst_test.cxx +++ b/sc/qa/unit/rangelst_test.cxx @@ -38,6 +38,7 @@ public: void testDeleteArea_0Ranges(); void testJoin_Case1(); void testJoin_Case2(); +void testGetIntersectedRange(); void testUpdateReference_DeleteRow(); void testUpdateReference_DeleteCol(); @@ -63,6 +64,7 @@ public: CPPUNIT_TEST(testJoin_Case2); CPPUNIT_TEST(testUpdateReference_DeleteRow); CPPUNIT_TEST(testUpdateReference_DeleteCol); +CPPUNIT_TEST(testGetIntersectedRange); CPPUNIT_TEST_SUITE_END(); @@ -71,6 +73,30 @@ private: ScDocShellRef m_xDocShRef; }; +namespace { + +std::ostream& operator<<(std::ostream& rStrm, const ScAddress& rAddr) +{ +rStrm << "Col: " << rAddr.Col() << " Row: " << rAddr.Row() << " Tab: " << rAddr.Tab() << "\n"; +return rStrm; +} + +std::ostream& operator<<(std::ostream& rStrm, const ScRange& rRange) +{ +rStrm << "ScRange: " << rRange.aStart << rRange.aEnd << "\n"; +return rStrm; +} + +std::ostream& operator<<(std::ostream& rStrm, const ScRangeList& rList) +{ +rStrm << "ScRangeList: \n"; +for(size_t i = 0; i < rList.size(); ++i) +rStrm << *rList[i]; +return rStrm; +} + +} + void Test::setUp() { @@ -449,6 +475,13 @@ void Test::testUpdateReference_DeleteCol() CPPUNIT_ASSERT_EQUAL(static_cast(12), aList.GetCellCount()); } +void Test::testGetIntersectedRange() +{ +ScRangeList aList(ScRange(2, 2, 0, 5, 5, 0)); +ScRangeList aIntersecting = aList.GetIntersectedRange(ScRange(0, 0, 0, 3, 3, 0)); +CPPUNIT_ASSERT_EQUAL(ScRangeList(ScRange(2,2,0,3,3,0)), aIntersecting); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Test); CPPUNIT_PLUGIN_IMPLEMENT(); commit 7c528f40e0aea9386d175b007974c02d265f96c6 Author: Markus Mohrhard Date: Wed Dec 26 04:09:31 2012 +0100 one more improvement around cond format rendering, fdo#57896 Change-Id: I5eb267ec2d1666edd53f5b9d58fd2a0cec044aa1 diff --git a/sc/source/core/data/conditio.cxx b/sc/source/core/data/conditio.cxx index 3dcc3be..016c5e9 100644 --- a/sc/source/core/data/conditio.cxx +++ b/sc/source/core/data/conditio.cxx @@ -1973,7 +1973,10 @@ void ScConditionalFormat::dumpInfo(rtl::OUStringBuffer& rBuf) const void ScConditionalFormat::DoRepaint( const ScRange* pModified ) { if(pModified) -pDoc->RepaintRange(*pModified); +{ +if(maRanges.Intersects(*pModified)) +pDoc->RepaintRange(*pModified); +} else { // all conditional format cells ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: Branch 'libreoffice-4-0' - 2 commits - sc/qa sc/source
sc/qa/unit/rangelst_test.cxx | 33 + sc/source/core/data/conditio.cxx |5 - 2 files changed, 37 insertions(+), 1 deletion(-) New commits: commit 29ffe4813bff7fa1925fad4da6e0ce2a37748dbf Author: Markus Mohrhard Date: Wed Dec 26 04:10:50 2012 +0100 add a unit test for new method in ScRangeList Change-Id: Id27973cc82c71daffec62cbaccba30777c08612b diff --git a/sc/qa/unit/rangelst_test.cxx b/sc/qa/unit/rangelst_test.cxx index b5381ec..62d9002 100644 --- a/sc/qa/unit/rangelst_test.cxx +++ b/sc/qa/unit/rangelst_test.cxx @@ -38,6 +38,7 @@ public: void testDeleteArea_0Ranges(); void testJoin_Case1(); void testJoin_Case2(); +void testGetIntersectedRange(); void testUpdateReference_DeleteRow(); void testUpdateReference_DeleteCol(); @@ -63,6 +64,7 @@ public: CPPUNIT_TEST(testJoin_Case2); CPPUNIT_TEST(testUpdateReference_DeleteRow); CPPUNIT_TEST(testUpdateReference_DeleteCol); +CPPUNIT_TEST(testGetIntersectedRange); CPPUNIT_TEST_SUITE_END(); @@ -71,6 +73,30 @@ private: ScDocShellRef m_xDocShRef; }; +namespace { + +std::ostream& operator<<(std::ostream& rStrm, const ScAddress& rAddr) +{ +rStrm << "Col: " << rAddr.Col() << " Row: " << rAddr.Row() << " Tab: " << rAddr.Tab() << "\n"; +return rStrm; +} + +std::ostream& operator<<(std::ostream& rStrm, const ScRange& rRange) +{ +rStrm << "ScRange: " << rRange.aStart << rRange.aEnd << "\n"; +return rStrm; +} + +std::ostream& operator<<(std::ostream& rStrm, const ScRangeList& rList) +{ +rStrm << "ScRangeList: \n"; +for(size_t i = 0; i < rList.size(); ++i) +rStrm << *rList[i]; +return rStrm; +} + +} + void Test::setUp() { @@ -449,6 +475,13 @@ void Test::testUpdateReference_DeleteCol() CPPUNIT_ASSERT_EQUAL(static_cast(12), aList.GetCellCount()); } +void Test::testGetIntersectedRange() +{ +ScRangeList aList(ScRange(2, 2, 0, 5, 5, 0)); +ScRangeList aIntersecting = aList.GetIntersectedRange(ScRange(0, 0, 0, 3, 3, 0)); +CPPUNIT_ASSERT_EQUAL(ScRangeList(ScRange(2,2,0,3,3,0)), aIntersecting); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Test); CPPUNIT_PLUGIN_IMPLEMENT(); commit f5e29978a8aa0260f91a9a7f5a648c602b9bad7d Author: Markus Mohrhard Date: Wed Dec 26 04:09:31 2012 +0100 one more improvement around cond format rendering, fdo#57896 Change-Id: I5eb267ec2d1666edd53f5b9d58fd2a0cec044aa1 diff --git a/sc/source/core/data/conditio.cxx b/sc/source/core/data/conditio.cxx index f72fa73..b0e99cb 100644 --- a/sc/source/core/data/conditio.cxx +++ b/sc/source/core/data/conditio.cxx @@ -1973,7 +1973,10 @@ void ScConditionalFormat::dumpInfo(rtl::OUStringBuffer& rBuf) const void ScConditionalFormat::DoRepaint( const ScRange* pModified ) { if(pModified) -pDoc->RepaintRange(*pModified); +{ +if(maRanges.Intersects(*pModified)) +pDoc->RepaintRange(*pModified); +} else { // all conditional format cells ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[PATCH] OUString cleanup in oox
Hi, I have submitted a patch for review: https://gerrit.libreoffice.org/1485 To pull it, you can do: git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/85/1485/1 OUString cleanup in oox Change-Id: Id3c121acddd515621325c93735bb3dd88592749e Signed-off-by: José Guilherme Vanz --- M oox/source/ole/axbinaryreader.cxx M oox/source/ole/axbinarywriter.cxx M oox/source/ole/axcontrol.cxx M oox/source/ole/axcontrolfragment.cxx M oox/source/ole/axfontdata.cxx M oox/source/ole/olehelper.cxx M oox/source/ole/oleobjecthelper.cxx M oox/source/ole/olestorage.cxx M oox/source/ole/vbacontrol.cxx M oox/source/ole/vbahelper.cxx M oox/source/ole/vbamodule.cxx M oox/source/ole/vbaproject.cxx 12 files changed, 70 insertions(+), 95 deletions(-) -- To view, visit https://gerrit.libreoffice.org/1485 To unsubscribe, visit https://gerrit.libreoffice.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Id3c121acddd515621325c93735bb3dd88592749e Gerrit-PatchSet: 1 Gerrit-Project: core Gerrit-Branch: master Gerrit-Owner: José Guilherme Vanz ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] .: instsetoo_native/util
instsetoo_native/util/makefile.mk |5 - 1 file changed, 4 insertions(+), 1 deletion(-) New commits: commit 53a5bf7529255e59d63645ee6a453ed56df39a9d Author: Tor Lillqvist Date: Wed Dec 26 02:51:19 2012 +0200 Fix the MSVC build with --without-help It tried to build helppack installer(s) anyway as it looked for "HELP" in BUILD_TYPE and was fooled by the "DBGHELP". Change-Id: I9a271a464a776f4f4dad8ea1bef662966b88f944 diff --git a/instsetoo_native/util/makefile.mk b/instsetoo_native/util/makefile.mk index 574ce4c..ea1022b0 100644 --- a/instsetoo_native/util/makefile.mk +++ b/instsetoo_native/util/makefile.mk @@ -68,7 +68,10 @@ LOCALPYFILES= \ $(BIN)$/pythonloader.py .ENDIF -.IF "$(BUILD_TYPE)"=="$(BUILD_TYPE:s/HELP//)" +# We can be pretty sure that the "HELP" in BUILD_TYPE, if it is there, +# is surrounded by spaces. We can't look for just "HELP" here because +# then DBGHELP would match... +.IF "$(BUILD_TYPE)"=="$(BUILD_TYPE:s/ HELP //)" OOOHELPPACK= OOODEVHELPPACK= .ELSE ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 3 commits - sw/source
sw/source/filter/ww1/w1class.cxx |2 +- sw/source/filter/ww1/w1class.hxx | 18 +- sw/source/filter/ww1/w1filter.cxx | 30 +++--- sw/source/filter/ww1/w1sprm.cxx| 10 ++ sw/source/filter/ww8/rtfexport.cxx |6 +++--- sw/source/filter/ww8/rtfexport.hxx |3 +-- sw/source/filter/ww8/wrtw8esh.cxx |4 ++-- sw/source/filter/ww8/wrtw8nds.cxx |4 ++-- sw/source/filter/ww8/ww8par.cxx|6 +++--- sw/source/filter/ww8/ww8par2.cxx |2 +- 10 files changed, 39 insertions(+), 46 deletions(-) New commits: commit 7af975da68a51aa640ca6cd239f98ee1f7b9ef45 Author: Takeshi Abe Date: Tue Dec 25 22:21:15 2012 +0900 Drop unused variable Change-Id: Iccfc052323f61f8b5416c7e4c68df3c7aeeb3b1c diff --git a/sw/source/filter/ww8/rtfexport.hxx b/sw/source/filter/ww8/rtfexport.hxx index 1db1a2d..6cd33ce 100644 --- a/sw/source/filter/ww8/rtfexport.hxx +++ b/sw/source/filter/ww8/rtfexport.hxx @@ -152,7 +152,6 @@ public: /// This is used by OutputFlyFrame_Impl() to control the written syntax bool bRTFFlySyntax; -sal_Bool m_bOutStyleTab : 1; SvStream& Strm(); SvStream& OutULong( sal_uLong nVal ); SvStream& OutLong( long nVal ); commit 31e7ef32646dee9aea1b455e9f408ec0dc0be54a Author: Takeshi Abe Date: Tue Dec 25 22:20:32 2012 +0900 Nuke unreachable code Change-Id: Id6db5aafda2f240225e6655ca7d5f594b072be31 diff --git a/sw/source/filter/ww1/w1sprm.cxx b/sw/source/filter/ww1/w1sprm.cxx index 9534483..0a7b243 100644 --- a/sw/source/filter/ww1/w1sprm.cxx +++ b/sw/source/filter/ww1/w1sprm.cxx @@ -321,7 +321,6 @@ void Ww1SingleSprmPDyaLine::Start( if(nSpace < 0) nSpace = -nSpace; SvxLineSpacingItem aLSpc( LINE_SPACE_DEFAULT_HEIGHT, RES_PARATR_LINESPACING ); -if(sal_True) {// MultilineSpace(proportional) long n = nSpace * 100 / 240;// W1: 240 = 100%, SW: 100 = 100% if(n>200) @@ -329,11 +328,6 @@ void Ww1SingleSprmPDyaLine::Start( aLSpc.GetLineSpaceRule() = SVX_LINE_SPACE_AUTO; aLSpc.SetPropLineSpace((sal_uInt8)n); } -else -{// Fixed / Minimum -aLSpc.SetLineHeight((sal_uInt16)nSpace); -aLSpc.GetInterLineSpaceRule() = SVX_INTER_LINE_SPACE_OFF; -} rOut << aLSpc; } commit 5bfe7ed9e7a3fdb3106ab8d61624ba0136073fb9 Author: Takeshi Abe Date: Tue Dec 25 22:17:38 2012 +0900 sal_Bool to bool Change-Id: I42b4d27101f663a75aa8fc1c13e5ec3f03c8a2da diff --git a/sw/source/filter/ww1/w1class.cxx b/sw/source/filter/ww1/w1class.cxx index 28b5435..e39e8d3 100644 --- a/sw/source/filter/ww1/w1class.cxx +++ b/sw/source/filter/ww1/w1class.cxx @@ -1188,7 +1188,7 @@ void Ww1Chp::operator++() // Manager Ww1Manager::Ww1Manager(SvStream& rStrm, sal_uLong nFieldFlgs) -: bOK(sal_False), bInTtp(sal_False), bInStyle(sal_False), bStopAll(sal_False), aFib(rStrm), +: bOK(sal_False), bInTtp(false), bInStyle(false), bStopAll(false), aFib(rStrm), aDop(aFib), aFonts(aFib, nFieldFlgs), aDoc(aFib), pDoc(&aDoc), ulDocSeek(0), pSeek(&ulDocSeek), aFld(aFib), pFld(&aFld), aChp(aFib), aPap(aFib), aFtn(aFib), aBooks(aFib), diff --git a/sw/source/filter/ww1/w1class.hxx b/sw/source/filter/ww1/w1class.hxx index acc52a1..b6cb854 100644 --- a/sw/source/filter/ww1/w1class.hxx +++ b/sw/source/filter/ww1/w1class.hxx @@ -1496,9 +1496,9 @@ public: class Ww1Manager { sal_Bool bOK; -sal_Bool bInTtp; -sal_Bool bInStyle; -sal_Bool bStopAll; +bool bInTtp; +bool bInStyle; +bool bStopAll; Ww1Fib aFib; Ww1Dop aDop; Ww1Fonts aFonts; @@ -1526,12 +1526,12 @@ public: sal_Bool GetError() const { return !bOK; } // Fuer Tabellen -void SetInTtp(sal_Bool bSet = sal_True) { bInTtp = bSet; } -sal_Bool IsInTtp() const{ return bInTtp; } -void SetInStyle(sal_Bool bSet = sal_True) { bInStyle = bSet; } -sal_Bool IsInStyle() const { return bInStyle; } -void SetStopAll(sal_Bool bSet = sal_True) { bStopAll = bSet; } -sal_Bool IsStopAll() const { return bStopAll; } +void SetInTtp(bool bSet = true) { bInTtp = bSet; } +bool IsInTtp() const{ return bInTtp; } +void SetInStyle(bool bSet = true) { bInStyle = bSet; } +bool IsInStyle() const { return bInStyle; } +void SetStopAll(bool bSet = true) { bStopAll = bSet; } +bool IsStopAll() const { return bStopAll; } sal_Bool HasInTable(); sal_Bool HasTtp(); sal_Bool LastHasTtp(); diff --git a/sw/source/filter/ww1/w1filter.cxx b/sw/source/filter/ww1/w1filter.cxx index bf31f5a..9aa1755 100644 --- a/sw/source/filter/ww1/w1filter.cxx +++ b/sw/source/filter/ww1/w1filter.cxx @@ -96,9 +96,9 @@ Ww1Shell& operator <<(Ww1Shell& rOut, Ww1Manager& This) if (!This.Pushed()) { { // der wird nur tempo
[Libreoffice-commits] .: configure.ac
configure.ac |1 + 1 file changed, 1 insertion(+) New commits: commit 8b456d10989438616466e95bf2062efc2ba32659 Author: Tor Lillqvist Date: Wed Dec 26 02:32:13 2012 +0200 Add config/config_graphite.h.in diff --git a/configure.ac b/configure.ac index 032c9c4..9de1aec 100644 --- a/configure.ac +++ b/configure.ac @@ -4165,6 +4165,7 @@ if test "$cross_compiling" = "yes"; then configure \ Makefile.in \ config/config_global.h.in \ +config/config_graphite.h.in \ config/config_telepathy.h.in \ config/config_vclplug.h.in \ bin/get_config_variables \ ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: distro-configs/LibreOfficeiOS.conf
distro-configs/LibreOfficeiOS.conf |2 -- 1 file changed, 2 deletions(-) New commits: commit 56b555387be3478c3f2a2749b7e1e4239683d846 Author: Tor Lillqvist Date: Wed Dec 26 02:29:38 2012 +0200 Drop obsolete options diff --git a/distro-configs/LibreOfficeiOS.conf b/distro-configs/LibreOfficeiOS.conf index 70bd6e4..f552e94 100644 --- a/distro-configs/LibreOfficeiOS.conf +++ b/distro-configs/LibreOfficeiOS.conf @@ -8,9 +8,7 @@ --disable-gnome-vfs --disable-gstreamer-0-10 --disable-gstreamer ---disable-librsvg --disable-lockdown ---disable-mozilla --disable-odk --disable-opengl --disable-postgresql-sdbc ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Bug 54157] LibreOffice 3.7/4.0 most annoying bugs
https://bugs.freedesktop.org/show_bug.cgi?id=54157 Bug 54157 depends on bug 58686, which changed state. Bug 58686 Summary: CRASH when edit CONDITIONAL FORMATTING https://bugs.freedesktop.org/show_bug.cgi?id=58686 What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] .: 2 commits - sc/inc sc/source
sc/inc/rangelst.hxx |2 + sc/source/core/data/documen2.cxx |2 + sc/source/core/data/table2.cxx | 71 +++ sc/source/core/tool/rangelst.cxx | 26 ++ sc/source/ui/view/cellsh1.cxx|4 +- 5 files changed, 54 insertions(+), 51 deletions(-) New commits: commit eaecc7971f7024a0f5aa7df1d933bd60a9f1357c Author: Markus Mohrhard Date: Tue Dec 25 21:04:15 2012 +0100 simplify cond format copy&paste code, fdo#58677 This should also help with fdo#57896 and some other problems I found Change-Id: I8cb3eb69a7ec1413cb57ce81c5f4d806250474e5 diff --git a/sc/inc/rangelst.hxx b/sc/inc/rangelst.hxx index 06cebec..b67445b 100644 --- a/sc/inc/rangelst.hxx +++ b/sc/inc/rangelst.hxx @@ -74,6 +74,8 @@ public: size_t GetCellCount() const; ScAddress GetTopLeftCorner() const; +ScRangeList GetIntersectedRange(const ScRange& rRange) const; + ScRange*Remove(size_t nPos); voidRemoveAll(); diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx index 095b41a..79f90f4 100644 --- a/sc/source/core/data/documen2.cxx +++ b/sc/source/core/data/documen2.cxx @@ -955,6 +955,8 @@ sal_uLong ScDocument::TransferTab( ScDocument* pSrcDoc, SCTAB nSrcPos, pSrcDoc->maTabs[nSrcPos]->CopyToTable(0, 0, MAXCOL, MAXROW, ( bResultsOnly ? IDF_ALL & ~IDF_FORMULA : IDF_ALL), false, maTabs[nDestPos] ); +maTabs[nDestPos]->CopyConditionalFormat(0, 0, MAXCOL, MAXROW, +0, 0, pSrcDoc->maTabs[nSrcPos]); } } maTabs[nDestPos]->SetTabNo(nDestPos); diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 6ebfd61..073f726 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -656,62 +656,33 @@ void ScTable::CopyToClip(const ScRangeList& rRanges, ScTable* pTable, void ScTable::CopyConditionalFormat( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, SCsCOL nDx, SCsROW nDy, ScTable* pTable) { -std::map aOldIdToNewId; -std::map aIdToRange; +ScRange aOldRange( nCol1 - nDx, nRow1 - nDy, pTable->nTab, nCol2 - nDx, nRow2 - nDy, pTable->nTab); +ScRange aNewRange( nCol1, nRow1, nTab, nCol2, nRow2, nTab ); -ScConditionalFormatList* pOldCondFormatList = pTable->mpCondFormatList.get(); -for(SCCOL i = nCol1; i <= nCol2; ++i) +for(ScConditionalFormatList::const_iterator itr = pTable->mpCondFormatList->begin(), +itrEnd = pTable->mpCondFormatList->end(); itr != itrEnd; ++itr) { -ScAttrIterator* pIter = pTable->aCol[i-nDx].CreateAttrIterator( nRow1-nDy, nRow2-nDy ); -SCROW nStartRow = 0, nEndRow = 0; -const ScPatternAttr* pPattern = pIter->Next( nStartRow, nEndRow ); -const std::vector& rCondFormatData = static_cast(pPattern->GetItem(ATTR_CONDITIONAL)).GetCondFormatData(); -for(std::vector::const_iterator itr = rCondFormatData.begin(), itrEnd = rCondFormatData.end(); -itr != itrEnd; ++itr) -{ -if (aOldIdToNewId.find(*itr) == aOldIdToNewId.end()) -{ -ScConditionalFormat* pFormat = pOldCondFormatList->GetFormat(*itr); -if(!pFormat) -{ -// may happen in some strange circumstances where cell storage and -// cond format storage are not in sync -continue; -} -ScConditionalFormat* pNewFormat = pFormat->Clone(pDocument); -pNewFormat->SetKey(0); -//not in list => create entries in both maps and new format -sal_uLong nMax = 0; -for(ScConditionalFormatList::const_iterator itrCond = mpCondFormatList->begin(); -itrCond != mpCondFormatList->end(); ++itrCond) -{ -if(itrCond->GetKey() > nMax) -nMax = itrCond->GetKey(); -} -pNewFormat->SetKey(nMax + 1); -mpCondFormatList->InsertNew(pNewFormat); -sal_Int32 nNewId = pNewFormat->GetKey(); -aOldIdToNewId.insert( std::pair( *itr, nNewId ) ); -aIdToRange.insert( std::pair( *itr, ScRangeList() ) ); -} +const ScRangeList& rCondFormatRange = itr->GetRange(); +if(!rCondFormatRange.Intersects( aOldRange )) +continue; -aIdToRange.find(*itr)->second.Join( ScRange( i, nStartRow + nDy, nTab, i, nEndRow + nDy, nTab ) ); -} -} +ScRangeList aIntersectedRange = rCondFormatRange.GetIntersectedRange(aOldRange); +ScConditionalFormat* pNewFormat = itr->Clone(pDocument); -for(std::map::const_iterator itr = aIdToRange.begin(); -itr != aIdToRa
[Libreoffice-commits] .: Branch 'libreoffice-4-0' - 2 commits - sc/inc sc/source
sc/inc/rangelst.hxx |2 + sc/source/core/data/documen2.cxx |2 + sc/source/core/data/table2.cxx | 71 +++ sc/source/core/tool/rangelst.cxx | 26 ++ sc/source/ui/view/cellsh1.cxx|4 +- 5 files changed, 54 insertions(+), 51 deletions(-) New commits: commit 350ae8294a8df78403fd8cdce56b9aeb8178e130 Author: Markus Mohrhard Date: Tue Dec 25 21:04:15 2012 +0100 simplify cond format copy&paste code, fdo#58677 This should also help with fdo#57896 and some other problems I found Change-Id: I8cb3eb69a7ec1413cb57ce81c5f4d806250474e5 diff --git a/sc/inc/rangelst.hxx b/sc/inc/rangelst.hxx index 06cebec..b67445b 100644 --- a/sc/inc/rangelst.hxx +++ b/sc/inc/rangelst.hxx @@ -74,6 +74,8 @@ public: size_t GetCellCount() const; ScAddress GetTopLeftCorner() const; +ScRangeList GetIntersectedRange(const ScRange& rRange) const; + ScRange*Remove(size_t nPos); voidRemoveAll(); diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx index 095b41a..79f90f4 100644 --- a/sc/source/core/data/documen2.cxx +++ b/sc/source/core/data/documen2.cxx @@ -955,6 +955,8 @@ sal_uLong ScDocument::TransferTab( ScDocument* pSrcDoc, SCTAB nSrcPos, pSrcDoc->maTabs[nSrcPos]->CopyToTable(0, 0, MAXCOL, MAXROW, ( bResultsOnly ? IDF_ALL & ~IDF_FORMULA : IDF_ALL), false, maTabs[nDestPos] ); +maTabs[nDestPos]->CopyConditionalFormat(0, 0, MAXCOL, MAXROW, +0, 0, pSrcDoc->maTabs[nSrcPos]); } } maTabs[nDestPos]->SetTabNo(nDestPos); diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 6ebfd61..073f726 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -656,62 +656,33 @@ void ScTable::CopyToClip(const ScRangeList& rRanges, ScTable* pTable, void ScTable::CopyConditionalFormat( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, SCsCOL nDx, SCsROW nDy, ScTable* pTable) { -std::map aOldIdToNewId; -std::map aIdToRange; +ScRange aOldRange( nCol1 - nDx, nRow1 - nDy, pTable->nTab, nCol2 - nDx, nRow2 - nDy, pTable->nTab); +ScRange aNewRange( nCol1, nRow1, nTab, nCol2, nRow2, nTab ); -ScConditionalFormatList* pOldCondFormatList = pTable->mpCondFormatList.get(); -for(SCCOL i = nCol1; i <= nCol2; ++i) +for(ScConditionalFormatList::const_iterator itr = pTable->mpCondFormatList->begin(), +itrEnd = pTable->mpCondFormatList->end(); itr != itrEnd; ++itr) { -ScAttrIterator* pIter = pTable->aCol[i-nDx].CreateAttrIterator( nRow1-nDy, nRow2-nDy ); -SCROW nStartRow = 0, nEndRow = 0; -const ScPatternAttr* pPattern = pIter->Next( nStartRow, nEndRow ); -const std::vector& rCondFormatData = static_cast(pPattern->GetItem(ATTR_CONDITIONAL)).GetCondFormatData(); -for(std::vector::const_iterator itr = rCondFormatData.begin(), itrEnd = rCondFormatData.end(); -itr != itrEnd; ++itr) -{ -if (aOldIdToNewId.find(*itr) == aOldIdToNewId.end()) -{ -ScConditionalFormat* pFormat = pOldCondFormatList->GetFormat(*itr); -if(!pFormat) -{ -// may happen in some strange circumstances where cell storage and -// cond format storage are not in sync -continue; -} -ScConditionalFormat* pNewFormat = pFormat->Clone(pDocument); -pNewFormat->SetKey(0); -//not in list => create entries in both maps and new format -sal_uLong nMax = 0; -for(ScConditionalFormatList::const_iterator itrCond = mpCondFormatList->begin(); -itrCond != mpCondFormatList->end(); ++itrCond) -{ -if(itrCond->GetKey() > nMax) -nMax = itrCond->GetKey(); -} -pNewFormat->SetKey(nMax + 1); -mpCondFormatList->InsertNew(pNewFormat); -sal_Int32 nNewId = pNewFormat->GetKey(); -aOldIdToNewId.insert( std::pair( *itr, nNewId ) ); -aIdToRange.insert( std::pair( *itr, ScRangeList() ) ); -} +const ScRangeList& rCondFormatRange = itr->GetRange(); +if(!rCondFormatRange.Intersects( aOldRange )) +continue; -aIdToRange.find(*itr)->second.Join( ScRange( i, nStartRow + nDy, nTab, i, nEndRow + nDy, nTab ) ); -} -} +ScRangeList aIntersectedRange = rCondFormatRange.GetIntersectedRange(aOldRange); +ScConditionalFormat* pNewFormat = itr->Clone(pDocument); -for(std::map::const_iterator itr = aIdToRange.begin(); -itr != aIdToRa
[PATCH] Cleanup: #include
Hi, I have submitted a patch for review: https://gerrit.libreoffice.org/1484 To pull it, you can do: git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/84/1484/1 Cleanup: #include Change-Id: Ic547b4a59102afc8bdbc85ec95ac312e32ef2530 --- M accessibility/source/extended/AccessibleBrowseBoxTableCell.cxx M accessibility/source/helper/characterattributeshelper.cxx M basctl/source/basicide/iderdll2.hxx M cppcanvas/source/mtfrenderer/pointaction.cxx M cppcanvas/source/mtfrenderer/polypolyaction.cxx M cppcanvas/source/mtfrenderer/textaction.hxx M dbaccess/inc/ToolBoxHelper.hxx M desktop/source/deployment/gui/dp_gui_dependencydialog.cxx M editeng/inc/editeng/svxfont.hxx M editeng/source/items/svxfont.cxx M editeng/source/misc/swafopt.cxx M filter/source/graphicfilter/idxf/dxfvec.cxx M filter/source/graphicfilter/idxf/dxfvec.hxx M idl/inc/bastype.hxx M idl/inc/lex.hxx M lotuswordpro/source/filter/lwpgrfobj.hxx M sc/inc/postit.hxx M sc/source/core/data/postit.cxx M sc/source/filter/excel/xechart.cxx M sc/source/filter/inc/imp_op.hxx M sc/source/filter/inc/xechart.hxx M sc/source/ui/inc/formdata.hxx M sd/inc/sdfilter.hxx M sd/source/filter/eppt/eppt.hxx M sd/source/filter/ppt/propread.hxx M sd/source/ui/inc/undoheaderfooter.hxx M sd/source/ui/slidesorter/cache/SlsBitmapCompressor.hxx M sd/source/ui/slidesorter/cache/SlsPageCache.cxx M sd/source/ui/slidesorter/inc/cache/SlsPageCache.hxx M sd/source/ui/slidesorter/inc/controller/SlsAnimationFunction.hxx M sd/source/ui/slidesorter/inc/controller/SlsScrollBarManager.hxx M sd/source/ui/slidesorter/inc/controller/SlsSelectionObserver.hxx M sd/source/ui/slidesorter/view/SlsLayeredDevice.cxx M sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx M sfx2/inc/sfx2/imgmgr.hxx M slideshow/source/engine/OGLTrans/unx/OGLTrans_TransitionerImpl.cxx M slideshow/source/engine/OGLTrans/win/OGLTrans_TransitionerImpl.cxx M svl/source/items/szitem.cxx M svtools/inc/svtools/fltcall.hxx M svtools/inc/svtools/javainteractionhandler.hxx M svtools/inc/svtools/scriptedtext.hxx M svtools/source/control/scriptedtext.cxx M svx/inc/svx/EnhancedCustomShape2d.hxx M svx/inc/svx/IAccessibleViewForwarderListener.hxx M svx/inc/svx/framelink.hxx M svx/inc/svx/msdffdef.hxx M svx/inc/svx/sdr/contact/objectcontactofpageview.hxx M svx/inc/svx/sdr/contact/viewcontact.hxx M svx/inc/svx/sdr/contact/viewcontactofsdrmediaobj.hxx M svx/inc/svx/sdr/contact/viewobjectcontact.hxx M svx/inc/svx/sdr/contact/viewobjectcontactofsdrmediaobj.hxx M svx/inc/svx/sdr/overlay/overlayhatchrect.hxx M svx/inc/svx/sdr/overlay/overlayobjectlist.hxx M svx/inc/svx/unoshape.hxx M svx/inc/xpolyimp.hxx M svx/source/dialog/framelink.cxx M svx/source/gallery2/codec.hxx M svx/source/mnuctrls/clipboardctl.cxx M svx/source/sdr/overlay/overlaycrosshair.cxx M svx/source/sdr/overlay/overlayhelpline.cxx M svx/source/sdr/overlay/overlayline.cxx M svx/source/sdr/overlay/overlayobjectlist.cxx M svx/source/sdr/overlay/overlayrollingrectangle.cxx M svx/source/svdraw/gradtrns.hxx M svx/source/table/tablelayouter.cxx M svx/source/table/tablelayouter.hxx M svx/source/table/tablemodel.cxx M svx/source/table/tablemodel.hxx M svx/source/tbxctrls/lboxctrl.cxx M svx/source/unodraw/unoshape.cxx M svx/source/xoutdev/_xpoly.cxx M sw/inc/anchoreddrawobject.hxx M sw/inc/frmfmt.hxx M sw/inc/node.hxx M sw/inc/numrule.hxx M sw/inc/pam.hxx M sw/source/core/crsr/pam.cxx M sw/source/core/docnode/node.cxx M sw/source/core/fields/postithelper.cxx M sw/source/core/inc/fntcache.hxx M sw/source/core/inc/swfont.hxx M sw/source/core/layout/anchoreddrawobject.cxx M toolkit/inc/toolkit/awt/vclxaccessiblecomponent.hxx M tools/inc/poly.h M tools/inc/tools/svborder.hxx M tools/source/generic/poly.cxx M tools/source/generic/poly2.cxx M vcl/generic/print/glyphset.cxx M vcl/generic/print/glyphset.hxx M vcl/inc/generic/gendisp.hxx M vcl/inc/outfont.hxx M vcl/inc/svdata.hxx M vcl/inc/unx/i18n_status.hxx M vcl/inc/unx/salstd.hxx M vcl/inc/vcl/font.hxx M vcl/inc/vcl/gradient.hxx M vcl/inc/vcl/lineinfo.hxx M vcl/inc/vcl/wall.hxx M vcl/source/app/svdata.cxx M vcl/source/gdi/font.cxx M vcl/source/gdi/gradient.cxx 101 files changed, 121 insertions(+), 81 deletions(-) -- To view, visit https://gerrit.libreoffice.org/1484 To unsubscribe, visit https://gerrit.libreoffice.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic547b4a59102afc8bdbc85ec95ac312e32ef2530 Gerrit-PatchSet: 1 Gerrit-Project: core Gerrit-Branch: master Gerrit-Owner: Matteo Casalin ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[PUSHED] Get rid of (most uses of) GUI
Hi, Thank you for your patch! It has been merged to LibreOffice. If you are interested in details, please visit https://gerrit.libreoffice.org/1304 Approvals: Peter Foley: Verified; Looks good to me, approved -- To view, visit https://gerrit.libreoffice.org/1304 To unsubscribe, visit https://gerrit.libreoffice.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I78ae32c03536a496a563e5deeb0fca78aebf9c34 Gerrit-PatchSet: 2 Gerrit-Project: core Gerrit-Branch: master Gerrit-Owner: Tor Lillqvist Gerrit-Reviewer: Michael Stahl Gerrit-Reviewer: Norbert Thiebaud Gerrit-Reviewer: Peter Foley Gerrit-Reviewer: Tor Lillqvist ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice-commits] .: bean/Library_officebean.mk RepositoryExternal.mk
RepositoryExternal.mk | 15 +++ bean/Library_officebean.mk |4 2 files changed, 19 insertions(+) New commits: commit e5ccda4bb32eef8cab99c4d43c1571ec4bad3980 Author: Peter Foley Date: Tue Dec 25 11:23:58 2012 -0500 fix officebean on mingw Change-Id: I18994c4c825748344f8d203e1a6be6b242249409 diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk index a982882..015eb88 100644 --- a/RepositoryExternal.mk +++ b/RepositoryExternal.mk @@ -507,6 +507,21 @@ endef endif # SYSTEM_LIBCMIS +ifeq ($(OS)$(COM),WNTGCC) + +define gb_LinkTarget__use_jawt +$(call gb_LinkTarget_use_packages,$(1),\ + jawt \ +) + +endef + +else # $(OS)$(COM) != WNTGCC + +gb_LinkTarget__use_jawt := + +endif # $(OS)$(COM) = WNTGCC + ifeq ($(SYSTEM_LIBEXTTEXTCAT),YES) diff --git a/bean/Library_officebean.mk b/bean/Library_officebean.mk index 1c3fb1f..2229e62 100644 --- a/bean/Library_officebean.mk +++ b/bean/Library_officebean.mk @@ -36,6 +36,10 @@ $(eval $(call gb_Library_use_packages,officebean,\ sal_inc \ )) +$(eval $(call gb_Library_use_externals,officebean,\ + jawt \ +)) + $(eval $(call gb_Library_add_cobjects,officebean,\ bean/native/unix/com_sun_star_comp_beans_LocalOfficeWindow \ bean/native/unix/com_sun_star_beans_LocalOfficeWindow \ ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 2 commits - Module_tail_build.mk tail_build/prj
Module_tail_build.mk |2 ++ tail_build/prj/build.lst |2 +- 2 files changed, 3 insertions(+), 1 deletion(-) New commits: commit 43a9cd8a9c6fe9db2f899cf35095baf6f559c6b2 Author: Peter Foley Date: Tue Dec 25 09:53:31 2012 -0500 add libpng to tail_build Change-Id: Icac37cd3e82c5dd4bb6339c57e70f47054a17c12 diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 6bd6539..b8c21ac 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -101,6 +101,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_build,\ $(call gb_Helper_optional,CMIS,libcmis) \ $(call gb_Helper_optional,LIBEXTTEXTCAT,libexttextcat) \ $(call gb_Helper_optional,LIBLANGTAG,liblangtag) \ + $(call gb_Helper_optional,LIBPNG,libpng) \ $(call gb_Helper_optional,MSPUB,libmspub) \ $(call gb_Helper_optional,ORCUS,liborcus) \ librelogo \ diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index bc769be..19db532 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : EXPAT:expat FONTCONFIG:fontconfig ICU:icu LIBPNG:libpng LIBXML2:libxml2 LIBXSLT:libxslt MOZ:moz NSS:nss OPENSSL:openssl PYTHON:python3 REDLAND:redland XPDF:xpdf external solenv soltools NULL +tb tail_build : EXPAT:expat FONTCONFIG:fontconfig ICU:icu LIBXML2:libxml2 LIBXSLT:libxslt MOZ:moz NSS:nss OPENSSL:openssl PYTHON:python3 REDLAND:redland XPDF:xpdf external solenv soltools NULL tb tail_build\prj nmake - all tb_prj NULL commit 01c7923d726c842cbd30daaeb1bccc985f10c240 Author: Peter Foley Date: Tue Dec 25 09:50:19 2012 -0500 add zlib to tail_build Change-Id: If891480564760044ad0af792f8c21a8ca1a06580 diff --git a/Module_tail_build.mk b/Module_tail_build.mk index 34569d1..6bd6539 100644 --- a/Module_tail_build.mk +++ b/Module_tail_build.mk @@ -203,6 +203,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_build,\ xmlscript \ xmlsecurity \ $(call gb_Helper_optional,XSLTML,xsltml) \ + $(call gb_Helper_optional,ZLIB,zlib) \ )) ifeq ($(MERGELIBS),TRUE) diff --git a/tail_build/prj/build.lst b/tail_build/prj/build.lst index 1adb285..bc769be 100644 --- a/tail_build/prj/build.lst +++ b/tail_build/prj/build.lst @@ -1,2 +1,2 @@ -tb tail_build : EXPAT:expat FONTCONFIG:fontconfig ICU:icu LIBPNG:libpng LIBXML2:libxml2 LIBXSLT:libxslt MOZ:moz NSS:nss OPENSSL:openssl PYTHON:python3 REDLAND:redland XPDF:xpdf ZLIB:zlib external solenv soltools NULL +tb tail_build : EXPAT:expat FONTCONFIG:fontconfig ICU:icu LIBPNG:libpng LIBXML2:libxml2 LIBXSLT:libxslt MOZ:moz NSS:nss OPENSSL:openssl PYTHON:python3 REDLAND:redland XPDF:xpdf external solenv soltools NULL tb tail_build\prj nmake - all tb_prj NULL ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: editeng/source
editeng/source/accessibility/AccessibleContextBase.cxx |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) New commits: commit 0897b55183dc76f5c9833fb2649116f560a1f034 Author: Peter Foley Date: Tue Dec 25 09:44:16 2012 -0500 build fix for editeng OUString cleanup Change-Id: I82fdca86631d5b364224d151d85da5baef1a54a8 diff --git a/editeng/source/accessibility/AccessibleContextBase.cxx b/editeng/source/accessibility/AccessibleContextBase.cxx index 895f655..14cb720 100644 --- a/editeng/source/accessibility/AccessibleContextBase.cxx +++ b/editeng/source/accessibility/AccessibleContextBase.cxx @@ -504,8 +504,8 @@ uno::Sequence< OUString > SAL_CALL { ThrowIfDisposed (); static const OUString sServiceNames[2] = { -"com.sun.star.accessibility.Accessible", -"com.sun.star.accessibility.AccessibleContext" +OUString("com.sun.star.accessibility.Accessible"), +OUString("com.sun.star.accessibility.AccessibleContext") }; return uno::Sequence (sServiceNames, 2); } ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: l10ntools/source
l10ntools/source/po.cxx |8 1 file changed, 4 insertions(+), 4 deletions(-) New commits: commit db99a31c4e4e7c74d4c4bb7caa747a5752a32757 Author: Zolnai Tamás Date: Sun Dec 23 03:51:17 2012 +0100 fdo#58673 Generate the same keyid for pots as for merge Change-Id: I65c71d22570c62c84d359b12aa5375016be1f69a diff --git a/l10ntools/source/po.cxx b/l10ntools/source/po.cxx index cdc2c98..06530a3 100644 --- a/l10ntools/source/po.cxx +++ b/l10ntools/source/po.cxx @@ -432,14 +432,14 @@ PoEntry::PoEntry(const OString& rSDFLine, const TYPE eType) /*Default case is unneeded because the type of eType has only three element*/ } -m_pGenPo->setExtractCom( -( !vParts[HELPTEXT].isEmpty() ? vParts[HELPTEXT] + "\n" : OString( "" )) + -lcl_GenKeyId( -vParts[SOURCEFILE] + sMsgCtxt + vParts[eType] ) ); m_pGenPo->setMsgCtxt(sMsgCtxt); m_pGenPo->setMsgId( lcl_UnEscapeSDFText( vParts[eType],vParts[SOURCEFILE].endsWith(".xhp"))); +m_pGenPo->setExtractCom( +( !vParts[HELPTEXT].isEmpty() ? vParts[HELPTEXT] + "\n" : OString( "" )) + +lcl_GenKeyId( +m_pGenPo->getReference() + sMsgCtxt + m_pGenPo->getMsgId() ) ); m_bIsInitialized = true; } ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 3 commits - connectivity/source
connectivity/source/drivers/odbcbase/ODatabaseMetaDataResultSet.cxx |1 connectivity/source/drivers/odbcbase/OTools.cxx | 21 -- 2 files changed, 11 insertions(+), 11 deletions(-) New commits: commit 5c0ca47ea05ac169c3aa6af5e95321b5de3e439d Author: Lionel Elie Mamane Date: Tue Dec 25 12:55:59 2012 +0100 ODBC: binary data is not null-terminated Change-Id: Ibc90fabf7534b537948c12de76b611daf5ca9808 diff --git a/connectivity/source/drivers/odbcbase/OTools.cxx b/connectivity/source/drivers/odbcbase/OTools.cxx index fbeeec6..d568b7f 100644 --- a/connectivity/source/drivers/odbcbase/OTools.cxx +++ b/connectivity/source/drivers/odbcbase/OTools.cxx @@ -365,9 +365,11 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, SQLLEN pcbValue = SQL_NO_TOTAL; Sequence aData; -// >= because if the data is nMaxLen long, our buffer is actually ONE byte short, -// for the null byte terminator! -while (pcbValue == SQL_NO_TOTAL || pcbValue >= nMaxLen) +OSL_ENSURE( _fSqlType != SQL_CHAR && _fSqlType != SQL_VARCHAR && _fSqlType != SQL_LONGVARCHAR && +_fSqlType != SQL_WCHAR && _fSqlType != SQL_WVARCHAR && _fSqlType != SQL_WLONGVARCHAR, +"connectivity::odbc::OTools::getBytesValue called with character _fSqlType"); + +while (pcbValue == SQL_NO_TOTAL || pcbValue > nMaxLen) { OTools::ThrowException(_pConnection, (*(T3SQLGetData)_pConnection->getOdbcFunction(ODBC3SQLGetData))( @@ -388,13 +390,8 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, // pcbValue will not be SQL_NO_TOTAL -> we have a reliable count if ( (pcbValue == SQL_NO_TOTAL) || (pcbValue >= nMaxLen) ) { -// we filled the buffer; remove the terminating null byte -nReadBytes = nMaxLen-1; -if ( aCharArray[nReadBytes] != 0) -{ -OSL_FAIL("Buggy ODBC driver? Did not null-terminate (variable length) data!"); -++nReadBytes; -} +// we filled the buffer +nReadBytes = nMaxLen; } else { commit 12bad6a4e958d01bd5b6195e612543829aebe978 Author: Lionel Elie Mamane Date: Tue Dec 25 13:05:04 2012 +0100 no reason to treat CHAR differently than VARCHAR Change-Id: I19a9f1b26d36bc6eb9e878506e51e8a65b34da9a diff --git a/connectivity/source/drivers/odbcbase/ODatabaseMetaDataResultSet.cxx b/connectivity/source/drivers/odbcbase/ODatabaseMetaDataResultSet.cxx index c8e4156..642aba6 100644 --- a/connectivity/source/drivers/odbcbase/ODatabaseMetaDataResultSet.cxx +++ b/connectivity/source/drivers/odbcbase/ODatabaseMetaDataResultSet.cxx @@ -250,6 +250,7 @@ Sequence< sal_Int8 > SAL_CALL ODatabaseMetaDataResultSet::getBytes( sal_Int32 co sal_Int32 nType = getMetaData()->getColumnType(columnIndex); switch(nType) { +case DataType::CHAR: case DataType::VARCHAR: case DataType::LONGVARCHAR: { commit 2f54f2a4ac508de3984d2865da984b9ecf30f602 Author: Lionel Elie Mamane Date: Tue Dec 25 13:04:44 2012 +0100 fdo#58693 ODBC SQLGetData returns byte length, not data size Change-Id: Icd2f6503d9452c36f858180e4193af993ae7e288 diff --git a/connectivity/source/drivers/odbcbase/OTools.cxx b/connectivity/source/drivers/odbcbase/OTools.cxx index 290aa61..fbeeec6 100644 --- a/connectivity/source/drivers/odbcbase/OTools.cxx +++ b/connectivity/source/drivers/odbcbase/OTools.cxx @@ -447,6 +447,8 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, return ::rtl::OUString(); SQLLEN nReadChars; +OSL_ENSURE( (pcbValue < 0) || (pcbValue % 2 == 0), +"ODBC: SQLGetData of SQL_C_WCHAR returned odd number of bytes"); if ( (pcbValue == SQL_NO_TOTAL) || (pcbValue >= nMaxLen) ) { // we filled the buffer; remove the terminating null character @@ -459,7 +461,7 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, } else { -nReadChars = pcbValue; +nReadChars = pcbValue/sizeof(sal_Unicode); } aData.append(waCharArray, nReadChars); ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: Branch 'libreoffice-4-0' - 2 commits - connectivity/source
connectivity/source/drivers/odbcbase/OTools.cxx | 21 ++--- 1 file changed, 10 insertions(+), 11 deletions(-) New commits: commit 51c8bb3242ad1e8e1a5906c4af2ba94c0252b36e Author: Lionel Elie Mamane Date: Tue Dec 25 13:04:44 2012 +0100 fdo#58693 ODBC SQLGetData returns byte length, not data size Change-Id: Icd2f6503d9452c36f858180e4193af993ae7e288 diff --git a/connectivity/source/drivers/odbcbase/OTools.cxx b/connectivity/source/drivers/odbcbase/OTools.cxx index 831eb3a..d568b7f 100644 --- a/connectivity/source/drivers/odbcbase/OTools.cxx +++ b/connectivity/source/drivers/odbcbase/OTools.cxx @@ -444,6 +444,8 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, return ::rtl::OUString(); SQLLEN nReadChars; +OSL_ENSURE( (pcbValue < 0) || (pcbValue % 2 == 0), +"ODBC: SQLGetData of SQL_C_WCHAR returned odd number of bytes"); if ( (pcbValue == SQL_NO_TOTAL) || (pcbValue >= nMaxLen) ) { // we filled the buffer; remove the terminating null character @@ -456,7 +458,7 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, } else { -nReadChars = pcbValue; +nReadChars = pcbValue/sizeof(sal_Unicode); } aData.append(waCharArray, nReadChars); commit 3016e7d84433a1b3bfce91a7a78ffef3c3d71bd9 Author: Lionel Elie Mamane Date: Tue Dec 25 12:55:59 2012 +0100 ODBC: binary data is not null-terminated Change-Id: Ibc90fabf7534b537948c12de76b611daf5ca9808 diff --git a/connectivity/source/drivers/odbcbase/OTools.cxx b/connectivity/source/drivers/odbcbase/OTools.cxx index 290aa61..831eb3a 100644 --- a/connectivity/source/drivers/odbcbase/OTools.cxx +++ b/connectivity/source/drivers/odbcbase/OTools.cxx @@ -365,9 +365,11 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, SQLLEN pcbValue = SQL_NO_TOTAL; Sequence aData; -// >= because if the data is nMaxLen long, our buffer is actually ONE byte short, -// for the null byte terminator! -while (pcbValue == SQL_NO_TOTAL || pcbValue >= nMaxLen) +OSL_ENSURE( _fSqlType != SQL_CHAR && _fSqlType != SQL_VARCHAR && _fSqlType != SQL_LONGVARCHAR && +_fSqlType != SQL_WCHAR && _fSqlType != SQL_WVARCHAR && _fSqlType != SQL_WLONGVARCHAR, +"connectivity::odbc::OTools::getBytesValue called with character _fSqlType"); + +while (pcbValue == SQL_NO_TOTAL || pcbValue > nMaxLen) { OTools::ThrowException(_pConnection, (*(T3SQLGetData)_pConnection->getOdbcFunction(ODBC3SQLGetData))( @@ -388,13 +390,8 @@ Sequence OTools::getBytesValue(const OConnection* _pConnection, // pcbValue will not be SQL_NO_TOTAL -> we have a reliable count if ( (pcbValue == SQL_NO_TOTAL) || (pcbValue >= nMaxLen) ) { -// we filled the buffer; remove the terminating null byte -nReadBytes = nMaxLen-1; -if ( aCharArray[nReadBytes] != 0) -{ -OSL_FAIL("Buggy ODBC driver? Did not null-terminate (variable length) data!"); -++nReadBytes; -} +// we filled the buffer +nReadBytes = nMaxLen; } else { ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: download.lst
download.lst |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit 26eaea11f3ede272dd18289e1caa550daa153fb0 Author: David Tardon Date: Tue Dec 25 12:33:56 2012 +0100 fix dbghelp.dll checksum Change-Id: Iee6b3eb7658d75f7f677066f29a2bccc8e119da1 diff --git a/download.lst b/download.lst index cea356c..0cf4fd1 100644 --- a/download.lst +++ b/download.lst @@ -18,7 +18,7 @@ export CMIS_TARBALL := b2371dc7cf4811c9d32146eec913d296-libcmis-0.3.0.tar.gz export CPPUNIT_TARBALL := ac4781e01619be13461bb2d562b94a7b-cppunit-1.13.1.tar.gz export CT2N_TARBALL := 451ccf439a36a568653b024534669971-ConvertTextToNumber-1.3.2.oxt export CURL_TARBALL := 3fa4d5236f2a36ca5c3af6715e837691-curl-7.26.0.tar.gz -export DBGHELP_DLL := 4003e34416ebd25e4c115d49dc15e1a7-dbghelp.dll +export DBGHELP_DLL := 13fbc2e8b37ddf28181dd6d8081c2b8e-dbghelp.dll export EPM_TARBALL := 3ade8cfe7e59ca8e65052644fed9fca4-epm-3.7.tar.gz export EXPAT_TARBALL := dd7dab7a5fea97d2a6a43f511449b7cd-expat-2.1.0.tar.gz export FONTCONFIG_TARBALL := 77e15a92006ddc2adbb06f840d591c0e-fontconfig-2.8.0.tar.gz ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: setup_native/source
setup_native/source/win32/customactions/shellextensions/completeinstallpath.cxx |2 -- 1 file changed, 2 deletions(-) New commits: commit a737ae58cc95585e90aa946074b68022d9a2dc2b Author: Tor Lillqvist Date: Tue Dec 25 13:31:18 2012 +0200 WaE: unreferenced local variable Change-Id: If234ce4af0f988c135a90a98312e24e4d80ca92c diff --git a/setup_native/source/win32/customactions/shellextensions/completeinstallpath.cxx b/setup_native/source/win32/customactions/shellextensions/completeinstallpath.cxx index 8869ee4..d56ad5e 100644 --- a/setup_native/source/win32/customactions/shellextensions/completeinstallpath.cxx +++ b/setup_native/source/win32/customactions/shellextensions/completeinstallpath.cxx @@ -71,8 +71,6 @@ extern "C" UINT __stdcall CompleteInstallPath( MSIHANDLE handle ) // so that in an OOo 3.3 or later, the directory "program" or "share" are directly created // below "c:\program files". -TCHAR szValue[8192]; -DWORD nValueSize = sizeof(szValue); HKEYhKey; // Reading property OFFICEDIRHOSTNAME_, that contains the part of the path behind ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: Makefile.fetch
Makefile.fetch |3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) New commits: commit bcb69319656df163b031bbce1fcddc05bd49aca6 Author: David Tardon Date: Tue Dec 25 10:56:41 2012 +0100 fix download of dbghelp.dll Change-Id: I200a623b70906a07b1549ff76472678e158496a4 diff --git a/Makefile.fetch b/Makefile.fetch index 4b60d7b..7326355 100644 --- a/Makefile.fetch +++ b/Makefile.fetch @@ -92,7 +92,6 @@ $(WORKDIR)/download: $(BUILDDIR)/config_host.mk $(SRCDIR)/download.lst $(SRCDIR) $(call fetch_Optional,CPPUNIT,$(CPPUNIT_TARBALL)) \ $(call fetch_Optional,CT2N,$(CT2N_TARBALL)) \ $(call fetch_Optional,CURL,$(CURL_TARBALL)) \ - $(call fetch_Optional,DBGHELP,$(DBGHELP_DLL)) \ $(call fetch_Optional,EPM,$(EPM_TARBALL)) \ $(call fetch_Optional,EXPAT,$(EXPAT_TARBALL)) \ $(call fetch_Optional,MORE_FONTS,$(FONT_DEJAVU_TARBALL)) \ @@ -164,7 +163,7 @@ $(WORKDIR)/download: $(BUILDDIR)/config_host.mk $(SRCDIR)/download.lst $(SRCDIR) $(call fetch_Optional,ZLIB,$(ZLIB_TARBALL)) \ ,$(call fetch_Download_item,http://dev-www.libreoffice.org/src,$(item))) $(foreach item, \ - $(if $(filter WNT,$(OS)),$(DBGHELP_DLL)) \ + $(call fetch_Optional,DBGHELP,$(DBGHELP_DLL)) \ $(call fetch_Optional,ODK,$(UNOWINREG_DLL)) \ ,$(call fetch_Download_item,http://dev-www.libreoffice.org/extern,$(item))) $(foreach item, \ ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] .: 2 commits - pyuno/source sd/source
pyuno/source/module/pyuno_impl.hxx |2 +- sd/source/ui/dlg/sdtreelb.cxx |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) New commits: commit ee6f9b5419af4e58354861ac775c207573989fc9 Author: Tor Lillqvist Date: Tue Dec 25 10:53:48 2012 +0200 WaE: unreferenced local variable Change-Id: I3a1eff09724ec79ebc87360e37ccb412b7173a59 diff --git a/sd/source/ui/dlg/sdtreelb.cxx b/sd/source/ui/dlg/sdtreelb.cxx index 0fb7588..66b8002 100644 --- a/sd/source/ui/dlg/sdtreelb.cxx +++ b/sd/source/ui/dlg/sdtreelb.cxx @@ -1414,7 +1414,7 @@ void SdPageObjsTLB::AddShapeToTransferable ( return pViewShell.get(); } } -catch (uno::Exception &e) +catch (uno::Exception &) { // When there is an exception then simply use the default value of // bIsEnabled and disable the controls. commit 43df436f6098b429dd6918a66ab8fd9073ac1728 Author: Tor Lillqvist Date: Tue Dec 25 10:51:28 2012 +0200 WaE: Fix needed with MSVS 2010, too Change-Id: I1d1da64b14139c1d90ac07685f3fe88e99253815 diff --git a/pyuno/source/module/pyuno_impl.hxx b/pyuno/source/module/pyuno_impl.hxx index 6231bad..446a286 100644 --- a/pyuno/source/module/pyuno_impl.hxx +++ b/pyuno/source/module/pyuno_impl.hxx @@ -19,7 +19,7 @@ #ifndef _PYUNO_IMPL_ #define _PYUNO_IMPL_ -#if defined(_MSC_VER) && (_MSC_VER >= 1700) +#if defined(_MSC_VER) && (_MSC_VER >= 1600) // Workaround for some horrible hypot() mess #include #endif ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[PUSHED] convert external to gbuild
Hi, Thank you for your patch! It has been merged to LibreOffice. If you are interested in details, please visit https://gerrit.libreoffice.org/1466 Objections: David Tardon: Do not submit -- To view, visit https://gerrit.libreoffice.org/1466 To unsubscribe, visit https://gerrit.libreoffice.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I7127db6aad9e97a0f3e758aa83b22ac8465d3f43 Gerrit-PatchSet: 6 Gerrit-Project: core Gerrit-Branch: master Gerrit-Owner: Peter Foley Gerrit-Reviewer: David Tardon Gerrit-Reviewer: Norbert Thiebaud Gerrit-Reviewer: Peter Foley ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice