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

2017-08-01 Thread Dennis Francis
 chart2/source/model/main/ChartModel.cxx |7 +++
 1 file changed, 7 insertions(+)

New commits:
commit 9561e0f392de3b99d8a0374486d4c0575b23180b
Author: Dennis Francis 
Date:   Wed Aug 2 10:38:12 2017 +0530

tdf#109523: Do not forget to remove the chart model from...

data-provider's listener set when the chart model is
getting disposed.

Change-Id: Iafbe1426cdb42059cbb4e2955a257a09aa42ec8e
Reviewed-on: https://gerrit.libreoffice.org/40663
Reviewed-by: Markus Mohrhard 
Tested-by: Jenkins 

diff --git a/chart2/source/model/main/ChartModel.cxx 
b/chart2/source/model/main/ChartModel.cxx
index 8918c04cc2a4..a73aa04f49ef 100644
--- a/chart2/source/model/main/ChartModel.cxx
+++ b/chart2/source/model/main/ChartModel.cxx
@@ -548,6 +548,13 @@ void SAL_CALL ChartModel::dispose()
 if ( m_xDiagram.is() )
 ModifyListenerHelper::removeListener( m_xDiagram, this );
 
+if ( m_xDataProvider.is() )
+{
+Reference xModifyBroadcaster( 
m_xDataProvider, uno::UNO_QUERY );
+if ( xModifyBroadcaster.is() )
+xModifyBroadcaster->removeModifyListener( this );
+}
+
 m_xDataProvider.clear();
 m_xInternalDataProvider.clear();
 m_xNumberFormatsSupplier.clear();
___
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' - chart2/qa sc/source

2017-08-01 Thread Dennis Francis
 chart2/qa/extras/chart2export.cxx   |   61 
 chart2/qa/extras/data/xls/axis_sourceformatting.xls |binary
 sc/source/filter/excel/xechart.cxx  |6 +
 sc/source/filter/excel/xichart.cxx  |   15 +++-
 sc/source/filter/inc/xlchart.hxx|1 
 5 files changed, 79 insertions(+), 4 deletions(-)

New commits:
commit adf049390cceb11df6ba438f30138d6f92d13b41
Author: Dennis Francis 
Date:   Mon Jul 31 10:52:55 2017 +0530

tdf#90352: set/handle LinkNumberFormatToSource property in xls...

Import/Export filter respectively for axis numbers. For ods and
xlsx this was already getting set/handled correctly.

Also add unit test to assert LinkNumberFormatToSource property
and number format for import and export-import roundtrip.

Change-Id: Id029ac7d0233ca490a6a00609e9cea8fdafee70f
Reviewed-on: https://gerrit.libreoffice.org/40577
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 
(cherry picked from commit d8e731adb8608aab17385e02f4441ed3122efa40)
Reviewed-on: https://gerrit.libreoffice.org/40664

diff --git a/chart2/qa/extras/chart2export.cxx 
b/chart2/qa/extras/chart2export.cxx
index 5975c7a3cfa2..e6b500c32b26 100644
--- a/chart2/qa/extras/chart2export.cxx
+++ b/chart2/qa/extras/chart2export.cxx
@@ -71,6 +71,7 @@ public:
 void testFdo78290ScatterChartMarkerX();
 void testFdo78290CombinationChartMarkerX();
 void testAxisNumberFormatODS();
+void testAxisNumberFormatXLS();
 void testDataLabelBordersDOCX();
 void testDataLabel3DChartDOCX();
 void testDataLabelBarChartDOCX();
@@ -135,6 +136,7 @@ public:
 CPPUNIT_TEST(testFdo78290ScatterChartMarkerX);
 CPPUNIT_TEST(testFdo78290CombinationChartMarkerX);
 CPPUNIT_TEST(testAxisNumberFormatODS);
+CPPUNIT_TEST(testAxisNumberFormatXLS);
 CPPUNIT_TEST(testDataLabelBordersDOCX);
 CPPUNIT_TEST(testDataLabel3DChartDOCX);
 CPPUNIT_TEST(testDataLabelBarChartDOCX);
@@ -759,6 +761,65 @@ void Chart2ExportTest::testAxisNumberFormatODS()
 aTest.check(xChartDoc);
 }
 
