summaryrefslogtreecommitdiff
path: root/extensions/source/propctrlr
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2017-10-26 23:15:06 +0200
committerMichael Stahl <mstahl@redhat.com>2017-10-26 23:17:45 +0200
commit11d2f3d6e1b6c9baf43d8521293c53525108436d (patch)
treeffe35d5d47713a11c93c3bf11f588eeaf492fc16 /extensions/source/propctrlr
parent213f7c02d4f3ddbe2f52950575e2559c52d98ac2 (diff)
vcl: make MapMode constructor explicit
Insert constructor everywhere, except a couple places that apparently want to compare GetMapUnit(). Change-Id: I1910deb60562e5e949203435e827057f70a3f988
Diffstat (limited to 'extensions/source/propctrlr')
-rw-r--r--extensions/source/propctrlr/browserline.cxx2
-rw-r--r--extensions/source/propctrlr/browserlistbox.cxx4
-rw-r--r--extensions/source/propctrlr/fontdialog.cxx4
-rw-r--r--extensions/source/propctrlr/inspectorhelpwindow.cxx8
-rw-r--r--extensions/source/propctrlr/listselectiondlg.cxx2
5 files changed, 10 insertions, 10 deletions
diff --git a/extensions/source/propctrlr/browserline.cxx b/extensions/source/propctrlr/browserline.cxx
index e345381733e9..67b9d6801dda 100644
--- a/extensions/source/propctrlr/browserline.cxx
+++ b/extensions/source/propctrlr/browserline.cxx
@@ -209,7 +209,7 @@ namespace pcr
if ( m_bIndentTitle )
{
- Size aIndent( m_pTheParent->LogicToPixel( Size( 8, 0 ), MapUnit::MapAppFont ) );
+ Size aIndent( m_pTheParent->LogicToPixel(Size(8, 0), MapMode(MapUnit::MapAppFont)) );
aTitlePos.X() += aIndent.Width();
aTitleSize.Width() -= aIndent.Width();
}
diff --git a/extensions/source/propctrlr/browserlistbox.cxx b/extensions/source/propctrlr/browserlistbox.cxx
index 2d53642bf580..38f5a92c6be8 100644
--- a/extensions/source/propctrlr/browserlistbox.cxx
+++ b/extensions/source/propctrlr/browserlistbox.cxx
@@ -418,7 +418,7 @@ namespace pcr
void OBrowserListBox::Resize()
{
tools::Rectangle aPlayground( Point( 0, 0 ), GetOutputSizePixel() );
- Size aHelpWindowDistance( LogicToPixel( Size( 0, LAYOUT_HELP_WINDOW_DISTANCE_APPFONT ), MapUnit::MapAppFont ) );
+ Size aHelpWindowDistance( LogicToPixel(Size(0, LAYOUT_HELP_WINDOW_DISTANCE_APPFONT), MapMode(MapUnit::MapAppFont)) );
long nHelpWindowHeight = m_nCurrentPreferredHelpHeight = impl_getPrefererredHelpHeight();
bool bPositionHelpWindow = ( nHelpWindowHeight != 0 );
@@ -746,7 +746,7 @@ namespace pcr
if ( HasHelpSection() )
{
- Size aHelpWindowDistance( LogicToPixel( Size( 0, LAYOUT_HELP_WINDOW_DISTANCE_APPFONT ), MapUnit::MapAppFont ) );
+ Size aHelpWindowDistance( LogicToPixel(Size(0, LAYOUT_HELP_WINDOW_DISTANCE_APPFONT), MapMode(MapUnit::MapAppFont)) );
nMinHeight += aHelpWindowDistance.Height();
nMinHeight += m_pHelpWindow->GetMinimalHeightPixel();
diff --git a/extensions/source/propctrlr/fontdialog.cxx b/extensions/source/propctrlr/fontdialog.cxx
index 447583056343..c9b0f0137cb7 100644
--- a/extensions/source/propctrlr/fontdialog.cxx
+++ b/extensions/source/propctrlr/fontdialog.cxx
@@ -224,7 +224,7 @@ namespace pcr
// build SfxItems with the values
SvxFontItem aFontItem((FontFamily)nFontFamily, aFontName, aFontStyleName, PITCH_DONTKNOW, nFontCharset, CFID_FONT);
- nFontHeight = (float)OutputDevice::LogicToLogic(Size(0, (sal_Int32)nFontHeight), MapUnit::MapPoint, MapUnit::MapTwip).Height();
+ nFontHeight = (float)OutputDevice::LogicToLogic(Size(0, (sal_Int32)nFontHeight), MapMode(MapUnit::MapPoint), MapMode(MapUnit::MapTwip)).Height();
SvxFontHeightItem aSvxFontHeightItem((sal_uInt32)nFontHeight,100,CFID_HEIGHT);
FontWeight eWeight=vcl::unohelper::ConvertFontWeight(nFontWeight);
@@ -328,7 +328,7 @@ namespace pcr
const SvxFontHeightItem& rSvxFontHeightItem =
static_cast<const SvxFontHeightItem&>(_rSet.Get(CFID_HEIGHT));
- float nHeight = (float)OutputDevice::LogicToLogic(Size(0, rSvxFontHeightItem.GetHeight()), MapUnit::MapTwip, MapUnit::MapPoint).Height();
+ float nHeight = (float)OutputDevice::LogicToLogic(Size(0, rSvxFontHeightItem.GetHeight()), MapMode(MapUnit::MapTwip), MapMode(MapUnit::MapPoint)).Height();
lcl_pushBackPropertyValue( _out_properties, PROPERTY_FONT_HEIGHT,makeAny(nHeight));
}
diff --git a/extensions/source/propctrlr/inspectorhelpwindow.cxx b/extensions/source/propctrlr/inspectorhelpwindow.cxx
index 05accc9b1365..91ee10a9d886 100644
--- a/extensions/source/propctrlr/inspectorhelpwindow.cxx
+++ b/extensions/source/propctrlr/inspectorhelpwindow.cxx
@@ -81,8 +81,8 @@ namespace pcr
long InspectorHelpWindow::impl_getSpaceAboveTextWindow()
{
- Size aSeparatorSize( LogicToPixel( Size( 0, 8 ), MapUnit::MapAppFont ) );
- Size a3AppFontSize( LogicToPixel( Size( 3, 3 ), MapUnit::MapAppFont ) );
+ Size aSeparatorSize(LogicToPixel(Size(0, 8), MapMode(MapUnit::MapAppFont)));
+ Size a3AppFontSize(LogicToPixel(Size(3, 3), MapMode(MapUnit::MapAppFont)));
return aSeparatorSize.Height() + a3AppFontSize.Height();
}
@@ -125,12 +125,12 @@ namespace pcr
void InspectorHelpWindow::Resize()
{
- Size a3AppFont( LogicToPixel( Size( 3, 3 ), MapUnit::MapAppFont ) );
+ Size a3AppFont(LogicToPixel(Size(3, 3), MapMode(MapUnit::MapAppFont)));
tools::Rectangle aPlayground( Point( 0, 0 ), GetOutputSizePixel() );
tools::Rectangle aSeparatorArea( aPlayground );
- aSeparatorArea.Bottom() = aSeparatorArea.Top() + LogicToPixel( Size( 0, 8 ), MapUnit::MapAppFont ).Height();
+ aSeparatorArea.Bottom() = aSeparatorArea.Top() + LogicToPixel(Size(0, 8), MapMode(MapUnit::MapAppFont)).Height();
m_aSeparator->SetPosSizePixel( aSeparatorArea.TopLeft(), aSeparatorArea.GetSize() );
tools::Rectangle aTextArea( aPlayground );
diff --git a/extensions/source/propctrlr/listselectiondlg.cxx b/extensions/source/propctrlr/listselectiondlg.cxx
index d1ce396bac15..2bc3d154c9c9 100644
--- a/extensions/source/propctrlr/listselectiondlg.cxx
+++ b/extensions/source/propctrlr/listselectiondlg.cxx
@@ -39,7 +39,7 @@ namespace pcr
OSL_PRECOND( m_xListBox.is(), "ListSelectionDialog::ListSelectionDialog: invalid list box!" );
get(m_pEntries, "treeview");
- Size aSize(LogicToPixel(Size(85, 97), MapUnit::MapAppFont));
+ Size aSize(LogicToPixel(Size(85, 97), MapMode(MapUnit::MapAppFont)));
m_pEntries->set_width_request(aSize.Width());
m_pEntries->set_height_request(aSize.Height());