diff options
Diffstat (limited to 'testautomation/global/tools/includes/required/t_doc1.inc')
-rw-r--r--[-rwxr-xr-x] | testautomation/global/tools/includes/required/t_doc1.inc | 82 |
1 files changed, 32 insertions, 50 deletions
diff --git a/testautomation/global/tools/includes/required/t_doc1.inc b/testautomation/global/tools/includes/required/t_doc1.inc index 77039370315c..ed74336dfc72 100755..100644 --- a/testautomation/global/tools/includes/required/t_doc1.inc +++ b/testautomation/global/tools/includes/required/t_doc1.inc @@ -1,28 +1,28 @@ 'encoding UTF-8 Do not remove or change this line! '************************************************************************** - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * <http://www.openoffice.org/license.html> - * for a copy of the LGPLv3 License. - * +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' '/************************************************************************ '* '* owner : thorsten.bosbach@sun.com @@ -224,33 +224,12 @@ end function ' '------------------------------------------------------------------------------- ' -sub hCloseDocument ( optional bANewDoc ) - '/// hCloseDocument : close a document without saving ///' - '///+ all documents will be closed without saving ///' - Dim sFehler$ - - if IsMissing ( bANewDoc ) <> TRUE then - if bANewDoc = TRUE then - gNoNewDoc = FALSE - else - gNoNewDoc = TRUE - end if - end if +function hCloseDocument() - ' if no new document was created, it isn't closed - if gNoNewDoc = TRUE then - exit sub - end if - - Sleep 3 - try - FileClose - catch - Exceptlog - exit sub - endcatch + '/// Trigger FileClose slot' + hUseAsyncSlot( "FileClose") - Sleep 1 + '/// Accept to lose changes' Kontext "Active" if Active.Exists(2) then try @@ -259,8 +238,11 @@ sub hCloseDocument ( optional bANewDoc ) Active.Click ( 202 ) endcatch end if - Sleep (2) -end sub + + '/// Wait for FileClose to complete' + WaitSlot( 2000 ) + +end function ' '------------------------------------------------------------------------------- ' |