XWindow anotherWindow = (XWindow) UnoRuntime.queryInterface(
XWindow.class,aModel2.getCurrentController());
log.println( "creating a new environment for impress view object" );
TestEnvironment tEnv = new TestEnvironment( oObj );
if (anotherWindow != null) {
tEnv.addObjRelation("XWindow.AnotherWindow",anotherWindow);
}
tEnv.addObjRelation("Selections", new Object[] {
shape1, shape2, shape3});
tEnv.addObjRelation("Pages", the_pages);
//Adding ObjRelations for XController
tEnv.addObjRelation("FirstModel", aModel);
tEnv.addObjRelation("XUserInputInterception.XModel", aModel);
XFrame the_frame = the_Desk.getCurrentFrame();
tEnv.addObjRelation("Frame", the_frame);
aModel = (XModel)
UnoRuntime.queryInterface(XModel.class, xSecondDrawDoc);
//Adding ObjRelations for XController
tEnv.addObjRelation("SecondModel", aModel);
XController secondController = aModel.getCurrentController();
tEnv.addObjRelation("SecondController", secondController);
tEnv.addObjRelation("XDispatchProvider.URL",
"slot:27009");
//Adding relations for DrawingDocumentDrawView
XDrawPage new_page = the_pages.insertNewByIndex(1);
tEnv.addObjRelation("DrawPage", new_page);
log.println("Implementation Name: "+utils.getImplName(oObj));
XModifiable modify = (XModifiable)
UnoRuntime.queryInterface(XModifiable.class,xDrawDoc);
tEnv.addObjRelation("Modifiable",modify);
tEnv.addObjRelation("XComponent.DisposeThis", xDrawDoc);
tEnv.addObjRelation("Comparer", new Comparator() {
public int compare(Object o1, Object o2) {
XIndexAccess indAc1 = (XIndexAccess)
UnoRuntime.queryInterface(XIndexAccess.class, o1);
XIndexAccess indAc2 = (XIndexAccess)
UnoRuntime.queryInterface(XIndexAccess.class, o2);