sd/source/ui/view/drviewse.cxx | 4 ++++ 1 file changed, 4 insertions(+)
New commits: commit 95efd80fcae322a14c5051e8a4455b571db926c5 Author: Miklos Vajna <vmik...@collabora.com> AuthorDate: Fri Nov 22 14:10:26 2024 +0100 Commit: Miklos Vajna <vmik...@collabora.com> CommitDate: Mon Nov 25 12:51:56 2024 +0100 cool#10582 sd lok: insert curve shapes directly Dispatching .uno:Line in LOK mode inserts a line shape with defaults at the center of the current slide, but dispatching .uno:Bezier_Unfilled starts an interactive mode where the preview is not exposed in LOK, so looks weird. .uno:Line works because DrawViewShell::FuPermanent() actives the "create directly" flag for SID_DRAW_LINE. Fix the problem by doing the same for SID_DRAW_BEZIER_NOFILL in the next block: we get a curve shape with reasonable defaults with this. If an interactive curve drawing mode is wanted for LOK in the future, then that would be handled outside LOK anyway, with taking the already drawn curve's properties at UNO command dispatch time. Change-Id: I03feded76578575ecfbd4a0d79c7ca1a31e37093 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177250 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmik...@collabora.com> diff --git a/sd/source/ui/view/drviewse.cxx b/sd/source/ui/view/drviewse.cxx index 7cd214e19331..2b354a104556 100644 --- a/sd/source/ui/view/drviewse.cxx +++ b/sd/source/ui/view/drviewse.cxx @@ -468,6 +468,10 @@ void DrawViewShell::FuPermanent(SfxRequest& rReq) case SID_DRAW_BEZIER_FILL: // BASIC case SID_DRAW_BEZIER_NOFILL: // BASIC { + // Direct mode means no interactive drawing, just insert the shape with reasonable + // defaults -- to be consistent with the line insert case above. + bCreateDirectly = comphelper::LibreOfficeKit::isActive(); + SetCurrentFunction( FuConstructBezierPolygon::Create(this, GetActiveWindow(), mpDrawView.get(), GetDoc(), rReq, bPermanent) ); rReq.Done(); }