sd/source/ui/dlg/present.cxx | 15 ++++++++------- sd/source/ui/inc/present.hxx | 2 +- sd/uiconfig/simpress/ui/presentationdialog.ui | 3 +-- 3 files changed, 10 insertions(+), 10 deletions(-)
New commits: commit d2080376b32c2523c877dd6ed7d18e9be0260551 Author: Ariel Darshan <abdaandr...@gmail.com> AuthorDate: Sun Nov 10 11:45:46 2024 +0200 Commit: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> CommitDate: Fri Dec 13 12:15:59 2024 +0100 tdf#163858 sd: Support autorepeating slides in windowed mode Change-Id: I6b1d78f234699062d6b846989e4d92bfa4b3d85d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176342 Tested-by: Jenkins Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakan...@libreoffice.org> diff --git a/sd/source/ui/dlg/present.cxx b/sd/source/ui/dlg/present.cxx index 96c503170a07..d3d79fba41f4 100644 --- a/sd/source/ui/dlg/present.cxx +++ b/sd/source/ui/dlg/present.cxx @@ -55,7 +55,7 @@ SdStartPresentationDlg::SdStartPresentationDlg(weld::Window* pWindow, const SfxI , m_xLbCustomshow(m_xBuilder->weld_combo_box(u"customslideshow_cb"_ustr)) , m_xRbtStandard(m_xBuilder->weld_radio_button(u"default"_ustr)) , m_xRbtWindow(m_xBuilder->weld_radio_button(u"window"_ustr)) - , m_xRbtAuto(m_xBuilder->weld_radio_button(u"auto"_ustr)) + , m_xCbxAuto(m_xBuilder->weld_check_button(u"auto"_ustr)) , m_xTmfPause(m_xBuilder->weld_formatted_spin_button(u"pauseduration"_ustr)) , m_xFormatter(new weld::TimeFormatter(*m_xTmfPause)) , m_xCbxAutoLogo(m_xBuilder->weld_check_button(u"showlogo"_ustr)) @@ -92,7 +92,7 @@ SdStartPresentationDlg::SdStartPresentationDlg(weld::Window* pWindow, const SfxI aLink = LINK( this, SdStartPresentationDlg, ClickWindowPresentationHdl ); m_xRbtStandard->connect_toggled( aLink ); m_xRbtWindow->connect_toggled( aLink ); - m_xRbtAuto->connect_toggled( aLink ); + m_xCbxAuto->connect_toggled( aLink ); m_xCbxShowNavigationButton->connect_toggled( aLink ); m_xTmfPause->connect_value_changed( LINK( this, SdStartPresentationDlg, ChangePauseHdl ) ); @@ -155,11 +155,12 @@ SdStartPresentationDlg::SdStartPresentationDlg(weld::Window* pWindow, const SfxI if( bWindow ) m_xRbtWindow->set_active(true); - else if( bEndless ) - m_xRbtAuto->set_active(true); else m_xRbtStandard->set_active(true); + if( bEndless ) + m_xCbxAuto->set_active(true); + if (!officecfg::Office::Impress::Misc::Start::EnablePresenterScreen::get()) m_xLbConsole->set_active(PresenterConsoleMode::Disabled); else if (officecfg::Office::Impress::Misc::Start::PresenterScreenFullScreen::get()) @@ -335,7 +336,7 @@ void SdStartPresentationDlg::GetAttr( SfxItemSet& rAttr ) rAttr.Put( SfxBoolItem ( ATTR_PRESENT_CHANGE_PAGE, m_xCbxChangePage->get_active() ) ); rAttr.Put( SfxBoolItem ( ATTR_PRESENT_ALWAYS_ON_TOP, m_xCbxAlwaysOnTop->get_active() ) ); rAttr.Put( SfxBoolItem ( ATTR_PRESENT_FULLSCREEN, !m_xRbtWindow->get_active() ) ); - rAttr.Put( SfxBoolItem ( ATTR_PRESENT_ENDLESS, m_xRbtAuto->get_active() ) ); + rAttr.Put( SfxBoolItem ( ATTR_PRESENT_ENDLESS, m_xCbxAuto->get_active() ) ); rAttr.Put( SfxUInt32Item ( ATTR_PRESENT_PAUSE_TIMEOUT, m_xFormatter->GetTime().GetMSFromTime() / 1000 ) ); rAttr.Put( SfxBoolItem ( ATTR_PRESENT_SHOW_PAUSELOGO, m_xCbxAutoLogo->get_active() ) ); rAttr.Put( SfxBoolItem ( ATTR_PRESENT_INTERACTIVE, m_xCbxInteractiveMode->get_active() ) ); @@ -368,7 +369,7 @@ IMPL_LINK_NOARG(SdStartPresentationDlg, ChangeRangeHdl, weld::Toggleable&, void) */ IMPL_LINK_NOARG(SdStartPresentationDlg, ClickWindowPresentationHdl, weld::Toggleable&, void) { - const bool bAuto = m_xRbtAuto->get_active(); + const bool bAuto = m_xCbxAuto->get_active(); const bool bWindow = m_xRbtWindow->get_active(); m_xTmfPause->set_sensitive( bAuto ); @@ -401,7 +402,7 @@ IMPL_LINK_NOARG(SdStartPresentationDlg, ChangePauseHdl, weld::FormattedSpinButto void SdStartPresentationDlg::ChangePause() { - m_xCbxAutoLogo->set_sensitive(m_xRbtAuto->get_active() && ( m_xFormatter->GetTime().GetMSFromTime() > 0 )); + m_xCbxAutoLogo->set_sensitive(m_xCbxAuto->get_active() && ( m_xFormatter->GetTime().GetMSFromTime() > 0 )); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sd/source/ui/inc/present.hxx b/sd/source/ui/inc/present.hxx index 6e1d1aadef26..36d746958263 100644 --- a/sd/source/ui/inc/present.hxx +++ b/sd/source/ui/inc/present.hxx @@ -43,7 +43,7 @@ private: std::unique_ptr<weld::RadioButton> m_xRbtStandard; std::unique_ptr<weld::RadioButton> m_xRbtWindow; - std::unique_ptr<weld::RadioButton> m_xRbtAuto; + std::unique_ptr<weld::CheckButton> m_xCbxAuto; std::unique_ptr<weld::FormattedSpinButton> m_xTmfPause; std::unique_ptr<weld::TimeFormatter> m_xFormatter; std::unique_ptr<weld::CheckButton> m_xCbxAutoLogo; diff --git a/sd/uiconfig/simpress/ui/presentationdialog.ui b/sd/uiconfig/simpress/ui/presentationdialog.ui index df522280b371..33bfc4f9d64a 100644 --- a/sd/uiconfig/simpress/ui/presentationdialog.ui +++ b/sd/uiconfig/simpress/ui/presentationdialog.ui @@ -527,14 +527,13 @@ </packing> </child> <child> - <object class="GtkRadioButton" id="auto"> + <object class="GtkCheckButton" id="auto"> <property name="label" translatable="yes" context="presentationdialog|auto">_Loop and repeat after:</property> <property name="visible">True</property> <property name="can-focus">True</property> <property name="receives-default">False</property> <property name="use-underline">True</property> <property name="draw-indicator">True</property> - <property name="group">default</property> <accessibility> <relation type="label-for" target="pauseduration"/> </accessibility>