summaryrefslogtreecommitdiff
path: root/testautomation/graphics/tools
diff options
context:
space:
mode:
authorJoerg Skottke [jsk] <jsk@openoffice.org>2010-05-25 14:27:34 +0200
committerJoerg Skottke [jsk] <jsk@openoffice.org>2010-05-25 14:27:34 +0200
commite0ffe123aa0ec3e555385d970dfde4534308878c (patch)
tree235c0a51bde82fc8ac9624116b3fa73c0d24fe80 /testautomation/graphics/tools
parent09d6255e020853d1dc52fa2cf07e4cc8cf736930 (diff)
vitomation01: #i109696 - Misc fixes to code logic
Diffstat (limited to 'testautomation/graphics/tools')
-rwxr-xr-x[-rw-r--r--]testautomation/graphics/tools/id_tools.inc95
-rwxr-xr-x[-rw-r--r--]testautomation/graphics/tools/id_tools_2.inc52
2 files changed, 29 insertions, 118 deletions
diff --git a/testautomation/graphics/tools/id_tools.inc b/testautomation/graphics/tools/id_tools.inc
index 117fa47725e2..9cd7bacdfb16 100644..100755
--- a/testautomation/graphics/tools/id_tools.inc
+++ b/testautomation/graphics/tools/id_tools.inc
@@ -31,45 +31,6 @@
'*
'\******************************************************************************
-'Functions:
-' #1 hFindSpellHypLanguage
-' #1 GetDecimalSeperator
-' #1 LiberalMeasurement
-' #1 GetMeasUnit
-' #1 StrToDouble
-' #1 fGetPositionX
-' #1 setStartCurrentPage
-' #1 fIsDocumentWritable
-' #1 fIsDocumentWritable
-' #1 fGetSizeXY
-' #1 hCallExport
-' #1 checkexppdfwaitmax10sec
-' #1 fCompareTwoValues
-' #1 fConvertBackslashToSlash
-' #1 hScreenFontAntialiasing
-' #1 fSaveLoadAllFormats
-' #1 setCharacterLanguage
-' #1 toggleGermanSpellchecking
-' #1 sAnalyseContextMenu
-' #1 sLongToBinary
-' #1 sBinaryToLong
-' #1 fGetIntoDictionary
-' #1 hSelectInList
-' #1 hWalkTheStyles2
-' #1 fGetSlideNumber
-' #1 fGetSlideCount
-' #1 fGetSlideName
-' #1 fGetSetPageBackground
-' #1 CreateTextSetEffectAndAngle
-' #1 fGetPresentationStyle
-' #1 hPrepareSearchBUG
-' #1 makeNumOutOfText
-' #1 wIgnorierenlisteLoeschen
-' #1 optionstest
-' #1 optionstest2
-
-
-'\*****************************************************************
function hFindSpellHypLanguage (optional sBooks()) as string
printlog "print all available languages that have a language module"
dim iListLength as integer
@@ -98,8 +59,7 @@ function hFindSpellHypLanguage (optional sBooks()) as string
ModuleBearbeiten.Close
Kontext "ExtrasOptionenDlg"
printlog "close dialog 'Options - '"
- ExtrasOptionenDlg.OK
- sleep 1
+ hCloseDialog( ExtrasOptionenDlg, "ok" )
endif
end function
@@ -235,19 +195,21 @@ function fGetPositionX () as string
fGetPositionX = ""
try
- ContextPositionAndSize
+ ContextPositionAndSize
+
+ kontext
+ active.SetPage TabPositionAndSize
+ kontext "TabPositionAndSize"
+ if ( TabPositionAndSize.exists( 5 ) ) then
+ fGetPositionX = PositionX.GetText()
+ TabPositionAndSize.OK()
+ else
+ warnlog( "Couldn't switch to <TabPositionAndSize>" )
+ endif
catch
- warnlog "couldn't call 'ContextPositionAndSize' no object selected ?"
+ warnlog "couldn't call 'ContextPositionAndSize' no object selected ?"
endcatch
- kontext
- active.SetPage TabPositionAndSize
- kontext "TabPositionAndSize"
- if TabPositionAndSize.exists (5) then
- fGetPositionX = PositionX.GetText
- TabPositionAndSize.OK
- else
- warnlog "Couldn't switch tab page :-( "
- endif
+
end function
'-------------------------------------------------------------------------------
@@ -266,7 +228,7 @@ function setStartCurrentPage(optional bState as boolean) as boolean
endif
Kontext "ExtrasOptionenDlg"
printlog "+ close dialog 'Options - Presenation - General' with OK "
- ExtrasOptionenDlg.OK
+ hCloseDialog( ExtrasOptionenDlg, "ok" )
end function
'-------------------------------------------------------------------------------
@@ -278,11 +240,11 @@ function fIsDocumentWritable() as boolean
printlog " true if the document is writeable otherwise false"
Kontext "Standardbar"
- if Bearbeiten.GetState(2) <> 1 then
- fIsDocumentWritable = false
- else
- fIsDocumentWritable = true
- endif
+ if Bearbeiten.GetState( 2 ) <> 1 then
+ fIsDocumentWritable = false
+ else
+ fIsDocumentWritable = true
+ endif
end function
@@ -295,17 +257,17 @@ function fMakeDocumentWritable() as boolean
printlog " true if the document can make writeable otherwise false"
Kontext "Standardbar"
- sleep (1)
+ sleep ( 1 )
if Bearbeiten.GetState(2) <> 1 then
Bearbeiten.Click
Kontext
- if Active.Exists(1) then
- Active.Yes
- fMakeDocumentWritable = true
- else
- warnlog "No messagebox after making document editable?"
- fMakeDocumentWritable = false
- endif
+ if Active.Exists(1) then
+ Active.Yes
+ fMakeDocumentWritable = true
+ else
+ warnlog "No messagebox after making document editable?"
+ fMakeDocumentWritable = false
+ endif
else
printlog "Document is allready writable."
fMakeDocumentWritable = true
@@ -323,6 +285,7 @@ function fGetSizeXY (sX as string, sY as string, bGet as boolean) as Boolean
bReturn = True
try
ContextPositionAndSize
+ exit function
catch
warnlog "couldn't call 'ContextPositionAndSize' no object selected ?"
endcatch
diff --git a/testautomation/graphics/tools/id_tools_2.inc b/testautomation/graphics/tools/id_tools_2.inc
index 6cf18494915d..3604875088a8 100644..100755
--- a/testautomation/graphics/tools/id_tools_2.inc
+++ b/testautomation/graphics/tools/id_tools_2.inc
@@ -31,58 +31,6 @@
'*
'\******************************************************************************
-'Subs:
-' #1 sFileExport
-' #1 callAutocorrectOptions
-' #1 sCheckCheck
-' #1 sCheckUnderlined
-' #1 sCheckSupperscript
-' #1 sCheckDash
-' #1 sPrintCheckOrder
-' #1 writertest
-' #1 calctest
-' #1 tClipboardFromDrawTest
-' #1 Select_Copy
-' #1 SaveMeasurementSetFirst
-' #1 MeasurementSetFirst
-' #1 ResetMeasurement
-' #1 SetKontextApplication
-' #1 hSetSpellHypLanguage
-' #1 hTBOtypeInDoc
-' #1 Position_Vergleichen
-' #1 g_demoguide
-' #1 sFormatTextDrawAnimation
-' #1 mouseclickinpresentation
-' #1 im_002_
-' #1 im_003_
-' #1 im_004_
-' #1 im_005_
-' #1 im_007_
-' #1 im_011_
-' #1 D_002_
-' #1 D_003_
-' #1 D_005_
-' #1 d_007
-' #1 hOpenGallery
-' #1 LoadGraphic
-' #1 CheckGraphic
-' #1 GetOnlyGraphics
-' #1 tSettingsToCM
-' #1 tResetSettings
-' #1 id_001
-' #1 id_002
-' #1 id_003
-' #1 id_004
-' #1 id_005
-' #1 id_006
-' #1 id_007
-' #1 id_008
-' #1 id_009
-' #1 id_011
-' #1 hWalkTheStyles
-
-'\*****************************************************************
-
sub sFileExport
printlog " just exporting is done in qatesttool/framework/first test: 'tGraphicExport' but there is no loading, "