the_frame2.setName("DatasourceBrowser");
XInterface oObj = null;
final XSelectionSupplier xSelect = (XSelectionSupplier) UnoRuntime.queryInterface(
XSelectionSupplier.class, the_frame2.getController());
PropertyValue[] params = new PropertyValue[]{new PropertyValue(), new PropertyValue(), new PropertyValue()};
params[0].Name = "DataSourceName";
params[0].Value = "Bibliography";
params[1].Name = "CommandType";
params[1].Value = new Integer(com.sun.star.sdb.CommandType.TABLE);
params[2].Name = "Command";
params[2].Value = "biblio";
final PropertyValue[] fParams = params;
shortWait();
try {
oObj = (XInterface) ((XMultiServiceFactory) tParam.getMSF()).createInstance("com.sun.star.awt.Toolkit");
} catch (com.sun.star.uno.Exception e) {
log.println("Couldn't get toolkit");
e.printStackTrace(log);
throw new StatusException("Couldn't get toolkit", e);
}
XExtendedToolkit tk = (XExtendedToolkit) UnoRuntime.queryInterface(XExtendedToolkit.class, oObj);
AccessibilityTools at = new AccessibilityTools();
XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class, tk.getActiveTopWindow());
XAccessible xRoot = at.getAccessibleObject(xWindow);
at.printAccessibleTree(log, xRoot, tParam.getBool(util.PropertyName.DEBUG_IS_ACTIVE));
oObj = at.getAccessibleObjectForRole(xRoot, AccessibleRole.PANEL, "", "AccessibleBrowseBox");
log.println("ImplementationName: " + util.utils.getImplName(oObj));
TestEnvironment tEnv = new TestEnvironment(oObj);
tEnv.addObjRelation("EventProducer",
new ifc.accessibility._XAccessibleEventBroadcaster.EventProducer() {
public void fireEvent() {
try {
xSelect.select(fParams);
} catch (com.sun.star.uno.Exception e) {
e.printStackTrace();
}
}
});