+void Chart2ExportTest::testAxisNumberFormatXLS()
+{
+struct
+{
+void check( const Reference& xChartDoc, bool 
bNumFmtLinkedActual, sal_Int16 nNumFmtTypeFlag ) const
+{
+Reference xAxisY = getAxisFromDoc( xChartDoc, 0, 1, 
0 );
+bool bNumFmtLinked = false;
+Reference xPS( xAxisY, uno::UNO_QUERY_THROW );
+xPS->getPropertyValue( "LinkNumberFormatToSource" ) >>= 
bNumFmtLinked;
+
+if ( bNumFmtLinkedActual )
+CPPUNIT_ASSERT_MESSAGE( "Y axis should have its number format 
linked to source.", bNumFmtLinked );
+else
+{
+CPPUNIT_ASSERT_MESSAGE( "Y axis should not have its number 
format linked to source.", !bNumFmtLinked );
+
+sal_Int32 nNumFmt = getNumberFormatFromAxis( xAxisY );
+sal_Int16 nType = getNumberFormatType( xChartDoc, nNumFmt );
+if ( nNumFmtTypeFlag == util::NumberFormat::PERCENT )
+CPPUNIT_ASSERT_MESSAGE( "Y axis should be percentage 
format.", ( nType & util::NumberFormat::PERCENT ) );
+else
+CPPUNIT_ASSERT_MESSAGE( "Y axis should be number format.", 
( nType & util::NumberFormat::NUMBER ) );
+}
+}
+
+void change( const Reference& xChartDoc, bool 
bSetNumFmtLinked, sal_Int16 nNumFmtTypeFlag )
+{
+Reference xAxisY = getAxisFromDoc( xChartDoc, 0, 1, 
0 );
+Reference xPS( xAxisY, uno::UNO_QUERY_THROW );
+Any aAny( bSetNumFmtLinked );
+xPS->setPropertyValue( "LinkNumberFormatToSource", aAny );
+if ( !bSetNumFmtLinked )
+{
+Reference xNFS( xChartDoc, 
uno::UNO_QUERY_THROW );
+Reference xNumberFormats = 
xNFS->getNumberFormats();
+CPPUNIT_ASSERT( xNumberFormats.is() );
+lang::Locale aLocale{ "en", "US", "" };
+Sequence aNumFmts = xNumberFormats->queryKeys( 
nNumFmtTypeFlag, aLocale, false );
+CPPUNIT_ASSERT( aNumFmts.hasElements() );
+aAny <<= aNumFmts[0];
+xPS->setPropertyValue( CHART_UNONAME_NUMFMT, aAny );
+}
+}
+
+} aTest;
+
+load( "/chart2/qa/extras/data/xls/", "axis_sourceformatting.xls" );
+
+Reference xChartDoc = getChartDocFromSheet( 0, 
mxComponent );
+aTest.check( xChartDoc, true, util::NumberFormat::PERCENT );
+
+aTest.change( xChartDoc, false, util::NumberFormat::NUMBER );
+// Write the document(xls) with changes made close it, load it and check 
if changes are intact
+reload( "MS Excel 97" );
+xChartDoc = getChartDocFromSheet( 0, mxComponent );
+aTest.check( xChartDoc, false, util::NumberFormat::NUMBER );
+}
+
 void Chart2ExportTest::testDataLabelBordersDOCX()
 {
 struct Check
diff 

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

2017-08-01 Thread Dennis Francis
 chart2/qa/extras/chart2export.cxx   |   61 
 chart2/qa/extras/data/xls/axis_sourceformatting.xls |binary
 sc/source/filter/excel/xechart.cxx  |6 +
 sc/source/filter/excel/xichart.cxx  |   15 +++-
 sc/source/filter/inc/xlchart.hxx|1 
 5 files changed, 79 insertions(+), 4 deletions(-)

New commits:
commit d8e731adb8608aab17385e02f4441ed3122efa40
Author: Dennis Francis 
Date:   Mon Jul 31 10:52:55 2017 +0530

tdf#90352: set/handle LinkNumberFormatToSource property in xls...

Import/Export filter respectively for axis numbers. For ods and
xlsx this was already getting set/handled correctly.

Also add unit test to assert LinkNumberFormatToSource property
and number format for import and export-import roundtrip.

Change-Id: Id029ac7d0233ca490a6a00609e9cea8fdafee70f
Reviewed-on: https://gerrit.libreoffice.org/40577
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/chart2/qa/extras/chart2export.cxx 
b/chart2/qa/extras/chart2export.cxx
index d9050f858c2c..67aa996c89d5 100644
--- a/chart2/qa/extras/chart2export.cxx
+++ b/chart2/qa/extras/chart2export.cxx
@@ -71,6 +71,7 @@ public:
 void testFdo78290ScatterChartMarkerX();
 void testFdo78290CombinationChartMarkerX();
 void testAxisNumberFormatODS();
+void testAxisNumberFormatXLS();
 void testDataLabelBordersDOCX();
 void testDataLabel3DChartDOCX();
 void testDataLabelBarChartDOCX();
@@ -135,6 +136,7 @@ public:
 CPPUNIT_TEST(testFdo78290ScatterChartMarkerX);
 CPPUNIT_TEST(testFdo78290CombinationChartMarkerX);
 CPPUNIT_TEST(testAxisNumberFormatODS);
+CPPUNIT_TEST(testAxisNumberFormatXLS);
 CPPUNIT_TEST(testDataLabelBordersDOCX);
 CPPUNIT_TEST(testDataLabel3DChartDOCX);
 CPPUNIT_TEST(testDataLabelBarChartDOCX);
@@ -758,6 +760,65 @@ void Chart2ExportTest::testAxisNumberFormatODS()
 aTest.check(xChartDoc);
 }
 
+void Chart2ExportTest::testAxisNumberFormatXLS()
+{
+struct
+{
+void check( const Reference& xChartDoc, bool 
bNumFmtLinkedActual, sal_Int16 nNumFmtTypeFlag ) const
+{
+Reference xAxisY = getAxisFromDoc( xChartDoc, 0, 1, 
0 );
+bool bNumFmtLinked = false;
+Reference xPS( xAxisY, uno::UNO_QUERY_THROW );
+xPS->getPropertyValue( "LinkNumberFormatToSource" ) >>= 
bNumFmtLinked;
+
+if ( bNumFmtLinkedActual )
+CPPUNIT_ASSERT_MESSAGE( "Y axis should have its number format 
linked to source.", bNumFmtLinked );
+else
+{
+CPPUNIT_ASSERT_MESSAGE( "Y axis should not have its number 
format linked to source.", !bNumFmtLinked );
+
+sal_Int32 nNumFmt = getNumberFormatFromAxis( xAxisY );
+sal_Int16 nType = getNumberFormatType( xChartDoc, nNumFmt );
+if ( nNumFmtTypeFlag == util::NumberFormat::PERCENT )
+CPPUNIT_ASSERT_MESSAGE( "Y axis should be percentage 
format.", ( nType & util::NumberFormat::PERCENT ) );
+else
+CPPUNIT_ASSERT_MESSAGE( "Y axis should be number format.", 
( nType & util::NumberFormat::NUMBER ) );
+}
+}
+
+void change( const Reference& xChartDoc, bool 
bSetNumFmtLinked, sal_Int16 nNumFmtTypeFlag )
+{
+Reference xAxisY = getAxisFromDoc( xChartDoc, 0, 1, 
0 );
+Reference xPS( xAxisY, uno::UNO_QUERY_THROW );
+Any aAny( bSetNumFmtLinked );
+xPS->setPropertyValue( "LinkNumberFormatToSource", aAny );
+if ( !bSetNumFmtLinked )
+{
+Reference xNFS( xChartDoc, 
uno::UNO_QUERY_THROW );
+Reference xNumberFormats = 
xNFS->getNumberFormats();
+CPPUNIT_ASSERT( xNumberFormats.is() );
+lang::Locale aLocale{ "en", "US", "" };
+Sequence aNumFmts = xNumberFormats->queryKeys( 
nNumFmtTypeFlag, aLocale, false );
+CPPUNIT_ASSERT( aNumFmts.hasElements() );
+aAny <<= aNumFmts[0];
+xPS->setPropertyValue( CHART_UNONAME_NUMFMT, aAny );
+}
+}
+
+} aTest;
+
+load( "/chart2/qa/extras/data/xls/", "axis_sourceformatting.xls" );
+
+Reference xChartDoc = getChartDocFromSheet( 0, 
mxComponent );
+aTest.check( xChartDoc, true, util::NumberFormat::PERCENT );
+
+aTest.change( xChartDoc, false, util::NumberFormat::NUMBER );
+// Write the document(xls) with changes made close it, load it and check 
if changes are intact
+reload( "MS Excel 97" );
+xChartDoc = getChartDocFromSheet( 0, mxComponent );
+aTest.check( xChartDoc, false, util::NumberFormat::NUMBER );
+}
+
 void Chart2ExportTest::testDataLabelBordersDOCX()
 {
 struct Check
diff --git a/chart2/qa/extras/data/xls/axis_sourceformatting.xls 
b/chart2/qa/extras/data/xls/axis_sourceformatting.xls
new file mod

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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/app.cxx |4 
 1 file changed, 4 insertions(+)

New commits:
commit 74a3a035143b471c3edd2392b44c68c8695dcc23
Author: Markus Mohrhard 
Date:   Wed Aug 2 05:39:40 2017 +0200

updater: flush the configuration changes before we call execv

Without this the external configuration writer thread might not have
written the config yet.

Change-Id: I361fd8a7ee102a8ca50899fb644a0745ed3386ca
Reviewed-on: https://gerrit.libreoffice.org/40659
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index c6a467682496..fe89eeb3b628 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1436,6 +1436,10 @@ int Desktop::Main()
 officecfg::Office::Update::Update::OldBuildID::set(aBuildID, 
batch);
 officecfg::Office::Update::Update::UpdateRunning::set(true, 
batch);
 batch->commit();
+
+// make sure the change is written to the configuration before 
we start the update
+css::uno::Reference 
xFlushable(css::configuration::theDefaultProvider::get(xContext), UNO_QUERY);;
+xFlushable->flush();
 // avoid the old oosplash staying around
 CloseSplashScreen();
 update();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/updater.cxx |5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

New commits:
commit 95c2f226b122c7fdb77c6e9085b1fbd02189db03
Author: Markus Mohrhard 
Date:   Wed Aug 2 05:40:47 2017 +0200

updater: fix incorrect installation directory path

With this change one step updates are finally working correctly.

Change-Id: I41a33b670039adc85a24de713bd0938d99da6662
Reviewed-on: https://gerrit.libreoffice.org/40660
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/app/updater.cxx b/desktop/source/app/updater.cxx
index 16e847d50df7..7e328a1a68d3 100644
--- a/desktop/source/app/updater.cxx
+++ b/desktop/source/app/updater.cxx
@@ -154,9 +154,8 @@ char** createCommandLine()
 }
 {
 // the actual update directory
-OUString aInstallPath = getPathFromURL(aInstallDir);
-Updater::log("Install Dir: " + aInstallPath);
-createStr(aInstallPath, pArgs, 2);
+Updater::log("Install Dir: " + aInstallDir);
+createStr(aInstallDir, pArgs, 2);
 }
 {
 // the temporary updated build
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/app.cxx |3 +--
 desktop/source/app/updater.cxx |3 +++
 2 files changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 682cd955c36cb97a8fd276fc57be6bdb4bb0e107
Author: Markus Mohrhard 
Date:   Wed Aug 2 03:57:06 2017 +0200

updater: always log all Updater messages also to SAL_INFO

Change-Id: Iafb9ebc8c1bc0ed317fa51b40e22bc8531bda6f1
Reviewed-on: https://gerrit.libreoffice.org/40657
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index dffa9a7ebc95..c6a467682496 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1397,14 +1397,13 @@ int Desktop::Main()
 OUString aBuildID = Updater::getBuildID();
 if (aOldBuildID == aBuildID)
 {
-SAL_INFO("desktop", "No updating took place.");
 Updater::log("Old and new Build ID are the same. No 
Updating took place.");
 }
 else
 {
 if (!aSeeAlso.isEmpty())
 {
-SAL_INFO("desktop", "See also: " << aSeeAlso);
+SAL_INFO("updater", "See also: " << aSeeAlso);
 Reference< css::system::XSystemShellExecute > 
xSystemShell(
 
SystemShellExecute::create(::comphelper::getProcessComponentContext()) );
 
diff --git a/desktop/source/app/updater.cxx b/desktop/source/app/updater.cxx
index ef4dcd29d122..16e847d50df7 100644
--- a/desktop/source/app/updater.cxx
+++ b/desktop/source/app/updater.cxx
@@ -750,6 +750,7 @@ OUString Updater::getExecutableDirURL()
 
 void Updater::log(const OUString& rMessage)
 {
+SAL_INFO("updater", rMessage);
 OUString aUpdateLog = getUpdateInfoLog();
 SvFileStream aLog(aUpdateLog, StreamMode::STD_READWRITE);
 aLog.Seek(aLog.Tell() + aLog.remainingSize()); // make sure we are at the 
end
@@ -758,6 +759,7 @@ void Updater::log(const OUString& rMessage)
 
 void Updater::log(const OString& rMessage)
 {
+SAL_INFO("updater", rMessage);
 OUString aUpdateLog = getUpdateInfoLog();
 SvFileStream aLog(aUpdateLog, StreamMode::STD_READWRITE);
 aLog.Seek(aLog.Tell() + aLog.remainingSize()); // make sure we are at the 
end
@@ -766,6 +768,7 @@ void Updater::log(const OString& rMessage)
 
 void Updater::log(const char* pMessage)
 {
+SAL_INFO("updater", pMessage);
 OUString aUpdateLog = getUpdateInfoLog();
 SvFileStream aLog(aUpdateLog, StreamMode::STD_READWRITE);
 aLog.Seek(aLog.Tell() + aLog.remainingSize()); // make sure we are at the 
end
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/app.cxx |1 +
 onlineupdate/source/update/updater/updater.cxx |3 +++
 2 files changed, 4 insertions(+)

New commits:
commit cff13c4b34430c2f70a70d96e758a8278db8f5ca
Author: Markus Mohrhard 
Date:   Wed Aug 2 05:39:19 2017 +0200

updater: log the update check time

Change-Id: I41092b3548715a89baf9d795aa58c87a0e1621b2
Reviewed-on: https://gerrit.libreoffice.org/40658
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index a8d066cd032f..dffa9a7ebc95 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1444,6 +1444,7 @@ int Desktop::Main()
 else if (isTimeForUpdateCheck())
 {
 sal_uInt64 nNow = tools::Time::GetSystemTicks();
+Updater::log("Update Check Time: " + OUString::number(nNow));
 std::shared_ptr< comphelper::ConfigurationChanges > batch(
 comphelper::ConfigurationChanges::create());
 officecfg::Office::Update::Update::LastUpdateTime::set(nNow, 
batch);
commit 9d3654668ec7d4a7e6e3627dde86093e8db18c0d
Author: Markus Mohrhard 
Date:   Wed Aug 2 03:37:55 2017 +0200

updater: disable the special handling of the user profile

This should be unnecessary for the one step updating strategy.

Change-Id: I8dddeae4fb4a560a1c261c0c2e84183d72fc638c
Reviewed-on: https://gerrit.libreoffice.org/40656
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/onlineupdate/source/update/updater/updater.cxx 
b/onlineupdate/source/update/updater/updater.cxx
index 08aa201cb47e..8a1ef8bf5b24 100644
--- a/onlineupdate/source/update/updater/updater.cxx
+++ b/onlineupdate/source/update/updater/updater.cxx
@@ -332,6 +332,8 @@ namespace {
 
 bool is_userprofile_in_instdir()
 {
+return false;
+/*
 // the algorithm is:
 // 1.) if userprofile path length is smaller than installation dir,
 //  the profile is surely not in instdir
@@ -350,6 +352,7 @@ bool is_userprofile_in_instdir()
 return false;
 
 return NS_tstrncmp(userprofile, gInstallDirPath, installdir_len) == 0;
+*/
 }
 
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/app.cxx |8 +
 desktop/source/app/updater.cxx |   62 ++---
 desktop/source/app/updater.hxx |2 -
 3 files changed, 7 insertions(+), 65 deletions(-)

New commits:
commit c74fbd43362254bfaa1dd31069e40d23ceef9fa0
Author: Markus Mohrhard 
Date:   Wed Aug 2 03:34:47 2017 +0200

updater: switch to an one-step update

Change-Id: I72af514ed0b3f83c8cc1fdfb8009ad523fc1a5a8
Reviewed-on: https://gerrit.libreoffice.org/40655
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index e0dd2a13b682..a8d066cd032f 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1424,13 +1424,11 @@ int Desktop::Main()
 Updater::removeUpdateFiles();
 }
 
-osl::DirectoryItem aPatchInfo;
-osl::DirectoryItem::get(Updater::getUpdateInfoURL(), aPatchInfo);
-osl::DirectoryItem aDirectoryItem;
-osl::DirectoryItem::get(Updater::getUpdateDirURL(), 
aDirectoryItem);
+osl::DirectoryItem aUpdateFile;
+osl::DirectoryItem::get(Updater::getUpdateFileURL(), aUpdateFile);
 
 const char* pUpdaterTestUpdate = 
std::getenv("LIBO_UPDATER_TEST_UPDATE");
-if (pUpdaterTestUpdate || (aPatchInfo.is() && aDirectoryItem.is()))
+if (pUpdaterTestUpdate || aUpdateFile.is())
 {
 OUString aBuildID("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" 
SAL_CONFIGFILE("version") ":buildid}");
 rtl::Bootstrap::expandMacros(aBuildID);
diff --git a/desktop/source/app/updater.cxx b/desktop/source/app/updater.cxx
index 5e596fc352fe..ef4dcd29d122 100644
--- a/desktop/source/app/updater.cxx
+++ b/desktop/source/app/updater.cxx
@@ -136,8 +136,7 @@ void createStr(const OUString& rStr, char** pArgs, size_t i)
 
 char** createCommandLine()
 {
-OUString aInstallDir( "$BRAND_BASE_DIR/" );
-rtl::Bootstrap::expandMacros(aInstallDir);
+OUString aInstallDir = Updater::getInstallationPath();
 
 size_t nCommandLineArgs = rtl_getAppCommandArgCount();
 size_t nArgs = 8 + nCommandLineArgs;
@@ -161,13 +160,11 @@ char** createCommandLine()
 }
 {
 // the temporary updated build
-OUString aUpdateDirURL = Updater::getUpdateDirURL();
-OUString aWorkingDir = getPathFromURL(aUpdateDirURL);
-Updater::log("Working Dir: " + aWorkingDir);
-createStr(aWorkingDir, pArgs, 3);
+Updater::log("Working Dir: " + aInstallDir);
+createStr(aInstallDir, pArgs, 3);
 }
 {
-const char* pPID = "/replace";
+const char* pPID = "0";
 createStr(pPID, pArgs, 4);
 }
 {
@@ -289,39 +286,6 @@ void update()
 delete[] pArgs;
 }
 
-void CreateValidUpdateDir(const update_info& update_info)
-{
-Updater::log(OString("Create Update Dir"));
-OUString aInstallDir("$BRAND_BASE_DIR");
-rtl::Bootstrap::expandMacros(aInstallDir);
-OUString aInstallPath = getPathFromURL(aInstallDir);
-OUString aWorkdirPath = getPathFromURL(Updater::getUpdateDirURL());
-
-OUString aPatchDir = getPathFromURL(Updater::getPatchDirURL());
-
-OUString aUpdaterPath = getPathFromURL(Updater::getExecutableDirURL() + 
OUString::fromUtf8(pUpdaterName));
-
-OUString aCommand = aUpdaterPath + " " + aPatchDir + " " + aInstallPath + 
" " + aWorkdirPath + " -1";
-
-OString aOCommand = OUStringToOString(aCommand, RTL_TEXTENCODING_UTF8);
-
-int nResult = std::system(aOCommand.getStr());
-if (nResult)
-{
-// TODO: remove the update directory
-SAL_WARN("desktop.updater", "failed to update");
-Updater::log(OUString("failed to create update dir"));
-}
-else
-{
-OUString aUpdateInfoURL(Updater::getPatchDirURL() + "/update.info");
-OUString aUpdateInfoPath = getPathFromURL(aUpdateInfoURL);
-SvFileStream aUpdateInfoFile(aUpdateInfoPath, StreamMode::WRITE | 
StreamMode::TRUNC);
-aUpdateInfoFile.WriteCharPtr("[UpdateInfo]\nOldBuildId=");
-aUpdateInfoFile.WriteByteStringLine(update_info.aFromBuildID, 
RTL_TEXTENCODING_UTF8);
-}
-}
-
 namespace {
 
 // Callback to get the response data from server.
@@ -712,7 +676,6 @@ void update_checker()
 download_file(lang_update.aUpdateFile.aURL, 
lang_update.aUpdateFile.nSize, lang_update.aUpdateFile.aHash, aFileName);
 }
 }
-CreateValidUpdateDir(aUpdateInfo);
 OUString aSeeAlsoURL = aUpdateInfo.aSeeAlsoURL;
 std::shared_ptr< comphelper::ConfigurationChanges > batch(
 comphelper::ConfigurationChanges::create());
@@ -748,14 +711,6 @@ void update_checker()
 }
 }
 
-OUString Updater::getUpdateInfoURL()
-{
-OUString aUpdateInfoURL("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" 
SAL_CONFIGFILE("bootstrap") ":UserInstallation}/p

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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/app.cxx |2 +
 desktop/source/app/updater.cxx |   48 +
 desktop/source/app/updater.hxx |4 +++
 3 files changed, 54 insertions(+)

New commits:
commit bdeb3fb0eee3ff013ed948fb759f9c99e0aa5ffe
Author: Markus Mohrhard 
Date:   Wed Aug 2 03:33:04 2017 +0200

updater: remove the updater files after an update

Change-Id: Iaf12cb66fae2ead6d899864309f0d7f4d131e072
Reviewed-on: https://gerrit.libreoffice.org/40654
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index 24545b9502d1..e0dd2a13b682 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1420,6 +1420,8 @@ int Desktop::Main()
 officecfg::Office::Update::Update::SeeAlso::set(OUString(), 
batch);
 officecfg::Office::Update::Update::OldBuildID::set(OUString(), 
batch);
 batch->commit();
+
+Updater::removeUpdateFiles();
 }
 
 osl::DirectoryItem aPatchInfo;
diff --git a/desktop/source/app/updater.cxx b/desktop/source/app/updater.cxx
index 24891fa8ae8e..5e596fc352fe 100644
--- a/desktop/source/app/updater.cxx
+++ b/desktop/source/app/updater.cxx
@@ -780,6 +780,20 @@ OUString Updater::getUpdateDirURL()
 return aUpdateDirURL;
 }
 
+
+OUString Updater::getUpdateFileURL()
+{
+return getPatchDirURL() + "update.mar";
+}
+
+OUString Updater::getInstallationPath()
+{
+OUString aInstallDir( "$BRAND_BASE_DIR/");
+rtl::Bootstrap::expandMacros(aInstallDir);
+
+return getPathFromURL(aInstallDir);
+}
+
 OUString Updater::getExecutableDirURL()
 {
 OUString aExeDir( "$BRAND_BASE_DIR/" LIBO_BIN_FOLDER "/" );
@@ -820,4 +834,38 @@ OUString Updater::getBuildID()
 return aBuildID;
 }
 
+void Updater::removeUpdateFiles()
+{
+Updater::log("Removing: " + getUpdateFileURL());
+osl::File::remove(getUpdateFileURL());
+
+OUString aPatchDirURL = getPatchDirURL();
+osl::Directory aDir(aPatchDirURL);
+aDir.open();
+
+osl::FileBase::RC eRC;
+do
+{
+osl::DirectoryItem aItem;
+eRC = aDir.getNextItem(aItem);
+if (eRC == osl::FileBase::E_None)
+{
+osl::FileStatus aStatus(osl_FileStatus_Mask_All);
+if (aItem.getFileStatus(aStatus) != osl::FileBase::E_None)
+continue;
+
+if (!aStatus.isRegular())
+continue;
+
+OUString aURL = aStatus.getFileURL();
+if (!aURL.endsWith(".mar"))
+continue;
+
+Updater::log("Removing. " + aURL);
+osl::File::remove(aURL);
+}
+}
+while (eRC == osl::FileBase::E_None);
+}
+
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/desktop/source/app/updater.hxx b/desktop/source/app/updater.hxx
index 214777fcba29..5d3d0c2cd98d 100644
--- a/desktop/source/app/updater.hxx
+++ b/desktop/source/app/updater.hxx
@@ -26,13 +26,17 @@ public:
 static OUString getUpdateInfoLog();
 static OUString getPatchDirURL();
 static OUString getUpdateDirURL();
+static OUString getUpdateFileURL();
 static OUString getExecutableDirURL();
+static OUString getInstallationPath();
 
 static OUString getBuildID();
 
 static void log(const OUString& rMessage);
 static void log(const OString& rMessage);
 static void log(const char* pMessage);
+
+static void removeUpdateFiles();
 };
 
 #endif
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/app.cxx |   10 ++
 1 file changed, 6 insertions(+), 4 deletions(-)

New commits:
commit 6d2ef60c30893f5b3771ad645b5680ee4081113a
Author: Markus Mohrhard 
Date:   Wed Aug 2 03:26:59 2017 +0200

updater: make it easier to test indenpendent updater parts

Change-Id: I3f06c6315349c9c53e3e76a8a01153679260c272
Reviewed-on: https://gerrit.libreoffice.org/40653
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index 0e9998d11581..24545b9502d1 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1383,11 +1383,12 @@ int Desktop::Main()
 return EXIT_FAILURE;
 
 #if HAVE_FEATURE_UPDATE_MAR
-const char* pUpdaterTestReplace = 
std::getenv("LIBO_UPDATER_TEST_REPLACE");
-if (pUpdaterTestReplace || 
officecfg::Office::Update::Update::Enabled::get())
+const char* pUpdaterTestEnable = 
std::getenv("LIBO_UPDATER_TEST_ENABLE");
+if (pUpdaterTestEnable || 
officecfg::Office::Update::Update::Enabled::get())
 {
 // check if we just updated
-bool bUpdateRunning = 
officecfg::Office::Update::Update::UpdateRunning::get();
+const char* pUpdaterRunning = 
std::getenv("LIBO_UPDATER_TEST_RUNNING");
+bool bUpdateRunning = 
officecfg::Office::Update::Update::UpdateRunning::get() || pUpdaterRunning;
 if (bUpdateRunning)
 {
 OUString aSeeAlso = 
officecfg::Office::Update::Update::SeeAlso::get();
@@ -1426,7 +1427,8 @@ int Desktop::Main()
 osl::DirectoryItem aDirectoryItem;
 osl::DirectoryItem::get(Updater::getUpdateDirURL(), 
aDirectoryItem);
 
-if (pUpdaterTestReplace || (aPatchInfo.is() && 
aDirectoryItem.is()))
+const char* pUpdaterTestUpdate = 
std::getenv("LIBO_UPDATER_TEST_UPDATE");
+if (pUpdaterTestUpdate || (aPatchInfo.is() && aDirectoryItem.is()))
 {
 OUString aBuildID("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" 
SAL_CONFIGFILE("version") ":buildid}");
 rtl::Bootstrap::expandMacros(aBuildID);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 desktop/source/app/app.cxx |6 +++---
 desktop/source/app/updater.cxx |   11 +--
 desktop/source/app/updater.hxx |2 ++
 3 files changed, 14 insertions(+), 5 deletions(-)

New commits:
commit a0c54ff9a6b92d220a1eb7099dd2ecd2bd92056f
Author: Markus Mohrhard 
Date:   Tue Aug 1 20:39:39 2017 +0200

updater: extract the build ID generation into own method

Change-Id: Ieee90215c155d031da40b2d9d0b50bc41ff2e980
Reviewed-on: https://gerrit.libreoffice.org/40652
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index e337130f66c3..0e9998d11581 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1393,11 +1393,11 @@ int Desktop::Main()
 OUString aSeeAlso = 
officecfg::Office::Update::Update::SeeAlso::get();
 OUString aOldBuildID = 
officecfg::Office::Update::Update::OldBuildID::get();
 
-OUString aBuildID("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" 
SAL_CONFIGFILE("version") ":buildid}");
-rtl::Bootstrap::expandMacros(aBuildID);
+OUString aBuildID = Updater::getBuildID();
 if (aOldBuildID == aBuildID)
 {
-SAL_INFO("desktop", "failed updater");
+SAL_INFO("desktop", "No updating took place.");
+Updater::log("Old and new Build ID are the same. No 
Updating took place.");
 }
 else
 {
diff --git a/desktop/source/app/updater.cxx b/desktop/source/app/updater.cxx
index 782bfef9079b..24891fa8ae8e 100644
--- a/desktop/source/app/updater.cxx
+++ b/desktop/source/app/updater.cxx
@@ -668,8 +668,7 @@ void update_checker()
 }
 
 OUString aProductName = utl::ConfigManager::getProductName();
-OUString aBuildID("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" 
SAL_CONFIGFILE("version") ":buildid}");
-rtl::Bootstrap::expandMacros(aBuildID);
+OUString aBuildID = Updater::getBuildID();
 OUString aBuildTarget = "${_OS}_${_ARCH}";
 rtl::Bootstrap::expandMacros(aBuildTarget);
 OUString aChannel = 
officecfg::Office::Update::Update::UpdateChannel::get();
@@ -813,4 +812,12 @@ void Updater::log(const char* pMessage)
 aLog.WriteCharPtr(pMessage);
 }
 
+OUString Updater::getBuildID()
+{
+OUString aBuildID("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" 
SAL_CONFIGFILE("version") ":buildid}");
+rtl::Bootstrap::expandMacros(aBuildID);
+
+return aBuildID;
+}
+
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/desktop/source/app/updater.hxx b/desktop/source/app/updater.hxx
index 922d5264ec5e..214777fcba29 100644
--- a/desktop/source/app/updater.hxx
+++ b/desktop/source/app/updater.hxx
@@ -28,6 +28,8 @@ public:
 static OUString getUpdateDirURL();
 static OUString getExecutableDirURL();
 
+static OUString getBuildID();
+
 static void log(const OUString& rMessage);
 static void log(const OString& rMessage);
 static void log(const char* pMessage);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: helpcontent2

2017-08-01 Thread Olivier Hallot
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e7f28f152fd6ec2606c0c355d277f613a92df52c
Author: Olivier Hallot 
Date:   Wed Aug 2 00:49:11 2017 -0300

Updated core
Project: help  9f9cebab254146cbae0a093626ed78801e85b98f

tdf#97745 Handle offline browser help

* Rename index.html to LOHelp.html. index.html is a bad name,
too generic. LOHelp.html is invoked by LibreOffice and is not a
popular file name.
* Clean the XSLT transform, add suport for local help.
* reposition bookmark2file.js in the target tree.
* remove obsolete files
* page tree now capable to be opened by file:// protocol, passing
'online' parameter and folder address to the bash script.

Change-Id: I2cf9f69de7896bd74074745993ef033bef5c3503
Reviewed-on: https://gerrit.libreoffice.org/40661
Reviewed-by: Olivier Hallot 
Tested-by: Olivier Hallot 

diff --git a/helpcontent2 b/helpcontent2
index 4d6f86d20381..9f9cebab2541 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit 4d6f86d203814a211eae9dfacd4baf195ca4ff1d
+Subproject commit 9f9cebab254146cbae0a093626ed78801e85b98f
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] help.git: help3xsl/help.js help3xsl/index2.html help3xsl/index.html help3xsl/LOHelp.html help3xsl/online_transform.xsl help3xsl/tabs.js help3xsl/tree.css help3xsl/xhp2html.sh

2017-08-01 Thread Olivier Hallot
 help3xsl/LOHelp.html  |   30 ++
 help3xsl/help.js  |   16 +
 help3xsl/index.html   |   49 ---
 help3xsl/index2.html  |   52 +++
 help3xsl/online_transform.xsl |  549 +-
 help3xsl/tabs.js  |   53 
 help3xsl/tree.css |  123 -
 help3xsl/xhp2html.sh  |   41 ++-
 8 files changed, 425 insertions(+), 488 deletions(-)

New commits:
commit 9f9cebab254146cbae0a093626ed78801e85b98f
Author: Olivier Hallot 
Date:   Wed Aug 2 00:49:11 2017 -0300

tdf#97745 Handle offline browser help

* Rename index.html to LOHelp.html. index.html is a bad name,
too generic. LOHelp.html is invoked by LibreOffice and is not a
popular file name.
* Clean the XSLT transform, add suport for local help.
* reposition bookmark2file.js in the target tree.
* remove obsolete files
* page tree now capable to be opened by file:// protocol, passing
'online' parameter and folder address to the bash script.

Change-Id: I2cf9f69de7896bd74074745993ef033bef5c3503
Reviewed-on: https://gerrit.libreoffice.org/40661
Reviewed-by: Olivier Hallot 
Tested-by: Olivier Hallot 

diff --git a/help3xsl/LOHelp.html b/help3xsl/LOHelp.html
new file mode 100644
index 0..bd2100a7e
--- /dev/null
+++ b/help3xsl/LOHelp.html
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+var url = window.location.href;
+var n = url.indexOf('LOHelp.html?');
+if (n != -1){
+// the URL came from LibreOffice help (F1)
+var version = getParameterByName("Version",url);
+var rest = url.substr(n+12,url.lenght);
+var newURL = version+'/index.html?'+rest;
+window.open(newURL,'_self');
+}else{
+// URL came from elsewhere, direct access to webroot, we redirect to main 
Help page
+
window.open('latest/en-US/text/shared/main0108.html?&DbPAR=WRITER&System=WIN','_self');
+}
+
+
+
+
diff --git a/help3xsl/help.js b/help3xsl/help.js
index 6028802be..1901a96ad 100644
--- a/help3xsl/help.js
+++ b/help3xsl/help.js
@@ -37,9 +37,11 @@ function fixURL(module, system){
 var pSystem = (system == null) ? "WIN" : system;
 var pAppl = (module == null) ? "WRITER" : module;
 var n = itemlink.length;
-var item;
-for (var i = 0; ihttp://mozilla.org/MPL/2.0/.
 -->
 
-   
-   
-   
-   
-   
-
-var url = window.location.href;
-var n = url.indexOf('index.html?');
-if (n != -1){
-// the URL came from LibreOffice help (F1)
-var version = getParameterByName("Version",url);
-var lang = getParameterByName("Language",url);
-var system  = getParameterByName("System",url);
-var rest= url.substr(n+11,url.lenght);
-var module;
-var defaultFile;
-var smodule = rest.substr(0, rest.indexOf('/'));
-switch (smodule) {
-case "swriter":   
{defaultFile='text/swriter/main.html';module="WRITER";break;}
-case "scalc": 
{defaultFile='text/scalc/main.html';module="CALC";break;}
-case "simpress":  
{defaultFile='text/simpress/main.html';module="IMPRESS";break;}
-case "sdraw": 
{defaultFile='text/sdraw/main.html';module="DRAW";break;}
-case "smath": 
{defaultFile='text/smath/main.html';module="MATH";break;}
-case "sdatabase": 
{defaultFile='text/shared/explorer/database/main.html';module="BASE";break;}
-case "sbasic":
{defaultFile='text/sbasic/shared/main0601.html';module="BASIC";break;}
-default:  
{defaultFile='text/shared/main.html';module="WRITER";break;}
-}
-var bookmark = rest.slice(rest.indexOf('/')+1, rest.indexOf('?')); 
-var file = map[bookmark];
-// rebuild URL
-if (file=='undefined'){
-file = defaultFile;
-}
-var newURL = 
'/'+version+'/'+lang+'/'+file+'?System='+system+'&DbPAR='+module;
-window.open(newURL,'_self');
-}else{
-// URL came from elsewhere, direct access to webroot, we redirect to 
main Help page
-
window.open('latest/en-US/text/shared/main0108.html?&DbPAR=WRITER&System=WIN','_self');
-}
-
-   
+
+
+
+
+
window.open('latest/en-US/text/shared/main0108.html?&DbPAR=WRITER&System=WIN','_self');
+
+
 
-
diff --git a/help3xsl/index2.html b/help3xsl/index2.html
new file mode 100644
index 0..fb0cb76a4
--- /dev/null
+++ b/help3xsl/index2.html
@@ -0,0 +1,52 @@
+
+
+
+   
+   
+   
+   
+   
+
+var url = window.location.href;
+var n = url.indexOf('index.html?');
+if (n != -1){
+// the URL came from LibreOffice help (F1)
+var version = getParameterByName("Version",url);
+var lang = getParameterByName("Language",url);
+var system  = getParameter

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

2017-08-01 Thread Caolán McNamara
 sc/source/ui/undo/undotab.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit eeff6a8f70184aa55f95bd8897a6ed8e125ad72f
Author: Caolán McNamara 
Date:   Tue Aug 1 11:34:22 2017 +0100

Related: tdf#109856 redo 'insert multiple tabs after' inserts too many tabs

Change-Id: I50e8941408343f8fa9acf017d7c195279952916d
Reviewed-on: https://gerrit.libreoffice.org/40627
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/source/ui/undo/undotab.cxx b/sc/source/ui/undo/undotab.cxx
index 9323e066978f..45a37dd1c079 100644
--- a/sc/source/ui/undo/undotab.cxx
+++ b/sc/source/ui/undo/undotab.cxx
@@ -224,7 +224,6 @@ void ScUndoInsertTables::Redo()
 
 pDocShell->SetInUndo( true );   //! BeginRedo
 bDrawIsInUndo = true;
-pViewShell->SetTabNo(nTab);
 pViewShell->InsertTables( aNameList, nTab, 
static_cast(aNameList.size()),false );
 
 bDrawIsInUndo = false;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-3' - sc/source

2017-08-01 Thread Caolán McNamara
 sc/source/ui/undo/undotab.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit def36294754a7263101b421166195eb1b95d6d6f
Author: Caolán McNamara 
Date:   Tue Aug 1 11:34:22 2017 +0100

Related: tdf#109856 redo 'insert multiple tabs after' inserts too many tabs

Change-Id: I50e8941408343f8fa9acf017d7c195279952916d
Reviewed-on: https://gerrit.libreoffice.org/40628
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/source/ui/undo/undotab.cxx b/sc/source/ui/undo/undotab.cxx
index 7245cc99a1f6..7a8311525e8a 100644
--- a/sc/source/ui/undo/undotab.cxx
+++ b/sc/source/ui/undo/undotab.cxx
@@ -226,7 +226,6 @@ void ScUndoInsertTables::Redo()
 
 pDocShell->SetInUndo( true );   //! BeginRedo
 bDrawIsInUndo = true;
-pViewShell->SetTabNo(nTab);
 pViewShell->InsertTables( aNameList, nTab, 
static_cast(aNameList.size()),false );
 
 bDrawIsInUndo = false;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-3' - sc/source

2017-08-01 Thread Caolán McNamara
 sc/source/core/data/document.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit b8db40fb2eb39c4330de475a7cc8155d16479218
Author: Caolán McNamara 
Date:   Tue Aug 1 09:16:28 2017 +0100

Resolves: tdf#109856 undo 'insert multiple tabs after' doesn't work

Change-Id: I534536358b2a949667c1c258bf27e13763c0de57
Reviewed-on: https://gerrit.libreoffice.org/40622
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index 3b968eb79e02..54cb77bafedc 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -786,7 +786,7 @@ void ScDocument::ClearTabs()
 bool ScDocument::DeleteTabs( SCTAB nTab, SCTAB nSheets )
 {
 bool bValid = false;
-if (ValidTab(nTab) && (nTab + nSheets) < static_cast(maTabs.size()))
+if (ValidTab(nTab) && (nTab + nSheets) <= 
static_cast(maTabs.size()))
 {
 if (maTabs[nTab])
 {
___
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' - sc/source

2017-08-01 Thread Caolán McNamara
 sc/source/core/data/document.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit fbfa25a14164abe77f11323cdf3249f8b1d528ea
Author: Caolán McNamara 
Date:   Tue Aug 1 09:16:28 2017 +0100

Resolves: tdf#109856 undo 'insert multiple tabs after' doesn't work

Change-Id: I534536358b2a949667c1c258bf27e13763c0de57
Reviewed-on: https://gerrit.libreoffice.org/40621
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index e597ae4485cf..ee5f7699dd01 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -785,7 +785,7 @@ void ScDocument::ClearTabs()
 bool ScDocument::DeleteTabs( SCTAB nTab, SCTAB nSheets )
 {
 bool bValid = false;
-if (ValidTab(nTab) && (nTab + nSheets) < static_cast(maTabs.size()))
+if (ValidTab(nTab) && (nTab + nSheets) <= 
static_cast(maTabs.size()))
 {
 if (maTabs[nTab])
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 vcl/source/uitest/uiobject.cxx |6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit 9ca7bda2cc8b67c2d10fcb81cce8bfd4d8b79b09
Author: Markus Mohrhard 
Date:   Wed Aug 2 01:46:27 2017 +0200

uitest: detect real floating windows better

We use the FloatingWindow base class also for some windows that are not
independent. A good example is the hyperlink dialog.

Change-Id: I067ac0465de9ff3c8f9bc0c1a5c817a5e09d96e5
Reviewed-on: https://gerrit.libreoffice.org/40650
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/vcl/source/uitest/uiobject.cxx b/vcl/source/uitest/uiobject.cxx
index 5d7132787ea3..ed5a84ab5655 100644
--- a/vcl/source/uitest/uiobject.cxx
+++ b/vcl/source/uitest/uiobject.cxx
@@ -97,7 +97,11 @@ bool isDialogWindow(vcl::Window const * pWindow)
 bool isTopWindow(vcl::Window const * pWindow)
 {
 WindowType eType = pWindow->GetType();
-return eType == WindowType::FLOATINGWINDOW;
+if (eType == WindowType::FLOATINGWINDOW)
+{
+return pWindow->GetStyle() & WB_SYSTEMFLOATWIN;
+}
+return false;
 }
 
 vcl::Window* get_top_parent(vcl::Window* pWindow)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Julien Nabet
 svx/source/svdraw/svdedtv.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 8b85fd641da60eae87ead152b0659c3c683509ef
Author: Julien Nabet 
Date:   Tue Aug 1 23:09:46 2017 +0200

Typo: usnig->using

Change-Id: I56012f1114d6af5851593dcff1c7b841918887fb
Reviewed-on: https://gerrit.libreoffice.org/40649
Reviewed-by: Julien Nabet 
Tested-by: Julien Nabet 

diff --git a/svx/source/svdraw/svdedtv.cxx b/svx/source/svdraw/svdedtv.cxx
index ef72376bc0c4..55d7d31fa64f 100644
--- a/svx/source/svdraw/svdedtv.cxx
+++ b/svx/source/svdraw/svdedtv.cxx
@@ -985,12 +985,12 @@ void SdrEditView::ReplaceObjectAtView(SdrObject* pOldObj, 
SdrPageView& rPV, SdrO
 #ifdef DBG_UTIL
 if(dynamic_cast< SdrTextObj* >(pOldObj) && static_cast< SdrTextObj* 
>(pOldObj)->IsTextEditActive())
 {
-OSL_ENSURE(false, "OldObject is in TextEdit mode, this has to be 
ended before replacing it usnig SdrEndTextEdit (!)");
+OSL_ENSURE(false, "OldObject is in TextEdit mode, this has to be 
ended before replacing it using SdrEndTextEdit (!)");
 }
 
 if(dynamic_cast< SdrTextObj* >(pNewObj) && static_cast< SdrTextObj* 
>(pNewObj)->IsTextEditActive())
 {
-OSL_ENSURE(false, "NewObject is in TextEdit mode, this has to be 
ended before replacing it usnig SdrEndTextEdit (!)");
+OSL_ENSURE(false, "NewObject is in TextEdit mode, this has to be 
ended before replacing it using SdrEndTextEdit (!)");
 }
 #endif
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Markus Mohrhard
 desktop/source/minidump/minidump.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit ec4229bc49a315f3f17664bb43e61d3b2e13fb87
Author: Markus Mohrhard 
Date:   Tue Aug 1 18:54:30 2017 +0200

tdf#109347: don't verify SSL certificate for crashreport upload

Seems that on Windows we can not rely on the CA information to include
the necessary info to verify the connection to the server.

Change-Id: Ieed639c438f5a66e538d1126bb1e8ec1ea02b168
Reviewed-on: https://gerrit.libreoffice.org/40641
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/desktop/source/minidump/minidump.cxx 
b/desktop/source/minidump/minidump.cxx
index e44fc4ccfb2f..ac63bd41096c 100644
--- a/desktop/source/minidump/minidump.cxx
+++ b/desktop/source/minidump/minidump.cxx
@@ -108,6 +108,7 @@ bool uploadContent(std::map& 
parameters, std::string&
 
 curl_easy_setopt(curl, CURLOPT_URL, url.c_str());
 curl_easy_setopt(curl, CURLOPT_USERAGENT, kUserAgent);
+curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, false);
 // Set proxy information if necessary.
 if (!proxy.empty())
 curl_easy_setopt(curl, CURLOPT_PROXY, proxy.c_str());
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Jan-Marek Glogowski
 vcl/inc/win/saldata.hxx  |2 +-
 vcl/win/app/salinst.cxx  |   39 +--
 vcl/win/app/saltimer.cxx |   22 ++
 3 files changed, 20 insertions(+), 43 deletions(-)

New commits:
commit 50799a721c7ddcf9475a1b79984ed64ddd7cdf57
Author: Jan-Marek Glogowski 
Date:   Mon Jul 31 19:49:34 2017 +0200

tdf#109997 WIN don't post a callback event directly

I doesn't seem possible to post an event deterministically to the
end of the Windows message queue and then process this queued
events "in order".

PeekMessage and now even DispatchMessage process events out of
order - that's how this assert was hit. I was quite sure it would
not hit, but a simple resize proved me wrong. And the assert just
proved that all my assumptions were wrong :-(

So this gives up the whole idea of a short-circuit message queue
handling on Windows for busy processing of LO Idles and goes back
to some kind of the original "always timer" implementation. Since
the "parallel" processing of LO events after system messages
during DoYield  was dropped, this might be slower; or not.

In the end this simplifies the main loop almost to the starting
point, except for a little busy loop, if we wait for an Idle event
timer - not so busy acually, as we just switch to another local
thread, which hopefully is our idle timer waiting to fire.
A short-circuit with a little detour.

Change-Id: Id63a2a9e2a3b1501ad50a2c6f308a36efe55e68f

diff --git a/vcl/inc/win/saldata.hxx b/vcl/inc/win/saldata.hxx
index ed1d225b14b8..9ad5d9cfddf1 100644
--- a/vcl/inc/win/saldata.hxx
+++ b/vcl/inc/win/saldata.hxx
@@ -85,7 +85,7 @@ public:
 BYTE*   mpDitherLow;// Dither mapping table
 BYTE*   mpDitherHigh;   // Dither mapping table
 HANDLE  mnTimerId;  ///< Windows timer id
-boolmbOnIdleRunScheduler;   ///< Run the scheduler, if 
yield is idle
+boolmbOnIdleRunScheduler;   ///< Run yield until the 
scheduler processed the idle
 HHOOK   mhSalObjMsgHook;// hook to get interesting 
msg for SalObject
 HWNDmhWantLeaveMsg; // window handle, that 
want a MOUSELEAVE message
 AutoTimer*  mpMouseLeaveTimer;  // Timer for MouseLeave 
Test
diff --git a/vcl/win/app/salinst.cxx b/vcl/win/app/salinst.cxx
index 6458fca73c43..7ea3bd526675 100644
--- a/vcl/win/app/salinst.cxx
+++ b/vcl/win/app/salinst.cxx
@@ -575,29 +575,20 @@ ImplSalYield( bool bWait, bool bHandleAllCurrentEvents )
 if ( bOneEvent )
 {
 bWasMsg = true;
-if ( !(aMsg.message == SAL_MSG_TIMER_CALLBACK && 1 == aMsg.wParam) 
)
-{
-TranslateMessage( &aMsg );
-ImplSalDispatchMessage( &aMsg );
-}
-else
-{
-// This is just the scheduler wakeup message, in case we're
-// waiting in GetMessageW
-// So we can just drop it, but we have to fix the accounting!
-assert( pSalData->mbOnIdleRunScheduler );
-++nMaxEvents;
-}
+TranslateMessage( &aMsg );
+ImplSalDispatchMessage( &aMsg );
 }
 else
-{
-if ( nMaxEvents && pSalData->mbOnIdleRunScheduler )
+// busy loop to catch the 0ms timeout
+// We don't need to busy loop, if we wait anyway.
+// Even if we didn't process the event directly, report it.
+if ( pSalData->mbOnIdleRunScheduler && !bWait )
 {
-pSalData->mbOnIdleRunScheduler = false;
-EmitTimerCallback();
+SwitchToThread();
+nMaxEvents++;
 bOneEvent = true;
+bWasMsg = true;
 }
-}
 } while( --nMaxEvents && bOneEvent );
 
 // Also check that we don't wait when application already has quit
@@ -606,11 +597,8 @@ ImplSalYield( bool bWait, bool bHandleAllCurrentEvents )
 if ( GetMessageW( &aMsg, nullptr, 0, 0 ) )
 {
 // Ignore the scheduler wakeup message
-if ( !(aMsg.message == SAL_MSG_TIMER_CALLBACK && 1 == aMsg.wParam) 
)
-{
-TranslateMessage( &aMsg );
-ImplSalDispatchMessage( &aMsg );
-}
+TranslateMessage( &aMsg );
+ImplSalDispatchMessage( &aMsg );
 }
 }
 return bWasMsg;
@@ -735,9 +723,8 @@ LRESULT CALLBACK SalComWndProc( HWND, UINT nMsg, WPARAM 
wParam, LPARAM lParam, i
 while ( PeekMessageW(&aMsg, nullptr, SAL_MSG_TIMER_CALLBACK,
  SAL_MSG_TIMER_CALLBACK, PM_REMOVE | 
PM_NOYIELD | PM_QS_POSTMESSAGE) )
 assert( "Multiple timer messages in queue" )

[Libreoffice-commits] core.git: writerperfect/Library_wpftwriter.mk writerperfect/source

2017-08-01 Thread Miklos Vajna
 writerperfect/Library_wpftwriter.mk  |1 
 writerperfect/source/writer/EPUBExportFilter.cxx |4 +
 writerperfect/source/writer/exp/xmlimp.cxx   |   60 +++
 writerperfect/source/writer/exp/xmlimp.hxx   |   47 ++
 4 files changed, 111 insertions(+), 1 deletion(-)

New commits:
commit c90e9ca50300c7f59558095c2716c098632c8d37
Author: Miklos Vajna 
Date:   Tue Aug 1 16:45:44 2017 +0200

EPUB export: add initial document handler

It doesn't do anything useful yet, though.

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

diff --git a/writerperfect/Library_wpftwriter.mk 
b/writerperfect/Library_wpftwriter.mk
index 85ede9a89f74..5d9b6b47ed1d 100644
--- a/writerperfect/Library_wpftwriter.mk
+++ b/writerperfect/Library_wpftwriter.mk
@@ -73,6 +73,7 @@ $(eval $(call gb_Library_add_exception_objects,wpftwriter,\
writerperfect/source/writer/PagesImportFilter \
writerperfect/source/writer/StarOfficeWriterImportFilter \
writerperfect/source/writer/WordPerfectImportFilter \
+   writerperfect/source/writer/exp/xmlimp \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/writerperfect/source/writer/EPUBExportFilter.cxx 
b/writerperfect/source/writer/EPUBExportFilter.cxx
index 36cff7ab9dd6..3e4bd6198de1 100644
--- a/writerperfect/source/writer/EPUBExportFilter.cxx
+++ b/writerperfect/source/writer/EPUBExportFilter.cxx
@@ -15,6 +15,8 @@
 
 #include 
 
+#include "exp/xmlimp.hxx"
+
 using namespace com::sun::star;
 
 namespace writerperfect
@@ -31,7 +33,7 @@ sal_Bool EPUBExportFilter::filter(const 
uno::Sequence &rDe
 uno::Reference 
xInitialization(mxContext->getServiceManager()->createInstanceWithContext("com.sun.star.comp.Writer.XMLOasisExporter",
 mxContext), uno::UNO_QUERY);
 
 // The document handler will make the calls on the text interface provided 
by the EPUB export.
-uno::Reference xExportHandler;
+uno::Reference xExportHandler(new 
exp::XMLImport);
 
 // Let the ODT exporter read the doc model and invoke the doc handler.
 xInitialization->initialize({uno::makeAny(xExportHandler)});
diff --git a/writerperfect/source/writer/exp/xmlimp.cxx 
b/writerperfect/source/writer/exp/xmlimp.cxx
new file mode 100644
index ..1c915857413e
--- /dev/null
+++ b/writerperfect/source/writer/exp/xmlimp.cxx
@@ -0,0 +1,60 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * 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 "xmlimp.hxx"
+
+using namespace com::sun::star;
+
+namespace writerperfect
+{
+namespace exp
+{
+
+XMLImport::XMLImport()
+{
+}
+
+void XMLImport::startDocument()
+{
+}
+
+void XMLImport::endDocument()
+{
+}
+
+void XMLImport::startElement(const OUString &/*rName*/, const 
css::uno::Reference &/*xAttribs*/)
+{
+}
+
+void XMLImport::endElement(const OUString &/*rName*/)
+{
+}
+
+void XMLImport::characters(const OUString &/*rChars*/)
+{
+}
+
+void XMLImport::ignorableWhitespace(const OUString &/*rWhitespaces*/)
+{
+}
+
+void XMLImport::processingInstruction(const OUString &/*rTarget*/, const 
OUString &/*rData*/)
+{
+SAL_WARN("writerperfect", "XMLImport::processingInstruction: implement 
me");
+}
+
+void XMLImport::setDocumentLocator(const 
css::uno::Reference &/*xLocator*/)
+{
+SAL_WARN("writerperfect", "XMLImport::setDocumentLocator: implement me");
+}
+
+} // namespace exp
+} // namespace writerperfect
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/writerperfect/source/writer/exp/xmlimp.hxx 
b/writerperfect/source/writer/exp/xmlimp.hxx
new file mode 100644
index ..9d6d1eb4c0c6
--- /dev/null
+++ b/writerperfect/source/writer/exp/xmlimp.hxx
@@ -0,0 +1,47 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * 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_WRITERPERFECT_SOURCE_WRITER_EXP_XMLIMP_HXX
+#define INCLUDED_WRITERPERFECT_SOURCE_WRITER_EXP_XMLIMP_HXX
+
+#include 
+
+#include 
+
+namespace writerperfect
+{
+namespace exp
+{
+
+/// ODT export feeds this class to make librevenge calls.
+class XMLImport : public cppu::WeakImplHelper
+<
+css::xml::sax::XDocumentHandler
+>
+{
+public:
+XMLImport();
+
+// XDocumentHandler
+void SAL_CALL startDocument() override;
+void SAL_CALL endDocument() override;
+void SAL_CALL startElement(const OUString &rName, const 
css::uno::Reference &xA

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

2017-08-01 Thread jmzambon
 sw/qa/complex/writer/TextPortionEnumerationTest.java |  156 ---
 sw/qa/python/text_portion_enumeration_test.py|  137 
 2 files changed, 137 insertions(+), 156 deletions(-)

New commits:
commit 51dee24ce82e0fc4b864ac2905ce3587acf344f3
Author: jmzambon 
Date:   Tue Jul 18 18:08:46 2017 +0200

tdf#97362: TextPortionEnumerationTest partially migrated to python (part 4)

Convert tests:
- test_end1
- test_end2
- test_end3
- test_end4
- test_end5
- test_empty1
- test_empty2
- test_empty3
- test1

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

diff --git a/sw/qa/complex/writer/TextPortionEnumerationTest.java 
b/sw/qa/complex/writer/TextPortionEnumerationTest.java
index 3cf8b6d1299b..b13401e07d20 100644
--- a/sw/qa/complex/writer/TextPortionEnumerationTest.java
+++ b/sw/qa/complex/writer/TextPortionEnumerationTest.java
@@ -1258,162 +1258,6 @@ public class TextPortionEnumerationTest
 util.DesktopTools.closeDoc(m_xDoc);
 }
 
-@Test public void testEnd1() throws Exception
-{
-String name1 = mkName("bookmark");
-String name2 = mkName("toxmark");
-String name3 = mkName("refmark");
-TreeNode root = new TreeNode();
-root.appendChild( new TextNode("abc") );
-root.appendChild( new BookmarkNode(name1) );
-root.appendChild( new DocumentIndexMarkNode(name2) );
-root.appendChild( new ReferenceMarkNode(name3) );
-doTest(root);
-}
-
-@Test public void testEnd2() throws Exception
-{
-String name1 = mkName("bookmark");
-String name2 = mkName("frame");
-String name3 = mkName("refmark");
-String name4 = mkName("frame");
-String name5 = mkName("frame");
-TreeNode root = new TreeNode();
-root.appendChild( new TextNode("abc") );
-root.appendChild( new BookmarkNode(name1) );
-root.appendChild( new FrameNode(name2, AT_CHARACTER) );
-root.appendChild( new ReferenceMarkNode(name3) );
-root.appendChild( new FrameNode(name4, AT_CHARACTER) );
-root.appendChild( new FrameNode(name5, AT_CHARACTER) );
-doTest(root);
-}
-
-@Test public void testEnd3() throws Exception
-{
-String name1 = mkName("ftn");
-String name2 = mkName("toxmark");
-TreeNode root = new TreeNode();
-root.appendChild( new TextNode("abc") );
-root.appendChild( new FootnoteNode(name1) );
-root.appendChild( new DocumentIndexMarkNode(name2) );
-doTest(root);
-}
-
-@Test public void testEnd4() throws Exception
-{
-String name1 = mkName("bookmark");
-String name2 = mkName("frame");
-TreeNode root = new TreeNode();
-root.appendChild( new BookmarkStartNode(name1) );
-root.appendChild( new TextNode("abc") );
-root.appendChild( new FrameNode(name2, AS_CHARACTER) );
-root.appendChild( new BookmarkEndNode(name1) );
-doTest(root);
-}
-
-@Test public void testEnd5() throws Exception
-{
-String name1 = mkName("refmark");
-String name2 = mkName("ruby");
-TreeNode root = new TreeNode();
-root.appendChild( new ReferenceMarkStartNode(name1) );
-root.appendChild( new TextNode("abc") );
-TreeNode ruby = new RubyNode(name2);
-ruby.appendChild( new TextFieldNode("de") );
-root.appendChild(ruby);
-root.appendChild( new ReferenceMarkEndNode(name1) );
-doTest(root);
-}
-
-@Test public void testEmpty1() throws Exception
-{
-String name1 = mkName("refmark");
-String name2 = mkName("toxmark");
-String name3 = mkName("bookmark");
-String name4 = mkName("frame");
-String name7 = mkName("refmark");
-String name8 = mkName("toxmark");
-String name9 = mkName("bookmark");
-String nameA = mkName("frame");
-TreeNode root = new TreeNode();
-root.appendChild( new ReferenceMarkNode(name1) );
-root.appendChild( new DocumentIndexMarkNode(name2) );
-root.appendChild( new BookmarkNode(name3) );
-root.appendChild( new FrameNode(name4, AT_CHARACTER) );
-root.appendChild( new ReferenceMarkNode(name7) );
-root.appendChild( new DocumentIndexMarkNode(name8) );
-root.appendChild( new BookmarkNode(name9) );
-root.appendChild( new FrameNode(nameA, AT_CHARACTER) );
-doTest(root);
-}
-
-@Test public void testEmpty2() throws Exception
-{
-String name3 = mkName("bookmark");
-String name4 = mkName("frame");
-String name9 = mkName("bookmark");
-String nameA = mkName("frame");
-TreeNode root = new TreeNode();
-root.appendChild( new BookmarkNode(name3) );
-root.appendChild( n

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

2017-08-01 Thread Miklos Vajna
 writerperfect/source/writer/EPUBExportFilter.cxx |   25 +--
 writerperfect/source/writer/EPUBExportFilter.hxx |4 ++-
 2 files changed, 22 insertions(+), 7 deletions(-)

New commits:
commit a0abb2f6a4e2392ce44634a58f3a5d1af1868499
Author: Miklos Vajna 
Date:   Tue Aug 1 15:09:03 2017 +0200

EPUB export: invoke the underlying ODT exporter

The document handler is still missing, though.

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

diff --git a/writerperfect/source/writer/EPUBExportFilter.cxx 
b/writerperfect/source/writer/EPUBExportFilter.cxx
index d7fb0cac0e0d..36cff7ab9dd6 100644
--- a/writerperfect/source/writer/EPUBExportFilter.cxx
+++ b/writerperfect/source/writer/EPUBExportFilter.cxx
@@ -9,7 +9,9 @@
 
 #include "EPUBExportFilter.hxx"
 
+#include 
 #include 
+#include 
 
 #include 
 
@@ -18,14 +20,25 @@ using namespace com::sun::star;
 namespace writerperfect
 {
 
-EPUBExportFilter::EPUBExportFilter()
+EPUBExportFilter::EPUBExportFilter(const 
uno::Reference &xContext)
+: mxContext(xContext)
 {
 }
 
-sal_Bool EPUBExportFilter::filter(const uno::Sequence 
&/*rDescriptor*/)
+sal_Bool EPUBExportFilter::filter(const uno::Sequence 
&rDescriptor)
 {
-SAL_WARN("writerperfect", "EPUBExportFilter::filter: implement me");
-return true;
+// Create ODT exporter, this will feed our document handler.
+uno::Reference 
xInitialization(mxContext->getServiceManager()->createInstanceWithContext("com.sun.star.comp.Writer.XMLOasisExporter",
 mxContext), uno::UNO_QUERY);
+
+// The document handler will make the calls on the text interface provided 
by the EPUB export.
+uno::Reference xExportHandler;
+
+// Let the ODT exporter read the doc model and invoke the doc handler.
+xInitialization->initialize({uno::makeAny(xExportHandler)});
+uno::Reference xExporter(xInitialization, 
uno::UNO_QUERY);
+xExporter->setSourceDocument(mxSourceDocument);
+uno::Reference xFilter(xInitialization, uno::UNO_QUERY);
+return xFilter->filter(rDescriptor);
 }
 
 void EPUBExportFilter::cancel()
@@ -56,9 +69,9 @@ uno::Sequence 
EPUBExportFilter::getSupportedServiceNames()
 return aRet;
 }
 
-extern "C" SAL_DLLPUBLIC_EXPORT uno::XInterface *SAL_CALL 
com_sun_star_comp_Writer_EPUBExportFilter_get_implementation(uno::XComponentContext
 *, uno::Sequence const &)
+extern "C" SAL_DLLPUBLIC_EXPORT uno::XInterface *SAL_CALL 
com_sun_star_comp_Writer_EPUBExportFilter_get_implementation(uno::XComponentContext
 *pContext, uno::Sequence const &)
 {
-return cppu::acquire(new EPUBExportFilter);
+return cppu::acquire(new EPUBExportFilter(pContext));
 }
 
 } // namespace writerperfect
diff --git a/writerperfect/source/writer/EPUBExportFilter.hxx 
b/writerperfect/source/writer/EPUBExportFilter.hxx
index 101a4f85bf42..10f39dcfbef4 100644
--- a/writerperfect/source/writer/EPUBExportFilter.hxx
+++ b/writerperfect/source/writer/EPUBExportFilter.hxx
@@ -15,6 +15,7 @@
 #include 
 #include 
 #include 
+#include 
 
 namespace writerperfect
 {
@@ -27,10 +28,11 @@ class EPUBExportFilter : public cppu::WeakImplHelper
 css::lang::XServiceInfo
 >
 {
+css::uno::Reference mxContext;
 css::uno::Reference mxSourceDocument;
 
 public:
-EPUBExportFilter();
+EPUBExportFilter(const css::uno::Reference 
&xContext);
 
 // XFilter
 sal_Bool SAL_CALL filter(const 
css::uno::Sequence &rDescriptor) override;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-2-1' - loleaflet/src

2017-08-01 Thread Pranav Kant
 loleaflet/src/control/Toolbar.js |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 9141a5a31ce213316a0c113fdfffdbd27eb946fb
Author: Pranav Kant 
Date:   Wed Jun 7 10:13:48 2017 +0530

No need to specify the full path

Moreover, its ideal to use the same URL to get this *-help.html file with
which loleaflet.html is loaded, and not the one with 'dist' in it.

Change-Id: I2e25f9a2ef41bb1d23fc09878b0726d6b4019cee
(cherry picked from commit 00f4b4c0f2831c243439463b0e2378cb8a50d7b7)
Reviewed-on: https://gerrit.libreoffice.org/40619
Reviewed-by: Jan Holesovsky 
Tested-by: Jan Holesovsky 

diff --git a/loleaflet/src/control/Toolbar.js b/loleaflet/src/control/Toolbar.js
index b5f68749..832abdb0 100644
--- a/loleaflet/src/control/Toolbar.js
+++ b/loleaflet/src/control/Toolbar.js
@@ -176,7 +176,7 @@ L.Map.include({
 
showLOKeyboardHelp: function() {
var w = window.innerWidth / 2;
-   $.get('/loleaflet/dist/loleaflet-help.html', function(data) {
+   $.get('loleaflet-help.html', function(data) {
vex.open({
content: data,
showCloseButton: true,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-2-1' - loleaflet/src

2017-08-01 Thread Pranav Kant
 loleaflet/src/map/handler/Map.WOPI.js |   11 +++
 1 file changed, 11 insertions(+)

New commits:
commit 9fd3b29485e444ff30d0c41a2c6610ef052d8381
Author: Pranav Kant 
Date:   Tue Jun 20 17:12:43 2017 +0530

Warn users if they try to use post message API incorrectly

Change-Id: I09ce1a14587f558765e02fc8197030f4a5d2cee0
(cherry picked from commit 2abf2421f3e984693b114e8597d2e88fd1430ba8)
Reviewed-on: https://gerrit.libreoffice.org/40618
Reviewed-by: Jan Holesovsky 
Tested-by: Jan Holesovsky 

diff --git a/loleaflet/src/map/handler/Map.WOPI.js 
b/loleaflet/src/map/handler/Map.WOPI.js
index dd4ddb21..8e96efcc 100644
--- a/loleaflet/src/map/handler/Map.WOPI.js
+++ b/loleaflet/src/map/handler/Map.WOPI.js
@@ -100,6 +100,17 @@ L.Map.WOPI = L.Handler.extend({
}
 
var msg = JSON.parse(e.data);
+   if (msg.MessageId === 'Host_PostmessageReady') {
+   // We already have a listener for this in 
loleaflet.html, so ignore it here
+   return;
+   }
+
+   // For all other messages, warn if trying to interact before we 
are completely loaded
+   if (!this._appLoaded) {
+   console.error('LibreOffice Online not loaded yet. 
Listen for App_LoadingStatus (Document_Loaded) event before using PostMessage 
API. Ignoring post message \'' + msg.MessageId + '\'.');
+   return;
+   }
+
if (msg.MessageId === 'Insert_Button') {
if (msg.Values) {
if (msg.Values.id && 
!w2ui['toolbar-up'].get(msg.Values.id)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-2-1' - loleaflet/src

2017-08-01 Thread Pranav Kant
 loleaflet/src/map/handler/Map.WOPI.js |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit fec6a48dbf4e51becbbf4b6a2e332e19598cd983
Author: Pranav Kant 
Date:   Tue Jun 20 16:38:28 2017 +0530

Make this custom button's css consistent with other toolbar images

Change-Id: I39158d634eb5fbe0ce54cb4e5f6be3d01982b074
(cherry picked from commit 8ca5efb6710c340f5ab53631f7a8edfceaa512c5)
Reviewed-on: https://gerrit.libreoffice.org/40617
Reviewed-by: Jan Holesovsky 
Tested-by: Jan Holesovsky 

diff --git a/loleaflet/src/map/handler/Map.WOPI.js 
b/loleaflet/src/map/handler/Map.WOPI.js
index 44f4917b..dd4ddb21 100644
--- a/loleaflet/src/map/handler/Map.WOPI.js
+++ b/loleaflet/src/map/handler/Map.WOPI.js
@@ -106,7 +106,7 @@ L.Map.WOPI = L.Handler.extend({
&& msg.Values.imgurl) {
if (this._map._permission === 'edit') {
// add the css rule for the 
image
-   $('html > head > 
style').append('.w2ui-icon.' + msg.Values.id + '{background: url(' + 
msg.Values.imgurl + ')}');
+   $('html > head > 
style').append('.w2ui-icon.' + msg.Values.id + '{background: url(' + 
msg.Values.imgurl + ') no-repeat center !important; }');
 
// add the item to the toolbar

w2ui['toolbar-up'].insert('save', [
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-2-1' - common/Seccomp.cpp wsd/AdminModel.hpp

2017-08-01 Thread Jan Holesovsky
 common/Seccomp.cpp |4 ++--
 wsd/AdminModel.hpp |1 +
 2 files changed, 3 insertions(+), 2 deletions(-)

New commits:
commit a1b40b10edb4555291c7313d85089a37c7b18920
Author: Jan Holesovsky 
Date:   Tue Aug 1 16:01:34 2017 +0200

Fix two gerrit mis-merges.

Change-Id: I03af522f6780ab9fd0f9daa3d004e5d69eb371fa

diff --git a/common/Seccomp.cpp b/common/Seccomp.cpp
index 230559f5..e08b9ea8 100644
--- a/common/Seccomp.cpp
+++ b/common/Seccomp.cpp
@@ -12,13 +12,13 @@
  */
 
 #include "config.h"
-
-#if DISABLE_SECCOMP == 0
 #include 
 #include 
 #include 
 #include 
+#if DISABLE_SECCOMP == 0
 #include 
+#endif
 #include 
 #include 
 #include 
diff --git a/wsd/AdminModel.hpp b/wsd/AdminModel.hpp
index 5a35bc8c..d20f6fcd 100644
--- a/wsd/AdminModel.hpp
+++ b/wsd/AdminModel.hpp
@@ -60,6 +60,7 @@ struct DocBasicInfo
   _saved(saved),
   _mem(mem)
 { }
+};
 
 struct DocProcSettings
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-3' - sw/qa xmloff/source

2017-08-01 Thread Tamás Zolnai
 sw/qa/extras/odfimport/data/tdf109228.odt  |binary
 sw/qa/extras/odfimport/odfimport.cxx   |7 +++
 xmloff/source/text/XMLTextFrameContext.cxx |1 +
 3 files changed, 8 insertions(+)

New commits:
commit de5afba4c116792d795339f7e773e302259d8bf0
Author: Tamás Zolnai 
Date:   Thu Jul 20 16:39:07 2017 +0200

tdf#109228: FILESAVE: ODT: Anchor changed to 'to character' after RT

Ignore frames without names, becuase the code does not handle
them well. It does not affect those use case for which the
deduplication code was added.

Reviewed-on: https://gerrit.libreoffice.org/40222
Tested-by: Jenkins 
Reviewed-by: Tamás Zolnai 
(cherry picked from commit 615c2a2c54d3e7aefb4986ae7d8de81a42022988)

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

diff --git a/sw/qa/extras/odfimport/data/tdf109228.odt 
b/sw/qa/extras/odfimport/data/tdf109228.odt
new file mode 100755
index ..0f3368e1b201
Binary files /dev/null and b/sw/qa/extras/odfimport/data/tdf109228.odt differ
diff --git a/sw/qa/extras/odfimport/odfimport.cxx 
b/sw/qa/extras/odfimport/odfimport.cxx
index 8911e8067107..af20b422505e 100644
--- a/sw/qa/extras/odfimport/odfimport.cxx
+++ b/sw/qa/extras/odfimport/odfimport.cxx
@@ -20,6 +20,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -808,5 +809,11 @@ DECLARE_ODFIMPORT_TEST(testTdf109080_style_ns, 
"tdf109080_style_ns.odt")
 parseDump("/root/page[2]/footer/txt/text()"));
 }
 
+DECLARE_ODFIMPORT_TEST(testTdf109228, "tdf109228.odt")
+{
+//  Embedded object with no frame name was imported incorrectly, it was 
achored 'to character' instead of 'as character'
+CPPUNIT_ASSERT_EQUAL(text::TextContentAnchorType_AS_CHARACTER, 
getProperty(getShape(1), "AnchorType"));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/xmloff/source/text/XMLTextFrameContext.cxx 
b/xmloff/source/text/XMLTextFrameContext.cxx
index 136ed2db8998..ed75d6cafca9 100644
--- a/xmloff/source/text/XMLTextFrameContext.cxx
+++ b/xmloff/source/text/XMLTextFrameContext.cxx
@@ -569,6 +569,7 @@ void XMLTextFrameContext_Impl::Create( bool 
/*bHRefOrBase64*/ )
 
 // Skip duplicated frames
 if(!mbMultipleContent && // It's allowed to have multiple image for the 
same frame
+   !sName.isEmpty() &&
xTextImportHelper->IsDuplicateFrame(sName, nX, nY, nWidth, nHeight))
 {
 bCreateFailed = true;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: configure.ac

2017-08-01 Thread brainbreaker
 configure.ac |   12 +++-
 1 file changed, 3 insertions(+), 9 deletions(-)

New commits:
commit 7f369c730a7e6ab834f67c294e4091378f3b99ce
Author: brainbreaker 
Date:   Thu Jul 27 18:21:55 2017 +0530

android: remove unused GCC related code from configure.ac

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

diff --git a/configure.ac b/configure.ac
index 51f336a9b83f..962cc2591733 100644
--- a/configure.ac
+++ b/configure.ac
@@ -351,7 +351,7 @@ AC_ARG_WITH(android-ndk,
 AC_ARG_WITH(android-ndk-toolchain-version,
 AS_HELP_STRING([--with-android-ndk-toolchain-version],
 [Specify which toolchain version to use, of those present in the
-Android NDK you are using. The default is 4.9 currently.]), ,)
+Android NDK you are using. The default is clang 5.0 currently.]), ,)
 
 AC_ARG_WITH(android-sdk,
 AS_HELP_STRING([--with-android-sdk],
@@ -530,9 +530,9 @@ if test -n "$with_android_ndk"; then
 test -z "$RANLIB" && 
RANLIB=$ANDROID_BINUTILS_BIN/$android_gnu_prefix-ranlib
 test -z "$STRIP" && STRIP=$ANDROID_BINUTILS_BIN/$android_gnu_prefix-strip
 
-# When using the 4.6 or newer toolchain, use the gold linker
+# When using the clang toolchain, use the gold linker
 case "$with_android_ndk_toolchain_version" in
-4.[[6789]]*|[[56789]].*|clang*)
+clang*)
 if test "$host_cpu" = arm -a "$ENABLE_LTO" != TRUE; then
 ANDROIDCFLAGS="$ANDROIDCFLAGS -fuse-ld=gold"
 fi
@@ -566,18 +566,12 @@ if test -n "$with_android_ndk"; then
 
 if test -z "$CC"; then
 case "$with_android_ndk_toolchain_version" in
-4.*)
-CC="$ANDROID_COMPILER_BIN/$android_gnu_prefix-gcc $ANDROIDCFLAGS"
-;;
 clang*)
 CC="$ANDROID_COMPILER_BIN/clang $ANDROIDCFLAGS"
 esac
 fi
 if test -z "$CXX"; then
 case "$with_android_ndk_toolchain_version" in
-4.*)
-CXX="$ANDROID_COMPILER_BIN/$android_gnu_prefix-g++ 
$ANDROIDCXXFLAGS"
-;;
 clang*)
 CXX="$ANDROID_COMPILER_BIN/clang++ $ANDROIDCXXFLAGS"
 ;;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: fpicker/Library_fps_aqua.mk

2017-08-01 Thread Caolán McNamara
 fpicker/Library_fps_aqua.mk |1 +
 1 file changed, 1 insertion(+)

New commits:
commit ae58332da82db163dee188ec3dff28662c746751
Author: Caolán McNamara 
Date:   Tue Aug 1 14:03:28 2017 +0100

fix aqua build

Change-Id: I814cecc30c95e967b16fd6d57cb4b3eaf3d5e5b4

diff --git a/fpicker/Library_fps_aqua.mk b/fpicker/Library_fps_aqua.mk
index 91e875c44ed9..84caa24dd31a 100644
--- a/fpicker/Library_fps_aqua.mk
+++ b/fpicker/Library_fps_aqua.mk
@@ -31,6 +31,7 @@ $(eval $(call gb_Library_use_libraries,fps_aqua,\
cppuhelper \
i18nlangtag \
sal \
+   utl \
tl \
vcl \
 ))
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: filter/Configuration_filter.mk filter/source writerperfect/Library_wpftwriter.mk writerperfect/source

2017-08-01 Thread Miklos Vajna
 filter/Configuration_filter.mk|2 
 filter/source/config/fragments/filters/EPUB.xcu   |   30 
 filter/source/config/fragments/types/writer_EPUB_Document.xcu |   29 
 writerperfect/Library_wpftwriter.mk   |1 
 writerperfect/source/writer/EPUBExportFilter.cxx  |   66 ++
 writerperfect/source/writer/EPUBExportFilter.hxx  |   52 +++
 writerperfect/source/writer/wpftwriter.component  |4 
 7 files changed, 184 insertions(+)

New commits:
commit ba7ebd400d39bc84ababab3bb416a199d57780e8
Author: Miklos Vajna 
Date:   Tue Aug 1 13:51:28 2017 +0200

writerperfect: add initial EPUB export filter

It doesn't do anything yet, but EPUBExportFilter::filter() is called.
Actual functionality will be provided by libepubgen later.

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

diff --git a/filter/Configuration_filter.mk b/filter/Configuration_filter.mk
index c39e5e03aba7..85bbaf583a85 100644
--- a/filter/Configuration_filter.mk
+++ b/filter/Configuration_filter.mk
@@ -354,6 +354,7 @@ $(eval $(call 
filter_Configuration_add_types,fcfg_langpack,fcfg_writer_types.xcu
MWAW_Text_Document \
Palm_Text_Document \
StarOffice_Writer \
+   writer_EPUB_Document \
 ))
 
 $(eval $(call 
filter_Configuration_add_filters,fcfg_langpack,fcfg_writer_filters.xcu,filter/source/config/fragments/filters,\
@@ -401,6 +402,7 @@ $(eval $(call 
filter_Configuration_add_filters,fcfg_langpack,fcfg_writer_filters
MWAW_Text_Document \
Palm_Text_Document \
StarOffice_Writer \
+   EPUB \
 ))
 
 # fcfg_web
diff --git a/filter/source/config/fragments/filters/EPUB.xcu 
b/filter/source/config/fragments/filters/EPUB.xcu
new file mode 100644
index ..49d8020b0d39
--- /dev/null
+++ b/filter/source/config/fragments/filters/EPUB.xcu
@@ -0,0 +1,30 @@
+
+
+EXPORT ALIEN 
3RDPARTYFILTER
+
+com.sun.star.comp.Writer.EPUBExportFilter
+EPUB
+
+EPUB Document
+
+0
+writer_EPUB_Document
+
+com.sun.star.text.TextDocument
+
diff --git a/filter/source/config/fragments/types/writer_EPUB_Document.xcu 
b/filter/source/config/fragments/types/writer_EPUB_Document.xcu
new file mode 100644
index ..51a0a73c2047
--- /dev/null
+++ b/filter/source/config/fragments/types/writer_EPUB_Document.xcu
@@ -0,0 +1,29 @@
+
+
+
+
+epub
+application/epub+zip
+false
+
+
+EPUB Document
+
+
+
diff --git a/writerperfect/Library_wpftwriter.mk 
b/writerperfect/Library_wpftwriter.mk
index cc59480eae11..85ede9a89f74 100644
--- a/writerperfect/Library_wpftwriter.mk
+++ b/writerperfect/Library_wpftwriter.mk
@@ -67,6 +67,7 @@ $(eval $(call gb_Library_use_externals,wpftwriter,\
 $(eval $(call gb_Library_add_exception_objects,wpftwriter,\
writerperfect/source/writer/AbiWordImportFilter \
writerperfect/source/writer/EBookImportFilter \
+   writerperfect/source/writer/EPUBExportFilter \
writerperfect/source/writer/MSWorksImportFilter \
writerperfect/source/writer/MWAWImportFilter \
writerperfect/source/writer/PagesImportFilter \
diff --git a/writerperfect/source/writer/EPUBExportFilter.cxx 
b/writerperfect/source/writer/EPUBExportFilter.cxx
new file mode 100644
index ..d7fb0cac0e0d
--- /dev/null
+++ b/writerperfect/source/writer/EPUBExportFilter.cxx
@@ -0,0 +1,66 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * 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 "EPUBExportFilter.hxx"
+
+#include 
+
+#include 
+
+using namespace com::sun::star;
+
+namespace writerperfect
+{
+
+EPUBExportFilter::EPUBExportFilter()
+{
+}
+
+sal_Bool EPUBExportFilter::filter(const uno::Sequence 
&/*rDescriptor*/)
+{
+SAL_WARN("writerperfect", "EPUBExportFilter::filter: implement me");
+return true;
+}
+
+void EPUBExportFilter::cancel()
+{
+}
+
+void EPUBExportFilter::setSourceDocument(const 
uno::Reference &xDocument)
+{
+mxSourceDocument = xDocument;
+}
+
+OUString EPUBExportFilter::getImplementationName()
+{
+return OUString("com.sun.star.comp.Writer.EPUBExportFilter");
+}
+
+sal_Bool EPUBExportFilter::supportsService(const OUString &rServiceName)
+{
+return cppu::supportsService(this, rServiceName);
+}
+
+uno::Sequence EPUBExportFilter::getSupportedServiceNames()
+{
+uno::Sequence aRet =
+{
+OUString("com.sun.star.document.ExportFilter")
+};
+   

[Libreoffice-commits] core.git: accessibility/inc accessibility/source avmedia/source basctl/inc basctl/source basic/source chart2/inc chart2/source compilerplugins/clang connectivity/source cppcanvas

2017-08-01 Thread Caolán McNamara
 accessibility/inc/pch/precompiled_acc.hxx   |2 
 accessibility/source/helper/accresmgr.cxx   |7 
 avmedia/source/framework/mediamisc.cxx  |7 
 avmedia/source/inc/mediamisc.hxx|2 
 basctl/inc/pch/precompiled_basctl.hxx   |2 
 basctl/source/basicide/iderdll.cxx  |4 
 basic/source/runtime/basrdll.cxx|4 
 basic/source/sbx/sbxscan.cxx|4 
 chart2/inc/pch/precompiled_chartcontroller.hxx  |2 
 chart2/source/tools/ResId.cxx   |2 
 chart2/source/tools/ResourceManager.cxx |6 
 compilerplugins/clang/unusedenumconstants.writeonly.results |8 -
 connectivity/source/commontools/sqlerror.cxx|6 
 connectivity/source/resource/sharedresources.cxx|6 
 cppcanvas/inc/pch/precompiled_cppcanvas.hxx |2 
 cui/inc/pch/precompiled_cui.hxx |2 
 cui/source/factory/cuiresmgr.cxx|   16 --
 dbaccess/inc/pch/precompiled_dba.hxx|2 
 dbaccess/inc/pch/precompiled_dbmm.hxx   |2 
 dbaccess/source/core/resource/core_resource.cxx |6 
 desktop/inc/app.hxx |2 
 desktop/inc/dp_shared.hxx   |6 
 desktop/inc/pch/precompiled_sofficeapp.hxx  |2 
 desktop/source/deployment/gui/dp_gui_dialog2.cxx|2 
 desktop/source/deployment/misc/dp_resource.cxx  |2 
 desktop/source/lib/init.cxx |2 
 desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx  |2 
 desktop/source/pkgchk/unopkg/unopkg_shared.h|2 
 editeng/inc/pch/precompiled_editeng.hxx |2 
 editeng/source/editeng/eerdll.cxx   |5 
 embeddedobj/source/general/docholder.cxx|4 
 extensions/CppunitTest_extensions_test_update.mk|2 
 extensions/Library_updatecheckui.mk |1 
 extensions/Library_updchk.mk|2 
 extensions/source/abpilot/unodialogabp.hxx  |7 
 extensions/source/bibliography/bibmod.cxx   |4 
 extensions/source/dbpilots/unoautopilot.hxx |1 
 extensions/source/inc/componentmodule.cxx   |   75 --
 extensions/source/inc/componentmodule.hxx   |   37 -
 extensions/source/propctrlr/modulepcr.cxx   |6 
 extensions/source/propctrlr/modulepcr.hxx   |6 
 extensions/source/scanner/sanedlg.cxx   |4 
 extensions/source/update/check/updatehdl.cxx|4 
 extensions/source/update/ui/updatecheckui.cxx   |4 
 filter/source/graphicfilter/eps/eps.cxx |4 
 filter/source/pdf/impdialog.cxx |4 
 filter/source/pdf/pdfexport.cxx |4 
 filter/source/t602/t602filter.cxx   |2 
 filter/source/xsltdialog/xmlfiltersettingsdialog.cxx|4 
 filter/source/xsltdialog/xmlfiltertabdialog.cxx |2 
 forms/source/resource/frm_resource.cxx  |7 
 formula/source/core/api/FormulaCompiler.cxx |2 
 formula/source/core/resource/core_resource.cxx  |6 
 formula/source/ui/inc/ModuleHelper.hxx  |2 
 formula/source/ui/resource/ModuleHelper.cxx |2 
 fpicker/inc/fpsofficeResMgr.hxx |4 
 fpicker/source/aqua/resourceprovider.mm |2 
 fpicker/source/office/iodlgimp.cxx  |4 
 fpicker/source/win32/misc/resourceprovider.cxx  |2 
 framework/inc/pch/precompiled_fwe.hxx   |2 
 framework/inc/pch/precompiled_fwi.hxx   |2 
 framework/inc/pch/precompiled_fwk.hxx   |2 
 framework/inc/pch/precompiled_fwl.hxx   |2 
 framework/source/fwe/classes/fwkresid.cxx   |   24 ---
 framework/source/uiconfiguration/ImageList.cxx  |1 
 include/unotools/componentresmodule.hxx |   57 ---
 include/unotools/resmgr.hxx |   17 +-
 include/vcl/builder.hxx |2 
 ios/CustomTarget_Lo_Xcconfig.mk |2 
 reportdesign/inc/pch/precompiled_rpt.hxx|2 
 reportdesign/inc/pch/precompiled_rptui.hxx  |2 
 reportdesign/source/core/resource/core_resource.cxx |7 
 

[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - sw/qa xmloff/source

2017-08-01 Thread Tamás Zolnai
 sw/qa/extras/odfimport/data/tdf109228.odt  |binary
 sw/qa/extras/odfimport/odfimport.cxx   |6 ++
 xmloff/source/text/XMLTextFrameContext.cxx |1 +
 3 files changed, 7 insertions(+)

New commits:
commit f200d5700782ae179fd96b6ad4b0fe8e7edd1616
Author: Tamás Zolnai 
Date:   Thu Jul 20 12:15:13 2017 +0200

tdf#109228: FILESAVE: ODT: Anchor changed to 'to character' after RT

Ignore frames without names, becuase the code does not handle
them well. It does not affect those use case for which the
deduplication code was added.

Reviewed-on: https://gerrit.libreoffice.org/40222
Tested-by: Jenkins 
Reviewed-by: Tamás Zolnai 
(cherry picked from commit 615c2a2c54d3e7aefb4986ae7d8de81a42022988)

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

diff --git a/sw/qa/extras/odfimport/data/tdf109228.odt 
b/sw/qa/extras/odfimport/data/tdf109228.odt
new file mode 100755
index ..0f3368e1b201
Binary files /dev/null and b/sw/qa/extras/odfimport/data/tdf109228.odt differ
diff --git a/sw/qa/extras/odfimport/odfimport.cxx 
b/sw/qa/extras/odfimport/odfimport.cxx
index 2f1f1f1f..2439334ea512 100644
--- a/sw/qa/extras/odfimport/odfimport.cxx
+++ b/sw/qa/extras/odfimport/odfimport.cxx
@@ -831,5 +831,11 @@ DECLARE_ODFIMPORT_TEST(testTdf109080_style_ns, 
"tdf109080_style_ns.odt")
 parseDump("/root/page[2]/footer/txt/text()"));
 }
 
+DECLARE_ODFIMPORT_TEST(testTdf109228, "tdf109228.odt")
+{
+//  Embedded object with no frame name was imported incorrectly, it was 
achored 'to character' instead of 'as character'
+CPPUNIT_ASSERT_EQUAL(text::TextContentAnchorType_AS_CHARACTER, 
getProperty(getShape(1), "AnchorType"));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/xmloff/source/text/XMLTextFrameContext.cxx 
b/xmloff/source/text/XMLTextFrameContext.cxx
index ece946e001b6..4876f755a183 100644
--- a/xmloff/source/text/XMLTextFrameContext.cxx
+++ b/xmloff/source/text/XMLTextFrameContext.cxx
@@ -526,6 +526,7 @@ void XMLTextFrameContext_Impl::Create()
 
 // Skip duplicated frames
 if(!mbMultipleContent && // It's allowed to have multiple image for the 
same frame
+   !sName.isEmpty() &&
xTextImportHelper->IsDuplicateFrame(sName, nX, nY, nWidth, nHeight))
 {
 bCreateFailed = true;
___
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.3-21'

2017-08-01 Thread Andras Timar
Tag 'cp-5.3-21' created by Andras Timar  at 
2017-08-01 12:17 +

cp-5.3-21

Changes since cp-5.3-20-54:
---
 0 files changed
---
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] help.git: Changes to 'refs/tags/cp-5.3-21'

2017-08-01 Thread Andras Timar
Tag 'cp-5.3-21' created by Andras Timar  at 
2017-08-01 12:17 +

cp-5.3-21

Changes since libreoffice-5-3-branch-point-28:
---
 0 files changed
---
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] translations.git: Changes to 'refs/tags/cp-5.3-21'

2017-08-01 Thread Christian Lohmaier
Tag 'cp-5.3-21' created by Andras Timar  at 
2017-08-01 12:17 +

cp-5.3-21

Changes since cp-5.3-10:
Christian Lohmaier (1):
  update translations for 5.3.3 rc2

---
 source/am/cui/source/options.po|8 
 source/am/cui/source/tabpages.po   |8 
 source/am/cui/uiconfig/ui.po   |8 
 source/am/fpicker/source/office.po |   10 
 source/am/officecfg/registry/data/org/openoffice/Office.po |6 
 source/am/sc/source/ui/src.po  |8 
 source/am/sfx2/source/dialog.po|   12 
 source/am/svtools/source/dialogs.po|8 
 source/am/svtools/source/misc.po   |8 
 source/am/svx/source/stbctrls.po   |8 
 source/am/svx/uiconfig/ui.po   |   10 
 source/bg/sc/uiconfig/scalc/ui.po  |   20 
 source/bg/sfx2/source/dialog.po|   12 
 source/bg/svx/source/dialog.po |   30 
 source/bg/svx/source/form.po   |   10 
 source/bg/svx/source/stbctrls.po   |8 
 source/bg/svx/source/tbxctrls.po   |6 
 source/bg/svx/uiconfig/ui.po   |  289 
 source/bg/sw/source/ui/utlui.po|   21 
 source/bg/sw/source/uibase/utlui.po|6 
 source/bg/sw/uiconfig/swriter/ui.po|5 
 source/br/cui/uiconfig/ui.po   |   70 -
 source/br/extensions/source/bibliography.po|   12 
 source/br/extensions/source/propctrlr.po   |  152 ++--
 source/br/sc/source/ui/src.po  |   12 
 source/ca/helpcontent2/source/text/scalc/00.po |   20 
 source/ca/helpcontent2/source/text/scalc/01.po |8 
 source/ca/helpcontent2/source/text/scalc/guide.po  |   10 
 source/ca/helpcontent2/source/text/shared/01.po|6 
 source/ca/helpcontent2/source/text/shared/guide.po |5 
 source/ca/helpcontent2/source/text/shared/optionen.po  |8 
 source/ca/helpcontent2/source/text/simpress/guide.po   |   10 
 source/ca/helpcontent2/source/text/swriter/01.po   |   13 
 source/ca/helpcontent2/source/text/swriter/guide.po|   25 
 source/ca/officecfg/registry/data/org/openoffice/Office/UI.po  |8 
 source/ca/sc/uiconfig/scalc/ui.po  |6 
 source/ca/svx/uiconfig/ui.po   |   12 
 source/cy/cui/uiconfig/ui.po   |8 
 source/cy/sfx2/source/dialog.po|   12 
 source/cy/sfx2/uiconfig/ui.po  |   15 
 source/cy/svtools/source/dialogs.po|8 
 source/cy/svtools/source/misc.po   |8 
 source/cy/svx/source/stbctrls.po   |   10 
 source/cy/svx/uiconfig/ui.po   |   10 
 source/da/cui/uiconfig/ui.po   |8 
 source/da/helpcontent2/source/text/scalc/01.po |   12 
 source/da/sfx2/source/dialog.po|   14 
 source/da/sfx2/uiconfig/ui.po  |   17 
 source/da/svtools/source/dialogs.po|   10 
 source/da/svtools/source/java.po   |   12 
 source/da/svtools/source/misc.po   |   10 
 source/da/svx/source/stbctrls.po   |8 
 source/da/svx/uiconfig/ui.po   |   12 
 source/de/editeng/source/items.po  |   10 
 source/de/formula/source/core/resource.po  |8 
 source/de/helpcontent2/source/auxiliary.po |6 
 source/de/helpcontent2/source/text/sbasic/shared/01.po |   10 
 source/de/helpcontent2/source/text/scalc.po|6 
 source/de/helpcontent2/source/text/scalc/00.po |6 
 source/de/helpcontent2/source/text/scalc/01.po |  100 +-
 source/de/helpcontent2/source/text/scalc/guide.po  |   34 
 source/de/helpcontent2/source/text/schart/01.po|6 
 source/de/helpcontent2/source/text/shared/00.po|   10 
 source/de/helpcontent2/source/text/shared/01.po|   12 
 source/de/helpcontent2/source/text/shared/explorer/database.po |8 
 source/de/helpcontent2/source/text/shared/guide.po |   16 
 source/de/helpcontent2/source/text/shared/optionen.po

[Libreoffice-commits] dictionaries.git: Changes to 'refs/tags/cp-5.3-21'

2017-08-01 Thread Olivier R
Tag 'cp-5.3-21' created by Andras Timar  at 
2017-08-01 12:17 +

cp-5.3-21

Changes since cp-5.3-10:
Olivier R (1):
  tdf#107558 French spelling dictionary (6.0.3) and thesaurus

---
 fr_FR/README_fr.txt   |4 
 fr_FR/description.xml |2 
 fr_FR/fr.aff  |17751 ++--
 fr_FR/fr.dic  |155369 
+-
 fr_FR/package-description.txt |2 
 fr_FR/thes_fr.dat |  206 
 6 files changed, 88495 insertions(+), 84839 deletions(-)
---
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Pranav Kant
 sd/source/ui/view/drviews2.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f4e5940abbbaa3c2747108b0954e8912d164f3e5
Author: Pranav Kant 
Date:   Tue Aug 1 16:37:52 2017 +0530

tdf#110743: Use page position to insert master page, not id

Fallback from c454fbb9b62164d5f047990ae63522c9fb932086

Change-Id: I8835f1a23feeb12d77963e621e8d9d59568420f2
(cherry picked from commit d4fc7da34f8cdd6f7823236fe57020c9b104bc1a)

diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx
index 15aeca53f41d..e817dcfc4757 100644
--- a/sd/source/ui/view/drviews2.cxx
+++ b/sd/source/ui/view/drviews2.cxx
@@ -354,7 +354,7 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
 xMasterPagesSupplier->getMasterPages());
 if (xMasterPages.is())
 {
-sal_uInt16 nIndex = GetCurPageId();
+sal_uInt16 nIndex = GetCurPagePos() + 1;
 xMasterPages->insertNewByIndex (nIndex);
 
 // Create shapes for the default layout.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-2-1' - loleaflet/src wsd/DocumentBroker.cpp wsd/protocol.txt

2017-08-01 Thread Pranav Kant
 loleaflet/src/core/Socket.js |3 +--
 wsd/DocumentBroker.cpp   |   22 ++
 wsd/protocol.txt |6 +++---
 3 files changed, 22 insertions(+), 9 deletions(-)

New commits:
commit c8e462fb6fd2b78e2d522a22005558f203dadced
Author: Pranav Kant 
Date:   Mon Jun 19 20:00:37 2017 +0530

wsd: Don't show dialog if document is unmodified

Change-Id: Ibb9e2122461c577863d1f713070748bdda6129d1
(cherry picked from commit c88780b2d4d7b86810f24fecd5cc2aa8a04781e7)
Reviewed-on: https://gerrit.libreoffice.org/40616
Reviewed-by: Jan Holesovsky 
Tested-by: Jan Holesovsky 

diff --git a/loleaflet/src/core/Socket.js b/loleaflet/src/core/Socket.js
index 88d3fd4d..2de5cceb 100644
--- a/loleaflet/src/core/Socket.js
+++ b/loleaflet/src/core/Socket.js
@@ -282,8 +282,7 @@ L.Socket = L.Class.extend({
}, timeoutMs);
}
else if (textMsg.startsWith('documentconflict')) {
-   var username = 
textMsg.substring('documentconflict '.length);
-   msg = _('%user asked to refresh the document. 
Document will now refresh automatically.').replace('%user', username);
+   msg = _('Document has changed in storage. 
Loading the new document. Your version is available as revision.');
 
if (this._map._docLayer) {
this._map._docLayer.removeAllViews();
diff --git a/wsd/DocumentBroker.cpp b/wsd/DocumentBroker.cpp
index 46eef5e5..eb3fc099 100644
--- a/wsd/DocumentBroker.cpp
+++ b/wsd/DocumentBroker.cpp
@@ -511,9 +511,16 @@ bool DocumentBroker::load(const 
std::shared_ptr& session, const s
  << "Actual: " << fileInfo._modifiedTime << Log::end;
 
 _documentChangedInStorage = true;
-const std::string errorMsg = "error: cmd=storage 
kind=documentconflict";
-session->sendTextFrame(errorMsg);
-broadcastMessage(errorMsg);
+if (_isModified)
+{
+const std::string errorMsg = "error: cmd=storage 
kind=documentconflict";
+session->sendTextFrame(errorMsg);
+broadcastMessage(errorMsg);
+}
+else
+{
+closeDocument("documentconflict");
+}
 }
 }
 
@@ -675,7 +682,14 @@ bool DocumentBroker::saveToStorageInternal(const 
std::string& sessionId,
 {
 LOG_ERR("PutFile says that Document changed in storage");
 _documentChangedInStorage = true;
-broadcastMessage("error: cmd=storage kind=documentconflict");
+if (_isModified)
+{
+broadcastMessage("error: cmd=storage kind=documentconflict");
+}
+else
+{
+closeDocument("documentconflict");
+}
 }
 
 return false;
diff --git a/wsd/protocol.txt b/wsd/protocol.txt
index e775a605..7ac54b68 100644
--- a/wsd/protocol.txt
+++ b/wsd/protocol.txt
@@ -277,9 +277,9 @@ close: 
 shutting down to let clients know they can try connecting
 after a short interval.
 
-* documentconflict  - All sessions of this document are going 
down
-because file was changed in storage and one of the user ( with ) asked to reload the session for all.
+* documentconflict - All sessions of this document are going down
+because file was changed in storage and we want to load the new document
+from the storage.
 
 getchildid: id=
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[GSoC] Replace EditEngine binary clipboard with ODF filter - Weekly Report 10 - Varun Dhall

2017-08-01 Thread Varun Dhall
Hi all!

Last week of GSoC was passed in removing BIN format from all the modules
and unused SfxItemPool serialisation code from editengine.

Right now I'm working to remove the SfxItemPool serialisation code from
other applications and modules which is now unused due to clipboard format
change.

My progress can be seen at
https://gerrit.libreoffice.org/#/q/project:core+branch:maste
r+topic:gsoc2017-editengine-clipboard

Regards,
Varun Dhall

IRC Nick: varundhall
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2017-08-01 Thread Caolán McNamara
 sc/source/ui/undo/undotab.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit 3fd6c24e3cddf41f88ec6a7405f4848209002adb
Author: Caolán McNamara 
Date:   Tue Aug 1 11:34:22 2017 +0100

Related: tdf#109856 redo 'insert multiple tabs after' inserts too many tabs

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

diff --git a/sc/source/ui/undo/undotab.cxx b/sc/source/ui/undo/undotab.cxx
index 09bcd659431b..b7224b805423 100644
--- a/sc/source/ui/undo/undotab.cxx
+++ b/sc/source/ui/undo/undotab.cxx
@@ -225,7 +225,6 @@ void ScUndoInsertTables::Redo()
 
 pDocShell->SetInUndo( true );   //! BeginRedo
 bDrawIsInUndo = true;
-pViewShell->SetTabNo(nTab);
 pViewShell->InsertTables( aNameList, nTab, 
static_cast(aNameList.size()),false );
 
 bDrawIsInUndo = false;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Caolán McNamara
 sfx2/source/sidebar/ResourceManager.cxx |   52 ++--
 svx/source/tbxctrls/PaletteManager.cxx  |   10 --
 2 files changed, 50 insertions(+), 12 deletions(-)

New commits:
commit 879c1c398ffdd00b7a9e9cc3cbe26e1aa263e00d
Author: Caolán McNamara 
Date:   Tue Aug 1 10:08:58 2017 +0100

Related: tdf#108655 only write to config if values changed

Change-Id: I6ba001745638dc2b8ce091d717915e334ece4b04
Reviewed-on: https://gerrit.libreoffice.org/40623
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sfx2/source/sidebar/ResourceManager.cxx 
b/sfx2/source/sidebar/ResourceManager.cxx
index 83ff5337dd6e..a75aa42c86b6 100644
--- a/sfx2/source/sidebar/ResourceManager.cxx
+++ b/sfx2/source/sidebar/ResourceManager.cxx
@@ -322,11 +322,29 @@ void ResourceManager::SaveDeckSettings(const 
DeckDescriptor* pDeckDesc)
 
 utl::OConfigurationNode aDeckNode 
(aDeckRootNode.openNode(pDeckDesc->msNodeName));
 
-aDeckNode.setNodeValue("Title", makeAny(pDeckDesc->msTitle));
-aDeckNode.setNodeValue("OrderIndex", makeAny(pDeckDesc->mnOrderIndex));
-aDeckNode.setNodeValue("ContextList", makeAny( sContextList ));
+css::uno::Any aTitle(makeAny(pDeckDesc->msTitle));
+css::uno::Any aOrder(makeAny(pDeckDesc->mnOrderIndex));
+css::uno::Any aContextList(makeAny(sContextList));
 
-aDeckRootNode.commit();
+bool bChanged = false;
+if (aTitle != aDeckNode.getNodeValue("Title"))
+{
+aDeckNode.setNodeValue("Title", aTitle);
+bChanged = true;
+}
+if (aOrder != aDeckNode.getNodeValue("OrderIndex"))
+{
+aDeckNode.setNodeValue("OrderIndex", aOrder);
+bChanged = true;
+}
+if (aContextList != aDeckNode.getNodeValue("ContextList"))
+{
+aDeckNode.setNodeValue("ContextList", aContextList);
+bChanged = true;
+}
+
+if (bChanged)
+aDeckRootNode.commit();
 
 // save panel settings
 
@@ -343,6 +361,7 @@ void ResourceManager::SaveDeckSettings(const 
DeckDescriptor* pDeckDesc)
 
 SharedPanelContainer rPanels = pDeckDesc->mpDeck->GetPanels();
 
+bChanged = false;
 for ( SharedPanelContainer::iterator iPanel(rPanels.begin()), 
iEnd(rPanels.end());
   iPanel!=iEnd; ++iPanel)
 {
@@ -354,14 +373,29 @@ void ResourceManager::SaveDeckSettings(const 
DeckDescriptor* pDeckDesc)
 
 utl::OConfigurationNode aPanelNode 
(aPanelRootNode.openNode(xPanelDesc->msNodeName));
 
-aPanelNode.setNodeValue("Title", makeAny(xPanelDesc->msTitle));
-aPanelNode.setNodeValue("OrderIndex", 
makeAny(xPanelDesc->mnOrderIndex));
-aPanelNode.setNodeValue("ContextList", makeAny( sPanelContextList ));
+aTitle <<= xPanelDesc->msTitle;
+aOrder <<= xPanelDesc->mnOrderIndex;
+aContextList <<= sPanelContextList;
 
+if (aTitle != aPanelNode.getNodeValue("Title"))
+{
+aPanelNode.setNodeValue("Title", aTitle);
+bChanged = true;
+}
+if (aOrder != aPanelNode.getNodeValue("OrderIndex"))
+{
+aPanelNode.setNodeValue("OrderIndex", aOrder);
+bChanged = true;
+}
+if (aContextList != aPanelNode.getNodeValue("ContextList"))
+{
+aPanelNode.setNodeValue("ContextList", aContextList);
+bChanged = true;
+}
 }
 
- aPanelRootNode.commit();
-
+if (bChanged)
+aPanelRootNode.commit();
 }
 
 void ResourceManager::ReadPanelList()
diff --git a/svx/source/tbxctrls/PaletteManager.cxx 
b/svx/source/tbxctrls/PaletteManager.cxx
index b9e14521af6e..6e77ff700521 100644
--- a/svx/source/tbxctrls/PaletteManager.cxx
+++ b/svx/source/tbxctrls/PaletteManager.cxx
@@ -206,9 +206,13 @@ void PaletteManager::SetPalette( sal_Int32 nPos )
 }
 }
 }
-std::shared_ptr 
batch(comphelper::ConfigurationChanges::create(m_context));
-officecfg::Office::Common::UserColors::PaletteName::set(GetPaletteName(), 
batch);
-batch->commit();
+OUString 
aPaletteName(officecfg::Office::Common::UserColors::PaletteName::get());
+if (aPaletteName != GetPaletteName())
+{
+std::shared_ptr 
batch(comphelper::ConfigurationChanges::create(m_context));
+
officecfg::Office::Common::UserColors::PaletteName::set(GetPaletteName(), 
batch);
+batch->commit();
+}
 }
 
 sal_Int32 PaletteManager::GetPalette()
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: include/jvmaccess include/test include/vbahelper jvmaccess/source test/source vbahelper/source vcl/inc vcl/opengl vcl/unx xmlsecurity/inc xmlsecurity/source

2017-08-01 Thread Noel Grandin
 include/jvmaccess/virtualmachine.hxx  |2 +-
 include/test/container/xelementaccess.hxx |2 +-
 include/test/screenshot_test.hxx  |2 +-
 include/vbahelper/vbahelper.hxx   |8 
 jvmaccess/source/virtualmachine.cxx   |2 +-
 test/source/screenshot_test.cxx   |2 +-
 vbahelper/source/msforms/vbacontrols.cxx  |2 +-
 vbahelper/source/msforms/vbauserform.cxx  |2 +-
 vbahelper/source/msforms/vbauserform.hxx  |2 +-
 vbahelper/source/vbahelper/vbahelper.cxx  |8 
 vcl/inc/opengl/x11/salvd.hxx  |2 +-
 vcl/inc/unx/salinst.h |2 +-
 vcl/inc/unx/salvd.h   |2 +-
 vcl/opengl/x11/salvd.cxx  |4 ++--
 vcl/unx/generic/gdi/salvd.cxx |6 +++---
 vcl/unx/gtk/fpicker/SalGtkPicker.cxx  |2 +-
 vcl/unx/gtk/fpicker/SalGtkPicker.hxx  |2 +-
 xmlsecurity/inc/certificatechooser.hxx|4 ++--
 xmlsecurity/source/dialogs/certificatechooser.cxx |4 ++--
 19 files changed, 30 insertions(+), 30 deletions(-)

New commits:
commit 871035d72aa0d59b42997056b16d889dd1371ce8
Author: Noel Grandin 
Date:   Tue Aug 1 10:09:18 2017 +0200

loplugin:constparams in various

Change-Id: Id15f3562f42afa6c679cea3c839172557ead0395
Reviewed-on: https://gerrit.libreoffice.org/40624
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/include/jvmaccess/virtualmachine.hxx 
b/include/jvmaccess/virtualmachine.hxx
index df18b5791e40..e7f5e63ec69b 100644
--- a/include/jvmaccess/virtualmachine.hxx
+++ b/include/jvmaccess/virtualmachine.hxx
@@ -125,7 +125,7 @@ public:
 the future).
  */
 VirtualMachine(JavaVM * pVm, int nVersion, bool bDestroy,
-   JNIEnv * pMainThreadEnv);
+   JNIEnv const * pMainThreadEnv);
 
 private:
 VirtualMachine(VirtualMachine &) = delete;
diff --git a/include/test/container/xelementaccess.hxx 
b/include/test/container/xelementaccess.hxx
index 14e7ad159621..d1830ef429ed 100644
--- a/include/test/container/xelementaccess.hxx
+++ b/include/test/container/xelementaccess.hxx
@@ -18,7 +18,7 @@ namespace apitest {
 class XElementAccess
 {
 public:
-XElementAccess(css::uno::Type& rType): maType(rType) {}
+XElementAccess(css::uno::Type const & rType): maType(rType) {}
 
 void testGetElementType();
 void testHasElements();
diff --git a/include/test/screenshot_test.hxx b/include/test/screenshot_test.hxx
index 5f8fbf89f022..c4ffa9a1ca17 100644
--- a/include/test/screenshot_test.hxx
+++ b/include/test/screenshot_test.hxx
@@ -36,7 +36,7 @@ private:
 private:
 /// helpers
 void implSaveScreenshot(const Bitmap& rScreenshot, const OString& 
rScreenshotId);
-void saveScreenshot(VclAbstractDialog& rDialog);
+void saveScreenshot(VclAbstractDialog const & rDialog);
 void saveScreenshot(Dialog& rDialog);
 
 /// helper method to populate maKnownDialogs, called in setUp(). Needs to 
be
diff --git a/include/vbahelper/vbahelper.hxx b/include/vbahelper/vbahelper.hxx
index 525b4237795a..c007257e64c3 100644
--- a/include/vbahelper/vbahelper.hxx
+++ b/include/vbahelper/vbahelper.hxx
@@ -73,7 +73,7 @@ namespace ooo
 
 /** Returns the VBA document implementation object representing the 
passed UNO document model. */
 VBAHELPER_DLLPUBLIC css::uno::Reference< XHelperInterface > 
getVBADocument( const css::uno::Reference< css::frame::XModel >& xModel );
-VBAHELPER_DLLPUBLIC css::uno::Reference< XHelperInterface > 
getUnoDocModule( const OUString& aModName, SfxObjectShell* pShell );
+VBAHELPER_DLLPUBLIC css::uno::Reference< XHelperInterface > 
getUnoDocModule( const OUString& aModName, SfxObjectShell const * pShell );
 /// @throws css::uno::RuntimeException
 VBAHELPER_DLLPUBLIC SfxObjectShell* getSfxObjShell( const 
css::uno::Reference< css::frame::XModel >& xModel );
 
@@ -95,7 +95,7 @@ namespace ooo
 
 VBAHELPER_DLLPUBLIC void dispatchRequests( const css::uno::Reference< 
css::frame::XModel>& xModel, const OUString& aUrl );
 VBAHELPER_DLLPUBLIC void dispatchRequests (const css::uno::Reference< 
css::frame::XModel>& xModel, const OUString & aUrl, const css::uno::Sequence< 
css::beans::PropertyValue >& sProps );
-VBAHELPER_DLLPUBLIC void dispatchExecute(SfxViewShell* pView, 
sal_uInt16 nSlot );
+VBAHELPER_DLLPUBLIC void dispatchExecute(SfxViewShell const * pView, 
sal_uInt16 nSlot );
 VBAHELPER_DLLPUBLIC sal_Int32 OORGBToXLRGB( sal_Int32 );
 VBAHELPER_DLLPUBLIC sal_Int32 XLRGBToOORGB( sal_Int32 );
 VBAHELPER_DLLPUBLIC css::uno::Any OORGBToXLRGB( const css::uno::Any& );
@@ -104,8 +104,8 @@ namespace ooo
 // the object when passed to IsNull will return true. aNULL
 // contains an empty object referen

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

2017-08-01 Thread Caolán McNamara
 sc/source/ui/docshell/tablink.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit d09b943fc4292d47a9d93f6e423cd0eafbd799ae
Author: Caolán McNamara 
Date:   Tue Aug 1 10:18:08 2017 +0100

ofz: survive missing config

Change-Id: I011b6e3259f1567ddbacb22e19b06f7ae5aa63ed

diff --git a/sc/source/ui/docshell/tablink.cxx 
b/sc/source/ui/docshell/tablink.cxx
index 580c8983434d..5c5e3a1f4d32 100644
--- a/sc/source/ui/docshell/tablink.cxx
+++ b/sc/source/ui/docshell/tablink.cxx
@@ -30,6 +30,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include "tablink.hxx"
 
@@ -454,7 +455,7 @@ bool ScDocumentLoader::GetFilterName( const OUString& 
rFileName,
 
 std::shared_ptr pSfxFilter;
 auto pMedium = o3tl::make_unique( rFileName, 
StreamMode::STD_READ );
-if ( pMedium->GetError() == ERRCODE_NONE )
+if (pMedium->GetError() == ERRCODE_NONE && 
!utl::ConfigManager::IsAvoidConfig())
 {
 if ( bWithInteraction )
 pMedium->UseInteractionHandler(true);   // #i73992# no longer 
called from GuessFilter
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Caolán McNamara
 sc/source/core/data/document.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 104aa89163c3ddc0c9ac5324d5c5708c32c06a94
Author: Caolán McNamara 
Date:   Tue Aug 1 09:16:28 2017 +0100

Resolves: tdf#109856 undo 'insert multiple tabs after' doesn't work

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

diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index 55978a93efb2..16e8b49b2a4c 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -786,7 +786,7 @@ void ScDocument::ClearTabs()
 bool ScDocument::DeleteTabs( SCTAB nTab, SCTAB nSheets )
 {
 bool bValid = false;
-if (ValidTab(nTab) && (nTab + nSheets) < static_cast(maTabs.size()))
+if (ValidTab(nTab) && (nTab + nSheets) <= 
static_cast(maTabs.size()))
 {
 if (maTabs[nTab])
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: basic/inc basic/source canvas/source chart2/source compilerplugins/clang connectivity/source cppcanvas/source cui/source dbaccess/source desktop/source drawinglayer/sou

2017-08-01 Thread Noel Grandin
 basic/inc/sbstdobj.hxx 
|   12 -
 basic/source/runtime/stdobj1.cxx   
|   25 +-
 canvas/source/tools/verifyinput.cxx
|9 
 
chart2/source/controller/chartapiwrapper/WrappedAxisAndGridExistenceProperties.cxx
 |2 
 chart2/source/controller/chartapiwrapper/WrappedStatisticProperties.cxx
|3 
 chart2/source/controller/dialogs/tp_Wizard_TitlesAndObjects.cxx
|2 
 chart2/source/controller/inc/MultipleChartConverters.hxx   
|1 
 chart2/source/controller/itemsetwrapper/MultipleChartConverters.cxx
|1 
 chart2/source/controller/itemsetwrapper/RegressionCurveItemConverter.cxx   
|3 
 chart2/source/controller/itemsetwrapper/StatisticsItemConverter.cxx
|3 
 chart2/source/controller/main/ChartController_Insert.cxx   
|5 
 chart2/source/controller/main/ChartController_Properties.cxx   
|2 
 chart2/source/controller/main/ChartController_Tools.cxx
|8 
 chart2/source/controller/sidebar/ChartElementsPanel.cxx
|2 
 chart2/source/controller/sidebar/ChartSeriesPanel.cxx  
|3 
 chart2/source/inc/AxisHelper.hxx   
|6 
 chart2/source/inc/ObjectIdentifier.hxx 
|8 
 chart2/source/inc/RegressionCurveHelper.hxx
|4 
 chart2/source/tools/AxisHelper.cxx 
|8 
 chart2/source/tools/ObjectIdentifier.cxx   
|   26 --
 chart2/source/tools/RegressionCurveHelper.cxx  
|5 
 chart2/source/view/charttypes/PieChart.cxx 
|   11 -
 chart2/source/view/charttypes/PieChart.hxx 
|1 
 compilerplugins/clang/checkunusedparams.cxx
|  105 --
 connectivity/source/drivers/hsqldb/HStorageAccess.cxx  
|   23 +-
 connectivity/source/drivers/hsqldb/StorageNativeInputStream.cxx
|9 
 connectivity/source/drivers/hsqldb/StorageNativeOutputStream.cxx   
|   11 -
 connectivity/source/inc/hsqldb/HStorageAccess.hxx  
|8 
 cppcanvas/source/mtfrenderer/textaction.cxx
|5 
 cui/source/inc/swpossizetabpage.hxx
|4 
 cui/source/tabpages/swpossizetabpage.cxx   
|   32 +--
 dbaccess/source/core/dataaccess/ContentHelper.cxx  
|4 
 dbaccess/source/core/inc/ContentHelper.hxx 
|3 
 dbaccess/source/ui/browser/genericcontroller.cxx   
|   16 -
 desktop/source/lib/init.cxx
|6 
 desktop/source/lib/lokinteractionhandler.cxx   
|1 
 desktop/source/lib/lokinteractionhandler.hxx   
|1 
 drawinglayer/source/primitive3d/polygontubeprimitive3d.cxx 
|2 
 editeng/source/editeng/impedit2.cxx
|6 
 filter/source/msfilter/svdfppt.cxx 
|4 
 filter/source/svg/impsvgdialog.cxx 
|   32 +--
 filter/source/svg/parserfragments.cxx  
|8 
 filter/source/svg/svgreader.cxx
|   34 ---
 framework/inc/dispatch/mailtodispatcher.hxx
|3 
 framework/inc/dispatch/servicehandler.hxx  
|3 
 framework/source/dispatch/mailtodispatcher.cxx 
|   13 -
 framework/source/dispatch/servicehandler.cxx   
|   13 -
 hwpfilter/source/drawing.h 
|   48 ++--
 include/canvas/verifyinput.hxx 
|   21 --
 include/oox/ole/axcontrol.hxx  
|4 
 include/oox/ppt/timenodelistcontext.hxx
|2 
 include/svtools/brwbox.hxx 
|1 
 include/svtools/htmlout.hxx
|6 
 include/svx/ruler.hxx  

[Libreoffice-commits] core.git: writerperfect/inc

2017-08-01 Thread Miklos Vajna
 writerperfect/inc/WPFTResMgr.hxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 17e14d459dea201b57be2d8e677fa776ead03291
Author: Miklos Vajna 
Date:   Tue Aug 1 10:47:42 2017 +0200

writerprefect: run astyle

So that whitespace and (later) functional changes are in separate
commits -- and writerperfect/README asks to run astyle before
committing.

Change-Id: I771ad70932ed8bb3254a230562ea40440e2d4be7

diff --git a/writerperfect/inc/WPFTResMgr.hxx b/writerperfect/inc/WPFTResMgr.hxx
index ccc75246b102..4b7bbf3e2a19 100644
--- a/writerperfect/inc/WPFTResMgr.hxx
+++ b/writerperfect/inc/WPFTResMgr.hxx
@@ -9,10 +9,10 @@
 
 struct WRITERPERFECT_DLLPUBLIC WPFTResLocale
 {
-static std::locale& GetResLocale();
+static std::locale &GetResLocale();
 };
 
-inline OUString WpResId(const char* pId)
+inline OUString WpResId(const char *pId)
 {
 return Translate::get(pId, WPFTResLocale::GetResLocale());
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2017-08-01 Thread Tor Lillqvist
 sc/inc/dociter.hxx   |4 ++--
 sc/source/core/tool/interpr1.cxx |2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 0267612dfb997032a870ae5c06171008c3af98d4
Author: Tor Lillqvist 
Date:   Mon Jul 31 21:03:00 2017 +0300

Bin default value for a bool parameter that was defaulted in only one place

Change-Id: Ie5d4339639a034c4be991c9302576a116866b085

diff --git a/sc/inc/dociter.hxx b/sc/inc/dociter.hxx
index 0cfda4c72440..2bbb90f31edd 100644
--- a/sc/inc/dociter.hxx
+++ b/sc/inc/dociter.hxx
@@ -293,8 +293,8 @@ class ScQueryCellIterator   // walk through all 
non-empty cells in an ar
 
 public:
 ScQueryCellIterator(ScDocument* pDocument, SCTAB nTable,
-const ScQueryParam& aParam, bool bMod 
= true);
-// for bMod = FALSE the QueryParam has 
to be filled
+const ScQueryParam& aParam, bool bMod);
+// when !bMod, the QueryParam has to 
be filled
 // (bIsString)
 bool GetFirst();
 bool GetNext();
diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx
index 5457403cad39..d0cf16fd3cb1 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -7533,7 +7533,7 @@ void ScInterpreter::ScDBCount()
 // so the source range has to be restricted, like before the 
introduction
 // of ScDBQueryParamBase.
 p->nCol1 = p->nCol2 = p->mnField;
-ScQueryCellIterator aCellIter( pDok, nTab, *p);
+ScQueryCellIterator aCellIter( pDok, nTab, *p, true);
 if ( aCellIter.GetFirst() )
 {
 do
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: LibreOffice Error during make command

2017-08-01 Thread Kaganski Mike
On 7/31/2017 11:08 AM, Miklos Vajna wrote:
> Hi,
> 
> On Fri, Jul 21, 2017 at 09:24:04PM -0700, sherlock  
> wrote:
>> As It mentioned in the tutorial(
>> https://wiki.documentfoundation.org/Development/BuildingForAndroid ), I
>> downloaded latest version via this command( git clone
>> git://anongit.freedesktop.org/libreoffice/core libreoffice ). If I should
>> use special commit how can I download it?
> 
> No, latest master is supposed to build.

I suppose that OP wanted to know how to switch to a specific commit of 
his liking, rather than if he needs some specific commit to build.

If my understanding is right, then you should use usual git clone (as 
you mentioned), and then use git checkout  to switch to a 
specific commit (if you have some good reason to use headless state).


-- 
Best regards,
Mike Kaganski
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: desktop/source lotuswordpro/source

2017-08-01 Thread Noel Grandin
 desktop/source/app/dispatchwatcher.cxx |2 -
 desktop/source/lib/init.cxx|2 -
 lotuswordpro/source/filter/bencont.cxx |2 -
 lotuswordpro/source/filter/bento.hxx   |6 ++--
 lotuswordpro/source/filter/lwpbulletstylemgr.cxx   |2 -
 lotuswordpro/source/filter/lwpbulletstylemgr.hxx   |2 -
 lotuswordpro/source/filter/lwpcelllayout.cxx   |8 +++---
 lotuswordpro/source/filter/lwpcelllayout.hxx   |8 +++---
 lotuswordpro/source/filter/lwpcharacterstyle.cxx   |4 +--
 lotuswordpro/source/filter/lwpcharacterstyle.hxx   |4 +--
 lotuswordpro/source/filter/lwpcontent.cxx  |6 ++--
 lotuswordpro/source/filter/lwpcontent.hxx  |6 ++--
 lotuswordpro/source/filter/lwpdivinfo.cxx  |2 -
 lotuswordpro/source/filter/lwpdivinfo.hxx  |2 -
 lotuswordpro/source/filter/lwpdivopts.cxx  |2 -
 lotuswordpro/source/filter/lwpdivopts.hxx  |2 -
 lotuswordpro/source/filter/lwpdlvlist.cxx  |6 ++--
 lotuswordpro/source/filter/lwpdlvlist.hxx  |6 ++--
 lotuswordpro/source/filter/lwpdoc.cxx  |4 +--
 lotuswordpro/source/filter/lwpdoc.hxx  |4 +--
 lotuswordpro/source/filter/lwpdocdata.cxx  |2 -
 lotuswordpro/source/filter/lwpdocdata.hxx  |2 -
 lotuswordpro/source/filter/lwpfilter.cxx   |2 -
 lotuswordpro/source/filter/lwpfilter.hxx   |2 -
 lotuswordpro/source/filter/lwpfnlayout.cxx |   16 ++--
 lotuswordpro/source/filter/lwpfnlayout.hxx |   16 ++--
 lotuswordpro/source/filter/lwpfootnote.cxx |6 ++--
 lotuswordpro/source/filter/lwpfootnote.hxx |6 ++--
 lotuswordpro/source/filter/lwpframelayout.cxx  |   10 +++
 lotuswordpro/source/filter/lwpframelayout.hxx  |   10 +++
 lotuswordpro/source/filter/lwpfribptr.cxx  |2 -
 lotuswordpro/source/filter/lwpfribptr.hxx  |2 -
 lotuswordpro/source/filter/lwpgrfobj.cxx   |4 +--
 lotuswordpro/source/filter/lwpgrfobj.hxx   |4 +--
 lotuswordpro/source/filter/lwpholder.cxx   |8 +++---
 lotuswordpro/source/filter/lwpholder.hxx   |8 +++---
 lotuswordpro/source/filter/lwplayout.cxx   |   12 -
 lotuswordpro/source/filter/lwplayout.hxx   |   12 -
 lotuswordpro/source/filter/lwplaypiece.cxx |   22 -
 lotuswordpro/source/filter/lwplaypiece.hxx |   22 -
 lotuswordpro/source/filter/lwpmarker.cxx   |   12 -
 lotuswordpro/source/filter/lwpmarker.hxx   |   12 -
 lotuswordpro/source/filter/lwpnotes.cxx|8 +++---
 lotuswordpro/source/filter/lwpnotes.hxx|8 +++---
 lotuswordpro/source/filter/lwpnumericfmt.hxx   |2 -
 lotuswordpro/source/filter/lwpobjid.cxx|2 -
 lotuswordpro/source/filter/lwpobjid.hxx|2 -
 lotuswordpro/source/filter/lwpoleobject.cxx|4 +--
 lotuswordpro/source/filter/lwpoleobject.hxx|4 +--
 lotuswordpro/source/filter/lwppagehint.cxx |2 -
 lotuswordpro/source/filter/lwppagehint.hxx |2 -
 lotuswordpro/source/filter/lwppagelayout.cxx   |8 +++---
 lotuswordpro/source/filter/lwppagelayout.hxx   |8 +++---
 lotuswordpro/source/filter/lwppara.cxx |4 +--
 lotuswordpro/source/filter/lwppara.hxx |   10 +++
 lotuswordpro/source/filter/lwppara1.cxx|8 +++---
 lotuswordpro/source/filter/lwpparaborderoverride.cxx   |8 +++---
 lotuswordpro/source/filter/lwpparaborderoverride.hxx   |8 +++---
 lotuswordpro/source/filter/lwpparastyle.cxx|2 -
 lotuswordpro/source/filter/lwpparastyle.hxx|2 -
 lotuswordpro/source/filter/lwppiece.hxx|   22 -
 lotuswordpro/source/filter/lwpproplist.cxx |2 -
 lotuswordpro/source/filter/lwpproplist.hxx |2 -
 lotuswordpro/source/filter/lwprowlayout.cxx|4 +--
 lotuswordpro/source/filter/lwprowlayout.hxx|4 +--
 lotuswordpro/source/filter/lwpsection.cxx  |6 ++--
 lotuswordpro/source/filter/lwpsection.hxx  |6 ++--
 lotuswordpro/source/filter/lwpsilverbullet.cxx |4 +--
 lotuswordpro/source/filter/lwpsilverbullet.hxx |6 +---
 lotuswordpro/source/filter/lwpstory.cxx|2 -
 lotuswordpro/source/filter/lwpstory.hxx|2 -
 lotuswordpro/source/filter/lwptable.cxx|   10 +++
 lotuswordpro/source/filter/lwptable.hxx|   10 +++
 lotuswordpro

[Libreoffice-commits] core.git: Branch 'feature/lok_dialog' - 3 commits - include/vcl libreofficekit/qa libreofficekit/source sw/source vcl/source

2017-08-01 Thread Pranav Kant
 include/vcl/dialog.hxx  |3 
 libreofficekit/qa/gtktiledviewer/gtv-lok-dialog.cxx |  126 +++-
 libreofficekit/source/gtk/lokdocview.cxx|   41 +-
 sw/source/uibase/uno/unotxdoc.cxx   |   31 
 vcl/source/window/dialog.cxx|   16 ++
 5 files changed, 182 insertions(+), 35 deletions(-)

New commits:
commit 1fdc2503344a7aeea7f351e7899b5155ffc4e101
Author: Pranav Kant 
Date:   Sun Jul 30 06:06:56 2017 +0530

lokdialog: Handle key events in core

Change-Id: If84aaac87beebf69d92db5446fc713d8cc20421e

diff --git a/include/vcl/dialog.hxx b/include/vcl/dialog.hxx
index fb0e0751ddc8..f0425a961cf3 100644
--- a/include/vcl/dialog.hxx
+++ b/include/vcl/dialog.hxx
@@ -74,6 +74,9 @@ public:
 void LogicMouseButtonUp(const MouseEvent& rMouseEvent);
 void LogicMouseMove(const MouseEvent& rMouseEvent);
 
+void KeyInput(const KeyEvent& rKeyEvent);
+void KeyUp(const KeyEvent& rKeyEvent);
+
 protected:
 explicitDialog( WindowType nType );
 explicitDialog( vcl::Window* pParent, const OUString& rID, const 
OUString& rUIXMLDescription, WindowType nType, InitFlag eFlag = 
InitFlag::Default );
diff --git a/sw/source/uibase/uno/unotxdoc.cxx 
b/sw/source/uibase/uno/unotxdoc.cxx
index 095ba9fee5f6..3be26d0f28b6 100644
--- a/sw/source/uibase/uno/unotxdoc.cxx
+++ b/sw/source/uibase/uno/unotxdoc.cxx
@@ -3581,9 +3581,38 @@ void SwXTextDocument::paintDialog(const vcl::DialogID& 
rDialogID, VirtualDevice&
 nHeight = aSize.getHeight();
 }
 
-void SwXTextDocument::postDialogKeyEvent(const vcl::DialogID& /*rDialogID*/, 
int /*nType*/, int /*nCharCode*/, int /*nKeyCode*/)
+void SwXTextDocument::postDialogKeyEvent(const vcl::DialogID& rDialogID, int 
nType, int nCharCode, int nKeyCode)
 {
+SolarMutexGuard aGuard;
+
+// check if dialog is already open
+SfxViewFrame* pViewFrame = pDocShell->GetView()->GetViewFrame();
+SfxSlotPool* pSlotPool = SW_MOD()->GetSlotPool();
+const SfxSlot* pSlot = pSlotPool->GetUnoSlot(rDialogID);
+if (!pSlot)
+{
+SAL_WARN("lok.dialog", "No slot found for " << rDialogID);
+return;
+}
+SfxChildWindow* pChild = pViewFrame->GetChildWindow(pSlot->GetSlotId());
+if (pChild)
+{
+Dialog* pDialog = static_cast(pChild->GetWindow());
+KeyEvent aEvent(nCharCode, nKeyCode, 0);
 
+switch (nType)
+{
+case LOK_KEYEVENT_KEYINPUT:
+pDialog->KeyInput(aEvent);
+break;
+case LOK_KEYEVENT_KEYUP:
+pDialog->KeyUp(aEvent);
+break;
+default:
+assert(false);
+break;
+}
+}
 }
 
 void SwXTextDocument::postDialogMouseEvent(const vcl::DialogID& rDialogID, int 
nType, int nX, int nY,
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx
index ee606eae351e..897bc8f74543 100644
--- a/vcl/source/window/dialog.cxx
+++ b/vcl/source/window/dialog.cxx
@@ -888,6 +888,22 @@ void Dialog::LogicMouseMove(const MouseEvent& rMouseEvent)
 ImplWindowFrameProc(this, SalEvent::ExternalMouseMove, &rMouseEvent);
 }
 
+void Dialog::KeyInput(const KeyEvent& rKeyEvent)
+{
+// as of now only lok uses it
+assert(comphelper::LibreOfficeKit::isActive());
+
+ImplWindowFrameProc(this, SalEvent::ExternalKeyInput, &rKeyEvent);
+}
+
+void Dialog::KeyUp(const KeyEvent& rKeyEvent)
+{
+// as of now only lok uses it
+assert(comphelper::LibreOfficeKit::isActive());
+
+ImplWindowFrameProc(this, SalEvent::ExternalKeyUp, &rKeyEvent);
+}
+
 void Dialog::ensureRepaint()
 {
 // ensure repaint
commit bee77206ff3ff7138b957a411d8f35ad5ffbdf8d
Author: Pranav Kant 
Date:   Sun Jul 30 05:18:33 2017 +0530

lokdialog: gtv: Forward key events on dialog to core

Change-Id: Icfc210b08c7f1d8ebaf9c731ed64bb128cfc4356

diff --git a/libreofficekit/qa/gtktiledviewer/gtv-lok-dialog.cxx 
b/libreofficekit/qa/gtktiledviewer/gtv-lok-dialog.cxx
index 7a9fa7712900..bb8800e3d734 100644
--- a/libreofficekit/qa/gtktiledviewer/gtv-lok-dialog.cxx
+++ b/libreofficekit/qa/gtktiledviewer/gtv-lok-dialog.cxx
@@ -8,9 +8,11 @@
  */
 
 #include 
+#include 
 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -136,7 +138,7 @@ gtv_lok_dialog_signal_button(GtkWidget* pDialogDrawingArea, 
GdkEventButton* pEve
 (pEvent->y),
 nCount,
 nEventButton,
-0/* Modifier */);
+priv->m_nKeyModifier);
 
 break;
 }
@@ -167,7 +169,7 @@ gtv_lok_dialog_signal_button(GtkWidget* pDialogDrawingArea, 
GdkEventButton* pEve
 (pEvent->y),
 nCount,

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

2017-08-01 Thread Miklos Vajna
 sw/qa/extras/rtfexport/data/tdf109790.rtf|   16 
 sw/qa/extras/rtfexport/rtfexport.cxx |8 
 writerfilter/source/rtftok/rtfdispatchflag.cxx   |   10 +-
 writerfilter/source/rtftok/rtfdispatchsymbol.cxx |4 
 writerfilter/source/rtftok/rtfdocumentimpl.cxx   |3 ++-
 writerfilter/source/rtftok/rtfdocumentimpl.hxx   |3 +++
 6 files changed, 42 insertions(+), 2 deletions(-)

New commits:
commit aaa6a5202a447fb4e86d5f016d8e79fbc34a3ed7
Author: Miklos Vajna 
Date:   Mon Jul 31 22:43:51 2017 +0200

tdf#109790 RTF import: keep remembering paragraph style between \cell and 
\row

This is the opposite situation as tdf#44715, where the problem was that
style was not reset between in-cell paragraphs.

Here we don't want to reset the paragraph style too early, so that
direct (character) formatting isn't lost just because the theoretical
end-of-row character would not have the same direct formatting.

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

diff --git a/sw/qa/extras/rtfexport/data/tdf109790.rtf 
b/sw/qa/extras/rtfexport/data/tdf109790.rtf
new file mode 100644
index ..c25c11622812
--- /dev/null
+++ b/sw/qa/extras/rtfexport/data/tdf109790.rtf
@@ -0,0 +1,16 @@
+{\rtf1\adeflang1037\ansi\ansicpg1252\uc1\adeff0\deff0
+\noqfpromote
+{\stylesheet
+{\ql \li0\ri0\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \rtlch\fcs1 
\afs20\alang1037 \ltrch\fcs0
+\fs20\lang1033\langfe1033\loch\f0\hich\dbch\cgrid\langnp1033\langfenp1033 
\snext0 \sqformat \spriority0 Normal;}
+{\s26\fs44 \sbasedon0 \snext26 \slink27 \sqformat Subtitle;}
+}
+\paperw12240\paperh15840
+\pard\plain Start.\par
+\trowd\cellx2310\pard\plain\s26\intbl
+{\fs20 }
+{\fs20 \cell }
+\pard
+{\row }
+\pard\plain End.\par
+}
diff --git a/sw/qa/extras/rtfexport/rtfexport.cxx 
b/sw/qa/extras/rtfexport/rtfexport.cxx
index 9f75068be62f..9f3b558e5bdb 100644
--- a/sw/qa/extras/rtfexport/rtfexport.cxx
+++ b/sw/qa/extras/rtfexport/rtfexport.cxx
@@ -1231,6 +1231,14 @@ DECLARE_RTFEXPORT_TEST(testWatermark, "watermark.rtf")
 CPPUNIT_ASSERT_EQUAL((float)66, nFontSize);
 }
 
+DECLARE_RTFEXPORT_TEST(testTdf109790, "tdf109790.rtf")
+{
+uno::Reference xTable(getParagraphOrTable(2), 
uno::UNO_QUERY);
+uno::Reference xCell(xTable->getCellByName("A1"), 
uno::UNO_QUERY);
+// Style information was reset, which caused character height to be 22.
+CPPUNIT_ASSERT_EQUAL(10.f, getProperty(getRun(getParagraphOfText(1, 
xCell->getText()), 1), "CharHeight"));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/writerfilter/source/rtftok/rtfdispatchflag.cxx 
b/writerfilter/source/rtftok/rtfdispatchflag.cxx
index 93d5eeb8f6a7..5f512b94df77 100644
--- a/writerfilter/source/rtftok/rtfdispatchflag.cxx
+++ b/writerfilter/source/rtftok/rtfdispatchflag.cxx
@@ -461,9 +461,12 @@ RTFError RTFDocumentImpl::dispatchFlag(RTFKeyword nKeyword)
 }
 break;
 case RTF_PARD:
+{
 if (m_bHadPicture)
 dispatchSymbol(RTF_PAR);
 // \pard is allowed between \cell and \row, but in that case it should 
not reset the fact that we're inside a table.
+// It should not reset the paragraph style, either, so remember the 
old paragraph style.
+RTFValue::Pointer_t pOldStyle = 
m_aStates.top().aParagraphSprms.find(NS_ooxml::LN_CT_PPrBase_pStyle);
 m_aStates.top().aParagraphSprms = m_aDefaultState.aParagraphSprms;
 m_aStates.top().aParagraphAttributes = 
m_aDefaultState.aParagraphAttributes;
 
@@ -476,13 +479,17 @@ RTFError RTFDocumentImpl::dispatchFlag(RTFKeyword 
nKeyword)
 {
 // We are still in a table.
 m_aStates.top().aParagraphSprms.set(NS_ooxml::LN_inTbl, 
std::make_shared(1));
+if (m_bAfterCellBeforeRow && pOldStyle)
+// And we still have the same paragraph style.
+
m_aStates.top().aParagraphSprms.set(NS_ooxml::LN_CT_PPrBase_pStyle, pOldStyle);
 // Ideally getDefaultSPRM() would take care of this, but it would 
not when we're buffering.
 m_aStates.top().aParagraphSprms.set(NS_ooxml::LN_CT_PPrBase_tabs, 
std::make_shared());
 }
 resetFrame();
 
-// Reset currently selected paragraph style as well.
+// Reset currently selected paragraph style as well, unless we are in 
the special "after \cell, before \row" state.
 // By default the style with index 0 is applied.
+if (!m_bAfterCellBeforeRow)
 {
 OUString const aName = getStyleName(0);
 // But only in case it's not a character style.
@@ -499,6 +506,7 @@ RTFError RTFDocumentImpl::dispatchFlag(RTFKeyword nKeyword)
 // Need to send paragraph properties again, if there will be any.
 m_bNeedPap = true;
 

[Libreoffice-commits] core.git: bin/get-bugzilla-attachments-by-mimetype

2017-08-01 Thread Aron Budea
 bin/get-bugzilla-attachments-by-mimetype |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit d99cc336d8476975a9fd7adf01b4b9f9cd917aaa
Author: Aron Budea 
Date:   Tue Aug 1 09:09:36 2017 +0200

get-bugzilla-attachments: fix typo, ppotx -> potx

Change-Id: I9ac25784cf772b0056936127ddd91d39264489ea
Reviewed-on: https://gerrit.libreoffice.org/40614
Reviewed-by: Julien Nabet 
Tested-by: Julien Nabet 

diff --git a/bin/get-bugzilla-attachments-by-mimetype 
b/bin/get-bugzilla-attachments-by-mimetype
index 93bd5a7f503f..4c384de7fc07 100755
--- a/bin/get-bugzilla-attachments-by-mimetype
+++ b/bin/get-bugzilla-attachments-by-mimetype
@@ -418,7 +418,7 @@ mimetypes = {
 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet': 
'xlsx',
 'application/vnd.openxmlformats-officedocument.spreadsheetml.template': 
'xltx',
 
'application/vnd.openxmlformats-officedocument.presentationml.presentation': 
'pptx',
-'application/vnd.openxmlformats-officedocument.presentationml.template': 
'ppotx',
+'application/vnd.openxmlformats-officedocument.presentationml.template': 
'potx',
 'application/vnd.openxmlformats-officedocument.presentationml.slideshow': 
'ppsx',
 'application/vnd.openxmlformats-officedocument.presentationml.slide': 
'sldx',
 'application/vnd.openxmlformats-officedocument.wordprocessingml.document': 
'docx',
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits