Examples of XulDomContainer


Examples of org.pentaho.ui.xul.XulDomContainer

        if (connectionDialog == null) {
            dbMeta = getDbMeta(null);
            connectionDialogController = new DataHandler();
            connectionDialogController.setName("dataHandler");

            XulDomContainer container = null;

            try {
                XulLoader loader = new SwingXulLoader();
                container = loader.loadXul(
                        DatabaseConnectionDialog.DIALOG_DEFINITION_FILE,
                        Messages.getBundle());
            } catch (XulException e) {
                throw new RuntimeException("Xul failed to initialize", e);
            }
            container.addEventHandler(connectionDialogController);
            connectionDialogController.loadConnectionData();
            connectionDialogController.setData(dbMeta);
            connectionDialog = (XulDialog) container.getDocumentRoot()
                    .getRootElement();
        }

        connectionDialog.show();
View Full Code Here

Examples of org.pentaho.ui.xul.XulDomContainer

    if (parent != null)
    {
      loader.setOuterContext(parent);
    }
    final XulDomContainer container = loader.loadXul(DIALOG_DEFINITION_FILE, Messages.getBundle());
    container.getDocumentRoot().addOverlay(OVERLAY_DEFINITION_FILE);
    container.initialize();

    handler = new XulDatabaseHandler();
    container.addEventHandler(handler);   //$NON-NLS-1$

    final Document documentRoot = container.getDocumentRoot();
    final XulComponent root = documentRoot.getRootElement();

    if (root instanceof XulDialog)
    {
      dialog = (XulDialog) root;
View Full Code Here

Examples of org.pentaho.ui.xul.XulDomContainer

        final Map.Entry<String, String> entry = entryIterator.next();
        loader.register(entry.getKey(), entry.getValue());
      }
    }

    final XulDomContainer container = loader.loadXul(DIALOG_DEFINITION_FILE);
    final Document documentRoot = container.getDocumentRoot();

    for (int i = 0; i < plugins.length; i++)
    {
      final ReportDesignerUiPlugin plugin = plugins[i];
      final String[] strings = plugin.getOverlaySources();
      for (int j = 0; j < strings.length; j++)
      {
        final String source = strings[j];
        documentRoot.addOverlay(source);
      }
    }
    for (int i = 0; i < plugins.length; i++)
    {
      final ReportDesignerUiPlugin plugin = plugins[i];
      final XulEventHandler[] xulEventHandlers = plugin.createEventHandlers();
      for (int j = 0; j < xulEventHandlers.length; j++)
      {
        final XulEventHandler eventHandler = xulEventHandlers[j];
        container.addEventHandler(eventHandler);
      }
    }

    container.initialize();

    final XulComponent root = documentRoot.getRootElement();
    if (root instanceof XulWindow)
    {
      window = (XulWindow) root;
View Full Code Here

Examples of org.pentaho.ui.xul.XulDomContainer

      final ResourceManager resourceManager = new ResourceManager();
      resourceManager.registerDefaults();
      final Resource resource = resourceManager.createDirectly(xulDocument, Document.class);
      final Document document = (Document) resource.getResource();
      final DOMReader domReader = new DOMReader();
      final XulDomContainer container = loader.loadXulFragment(domReader.read(document));


      // Create our main Controller
      final String className = configuration.getConfigProperty
          ("org.pentaho.reporting.designer.core.editor.drilldown.xul-controller." + configurationTag, // NON-NLS
              DefaultXulDrillDownController.class.getName());
      controller = (XulDrillDownController)
          ObjectUtilities.loadAndInstantiate(className, XulDrillDownController.class, XulDrillDownController.class);
      if (controller != null)
      {
        controller.setName("controller"); // NON-NLS
        controller.setXulDomContainer(container);
        controller.init(reportDesignerContext, model);
        container.addEventHandler(controller);
      }

      // Start it up!
      final XulRunner runner = new SwingXulRunner();
      runner.addContainer(container);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.