diff options
Diffstat (limited to 'qadevOOo/tests/java/mod/_toolkit/UnoControlDialogModel.java')
-rw-r--r-- | qadevOOo/tests/java/mod/_toolkit/UnoControlDialogModel.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/qadevOOo/tests/java/mod/_toolkit/UnoControlDialogModel.java b/qadevOOo/tests/java/mod/_toolkit/UnoControlDialogModel.java index f254bf745f33..1d8f50e365f8 100644 --- a/qadevOOo/tests/java/mod/_toolkit/UnoControlDialogModel.java +++ b/qadevOOo/tests/java/mod/_toolkit/UnoControlDialogModel.java @@ -84,7 +84,7 @@ public class UnoControlDialogModel extends TestCase { "com.sun.star.awt.UnoControlDialogModel"); // create the dialog model and set the properties - XPropertySet xPSetDialog = (XPropertySet) UnoRuntime.queryInterface( + XPropertySet xPSetDialog = UnoRuntime.queryInterface( XPropertySet.class, dialogModel); xPSetDialog.setPropertyValue("PositionX", new Integer(100)); xPSetDialog.setPropertyValue("PositionY", new Integer(100)); @@ -102,7 +102,7 @@ public class UnoControlDialogModel extends TestCase { // create the button model and set the properties Object buttonModel = xMultiServiceFactory.createInstance( "com.sun.star.awt.UnoControlButtonModel"); - XPropertySet xPSetButton = (XPropertySet) UnoRuntime.queryInterface( + XPropertySet xPSetButton = UnoRuntime.queryInterface( XPropertySet.class, buttonModel); xPSetButton.setPropertyValue("PositionX", new Integer(50)); xPSetButton.setPropertyValue("PositionY", new Integer(30)); @@ -115,7 +115,7 @@ public class UnoControlDialogModel extends TestCase { // create the label model and set the properties Object labelModel = xMultiServiceFactory.createInstance( "com.sun.star.awt.UnoControlFixedTextModel"); - XPropertySet xPSetLabel = (XPropertySet) UnoRuntime.queryInterface( + XPropertySet xPSetLabel = UnoRuntime.queryInterface( XPropertySet.class, labelModel); xPSetLabel.setPropertyValue("PositionX", new Integer(40)); xPSetLabel.setPropertyValue("PositionY", new Integer(60)); @@ -126,7 +126,7 @@ public class UnoControlDialogModel extends TestCase { xPSetLabel.setPropertyValue("Label", _labelPrefix); // insert the control models into the dialog model - XNameContainer xNameCont = (XNameContainer) UnoRuntime.queryInterface( + XNameContainer xNameCont = UnoRuntime.queryInterface( XNameContainer.class, dialogModel); xNameCont.insertByName(_buttonName, buttonModel); |