wizards/com/sun/star/wizards/document/FormHandler.java | 13 +++++++++++++ 1 file changed, 13 insertions(+)
New commits: commit 09e623b8c8948f40e7110191caccc84117f5ae7d Author: Lionel Elie Mamane <lio...@mamane.lu> Date: Fri Dec 19 22:59:15 2014 +0100 detect groupShapes (TimestampFields) in forms, too as a consequence, successfully delete them Change-Id: I5dd7b329708dd13f8bfe4a38974c5f6f1202b392 Reviewed-on: https://gerrit.libreoffice.org/13556 Reviewed-by: David Tardon <dtar...@redhat.com> Tested-by: David Tardon <dtar...@redhat.com> diff --git a/wizards/com/sun/star/wizards/document/FormHandler.java b/wizards/com/sun/star/wizards/document/FormHandler.java index b07f45a..57dd83d 100644 --- a/wizards/com/sun/star/wizards/document/FormHandler.java +++ b/wizards/com/sun/star/wizards/document/FormHandler.java @@ -307,6 +307,19 @@ public class FormHandler public boolean belongsToForm(Object _oDrawPageElement, String _FormName) { XServiceInfo xServiceInfo = UnoRuntime.queryInterface(XServiceInfo.class, _oDrawPageElement); + while (xServiceInfo.supportsService("com.sun.star.drawing.GroupShape")) + { + XShapes xShapes = UnoRuntime.queryInterface(XShapes.class, _oDrawPageElement); + try + { + _oDrawPageElement = xShapes.getByIndex(0); + xServiceInfo = UnoRuntime.queryInterface(XServiceInfo.class, _oDrawPageElement); + } + catch(final com.sun.star.uno.Exception e) + { + return false; + } + } if (xServiceInfo.supportsService("com.sun.star.drawing.ControlShape")) { XControlShape xControlShape = UnoRuntime.queryInterface(XControlShape.class, _oDrawPageElement); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits