[Libreoffice-commits] core.git: 2 commits - cui/source editeng/source external/python3 include/svl include/svtools svtools/source
Andras Timar
andras.timar at collabora.com
Mon Jun 8 06:44:27 PDT 2015
cui/source/tabpages/chardlg.cxx | 2 +-
editeng/source/items/textitem.cxx | 4 ++--
external/python3/UnpackedTarball_python3.mk | 1 +
external/python3/python-3.3.5-darwin-gnu-xargs.patch.1 | 12 ++++++++++++
include/svl/poolitem.hxx | 6 ------
include/svtools/unitconv.hxx | 4 ++--
svtools/source/misc/unitconv.cxx | 14 +++++++-------
7 files changed, 25 insertions(+), 18 deletions(-)
New commits:
commit 7f4230675c6c78ebea8b6db3f3612e3ef6fb23df
Author: Andras Timar <andras.timar at collabora.com>
Date: Mon Jun 8 13:50:37 2015 +0200
tdf#90804 remove SfxFieldUnit enum
b78d881520f2eb658180e2c90ffee3d30a80f0ae removed unused values
from SfxFieldUnit enum. This broke the mapping between SfxFieldUnit
and FieldUnit. In fact SfxFieldUnit was redundant.
Change-Id: I13c7e7d708c6eeab0de192f4cd110b0a23989a31
Reviewed-on: https://gerrit.libreoffice.org/16150
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Andras Timar <andras.timar at collabora.com>
diff --git a/cui/source/tabpages/chardlg.cxx b/cui/source/tabpages/chardlg.cxx
index 8cb2b46..2b48fde 100644
--- a/cui/source/tabpages/chardlg.cxx
+++ b/cui/source/tabpages/chardlg.cxx
@@ -520,7 +520,7 @@ namespace
// conversion twips for the example-window
aSize.Height() =
- ItemToControl( nHeight, _pPage->GetItemSet().GetPool()->GetMetric( _nFontHeightWhich ), SFX_FUNIT_TWIP );
+ ItemToControl( nHeight, _pPage->GetItemSet().GetPool()->GetMetric( _nFontHeightWhich ), FUNIT_TWIP );
}
else if ( !_pFontSizeLB->GetText().isEmpty() )
aSize.Height() = PointToTwips( static_cast<long>(_pFontSizeLB->GetValue() / 10) );
diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx
index 337d714..fa29b6a 100644
--- a/editeng/source/items/textitem.cxx
+++ b/editeng/source/items/textitem.cxx
@@ -1099,7 +1099,7 @@ void SvxFontHeightItem::SetHeight( sal_uInt32 nNewHeight, const sal_uInt16 nNewP
if( SFX_MAPUNIT_RELATIVE != eUnit )
nHeight = nNewHeight + ::ItemToControl( (short)nNewProp, eUnit,
- SFX_FUNIT_TWIP );
+ FUNIT_TWIP );
else if( 100 != nNewProp )
nHeight = sal_uInt32(( nNewHeight * nNewProp ) / 100 );
else
@@ -1117,7 +1117,7 @@ void SvxFontHeightItem::SetHeight( sal_uInt32 nNewHeight, sal_uInt16 nNewProp,
if( SFX_MAPUNIT_RELATIVE != eMetric )
nHeight = nNewHeight +
::ControlToItem( ::ItemToControl((short)nNewProp, eMetric,
- SFX_FUNIT_TWIP ), SFX_FUNIT_TWIP,
+ FUNIT_TWIP ), FUNIT_TWIP,
eCoreMetric );
else if( 100 != nNewProp )
nHeight = sal_uInt32(( nNewHeight * nNewProp ) / 100 );
diff --git a/include/svl/poolitem.hxx b/include/svl/poolitem.hxx
index 4cd3c88..518c875 100644
--- a/include/svl/poolitem.hxx
+++ b/include/svl/poolitem.hxx
@@ -80,12 +80,6 @@ inline ::com::sun::star::uno::Any Bool2Any( bool bValue )
return ::com::sun::star::uno::Any( &bValue, cppu::UnoType<bool>::get() );
}
-
-enum SfxFieldUnit
-{
- SFX_FUNIT_NONE, SFX_FUNIT_TWIP
-};
-
enum SfxMapUnit
{
SFX_MAPUNIT_100TH_MM,
diff --git a/include/svtools/unitconv.hxx b/include/svtools/unitconv.hxx
index e95bb90..33fb8dd 100644
--- a/include/svtools/unitconv.hxx
+++ b/include/svtools/unitconv.hxx
@@ -37,8 +37,8 @@ SVT_DLLPUBLIC void SetFieldUnit( MetricBox& rCtrl, FieldUnit eUnit, bool bA
SVT_DLLPUBLIC long CalcToUnit( float nIn, SfxMapUnit eUnit );
SVT_DLLPUBLIC long CalcToPoint( long nIn, SfxMapUnit eUnit, sal_uInt16 nFactor );
-SVT_DLLPUBLIC long ItemToControl( long nIn, SfxMapUnit eItem, SfxFieldUnit eCtrl );
-SVT_DLLPUBLIC long ControlToItem( long nIn, SfxFieldUnit eCtrl, SfxMapUnit eItem );
+SVT_DLLPUBLIC long ItemToControl( long nIn, SfxMapUnit eItem, FieldUnit eCtrl );
+SVT_DLLPUBLIC long ControlToItem( long nIn, FieldUnit eCtrl, SfxMapUnit eItem );
SVT_DLLPUBLIC FieldUnit MapToFieldUnit( const SfxMapUnit eUnit );
diff --git a/svtools/source/misc/unitconv.cxx b/svtools/source/misc/unitconv.cxx
index f9b3a88..190cb0f 100644
--- a/svtools/source/misc/unitconv.cxx
+++ b/svtools/source/misc/unitconv.cxx
@@ -185,7 +185,7 @@ long CalcToUnit( float nIn, SfxMapUnit eUnit )
-long ItemToControl( long nIn, SfxMapUnit eItem, SfxFieldUnit eCtrl )
+long ItemToControl( long nIn, SfxMapUnit eItem, FieldUnit eCtrl )
{
long nOut = 0;
@@ -199,13 +199,13 @@ long ItemToControl( long nIn, SfxMapUnit eItem, SfxFieldUnit eCtrl )
nIn /= 10;
else if ( eItem == SFX_MAPUNIT_100TH_MM )
nIn /= 100;
- nOut = TransformMetric( nIn, FUNIT_MM, (FieldUnit)eCtrl );
+ nOut = TransformMetric( nIn, FUNIT_MM, eCtrl );
}
break;
case SFX_MAPUNIT_CM:
{
- nOut = TransformMetric( nIn, FUNIT_CM, (FieldUnit)eCtrl );
+ nOut = TransformMetric( nIn, FUNIT_CM, eCtrl );
}
break;
@@ -220,19 +220,19 @@ long ItemToControl( long nIn, SfxMapUnit eItem, SfxFieldUnit eCtrl )
nIn /= 100;
else if ( eItem == SFX_MAPUNIT_1000TH_INCH )
nIn /= 1000;
- nOut = TransformMetric( nIn, FUNIT_INCH, (FieldUnit)eCtrl );
+ nOut = TransformMetric( nIn, FUNIT_INCH, eCtrl );
}
break;
case SFX_MAPUNIT_POINT:
{
- nOut = TransformMetric( nIn, FUNIT_POINT, (FieldUnit)eCtrl );
+ nOut = TransformMetric( nIn, FUNIT_POINT, eCtrl );
}
break;
case SFX_MAPUNIT_TWIP:
{
- nOut = TransformMetric( nIn, FUNIT_TWIP, (FieldUnit)eCtrl );
+ nOut = TransformMetric( nIn, FUNIT_TWIP, eCtrl );
}
break;
default: ;//prevent warning
@@ -242,7 +242,7 @@ long ItemToControl( long nIn, SfxMapUnit eItem, SfxFieldUnit eCtrl )
-long ControlToItem( long nIn, SfxFieldUnit eCtrl, SfxMapUnit eItem )
+long ControlToItem( long nIn, FieldUnit eCtrl, SfxMapUnit eItem )
{
return ItemToControl( nIn, eItem, eCtrl );
}
commit ca96e9a8c20b9fc60bf82e6f510e5469de01103a
Author: Khaled Hosny <khaledhosny at eglug.org>
Date: Sat Jun 6 08:39:12 2015 +0300
Allow building Python on Mac with GNU xargs
GNU xargs executes the command at least once even if the standard input
is empty, unlike BSD xargs, which causes rm -r to be called with no
arguments ween the find command finds nothing leading to an error.
Adding -f to rm allows buikding with either implementation.
Change-Id: I0df5fcb379d2a5a8b1121594ec1a82d917d80dfc
Reviewed-on: https://gerrit.libreoffice.org/16116
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: David Tardon <dtardon at redhat.com>
diff --git a/external/python3/UnpackedTarball_python3.mk b/external/python3/UnpackedTarball_python3.mk
index 8c5b1b7..b091bfc 100644
--- a/external/python3/UnpackedTarball_python3.mk
+++ b/external/python3/UnpackedTarball_python3.mk
@@ -31,6 +31,7 @@ $(eval $(call gb_UnpackedTarball_add_patches,python3,\
external/python3/python-3.3.3-msvc2012-winxp.patch.1 \
external/python3/python-3.3.5-pyexpat-symbols.patch.1 \
external/python3/python-3.3.5-vs2013.patch.1 \
+ external/python3/python-3.3.5-darwin-gnu-xargs.patch.1 \
external/python3/python-msvc-disable-sse2.patch.1 \
external/python3/python-lsan.patch.0 \
external/python3/ubsan.patch.0 \
diff --git a/external/python3/python-3.3.5-darwin-gnu-xargs.patch.1 b/external/python3/python-3.3.5-darwin-gnu-xargs.patch.1
new file mode 100644
index 0000000..d955618
--- /dev/null
+++ b/external/python3/python-3.3.5-darwin-gnu-xargs.patch.1
@@ -0,0 +1,12 @@
+diff -ur python3.org/Mac/PythonLauncher/Makefile.in python3/Mac/PythonLauncher/Makefile.in
+--- python3.org/Mac/PythonLauncher/Makefile.in 2015-06-06 08:47:38.000000000 +0300
++++ python3/Mac/PythonLauncher/Makefile.in 2015-06-06 08:48:18.000000000 +0300
+@@ -53,7 +53,7 @@
+ --resource=$(srcdir)/factorySettings.plist \
+ --plist Info.plist \
+ build
+- find "Python Launcher.app" -name '.svn' -print0 | xargs -0 rm -r
++ find "Python Launcher.app" -name '.svn' -print0 | xargs -0 rm -rf
+
+
+ FileSettings.o: $(srcdir)/FileSettings.m
More information about the Libreoffice-commits
mailing list