Examples of GuiManager


Examples of de.iritgo.aktario.framework.dataobject.gui.GUIManager

    Rectangle bounds = new Rectangle(400, 300, 800, 600);

    CommandTools.performSimple(new ShowOtherFrame(null, "address.embeddedview", onScreenUniqueId, bounds));

    GUIManager guiManager = (GUIManager) Engine.instance().getManagerRegistry().getManager("GUIManager");

    Controller controller = guiManager.getController(controllerId);

    String editModel = controller.getCommandDescription("EditAkteraObjectCommand").getValue();

    CommandTools
            .performSimple(new ShowWindow("DataObjectGUIPane", onScreenUniqueId, onScreenUniqueId, null),
View Full Code Here

Examples of de.iritgo.aktario.framework.dataobject.gui.GUIManager

   * @param GUIControllerMissingEvent The event.
   */
  public void guiControllerMissingEvent(GUIControllerMissingEvent event)
  {
    String controllerTypeId = event.getControllerTypeId();
    GUIManager guiManager = event.getGUIManager();
    int displayType = event.getDisplayType();
    long userUniqueId = event.getUserUniqueId();

    if (displayType == GUIControllerRequest.QUERY)
    {
      KeelResponse result = getKeelResultList(controllerTypeId, "list", userUniqueId, "", "");

      if (result == null)
      {
        return;
      }

      ResponseElement resultList = result.get("list");

      Controller controller = createController(controllerTypeId);

      WidgetDescription wdGroup = createWidget(controller.getUniqueId(), controllerTypeId, "group", "group",
              false, true);

      controller.addWidgetDescription(wdGroup);

      for (Iterator i = ((ResponseElement) resultList.getAttribute("header")).getAll().iterator(); i.hasNext();)
      {
        ResponseElement field = (ResponseElement) i.next();
        String attributeName = (String) ((Output) field).getContent();
        String fieldLabel = (String) ((Output) field).getAttribute("label");
        boolean hide = ((Output) field).getAttribute("hide") != null ? true : false;

        wdGroup.addWidgetDescription(createWidget(controller.getUniqueId(), fieldLabel, attributeName,
                attributeName, false, hide));
      }

      Input attribute = (Input) result.get("listSearchCategory");

      if (attribute != null)
      {
        controller.addWidgetDescription(createWidget(controller.getUniqueId(), "listSearchCategory",
                "listSearchCategory", "listSearchCategory", false, false));
      }

      // Wird noch ben�tigt um zu �perpr�fen ob �berhaupt die Neuanlage
      // erlaubt ist.
      // Command cmdNew = (Command) resultList.getAttribute ("cmdNew");
      Command cmdEdit = (Command) resultList.getAttribute("cmdEdit");

      if (cmdEdit != null)
      {
        controller.addCommandDescription(createCommand(controller.getUniqueId(), "NewAkteraObjectCommand",
                cmdEdit.getModel(), "new", "new", "des", true, true));

        controller.addCommandDescription(createCommand(controller.getUniqueId(), "EditAkteraObjectCommand",
                cmdEdit.getModel(), "edit", "edit", "des", true, true));
      }

      ResponseElement itemCommands = (ResponseElement) resultList.getAttribute("itemCommands");

      if (itemCommands != null)
      {
        for (Iterator i = itemCommands.getAll().iterator(); i.hasNext();)
        {
          Command command = (Command) i.next();

          if (command.getName().equals("delete"))
          {
            controller.addCommandDescription(createCommand(controller.getUniqueId(),
                    "DeleteAkteraObjectCommand", command.getModel(), "delete", "delete", "des",
                    true, true));
          }
        }
      }

      controller.addCommandDescription(createCommand(controller.getUniqueId(), "CancelAkteraObjectCommand",
              "cancel", "cancel", "cancel", "des", true, true));

      guiManager.addController(controllerTypeId, controller);
    }

    if (displayType == GUIControllerRequest.DATAOBJECT)
    {
      KeelResponse keelForm = getKeelObject(controllerTypeId, "0", userUniqueId);

      Controller controller = createController(controllerTypeId);

      ResponseElement groups = keelForm.get("groups");

      for (Iterator i = groups.getAll().iterator(); i.hasNext();)
      {
        ResponseElement group = (ResponseElement) i.next();

        WidgetDescription wdGroup = createWidget(controller.getUniqueId(), (String) ((Output) group)
                .getContent(), "group", "group", false, true);

        controller.addWidgetDescription(wdGroup);

        for (Iterator j = group.getAll().iterator(); j.hasNext();)
        {
          Input field = (Input) j.next();
          String fieldName = field.getName();
          String fieldLabel = field.getLabel();
          boolean duty = field.getAttribute("duty") == null ? false : true;

          WidgetDescription fieldWidget = createWidget(controller.getUniqueId(), fieldLabel, fieldName,
                  (String) ((Input) field).getAttribute("editor"), duty, true);

          wdGroup.addWidgetDescription(fieldWidget);
        }
      }

      Command cmdSave = (Command) keelForm.get("save");

      if (cmdSave != null)
      {
        controller.addCommandDescription(createCommand(controller.getUniqueId(), "SaveAkteraObjectCommand",
                cmdSave.getModel(), "save", "save", "des", true, true));
      }

      controller.addCommandDescription(createCommand(controller.getUniqueId(), "CancelAkteraObjectCommand",
              "cancel", "cancel", "cancel", "des", true, true));

      guiManager.addController(controllerTypeId, controller);
    }
  }
View Full Code Here

Examples of gui.GUIManager

      nManag = new DOPTNetworkManager(peerIndex);
    if (Main.algorithm.equals(JUPITER_ALGO))
      nManag = new JupiterNetworkManager(peerIndex);

    /* Start and show the gui */
    GUIManager gui = new GUIManager(nManag, peerIndex);
    nManag.connectToGUI(gui);
    nManag.start();

    gui.showGUI();


    /* Check if the test driver needs to run */
    if (args.length > 1 && args[1].equals("test")) {

View Full Code Here

Examples of gui.GUIManager

  public static final String COMMAND_INS = "ins";
  public static final String COMMAND_DEL = "del";


  public static void test(int peerIndex, NetworkManager nm) {
    GUIManager gui = nm.getGUI();

    try {
      BufferedReader buff = new BufferedReader(new FileReader(COMMAND_FILE + peerIndex));

      while(true) {
        String command = buff.readLine();
        System.out.println("["+ Thread.currentThread().getId() + "]" + " Command " + command);
        if (command == null)
          break;

        synchronized (JupiterNetworkManager.lock) {
          if (command.substring(0, 3).equals(COMMAND_INS))
            gui.insertCharInDoc(Integer.parseInt(command.substring(8, 9)) - 1, command.charAt(5));
          if (command.substring(0, 3).equals(COMMAND_DEL))
            gui.deleteCharFromDoc(Integer.parseInt(command.substring(4, 5)) - 1);
        }

        /* Wait before executing next task */
        Thread.sleep(randomWithRange(1, 5) * 100);
      }
 
View Full Code Here

Examples of org.apache.lenya.cms.usecase.gui.GUIManager

        // get <tab/> configuration:
        Configuration tabConfig = config.getChild(ELEMENT_TAB, false);
        if (tabConfig != null) {
            String tabName = tabConfig.getAttribute(ATTRIBUTE_NAME);
            String tabGroup = tabConfig.getAttribute(ATTRIBUTE_GROUP);
            GUIManager guiMgr = null;
            try {
                guiMgr = (GUIManager) this.manager.lookup(GUIManager.ROLE);
                this.tab = guiMgr.getTab(tabGroup, tabName);
            } catch (ServiceException e) {
                throw new RuntimeException(e);
            } finally {
                if (guiMgr != null) {
                    this.manager.release(guiMgr);
View Full Code Here

Examples of org.apache.lenya.cms.usecase.gui.GUIManager

     */
    public Tab[] getTabsInGroup() {
        if (getTab() == null) {
            return null;
        } else {
            GUIManager guiMgr = null;
            try {
                guiMgr = (GUIManager) this.manager.lookup(GUIManager.ROLE);
                return guiMgr.getActiveTabs(getTab().getGroup());
            } catch (ServiceException e) {
                throw new RuntimeException(e);
            } finally {
                if (guiMgr != null) {
                    this.manager.release(guiMgr);
View Full Code Here

Examples of pu.web.client.gui.GUIManager

  }
 
  static PU_Login login;
  public static void resourcesLoaded()
  {
    PUWeb.mGui = new GUIManager(0, 0, PU_Engine.SCREEN_WIDTH, PU_Engine.SCREEN_HEIGHT, mResources.getFont(Fonts.FONT_ARIALBLK_BOLD_14));
    PUWeb.mEvents = new PU_Events(Document.get().getElementById("gwtGL"), PUWeb.mGui);
   
    mGame.initPanels();
   
    mGame.setState(PU_Game.GAMESTATE_LOGIN);
View Full Code Here

Examples of ui.GuiManager

    // creating and showing this application's GUI.
    javax.swing.SwingUtilities.invokeLater(new Runnable()
    {
      public void run()
      {
        guiManager = new GuiManager();
        statusManager = guiManager.getStatusManager();
      }

    });
  }
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.