Package org.eclipse.wb.internal.core.model.description

Examples of org.eclipse.wb.internal.core.model.description.ComponentDescription


  //
  // Constructor
  //
  ////////////////////////////////////////////////////////////////////////////
  public DefaultLayoutInfo(AstEditor editor, CreationSupport creationSupport) throws Exception {
    super(editor, new ComponentDescription(null), creationSupport);
    ObjectInfoUtils.setNewId(this);
    getDescription().setToolkit(ToolkitProvider.DESCRIPTION);
  }
View Full Code Here


    List<LayoutDescription> descriptions =
        LayoutDescriptionHelper.get(GwtExtToolkitDescription.INSTANCE);
    for (final LayoutDescription description : descriptions) {
      final Class<?> layoutClass = editorLoader.loadClass(description.getLayoutClassName());
      final String creationId = description.getCreationId();
      ComponentDescription layoutComponentDescription =
          ComponentDescriptionHelper.getDescription(editor, layoutClass);
      ObjectInfoAction action = new ObjectInfoAction(this) {
        @Override
        protected void runEx() throws Exception {
          description.ensureLibraries(editor.getJavaProject());
          LayoutInfo layout =
              (LayoutInfo) JavaInfoUtils.createJavaInfo(
                  getEditor(),
                  layoutClass,
                  new ConstructorCreationSupport(creationId, true));
          setLayout(layout);
        }
      };
      action.setText(description.getName());
      action.setImageDescriptor(new ImageImageDescriptor(layoutComponentDescription.getIcon()));
      layoutsManager.add(action);
    }
  }
View Full Code Here

    List<LayoutDescription> descriptions =
        LayoutDescriptionHelper.get(ExtGwtToolkitDescription.INSTANCE);
    for (final LayoutDescription description : descriptions) {
      final Class<?> layoutClass = editorLoader.loadClass(description.getLayoutClassName());
      final String creationId = description.getCreationId();
      ComponentDescription layoutComponentDescription =
          ComponentDescriptionHelper.getDescription(editor, layoutClass);
      ObjectInfoAction action = new ObjectInfoAction(this) {
        @Override
        protected void runEx() throws Exception {
          description.ensureLibraries(editor.getJavaProject());
          LayoutInfo layout =
              (LayoutInfo) JavaInfoUtils.createJavaInfo(
                  getEditor(),
                  layoutClass,
                  new ConstructorCreationSupport(creationId, true));
          setLayout(layout);
        }
      };
      action.setText(description.getName());
      action.setImageDescriptor(new ImageImageDescriptor(layoutComponentDescription.getIcon()));
      layoutsManager.add(action);
    }
  }
View Full Code Here

  }

  private List<EventDescription> getEventDescriptions(ComponentInfo component) {
    List<EventDescription> descriptions = Lists.newArrayList();
    // fill
    ComponentDescription componentDescription = component.getDescription();
    Class<?> componentClass = componentDescription.getComponentClass();
    while (componentClass != null) {
      String paramaterName = "GXT.untyped.events: " + componentClass.getName();
      String parameter = JavaInfoUtils.getParameter(component, paramaterName);
      if (parameter != null) {
        String[] lines = StringUtils.split(parameter, "\n");
View Full Code Here

            CodeUtils.getShortClass(clazz.getName()));
    // script
    String script;
    {
      AstEditor editor = EditorState.getActiveJavaInfo().getEditor();
      ComponentDescription description = ComponentDescriptionHelper.getDescription(editor, clazz);
      script = description.getParameter("placeholderScript");
    }
    // variables
    Map<String, Object> variables = Maps.newTreeMap();
    variables.put("clazz", clazz);
    variables.put("message", message);
View Full Code Here

  //
  // Constructor
  //
  ////////////////////////////////////////////////////////////////////////////
  public DefaultLayoutInfo(AstEditor editor, CreationSupport creationSupport) throws Exception {
    super(editor, new ComponentDescription(null), creationSupport);
    ObjectInfoUtils.setNewId(this);
    getDescription().setToolkit(ToolkitProvider.DESCRIPTION);
  }
View Full Code Here

  /**
   * Checks that GWT-Ext component has <code>"flowContainer"</code> parameter.
   */
  private void check_is_flowContainer(String className) throws Exception {
    ComponentDescription description =
        ComponentDescriptionHelper.getDescription(m_lastEditor, className);
    assertEquals("true", description.getParameter("flowContainer"));
  }
View Full Code Here

  /**
   * Checks that GWT component has <code>"simpleContainer"</code> parameter.
   */
  private void check_is_simpleContainer(String className) throws Exception {
    ComponentDescription description =
        ComponentDescriptionHelper.getDescription(m_lastEditor, className);
    assertEquals("true", description.getParameter("simpleContainer"));
  }
View Full Code Here

  /**
   * Checks that GWT component has <code>"flowContainer"</code> parameter.
   */
  private void check_is_flowContainer(String className, boolean horizontal) throws Exception {
    ComponentDescription description =
        ComponentDescriptionHelper.getDescription(m_lastEditor, className);
    assertEquals("true", description.getParameter("flowContainer"));
    assertEquals(
        horizontal,
        Boolean.parseBoolean(description.getParameter("flowContainer.horizontal")));
  }
View Full Code Here

TOP

Related Classes of org.eclipse.wb.internal.core.model.description.ComponentDescription

Copyright © 2018 www.massapicom. 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.