From ccbaaa04417eac83f9f521e034a3e62821e4b7f3 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 9 Apr 2018 15:04:02 +0100 Subject: weld SmFontSizeDialog MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit and give it a parent via SfxRequest::GetFrameWeld Change-Id: I126c300ce4b3f477fd927efbcc83b1a6d315f594 Reviewed-on: https://gerrit.libreoffice.org/52637 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- cui/source/dialogs/colorpicker.cxx | 23 +++++++---------------- cui/source/dialogs/zoom.cxx | 4 +--- 2 files changed, 8 insertions(+), 19 deletions(-) (limited to 'cui') diff --git a/cui/source/dialogs/colorpicker.cxx b/cui/source/dialogs/colorpicker.cxx index 864281ae3ad1..7c64bb23a136 100644 --- a/cui/source/dialogs/colorpicker.cxx +++ b/cui/source/dialogs/colorpicker.cxx @@ -802,25 +802,16 @@ ColorPickerDialog::ColorPickerDialog(weld::Window* pParent, Color nColor, sal_In , m_xMFGreen(m_xBuilder->weld_spin_button("greenSpinbutton")) , m_xMFBlue(m_xBuilder->weld_spin_button("blueSpinbutton")) , m_xEDHex(new weld::HexColorControl(m_xBuilder->weld_entry("hexEntry"))) - , m_xMFHue(m_xBuilder->weld_metric_spin_button("hueSpinbutton")) - , m_xMFSaturation(m_xBuilder->weld_metric_spin_button("satSpinbutton")) - , m_xMFBrightness(m_xBuilder->weld_metric_spin_button("brightSpinbutton")) - , m_xMFCyan(m_xBuilder->weld_metric_spin_button("cyanSpinbutton")) - , m_xMFMagenta(m_xBuilder->weld_metric_spin_button("magSpinbutton")) - , m_xMFYellow(m_xBuilder->weld_metric_spin_button("yellowSpinbutton")) - , m_xMFKey(m_xBuilder->weld_metric_spin_button("keySpinbutton")) + , m_xMFHue(m_xBuilder->weld_metric_spin_button("hueSpinbutton", FUNIT_DEGREE)) + , m_xMFSaturation(m_xBuilder->weld_metric_spin_button("satSpinbutton", FUNIT_PERCENT)) + , m_xMFBrightness(m_xBuilder->weld_metric_spin_button("brightSpinbutton", FUNIT_PERCENT)) + , m_xMFCyan(m_xBuilder->weld_metric_spin_button("cyanSpinbutton", FUNIT_PERCENT)) + , m_xMFMagenta(m_xBuilder->weld_metric_spin_button("magSpinbutton", FUNIT_PERCENT)) + , m_xMFYellow(m_xBuilder->weld_metric_spin_button("yellowSpinbutton", FUNIT_PERCENT)) + , m_xMFKey(m_xBuilder->weld_metric_spin_button("keySpinbutton", FUNIT_PERCENT)) , mnDialogMode( nMode ) , meMode( DefaultMode ) { - m_xMFHue->set_unit(FUNIT_DEGREE); - m_xMFSaturation->set_unit(FUNIT_PERCENT); - m_xMFBrightness->set_unit(FUNIT_PERCENT); - - m_xMFCyan->set_unit(FUNIT_PERCENT); - m_xMFMagenta->set_unit(FUNIT_PERCENT); - m_xMFYellow->set_unit(FUNIT_PERCENT); - m_xMFKey->set_unit(FUNIT_PERCENT); - m_xColorField->SetModifyHdl( LINK( this, ColorPickerDialog, ColorFieldControlModifydl ) ); m_xColorSlider->SetModifyHdl( LINK( this, ColorPickerDialog, ColorSliderControlModifyHdl ) ); diff --git a/cui/source/dialogs/zoom.cxx b/cui/source/dialogs/zoom.cxx index d7f91462f971..9ff5d03f9ace 100644 --- a/cui/source/dialogs/zoom.cxx +++ b/cui/source/dialogs/zoom.cxx @@ -132,7 +132,7 @@ SvxZoomDialog::SvxZoomDialog(weld::Window* pParent, const SfxItemSet& rCoreSet) , m_xPageWidthBtn(m_xBuilder->weld_radio_button("fitw")) , m_x100Btn(m_xBuilder->weld_radio_button("100pc")) , m_xUserBtn(m_xBuilder->weld_radio_button("variable")) - , m_xUserEdit(m_xBuilder->weld_metric_spin_button("zoomsb")) + , m_xUserEdit(m_xBuilder->weld_metric_spin_button("zoomsb", FUNIT_PERCENT)) , m_xViewFrame(m_xBuilder->weld_widget("viewframe")) , m_xAutomaticBtn(m_xBuilder->weld_radio_button("automatic")) , m_xSingleBtn(m_xBuilder->weld_radio_button("singlepage")) @@ -141,8 +141,6 @@ SvxZoomDialog::SvxZoomDialog(weld::Window* pParent, const SfxItemSet& rCoreSet) , m_xBookModeChk(m_xBuilder->weld_check_button("bookmode")) , m_xOKBtn(m_xBuilder->weld_button("ok")) { - m_xUserEdit->set_unit(FUNIT_PERCENT); - Link aLink = LINK(this, SvxZoomDialog, UserHdl); m_x100Btn->connect_toggled(aLink); m_xOptimalBtn->connect_toggled(aLink); -- cgit