core.git: Branch 'distro/collabora/co-23.05' - sd/source
sd/source/ui/view/drviews5.cxx | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) New commits: commit 496be6be71ca9ce107213da793f3502a3bfda022 Author: Hubert Figuière AuthorDate: Mon May 20 11:15:35 2024 -0400 Commit: Caolán McNamara CommitDate: Thu May 23 12:48:07 2024 +0200 cool#9019: draw/impress: disable the Grid for now So that the grid isn't shown in the thumbnail. This will need to be reverted later for cool#7406 Change-Id: I01fbc7ebc9e33a27fb866b7ea6dbaaac68ae8f9b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167872 Tested-by: Jenkins CollaboraOffice Reviewed-by: Caolán McNamara (cherry picked from commit 41130a39ad68310a0136605cbced1f191396c456) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167826 Tested-by: Jenkins (cherry picked from commit 09f23b8c6cd369b5d0594119f3df62941346a610) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167933 diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx index c6774537cfea..160b5c5edf27 100644 --- a/sd/source/ui/view/drviews5.cxx +++ b/sd/source/ui/view/drviews5.cxx @@ -312,7 +312,15 @@ void DrawViewShell::WriteFrameViewData() mpFrameView->SetGridCoarse( mpDrawView->GetGridCoarse() ); mpFrameView->SetGridFine( mpDrawView->GetGridFine() ); mpFrameView->SetSnapGridWidth(mpDrawView->GetSnapGridWidthX(), mpDrawView->GetSnapGridWidthY()); -mpFrameView->SetGridVisible( mpDrawView->IsGridVisible() ); + +// In LOK, Grid isn't implemented, and it appears in the slide thumbnails +// Remove this when Grid is implemented and/or thumbnails are fixed to no longer +// show the grid. +if (comphelper::LibreOfficeKit::isActive()) +mpFrameView->SetGridVisible( false ); +else +mpFrameView->SetGridVisible( mpDrawView->IsGridVisible() ); + mpFrameView->SetGridFront( mpDrawView->IsGridFront() ); mpFrameView->SetSnapAngle( mpDrawView->GetSnapAngle() ); mpFrameView->SetGridSnap( mpDrawView->IsGridSnap() );
core.git: sd/source
sd/source/ui/view/drviews5.cxx | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) New commits: commit 09f23b8c6cd369b5d0594119f3df62941346a610 Author: Hubert Figuière AuthorDate: Mon May 20 11:15:35 2024 -0400 Commit: Caolán McNamara CommitDate: Tue May 21 11:59:02 2024 +0200 cool#9019: draw/impress: disable the Grid for now So that the grid isn't shown in the thumbnail. This will need to be reverted later for cool#7406 Change-Id: I01fbc7ebc9e33a27fb866b7ea6dbaaac68ae8f9b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167872 Tested-by: Jenkins CollaboraOffice Reviewed-by: Caolán McNamara (cherry picked from commit 41130a39ad68310a0136605cbced1f191396c456) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167826 Tested-by: Jenkins diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx index 8583ecc182c7..fa744fe49bcd 100644 --- a/sd/source/ui/view/drviews5.cxx +++ b/sd/source/ui/view/drviews5.cxx @@ -315,7 +315,15 @@ void DrawViewShell::WriteFrameViewData() mpFrameView->SetGridCoarse( mpDrawView->GetGridCoarse() ); mpFrameView->SetGridFine( mpDrawView->GetGridFine() ); mpFrameView->SetSnapGridWidth(mpDrawView->GetSnapGridWidthX(), mpDrawView->GetSnapGridWidthY()); -mpFrameView->SetGridVisible( mpDrawView->IsGridVisible() ); + +// In LOK, Grid isn't implemented, and it appears in the slide thumbnails +// Remove this when Grid is implemented and/or thumbnails are fixed to no longer +// show the grid. +if (comphelper::LibreOfficeKit::isActive()) +mpFrameView->SetGridVisible( false ); +else +mpFrameView->SetGridVisible( mpDrawView->IsGridVisible() ); + mpFrameView->SetGridFront( mpDrawView->IsGridFront() ); mpFrameView->SetSnapAngle( mpDrawView->GetSnapAngle() ); mpFrameView->SetGridSnap( mpDrawView->IsGridSnap() );
core.git: Branch 'distro/collabora/co-24.04' - sd/source
sd/source/ui/view/drviews5.cxx | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) New commits: commit 41130a39ad68310a0136605cbced1f191396c456 Author: Hubert Figuière AuthorDate: Mon May 20 11:15:35 2024 -0400 Commit: Caolán McNamara CommitDate: Mon May 20 18:36:02 2024 +0200 cool#9019: draw/impress: disable the Grid for now So that the grid isn't shown in the thumbnail. This will need to be reverted later for cool#7406 Change-Id: I01fbc7ebc9e33a27fb866b7ea6dbaaac68ae8f9b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167872 Tested-by: Jenkins CollaboraOffice Reviewed-by: Caolán McNamara diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx index 8583ecc182c7..fa744fe49bcd 100644 --- a/sd/source/ui/view/drviews5.cxx +++ b/sd/source/ui/view/drviews5.cxx @@ -315,7 +315,15 @@ void DrawViewShell::WriteFrameViewData() mpFrameView->SetGridCoarse( mpDrawView->GetGridCoarse() ); mpFrameView->SetGridFine( mpDrawView->GetGridFine() ); mpFrameView->SetSnapGridWidth(mpDrawView->GetSnapGridWidthX(), mpDrawView->GetSnapGridWidthY()); -mpFrameView->SetGridVisible( mpDrawView->IsGridVisible() ); + +// In LOK, Grid isn't implemented, and it appears in the slide thumbnails +// Remove this when Grid is implemented and/or thumbnails are fixed to no longer +// show the grid. +if (comphelper::LibreOfficeKit::isActive()) +mpFrameView->SetGridVisible( false ); +else +mpFrameView->SetGridVisible( mpDrawView->IsGridVisible() ); + mpFrameView->SetGridFront( mpDrawView->IsGridFront() ); mpFrameView->SetSnapAngle( mpDrawView->GetSnapAngle() ); mpFrameView->SetGridSnap( mpDrawView->IsGridSnap() );
core.git: sfx2/source
sfx2/source/control/unoctitm.cxx |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) New commits: commit fd0a249ad1f4a55677e97bd6355e5316a863f9e6 Author: Hubert Figuière AuthorDate: Wed May 8 17:34:47 2024 -0400 Commit: Caolán McNamara CommitDate: Thu May 9 17:13:37 2024 +0200 lokit: Properly handle state update for .uno:ToggleSheetGrid This is a follow up on cool#8066 Signed-off-by: Hubert Figuière Change-Id: I7d6ce4c9dfe7c2e9a2dda110e587c8c825c4df2f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167370 Reviewed-by: Szymon Kłos Tested-by: Jenkins CollaboraOffice (cherry picked from commit 9bbe40cc2d39f89ffcae57875d4c7ef7688d83d7) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167317 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 7d518f435d81..6fb25977796e 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -940,8 +940,7 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, SfxViewFrame* pViewFra aEvent.FeatureURL.Path == "SpacePara15" || aEvent.FeatureURL.Path == "SpacePara2" || aEvent.FeatureURL.Path == "DataFilterAutoFilter" || -aEvent.FeatureURL.Path == "CellProtection" || -aEvent.FeatureURL.Path == "ToggleSheetGrid") +aEvent.FeatureURL.Path == "CellProtection") { bool bTemp = false; aEvent.State >>= bTemp; @@ -1222,7 +1221,8 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, SfxViewFrame* pViewFra } } else if (aEvent.FeatureURL.Path == "ToggleMergeCells" || - aEvent.FeatureURL.Path == "SheetRightToLeft") + aEvent.FeatureURL.Path == "SheetRightToLeft" || + aEvent.FeatureURL.Path == "ToggleSheetGrid") { bool aBool;
core.git: Branch 'distro/collabora/co-24.04' - sfx2/source
sfx2/source/control/unoctitm.cxx |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) New commits: commit 9bbe40cc2d39f89ffcae57875d4c7ef7688d83d7 Author: Hubert Figuière AuthorDate: Wed May 8 17:34:47 2024 -0400 Commit: Szymon Kłos CommitDate: Thu May 9 08:52:37 2024 +0200 lokit: Properly handle state update for .uno:ToggleSheetGrid This is a follow up on cool#8066 Signed-off-by: Hubert Figuière Change-Id: I7d6ce4c9dfe7c2e9a2dda110e587c8c825c4df2f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167370 Reviewed-by: Szymon Kłos Tested-by: Jenkins CollaboraOffice diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 6572761c11ea..d289cd2616a8 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -940,8 +940,7 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, SfxViewFrame* pViewFra aEvent.FeatureURL.Path == "SpacePara15" || aEvent.FeatureURL.Path == "SpacePara2" || aEvent.FeatureURL.Path == "DataFilterAutoFilter" || -aEvent.FeatureURL.Path == "CellProtection" || -aEvent.FeatureURL.Path == "ToggleSheetGrid") +aEvent.FeatureURL.Path == "CellProtection") { bool bTemp = false; aEvent.State >>= bTemp; @@ -1224,7 +1223,8 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, SfxViewFrame* pViewFra } } else if (aEvent.FeatureURL.Path == "ToggleMergeCells" || - aEvent.FeatureURL.Path == "SheetRightToLeft") + aEvent.FeatureURL.Path == "SheetRightToLeft" || + aEvent.FeatureURL.Path == "ToggleSheetGrid") { bool aBool;
core.git: desktop/source sfx2/source
desktop/source/lib/init.cxx |3 ++- sfx2/source/control/unoctitm.cxx |3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) New commits: commit 9648f81f98d07cd4aef8611a50a77f11fb7ba86e Author: Hubert Figuière AuthorDate: Thu Apr 25 14:01:11 2024 -0400 Commit: Caolán McNamara CommitDate: Mon Apr 29 09:31:06 2024 +0200 cool#8066: calc: enable .uno:ToggleSheetGrid Signed-off-by: Hubert Figuière Change-Id: Ibe5bca4d0622c4015030a21d4ecccd41d5e9f483 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166529 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index f13bc1f48e26..f06151be6cfa 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -3847,7 +3847,8 @@ static void doc_iniUnoCommands () u".uno:InsertPictureContentControl"_ustr, u".uno:DataFilterAutoFilter"_ustr, u".uno:CellProtection"_ustr, -u".uno:MoveKeepInsertMode"_ustr +u".uno:MoveKeepInsertMode"_ustr, +u".uno:ToggleSheetGrid"_ustr, }; util::URL aCommandURL; diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 0691a6bad444..c6250e27d170 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -940,7 +940,8 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, SfxViewFrame* pViewFra aEvent.FeatureURL.Path == "SpacePara15" || aEvent.FeatureURL.Path == "SpacePara2" || aEvent.FeatureURL.Path == "DataFilterAutoFilter" || -aEvent.FeatureURL.Path == "CellProtection") +aEvent.FeatureURL.Path == "CellProtection" || +aEvent.FeatureURL.Path == "ToggleSheetGrid") { bool bTemp = false; aEvent.State >>= bTemp;
core.git: Branch 'distro/collabora/co-24.04' - desktop/source sfx2/source
desktop/source/lib/init.cxx |3 ++- sfx2/source/control/unoctitm.cxx |3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) New commits: commit dd78abffa4ab89507310e3080be25586f21c2021 Author: Hubert Figuière AuthorDate: Thu Apr 25 14:01:11 2024 -0400 Commit: Caolán McNamara CommitDate: Thu Apr 25 20:42:57 2024 +0200 cool#8066: calc: enable .uno:ToggleSheetGrid Signed-off-by: Hubert Figuière Change-Id: Ibe5bca4d0622c4015030a21d4ecccd41d5e9f483 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166647 Tested-by: Jenkins CollaboraOffice Reviewed-by: Caolán McNamara diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index 5f51d05615d8..ba9b45230093 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -3900,7 +3900,8 @@ static void doc_iniUnoCommands () u".uno:InsertPictureContentControl"_ustr, u".uno:DataFilterAutoFilter"_ustr, u".uno:CellProtection"_ustr, -u".uno:MoveKeepInsertMode"_ustr +u".uno:MoveKeepInsertMode"_ustr, +u".uno:ToggleSheetGrid"_ustr, }; util::URL aCommandURL; diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 37286cc2d71d..19bc307a1011 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -940,7 +940,8 @@ static void InterceptLOKStateChangeEvent(sal_uInt16 nSID, SfxViewFrame* pViewFra aEvent.FeatureURL.Path == "SpacePara15" || aEvent.FeatureURL.Path == "SpacePara2" || aEvent.FeatureURL.Path == "DataFilterAutoFilter" || -aEvent.FeatureURL.Path == "CellProtection") +aEvent.FeatureURL.Path == "CellProtection" || +aEvent.FeatureURL.Path == "ToggleSheetGrid") { bool bTemp = false; aEvent.State >>= bTemp;
core.git: include/vcl vcl/inc vcl/jsdialog vcl/source
include/vcl/toolkit/prgsbar.hxx |3 +++ include/vcl/wintypes.hxx |3 ++- vcl/inc/jsdialog/jsdialogbuilder.hxx | 10 ++ vcl/inc/salvtables.hxx | 19 +++ vcl/jsdialog/jsdialogbuilder.cxx | 25 + vcl/source/app/salvtables.cxx| 19 --- vcl/source/control/prgsbar.cxx |8 vcl/source/window/window.cxx |1 + 8 files changed, 68 insertions(+), 20 deletions(-) New commits: commit 460a7103664ac8dc60e260c56e5113d689b8072f Author: Hubert Figuière AuthorDate: Fri Mar 22 09:59:54 2024 -0400 Commit: Caolán McNamara CommitDate: Thu Mar 28 09:36:17 2024 +0100 vcl: Implement JSLevelBar This fixes the JSDialog layout of the sheet protection dialog. This was introduced for 24.02 to provide password strength indication of the sheet password. Defined a new WindowType of PROGRESSBAR. The type property in JSDialog JSON will be "progressbar". Change-Id: I202528a81706943e1838f3c37fb555f4a1bf889e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165236 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/include/vcl/toolkit/prgsbar.hxx b/include/vcl/toolkit/prgsbar.hxx index 1fcba74fdaba..bced6fc9e259 100644 --- a/include/vcl/toolkit/prgsbar.hxx +++ b/include/vcl/toolkit/prgsbar.hxx @@ -73,6 +73,9 @@ private: SAL_DLLPRIVATE void ImplInitSettings( bool bFont, bool bForeground, bool bBackground ); SAL_DLLPRIVATE void ImplDrawProgress(vcl::RenderContext& rRenderContext, sal_uInt16 nNewPerc); +protected: +virtual voidDumpAsPropertyTree(tools::JsonWriter&) override; + public: ProgressBar( vcl::Window* pParent, WinBits nWinBits, BarStyle eBarStyle ); diff --git a/include/vcl/wintypes.hxx b/include/vcl/wintypes.hxx index 644b2405cc2a..c025e83b0afe 100644 --- a/include/vcl/wintypes.hxx +++ b/include/vcl/wintypes.hxx @@ -98,7 +98,8 @@ enum class WindowType : sal_uInt16 RULER, HEADERBAR, VERTICALTABCONTROL , -LAST = VERTICALTABCONTROL, +PROGRESSBAR , +LAST = PROGRESSBAR, // only used in vclxtoolkit.cxx TOOLKIT_FRAMEWINDOW= 0x1000, TOOLKIT_SYSTEMCHILDWINDOW = 0x1001, diff --git a/vcl/inc/jsdialog/jsdialogbuilder.hxx b/vcl/inc/jsdialog/jsdialogbuilder.hxx index 34fdb7a068d5..2c544146dfad 100644 --- a/vcl/inc/jsdialog/jsdialogbuilder.hxx +++ b/vcl/inc/jsdialog/jsdialogbuilder.hxx @@ -16,6 +16,7 @@ #include #include #include +#include #include #include @@ -312,6 +313,7 @@ public: virtual std::unique_ptr weld_box(const OUString& id) override; virtual std::unique_ptr weld_widget(const OUString& id) override; virtual std::unique_ptr weld_image(const OUString& id) override; +virtual std::unique_ptr weld_level_bar(const OUString& id) override; virtual std::unique_ptr weld_calendar(const OUString& id) override; static weld::MessageDialog* @@ -892,6 +894,14 @@ public: virtual void set_image(const css::uno::Reference& rImage) override; }; +class JSLevelBar : public JSWidget +{ +public: +JSLevelBar(JSDialogSender* pSender, ::ProgressBar* pProgressBar, SalInstanceBuilder* pBuilder, + bool bTakeOwnership); +virtual void set_percentage(double fPercentage) override; +}; + class JSCalendar : public JSWidget { public: diff --git a/vcl/inc/salvtables.hxx b/vcl/inc/salvtables.hxx index cc7b34092d01..54abb89ffa21 100644 --- a/vcl/inc/salvtables.hxx +++ b/vcl/inc/salvtables.hxx @@ -22,6 +22,7 @@ #include #include #include +#include #include #include #include @@ -2181,6 +2182,24 @@ public: virtual ~SalInstanceScrolledWindow() override; }; +class SalInstanceLevelBar : public SalInstanceWidget, public virtual weld::LevelBar +{ +private: +VclPtr<::ProgressBar> m_xLevelBar; + +public: +SalInstanceLevelBar(::ProgressBar* pLevelBar, SalInstanceBuilder* pBuilder, bool bTakeOwnership) +: SalInstanceWidget(pLevelBar, pBuilder, bTakeOwnership) +, m_xLevelBar(pLevelBar) +{ +} + +virtual void set_percentage(double fPercentage) override +{ +m_xLevelBar->SetValue(static_cast(fPercentage)); +} +}; + class SalInstanceCalendar : public SalInstanceWidget, public virtual weld::Calendar { private: diff --git a/vcl/jsdialog/jsdialogbuilder.cxx b/vcl/jsdialog/jsdialogbuilder.cxx index 1f56bda71bba..fa574088c7c6 100644 --- a/vcl/jsdialog/jsdialogbuilder.cxx +++ b/vcl/jsdialog/jsdialogbuilder.cxx @@ -1264,6 +1264,19 @@ std::unique_ptr JSInstanceBuilder::weld_image(const OUString& id) return pWeldWidget; } +std::unique_ptr JSInstanceBuilder::weld_level_bar(const OUString& id) +{ +::ProgressBar* pLevelBar = m_xBuilder->get<::ProgressBar>(id); + +auto pWeldWidget += pLevelBar ?
core.git: Branch 'distro/collabora/co-24.04' - include/vcl vcl/inc vcl/jsdialog vcl/source
include/vcl/toolkit/prgsbar.hxx |3 +++ include/vcl/wintypes.hxx |3 ++- vcl/inc/jsdialog/jsdialogbuilder.hxx | 10 ++ vcl/inc/salvtables.hxx | 19 +++ vcl/jsdialog/jsdialogbuilder.cxx | 25 + vcl/source/app/salvtables.cxx| 19 --- vcl/source/control/prgsbar.cxx |8 vcl/source/window/window.cxx |1 + 8 files changed, 68 insertions(+), 20 deletions(-) New commits: commit 7586da84124f4aa73fd21081610de78d5d416fe6 Author: Hubert Figuière AuthorDate: Fri Mar 22 09:59:54 2024 -0400 Commit: Caolán McNamara CommitDate: Mon Mar 25 15:39:27 2024 +0100 vcl: Implement JSLevelBar This fixes the JSDialog layout of the sheet protection dialog. This was introduced for 24.02 to provide password strength indication of the sheet password. Defined a new WindowType of PROGRESSBAR. The type property in JSDialog JSON will be "progressbar". Change-Id: I202528a81706943e1838f3c37fb555f4a1bf889e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165168 Tested-by: Jenkins CollaboraOffice Reviewed-by: Caolán McNamara diff --git a/include/vcl/toolkit/prgsbar.hxx b/include/vcl/toolkit/prgsbar.hxx index 1fcba74fdaba..bced6fc9e259 100644 --- a/include/vcl/toolkit/prgsbar.hxx +++ b/include/vcl/toolkit/prgsbar.hxx @@ -73,6 +73,9 @@ private: SAL_DLLPRIVATE void ImplInitSettings( bool bFont, bool bForeground, bool bBackground ); SAL_DLLPRIVATE void ImplDrawProgress(vcl::RenderContext& rRenderContext, sal_uInt16 nNewPerc); +protected: +virtual voidDumpAsPropertyTree(tools::JsonWriter&) override; + public: ProgressBar( vcl::Window* pParent, WinBits nWinBits, BarStyle eBarStyle ); diff --git a/include/vcl/wintypes.hxx b/include/vcl/wintypes.hxx index 644b2405cc2a..c025e83b0afe 100644 --- a/include/vcl/wintypes.hxx +++ b/include/vcl/wintypes.hxx @@ -98,7 +98,8 @@ enum class WindowType : sal_uInt16 RULER, HEADERBAR, VERTICALTABCONTROL , -LAST = VERTICALTABCONTROL, +PROGRESSBAR , +LAST = PROGRESSBAR, // only used in vclxtoolkit.cxx TOOLKIT_FRAMEWINDOW= 0x1000, TOOLKIT_SYSTEMCHILDWINDOW = 0x1001, diff --git a/vcl/inc/jsdialog/jsdialogbuilder.hxx b/vcl/inc/jsdialog/jsdialogbuilder.hxx index 066dcddfcfc8..3d98e7e61a19 100644 --- a/vcl/inc/jsdialog/jsdialogbuilder.hxx +++ b/vcl/inc/jsdialog/jsdialogbuilder.hxx @@ -16,6 +16,7 @@ #include #include #include +#include #include #include @@ -311,6 +312,7 @@ public: virtual std::unique_ptr weld_box(const OUString& id) override; virtual std::unique_ptr weld_widget(const OUString& id) override; virtual std::unique_ptr weld_image(const OUString& id) override; +virtual std::unique_ptr weld_level_bar(const OUString& id) override; virtual std::unique_ptr weld_calendar(const OUString& id) override; static weld::MessageDialog* @@ -889,6 +891,14 @@ public: virtual void set_image(const css::uno::Reference& rImage) override; }; +class JSLevelBar : public JSWidget +{ +public: +JSLevelBar(JSDialogSender* pSender, ::ProgressBar* pProgressBar, SalInstanceBuilder* pBuilder, + bool bTakeOwnership); +virtual void set_percentage(double fPercentage) override; +}; + class JSCalendar : public JSWidget { public: diff --git a/vcl/inc/salvtables.hxx b/vcl/inc/salvtables.hxx index 4074e097a4f4..46aa3da22b71 100644 --- a/vcl/inc/salvtables.hxx +++ b/vcl/inc/salvtables.hxx @@ -22,6 +22,7 @@ #include #include #include +#include #include #include #include @@ -2182,6 +2183,24 @@ public: virtual ~SalInstanceScrolledWindow() override; }; +class SalInstanceLevelBar : public SalInstanceWidget, public virtual weld::LevelBar +{ +private: +VclPtr<::ProgressBar> m_xLevelBar; + +public: +SalInstanceLevelBar(::ProgressBar* pLevelBar, SalInstanceBuilder* pBuilder, bool bTakeOwnership) +: SalInstanceWidget(pLevelBar, pBuilder, bTakeOwnership) +, m_xLevelBar(pLevelBar) +{ +} + +virtual void set_percentage(double fPercentage) override +{ +m_xLevelBar->SetValue(static_cast(fPercentage)); +} +}; + class SalInstanceCalendar : public SalInstanceWidget, public virtual weld::Calendar { private: diff --git a/vcl/jsdialog/jsdialogbuilder.cxx b/vcl/jsdialog/jsdialogbuilder.cxx index 97675b6267c1..1704988084f1 100644 --- a/vcl/jsdialog/jsdialogbuilder.cxx +++ b/vcl/jsdialog/jsdialogbuilder.cxx @@ -1269,6 +1269,19 @@ std::unique_ptr JSInstanceBuilder::weld_image(const OUString& id) return pWeldWidget; } +std::unique_ptr JSInstanceBuilder::weld_level_bar(const OUString& id) +{ +::ProgressBar* pLevelBar = m_xBuilder->get<::ProgressBar>(id); + +auto pWeldWidget +=
core.git: Branch 'distro/collabora/co-23.05' - sc/uiconfig
sc/uiconfig/scalc/ui/cellprotectionpage.ui |4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) New commits: commit 581ca37c96ee5b1d029d79bf7bb4c7b6baf5487c Author: Hubert Figuière AuthorDate: Thu Feb 22 10:50:53 2024 -0500 Commit: Andras Timar CommitDate: Thu Feb 22 23:12:33 2024 +0100 [cp] tdf#159748 Remove reference to menu in dialog text This menu doesn't exist when using the tabbed UI Change-Id: I2dc89e630049171777684aff55b51872121b6e39 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163776 Reviewed-by: Andras Timar Tested-by: Andras Timar diff --git a/sc/uiconfig/scalc/ui/cellprotectionpage.ui b/sc/uiconfig/scalc/ui/cellprotectionpage.ui index b9a2d90a72c6..9074d3a04aff 100644 --- a/sc/uiconfig/scalc/ui/cellprotectionpage.ui +++ b/sc/uiconfig/scalc/ui/cellprotectionpage.ui @@ -96,9 +96,7 @@ False end True -Cell protection is only effective after the current sheet has been protected. - -Select 'Protect Sheet' from the 'Tools' menu. +Cell protection is only effective after the current sheet has been protected. True 52 0
core.git: sc/source
sc/source/ui/inc/tabvwsh.hxx |3 sc/source/ui/view/tabvwsh3.cxx | 190 - 2 files changed, 117 insertions(+), 76 deletions(-) New commits: commit e86c6423d6ec9641dcc2ea3748d74759cd8e67fe Author: Hubert Figuière AuthorDate: Mon Feb 12 10:14:05 2024 -0500 Commit: Caolán McNamara CommitDate: Fri Feb 16 15:51:14 2024 +0100 calc: sheet protection dialog is async Change-Id: I33930ae212a8b35a4430df3180f4ffcca86ff870 Signed-off-by: Hubert Figuière Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163496 Tested-by: Jenkins Reviewed-by: Caolán McNamara diff --git a/sc/source/ui/inc/tabvwsh.hxx b/sc/source/ui/inc/tabvwsh.hxx index 2a7f83c602fd..d6c159a9fa61 100644 --- a/sc/source/ui/inc/tabvwsh.hxx +++ b/sc/source/ui/inc/tabvwsh.hxx @@ -408,6 +408,9 @@ public: boolExecuteRetypePassDlg(ScPasswordHash eDesiredHash); +voidFinishProtectTable(); +voidExecProtectTable( SfxRequest& rReq ); + using ScTabView::ShowCursor; bool IsActive() const { return bIsActive; } diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx index 208748b7110f..23e3eacfa901 100644 --- a/sc/source/ui/view/tabvwsh3.cxx +++ b/sc/source/ui/view/tabvwsh3.cxx @@ -170,6 +170,118 @@ namespace } } +void ScTabViewShell::FinishProtectTable() +{ +TabChanged(); +UpdateInputHandler(true); // to immediately enable input again +SelectionChanged(); +} + +void ScTabViewShell::ExecProtectTable( SfxRequest& rReq ) +{ +ScModule* pScMod = SC_MOD(); +const SfxItemSet* pReqArgs= rReq.GetArgs(); +ScDocument& rDoc = GetViewData().GetDocument(); +SCTAB nTab = GetViewData().GetTabNo(); +boolbOldProtection = rDoc.IsTabProtected(nTab); + +if( pReqArgs ) +{ +const SfxPoolItem* pItem; +bool bNewProtection = !bOldProtection; +if( pReqArgs->HasItem( FID_PROTECT_TABLE, ) ) +bNewProtection = static_cast(pItem)->GetValue(); +if( bNewProtection == bOldProtection ) +{ +rReq.Ignore(); +return; +} +} + +if (bOldProtection) +{ +// Unprotect a protected sheet. + +const ScTableProtection* pProtect = rDoc.GetTabProtection(nTab); +if (pProtect && pProtect->isProtectedWithPass()) +{ +std::shared_ptr xRequest; +if (!pReqArgs) +{ +xRequest = std::make_shared(rReq); +rReq.Ignore(); // the 'old' request is not relevant any more +} + +OUString aText( ScResId(SCSTR_PASSWORDOPT) ); +auto pDlg = std::make_shared(GetFrameWeld(), ); +pDlg->set_title(ScResId(SCSTR_UNPROTECTTAB)); +pDlg->SetMinLen(0); + pDlg->set_help_id(GetStaticInterface()->GetSlot(FID_PROTECT_TABLE)->GetCommand()); +pDlg->SetEditHelpId(HID_PASSWD_TABLE); + +pDlg->PreRun(); + +weld::DialogController::runAsync(pDlg, [this, nTab, pDlg, xRequest](sal_Int32 response) { +if (response == RET_OK) +{ +OUString aPassword = pDlg->GetPassword(); +Unprotect(nTab, aPassword); +} +if (xRequest) +{ +xRequest->AppendItem( SfxBoolItem(FID_PROTECT_TABLE, false) ); +xRequest->Done(); +} +FinishProtectTable(); +}); +return; +} +else +// this sheet is not password-protected. +Unprotect(nTab, OUString()); + +if (!pReqArgs) +{ +rReq.AppendItem( SfxBoolItem(FID_PROTECT_TABLE, false) ); +rReq.Done(); +} +} +else +{ +// Protect a current sheet. +std::shared_ptr xRequest; +if (!pReqArgs) +{ +xRequest = std::make_shared(rReq); +rReq.Ignore(); // the 'old' request is not relevant any more +} + +auto pDlg = std::make_shared(GetFrameWeld()); + +const ScTableProtection* pProtect = rDoc.GetTabProtection(nTab); +if (pProtect) +pDlg->SetDialogData(*pProtect); +weld::DialogController::runAsync(pDlg, [this, pDlg, pScMod, nTab, xRequest](sal_uInt32 nResult) { +if (nResult == RET_OK) +{ +pScMod->InputEnterHandler(); + +ScTableProtection aNewProtect; +pDlg->WriteData(aNewProtect); +ProtectSheet(nTab, aNewProtect); +if (xRequest) +{ +xRequest->AppendItem( SfxBoolItem(FID_PROTECT_TABLE, true) ); +xRequest->Done(); +} +} +FinishProtectTable(); +}); +return; +} +
core.git: Branch 'distro/collabora/co-24.04' - sc/source
sc/source/ui/inc/tabvwsh.hxx |3 sc/source/ui/view/tabvwsh3.cxx | 190 - 2 files changed, 117 insertions(+), 76 deletions(-) New commits: commit cba33694c894ff49248cfb14c2218e4f34a35be0 Author: Hubert Figuière AuthorDate: Mon Feb 12 10:14:05 2024 -0500 Commit: Caolán McNamara CommitDate: Fri Feb 16 13:12:41 2024 +0100 calc: sheet protection dialog is async Change-Id: I33930ae212a8b35a4430df3180f4ffcca86ff870 Signed-off-by: Hubert Figuière Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163495 Tested-by: Jenkins CollaboraOffice Reviewed-by: Caolán McNamara diff --git a/sc/source/ui/inc/tabvwsh.hxx b/sc/source/ui/inc/tabvwsh.hxx index fff123aa1bc6..b457e1167100 100644 --- a/sc/source/ui/inc/tabvwsh.hxx +++ b/sc/source/ui/inc/tabvwsh.hxx @@ -397,6 +397,9 @@ public: boolExecuteRetypePassDlg(ScPasswordHash eDesiredHash); +voidFinishProtectTable(); +voidExecProtectTable( SfxRequest& rReq ); + using ScTabView::ShowCursor; bool IsActive() const { return bIsActive; } diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx index 208748b7110f..23e3eacfa901 100644 --- a/sc/source/ui/view/tabvwsh3.cxx +++ b/sc/source/ui/view/tabvwsh3.cxx @@ -170,6 +170,118 @@ namespace } } +void ScTabViewShell::FinishProtectTable() +{ +TabChanged(); +UpdateInputHandler(true); // to immediately enable input again +SelectionChanged(); +} + +void ScTabViewShell::ExecProtectTable( SfxRequest& rReq ) +{ +ScModule* pScMod = SC_MOD(); +const SfxItemSet* pReqArgs= rReq.GetArgs(); +ScDocument& rDoc = GetViewData().GetDocument(); +SCTAB nTab = GetViewData().GetTabNo(); +boolbOldProtection = rDoc.IsTabProtected(nTab); + +if( pReqArgs ) +{ +const SfxPoolItem* pItem; +bool bNewProtection = !bOldProtection; +if( pReqArgs->HasItem( FID_PROTECT_TABLE, ) ) +bNewProtection = static_cast(pItem)->GetValue(); +if( bNewProtection == bOldProtection ) +{ +rReq.Ignore(); +return; +} +} + +if (bOldProtection) +{ +// Unprotect a protected sheet. + +const ScTableProtection* pProtect = rDoc.GetTabProtection(nTab); +if (pProtect && pProtect->isProtectedWithPass()) +{ +std::shared_ptr xRequest; +if (!pReqArgs) +{ +xRequest = std::make_shared(rReq); +rReq.Ignore(); // the 'old' request is not relevant any more +} + +OUString aText( ScResId(SCSTR_PASSWORDOPT) ); +auto pDlg = std::make_shared(GetFrameWeld(), ); +pDlg->set_title(ScResId(SCSTR_UNPROTECTTAB)); +pDlg->SetMinLen(0); + pDlg->set_help_id(GetStaticInterface()->GetSlot(FID_PROTECT_TABLE)->GetCommand()); +pDlg->SetEditHelpId(HID_PASSWD_TABLE); + +pDlg->PreRun(); + +weld::DialogController::runAsync(pDlg, [this, nTab, pDlg, xRequest](sal_Int32 response) { +if (response == RET_OK) +{ +OUString aPassword = pDlg->GetPassword(); +Unprotect(nTab, aPassword); +} +if (xRequest) +{ +xRequest->AppendItem( SfxBoolItem(FID_PROTECT_TABLE, false) ); +xRequest->Done(); +} +FinishProtectTable(); +}); +return; +} +else +// this sheet is not password-protected. +Unprotect(nTab, OUString()); + +if (!pReqArgs) +{ +rReq.AppendItem( SfxBoolItem(FID_PROTECT_TABLE, false) ); +rReq.Done(); +} +} +else +{ +// Protect a current sheet. +std::shared_ptr xRequest; +if (!pReqArgs) +{ +xRequest = std::make_shared(rReq); +rReq.Ignore(); // the 'old' request is not relevant any more +} + +auto pDlg = std::make_shared(GetFrameWeld()); + +const ScTableProtection* pProtect = rDoc.GetTabProtection(nTab); +if (pProtect) +pDlg->SetDialogData(*pProtect); +weld::DialogController::runAsync(pDlg, [this, pDlg, pScMod, nTab, xRequest](sal_uInt32 nResult) { +if (nResult == RET_OK) +{ +pScMod->InputEnterHandler(); + +ScTableProtection aNewProtect; +pDlg->WriteData(aNewProtect); +ProtectSheet(nTab, aNewProtect); +if (xRequest) +{ +xRequest->AppendItem( SfxBoolItem(FID_PROTECT_TABLE, true) ); +xRequest->Done(); +} +} +FinishProtectTable(); +}); +return; +} +
core.git: Branch 'distro/collabora/co-23.05' - sc/source
sc/source/ui/inc/tabvwsh.hxx |3 sc/source/ui/view/tabvwsh3.cxx | 190 - 2 files changed, 117 insertions(+), 76 deletions(-) New commits: commit 9f793970fd091d215d11fcfe2098b7a2792d57f0 Author: Hubert Figuière AuthorDate: Mon Feb 12 10:14:05 2024 -0500 Commit: Caolán McNamara CommitDate: Fri Feb 16 12:33:31 2024 +0100 calc: sheet protection dialog is async Change-Id: I33930ae212a8b35a4430df3180f4ffcca86ff870 Signed-off-by: Hubert Figuière Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163387 Tested-by: Jenkins CollaboraOffice Tested-by: Caolán McNamara Reviewed-by: Caolán McNamara diff --git a/sc/source/ui/inc/tabvwsh.hxx b/sc/source/ui/inc/tabvwsh.hxx index 734906e50176..aaf51915609b 100644 --- a/sc/source/ui/inc/tabvwsh.hxx +++ b/sc/source/ui/inc/tabvwsh.hxx @@ -395,6 +395,9 @@ public: boolExecuteRetypePassDlg(ScPasswordHash eDesiredHash); +voidFinishProtectTable(); +voidExecProtectTable( SfxRequest& rReq ); + using ScTabView::ShowCursor; bool IsActive() const { return bIsActive; } diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx index fe36ab3a5528..2ea10a592f1b 100644 --- a/sc/source/ui/view/tabvwsh3.cxx +++ b/sc/source/ui/view/tabvwsh3.cxx @@ -169,6 +169,118 @@ namespace } } +void ScTabViewShell::FinishProtectTable() +{ +TabChanged(); +UpdateInputHandler(true); // to immediately enable input again +SelectionChanged(); +} + +void ScTabViewShell::ExecProtectTable( SfxRequest& rReq ) +{ +ScModule* pScMod = SC_MOD(); +const SfxItemSet* pReqArgs= rReq.GetArgs(); +ScDocument& rDoc = GetViewData().GetDocument(); +SCTAB nTab = GetViewData().GetTabNo(); +boolbOldProtection = rDoc.IsTabProtected(nTab); + +if( pReqArgs ) +{ +const SfxPoolItem* pItem; +bool bNewProtection = !bOldProtection; +if( pReqArgs->HasItem( FID_PROTECT_TABLE, ) ) +bNewProtection = static_cast(pItem)->GetValue(); +if( bNewProtection == bOldProtection ) +{ +rReq.Ignore(); +return; +} +} + +if (bOldProtection) +{ +// Unprotect a protected sheet. + +const ScTableProtection* pProtect = rDoc.GetTabProtection(nTab); +if (pProtect && pProtect->isProtectedWithPass()) +{ +std::shared_ptr xRequest; +if (!pReqArgs) +{ +xRequest = std::make_shared(rReq); +rReq.Ignore(); // the 'old' request is not relevant any more +} + +OUString aText( ScResId(SCSTR_PASSWORDOPT) ); +auto pDlg = std::make_shared(GetFrameWeld(), ); +pDlg->set_title(ScResId(SCSTR_UNPROTECTTAB)); +pDlg->SetMinLen(0); + pDlg->set_help_id(GetStaticInterface()->GetSlot(FID_PROTECT_TABLE)->GetCommand()); +pDlg->SetEditHelpId(HID_PASSWD_TABLE); + +pDlg->PreRun(); + +weld::DialogController::runAsync(pDlg, [this, nTab, pDlg, xRequest](sal_Int32 response) { +if (response == RET_OK) +{ +OUString aPassword = pDlg->GetPassword(); +Unprotect(nTab, aPassword); +} +if (xRequest) +{ +xRequest->AppendItem( SfxBoolItem(FID_PROTECT_TABLE, false) ); +xRequest->Done(); +} +FinishProtectTable(); +}); +return; +} +else +// this sheet is not password-protected. +Unprotect(nTab, OUString()); + +if (!pReqArgs) +{ +rReq.AppendItem( SfxBoolItem(FID_PROTECT_TABLE, false) ); +rReq.Done(); +} +} +else +{ +// Protect a current sheet. +std::shared_ptr xRequest; +if (!pReqArgs) +{ +xRequest = std::make_shared(rReq); +rReq.Ignore(); // the 'old' request is not relevant any more +} + +auto pDlg = std::make_shared(GetFrameWeld()); + +const ScTableProtection* pProtect = rDoc.GetTabProtection(nTab); +if (pProtect) +pDlg->SetDialogData(*pProtect); +weld::DialogController::runAsync(pDlg, [this, pDlg, pScMod, nTab, xRequest](sal_uInt32 nResult) { +if (nResult == RET_OK) +{ +pScMod->InputEnterHandler(); + +ScTableProtection aNewProtect; +pDlg->WriteData(aNewProtect); +ProtectSheet(nTab, aNewProtect); +if (xRequest) +{ +xRequest->AppendItem( SfxBoolItem(FID_PROTECT_TABLE, true) ); +xRequest->Done(); +} +} +FinishProtectTable(); +
core.git: Branch 'distro/collabora/co-24.04' - sc/source
sc/source/ui/unoobj/docuno.cxx |3 +++ 1 file changed, 3 insertions(+) New commits: commit 3f7eb1423bdcc5d1506a87096d535d05a59fab00 Author: Hubert Figuière AuthorDate: Tue Feb 13 15:56:57 2024 -0500 Commit: Michael Meeks CommitDate: Wed Feb 14 10:16:12 2024 +0100 calc: getPartInfo() returns the sheet protected state Change-Id: I67e2a26680895b5c76977109f4c3f9e1638a9f9e Signed-off-by: Hubert Figuière Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163336 Tested-by: Michael Meeks Reviewed-by: Michael Meeks diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx index fbc33cff551d..a6de0da0cc92 100644 --- a/sc/source/ui/unoobj/docuno.cxx +++ b/sc/source/ui/unoobj/docuno.cxx @@ -614,6 +614,7 @@ OUString ScModelObj::getPartInfo( int nPart ) return OUString(); const bool bIsVisible = pViewData->GetDocument().IsVisible(nPart); +const bool bIsProtected = pViewData->GetDocument().IsTabProtected(nPart); //FIXME: Implement IsSelected(). const bool bIsSelected = false; //pViewData->GetDocument()->IsSelected(nPart); const bool bIsRTLLayout = pViewData->GetDocument().IsLayoutRTL(nPart); @@ -624,6 +625,8 @@ OUString ScModelObj::getPartInfo( int nPart ) OUString::number(static_cast(bIsSelected)) + "\", \"rtllayout\": \"" + OUString::number(static_cast(bIsRTLLayout)) + +"\", \"protected\": \"" + +OUString::number(static_cast(bIsProtected)) + "\" }"; return aPartInfo; }
core.git: sc/source
sc/source/ui/unoobj/docuno.cxx |3 +++ 1 file changed, 3 insertions(+) New commits: commit f34025d36dda12ca99bb82f80e711fbd93fe4967 Author: Hubert Figuière AuthorDate: Tue Feb 13 15:56:57 2024 -0500 Commit: Michael Meeks CommitDate: Wed Feb 14 10:16:26 2024 +0100 calc: getPartInfo() returns the sheet protected state Change-Id: I67e2a26680895b5c76977109f4c3f9e1638a9f9e Signed-off-by: Hubert Figuière Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163337 Tested-by: Jenkins Reviewed-by: Michael Meeks diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx index e45ef91d2246..abb046ba1dd2 100644 --- a/sc/source/ui/unoobj/docuno.cxx +++ b/sc/source/ui/unoobj/docuno.cxx @@ -616,6 +616,7 @@ OUString ScModelObj::getPartInfo( int nPart ) return OUString(); const bool bIsVisible = pViewData->GetDocument().IsVisible(nPart); +const bool bIsProtected = pViewData->GetDocument().IsTabProtected(nPart); //FIXME: Implement IsSelected(). const bool bIsSelected = false; //pViewData->GetDocument()->IsSelected(nPart); const bool bIsRTLLayout = pViewData->GetDocument().IsLayoutRTL(nPart); @@ -626,6 +627,8 @@ OUString ScModelObj::getPartInfo( int nPart ) OUString::number(static_cast(bIsSelected)) + "\", \"rtllayout\": \"" + OUString::number(static_cast(bIsRTLLayout)) + +"\", \"protected\": \"" + +OUString::number(static_cast(bIsProtected)) + "\" }"; return aPartInfo; }
core.git: Branch 'distro/collabora/co-23.05' - sc/source
sc/source/ui/unoobj/docuno.cxx |3 +++ 1 file changed, 3 insertions(+) New commits: commit db963d695dae5f9d4e3825a896f41bbdf9484bb2 Author: Hubert Figuière AuthorDate: Tue Feb 13 15:56:57 2024 -0500 Commit: Andras Timar CommitDate: Wed Feb 14 09:51:09 2024 +0100 calc: getPartInfo() returns the sheet protected state Change-Id: I67e2a26680895b5c76977109f4c3f9e1638a9f9e Signed-off-by: Hubert Figuière Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163325 Reviewed-by: Michael Meeks Tested-by: Jenkins CollaboraOffice diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx index cb13801b7b1e..832b2015c2b2 100644 --- a/sc/source/ui/unoobj/docuno.cxx +++ b/sc/source/ui/unoobj/docuno.cxx @@ -613,6 +613,7 @@ OUString ScModelObj::getPartInfo( int nPart ) return OUString(); const bool bIsVisible = pViewData->GetDocument().IsVisible(nPart); +const bool bIsProtected = pViewData->GetDocument().IsTabProtected(nPart); //FIXME: Implement IsSelected(). const bool bIsSelected = false; //pViewData->GetDocument()->IsSelected(nPart); const bool bIsRTLLayout = pViewData->GetDocument().IsLayoutRTL(nPart); @@ -623,6 +624,8 @@ OUString ScModelObj::getPartInfo( int nPart ) OUString::number(static_cast(bIsSelected)) + "\", \"rtllayout\": \"" + OUString::number(static_cast(bIsRTLLayout)) + +"\", \"protected\": \"" + +OUString::number(static_cast(bIsProtected)) + "\" }"; return aPartInfo; }
core.git: Branch 'distro/collabora/co-24.04' - sc/source vcl/jsdialog
sc/source/ui/attrdlg/attrdlg.cxx |7 +-- vcl/jsdialog/enabled.cxx |1 + 2 files changed, 2 insertions(+), 6 deletions(-) New commits: commit 11ccb687f6739d58d5ad878aece31db330825d08 Author: Hubert Figuière AuthorDate: Mon Feb 12 17:32:31 2024 -0500 Commit: Michael Meeks CommitDate: Tue Feb 13 20:58:26 2024 +0100 sc: add back protect cell tab from cell format dialog Also enable the tab in jsdialogs Signed-off-by: Hubert Figuière Change-Id: I2c4eac029568cc0de4be5ebb6b0f4ae47f2da1a1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163263 Tested-by: Jenkins CollaboraOffice Reviewed-by: Michael Meeks (cherry picked from commit 6cda8155c66bfcd3ebda49ac8254d529629a300e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163287 Tested-by: Michael Meeks diff --git a/sc/source/ui/attrdlg/attrdlg.cxx b/sc/source/ui/attrdlg/attrdlg.cxx index faa08bf3ca00..c0653ad4f1d0 100644 --- a/sc/source/ui/attrdlg/attrdlg.cxx +++ b/sc/source/ui/attrdlg/attrdlg.cxx @@ -30,7 +30,6 @@ #include #include #include -#include ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) : SfxTabDialogController(pParent, "modules/scalc/ui/formatcellsdialog.ui", @@ -58,11 +57,7 @@ ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) AddTabPage( "borders", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BORDER ), nullptr ); OSL_ENSURE(pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), "GetTabPageCreatorFunc fail!"); AddTabPage( "background", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), nullptr ); - -if (!comphelper::LibreOfficeKit::isActive()) -AddTabPage( "cellprotection" , ScTabPageProtection::Create, nullptr ); -else -RemoveTabPage( "cellprotection" ); +AddTabPage( "cellprotection" , ScTabPageProtection::Create,nullptr ); } ScAttrDlg::~ScAttrDlg() diff --git a/vcl/jsdialog/enabled.cxx b/vcl/jsdialog/enabled.cxx index beb12b5dd081..b04418257bff 100644 --- a/vcl/jsdialog/enabled.cxx +++ b/vcl/jsdialog/enabled.cxx @@ -97,6 +97,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool bMobile) // scalc || rUIFile == u"modules/scalc/ui/advancedfilterdialog.ui" || rUIFile == u"modules/scalc/ui/analysisofvariancedialog.ui" +|| rUIFile == u"modules/scalc/ui/cellprotectionpage.ui" || rUIFile == u"modules/scalc/ui/chardialog.ui" || rUIFile == u"modules/scalc/ui/chisquaretestdialog.ui" || rUIFile == u"modules/scalc/ui/colwidthdialog.ui"
core.git: sc/source vcl/jsdialog
sc/source/ui/attrdlg/attrdlg.cxx |7 +-- vcl/jsdialog/enabled.cxx |1 + 2 files changed, 2 insertions(+), 6 deletions(-) New commits: commit eeadb4d703659987c7f54ca296755f6e7e5ffd1e Author: Hubert Figuière AuthorDate: Mon Feb 12 17:32:31 2024 -0500 Commit: Michael Meeks CommitDate: Tue Feb 13 20:58:01 2024 +0100 sc: add back protect cell tab from cell format dialog Also enable the tab in jsdialogs Signed-off-by: Hubert Figuière Change-Id: I2c4eac029568cc0de4be5ebb6b0f4ae47f2da1a1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163263 Tested-by: Jenkins CollaboraOffice Reviewed-by: Michael Meeks (cherry picked from commit eb6674aa7899e7b9542bcc9e1ca5cb5c4dfee843) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163332 Tested-by: Jenkins diff --git a/sc/source/ui/attrdlg/attrdlg.cxx b/sc/source/ui/attrdlg/attrdlg.cxx index faa08bf3ca00..c0653ad4f1d0 100644 --- a/sc/source/ui/attrdlg/attrdlg.cxx +++ b/sc/source/ui/attrdlg/attrdlg.cxx @@ -30,7 +30,6 @@ #include #include #include -#include ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) : SfxTabDialogController(pParent, "modules/scalc/ui/formatcellsdialog.ui", @@ -58,11 +57,7 @@ ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) AddTabPage( "borders", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BORDER ), nullptr ); OSL_ENSURE(pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), "GetTabPageCreatorFunc fail!"); AddTabPage( "background", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), nullptr ); - -if (!comphelper::LibreOfficeKit::isActive()) -AddTabPage( "cellprotection" , ScTabPageProtection::Create, nullptr ); -else -RemoveTabPage( "cellprotection" ); +AddTabPage( "cellprotection" , ScTabPageProtection::Create,nullptr ); } ScAttrDlg::~ScAttrDlg() diff --git a/vcl/jsdialog/enabled.cxx b/vcl/jsdialog/enabled.cxx index 6d5acc3dc538..c7973fad4d57 100644 --- a/vcl/jsdialog/enabled.cxx +++ b/vcl/jsdialog/enabled.cxx @@ -97,6 +97,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool bMobile) // scalc || rUIFile == u"modules/scalc/ui/advancedfilterdialog.ui" || rUIFile == u"modules/scalc/ui/analysisofvariancedialog.ui" +|| rUIFile == u"modules/scalc/ui/cellprotectionpage.ui" || rUIFile == u"modules/scalc/ui/chardialog.ui" || rUIFile == u"modules/scalc/ui/chisquaretestdialog.ui" || rUIFile == u"modules/scalc/ui/colwidthdialog.ui"
core.git: Branch 'distro/collabora/co-23.05' - sc/source vcl/jsdialog
sc/source/ui/attrdlg/attrdlg.cxx |7 +-- vcl/jsdialog/enabled.cxx |1 + 2 files changed, 2 insertions(+), 6 deletions(-) New commits: commit eb6674aa7899e7b9542bcc9e1ca5cb5c4dfee843 Author: Hubert Figuière AuthorDate: Mon Feb 12 17:32:31 2024 -0500 Commit: Michael Meeks CommitDate: Tue Feb 13 10:51:32 2024 +0100 sc: add back protect cell tab from cell format dialog Also enable the tab in jsdialogs Signed-off-by: Hubert Figuière Change-Id: I2c4eac029568cc0de4be5ebb6b0f4ae47f2da1a1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163263 Tested-by: Jenkins CollaboraOffice Reviewed-by: Michael Meeks diff --git a/sc/source/ui/attrdlg/attrdlg.cxx b/sc/source/ui/attrdlg/attrdlg.cxx index 1b2802c32461..3f307adddeb4 100644 --- a/sc/source/ui/attrdlg/attrdlg.cxx +++ b/sc/source/ui/attrdlg/attrdlg.cxx @@ -30,7 +30,6 @@ #include #include #include -#include ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) : SfxTabDialogController(pParent, "modules/scalc/ui/formatcellsdialog.ui", @@ -58,11 +57,7 @@ ScAttrDlg::ScAttrDlg(weld::Window* pParent, const SfxItemSet* pCellAttrs) AddTabPage( "borders", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BORDER ), nullptr ); OSL_ENSURE(pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), "GetTabPageCreatorFunc fail!"); AddTabPage( "background", pFact->GetTabPageCreatorFunc( RID_SVXPAGE_BKG ), nullptr ); - -if (!comphelper::LibreOfficeKit::isActive()) -AddTabPage( "cellprotection" , ScTabPageProtection::Create, nullptr ); -else -RemoveTabPage( "cellprotection" ); +AddTabPage( "cellprotection" , ScTabPageProtection::Create,nullptr ); } ScAttrDlg::~ScAttrDlg() diff --git a/vcl/jsdialog/enabled.cxx b/vcl/jsdialog/enabled.cxx index beb12b5dd081..b04418257bff 100644 --- a/vcl/jsdialog/enabled.cxx +++ b/vcl/jsdialog/enabled.cxx @@ -97,6 +97,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool bMobile) // scalc || rUIFile == u"modules/scalc/ui/advancedfilterdialog.ui" || rUIFile == u"modules/scalc/ui/analysisofvariancedialog.ui" +|| rUIFile == u"modules/scalc/ui/cellprotectionpage.ui" || rUIFile == u"modules/scalc/ui/chardialog.ui" || rUIFile == u"modules/scalc/ui/chisquaretestdialog.ui" || rUIFile == u"modules/scalc/ui/colwidthdialog.ui"
core.git: Branch 'distro/collabora/co-24.04' - vcl/jsdialog
vcl/jsdialog/enabled.cxx |1 + 1 file changed, 1 insertion(+) New commits: commit 5fccf088d19af7af42e99780a9ae8eb780800a2c Author: Hubert Figuière AuthorDate: Fri Feb 9 14:56:49 2024 -0500 Commit: Michael Meeks CommitDate: Sat Feb 10 18:28:54 2024 +0100 vcl: Enable sheet protection dialog Change-Id: Ib8e8209225d027472c1f2eef57839df5784acf30 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163205 Tested-by: Jenkins CollaboraOffice Reviewed-by: Michael Meeks (cherry picked from commit 5c1c842863ee2a63ce69a75ef0820864864905f0) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163175 Tested-by: Michael Meeks diff --git a/vcl/jsdialog/enabled.cxx b/vcl/jsdialog/enabled.cxx index d792128f3360..beb12b5dd081 100644 --- a/vcl/jsdialog/enabled.cxx +++ b/vcl/jsdialog/enabled.cxx @@ -128,6 +128,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool bMobile) || rUIFile == u"modules/scalc/ui/pastespecial.ui" || rUIFile == u"modules/scalc/ui/pivotfielddialog.ui" || rUIFile == u"modules/scalc/ui/pivottablelayoutdialog.ui" +|| rUIFile == u"modules/scalc/ui/protectsheetdlg.ui" || rUIFile == u"modules/scalc/ui/regressiondialog.ui" || rUIFile == u"modules/scalc/ui/rowheightdialog.ui" || rUIFile == u"modules/scalc/ui/samplingdialog.ui"
core.git: vcl/jsdialog
vcl/jsdialog/enabled.cxx |1 + 1 file changed, 1 insertion(+) New commits: commit 46ea6ae814e83b380b5f6bd044119af8247583a8 Author: Hubert Figuière AuthorDate: Fri Feb 9 14:56:49 2024 -0500 Commit: Michael Meeks CommitDate: Sat Feb 10 12:51:50 2024 +0100 vcl: Enable sheet protection dialog Change-Id: Ib8e8209225d027472c1f2eef57839df5784acf30 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163205 Tested-by: Jenkins CollaboraOffice Reviewed-by: Michael Meeks (cherry picked from commit 5c1c842863ee2a63ce69a75ef0820864864905f0) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163174 Tested-by: Jenkins diff --git a/vcl/jsdialog/enabled.cxx b/vcl/jsdialog/enabled.cxx index d792128f3360..beb12b5dd081 100644 --- a/vcl/jsdialog/enabled.cxx +++ b/vcl/jsdialog/enabled.cxx @@ -128,6 +128,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool bMobile) || rUIFile == u"modules/scalc/ui/pastespecial.ui" || rUIFile == u"modules/scalc/ui/pivotfielddialog.ui" || rUIFile == u"modules/scalc/ui/pivottablelayoutdialog.ui" +|| rUIFile == u"modules/scalc/ui/protectsheetdlg.ui" || rUIFile == u"modules/scalc/ui/regressiondialog.ui" || rUIFile == u"modules/scalc/ui/rowheightdialog.ui" || rUIFile == u"modules/scalc/ui/samplingdialog.ui"
core.git: Branch 'distro/collabora/co-23.05' - vcl/jsdialog
vcl/jsdialog/enabled.cxx |1 + 1 file changed, 1 insertion(+) New commits: commit 21bb5813271f294f2de82ebba8ca89d2a7474d5f Author: Hubert Figuière AuthorDate: Fri Feb 9 14:56:49 2024 -0500 Commit: Michael Meeks CommitDate: Sat Feb 10 10:38:28 2024 +0100 vcl: Enable sheet protection dialog Change-Id: Ib8e8209225d027472c1f2eef57839df5784acf30 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163205 Tested-by: Jenkins CollaboraOffice Reviewed-by: Michael Meeks diff --git a/vcl/jsdialog/enabled.cxx b/vcl/jsdialog/enabled.cxx index d792128f3360..beb12b5dd081 100644 --- a/vcl/jsdialog/enabled.cxx +++ b/vcl/jsdialog/enabled.cxx @@ -128,6 +128,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool bMobile) || rUIFile == u"modules/scalc/ui/pastespecial.ui" || rUIFile == u"modules/scalc/ui/pivotfielddialog.ui" || rUIFile == u"modules/scalc/ui/pivottablelayoutdialog.ui" +|| rUIFile == u"modules/scalc/ui/protectsheetdlg.ui" || rUIFile == u"modules/scalc/ui/regressiondialog.ui" || rUIFile == u"modules/scalc/ui/rowheightdialog.ui" || rUIFile == u"modules/scalc/ui/samplingdialog.ui"