summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorFrank Schoenheit [fs] <frank.schoenheit@sun.com>2010-10-19 13:02:51 +0200
committerFrank Schoenheit [fs] <frank.schoenheit@sun.com>2010-10-19 13:02:51 +0200
commit80b680882f93882ed5016921cfab23fad666b7ba (patch)
tree6623e6162ddf0aa055c047093d6eb3966a332bcc /test
parent4a8b1355d87b3e3457b61c050192557f742f6eb6 (diff)
undoapi: added PRESENTATION/FORMULAR doc types
Diffstat (limited to 'test')
-rw-r--r--test/source/java/org/openoffice/test/tools/DocumentType.java4
-rw-r--r--test/source/java/org/openoffice/test/tools/OfficeDocument.java8
2 files changed, 12 insertions, 0 deletions
diff --git a/test/source/java/org/openoffice/test/tools/DocumentType.java b/test/source/java/org/openoffice/test/tools/DocumentType.java
index cccf803cec81..bf310c5ed0fa 100644
--- a/test/source/java/org/openoffice/test/tools/DocumentType.java
+++ b/test/source/java/org/openoffice/test/tools/DocumentType.java
@@ -44,6 +44,8 @@ public class DocumentType extends com.sun.star.uno.Enum
public static final DocumentType CALC = new DocumentType(1);
public static final DocumentType DRAWING = new DocumentType(2);
public static final DocumentType XMLFORM = new DocumentType(3);
+ public static final DocumentType PRESENTATION = new DocumentType(4);
+ public static final DocumentType FORMULA = new DocumentType(5);
public static final DocumentType UNKNOWN = new DocumentType(-1);
public static DocumentType fromInt(int value)
@@ -54,6 +56,8 @@ public class DocumentType extends com.sun.star.uno.Enum
case 1: return CALC;
case 2: return DRAWING;
case 3: return XMLFORM;
+ case 4: return PRESENTATION;
+ case 5: return FORMULA;
default: return UNKNOWN;
}
}
diff --git a/test/source/java/org/openoffice/test/tools/OfficeDocument.java b/test/source/java/org/openoffice/test/tools/OfficeDocument.java
index 2a051fddad46..bfb76a347e1c 100644
--- a/test/source/java/org/openoffice/test/tools/OfficeDocument.java
+++ b/test/source/java/org/openoffice/test/tools/OfficeDocument.java
@@ -226,6 +226,10 @@ public class OfficeDocument
return "private:factory/sdraw";
if ( eType == DocumentType.XMLFORM )
return "private:factory/swriter?slot=21053";
+ if ( eType == DocumentType.PRESENTATION )
+ return "private:factory/simpress";
+ if ( eType == DocumentType.FORMULA )
+ return "private:factory/smath";
return "private:factory/swriter";
}
@@ -242,6 +246,10 @@ public class OfficeDocument
return DocumentType.CALC;
else if ( xSI.supportsService( "com.sun.star.drawing.DrawingDocument" ) )
return DocumentType.DRAWING;
+ else if ( xSI.supportsService( "com.sun.star.presentation.PresentationDocument" ) )
+ return DocumentType.PRESENTATION;
+ else if ( xSI.supportsService( "com.sun.star.formula.FormulaProperties" ) )
+ return DocumentType.FORMULA;
return DocumentType.UNKNOWN;
}