Package com.extjs.gxt.ui.client.event

Examples of com.extjs.gxt.ui.client.event.ContainerEvent


  protected boolean remove(T item) {
    return remove(item, false);
  }

  protected boolean remove(T component, boolean force) {
    ContainerEvent containerEvent = createContainerEvent(component);
    containerEvent.item = component;
    if (fireEvent(Events.BeforeRemove, containerEvent) || force) {
      ComponentEvent componentEvent = component.createComponentEvent(null);
      if (component.fireEvent(Events.BeforeOrphan, componentEvent) || force) {
        onRemove(component);
View Full Code Here


  protected void adopt(T child) {
    setParent(this, child);
  }

  protected ContainerEvent createContainerEvent(T item) {
    return new ContainerEvent(this, item);
  }
View Full Code Here

      } else {
        c.recalculate();
      }
    }

    ContainerEvent ce = new ContainerEvent(this);
    fireEvent(Events.AfterLayout, ce);
    return true;
  }
View Full Code Here

   *
   * @param item the item to insert
   * @param index the insert location
   */
  protected boolean insert(T item, int index) {
    ContainerEvent containerEvent = createContainerEvent(item);
    containerEvent.index = index;
    if (fireEvent(Events.BeforeAdd, containerEvent)) {
      ComponentEvent componentEvent = item.createComponentEvent(null);
      if (item.fireEvent(Events.BeforeAdopt, componentEvent)) {
        onInsert(item, index);
View Full Code Here

  protected boolean remove(T item) {
    return remove(item, false);
  }

  protected boolean remove(T component, boolean force) {
    ContainerEvent containerEvent = createContainerEvent(component);
    containerEvent.item = component;
    if (fireEvent(Events.BeforeRemove, containerEvent) || force) {
      ComponentEvent componentEvent = component.createComponentEvent(null);
      if (component.fireEvent(Events.BeforeOrphan, componentEvent) || force) {
        onRemove(component);
View Full Code Here

    setParent(this, child);
  }

  @SuppressWarnings("unchecked")
  protected ContainerEvent createContainerEvent(T item) {
    return new ContainerEvent(this, item);
  }
View Full Code Here

   * @param item the item to insert
   * @param index the insert location
   */
  @SuppressWarnings("unchecked")
  protected boolean insert(T item, int index) {
    ContainerEvent containerEvent = createContainerEvent(item);
    containerEvent.setIndex(index);
    if (fireEvent(Events.BeforeAdd, containerEvent)) {
      ComponentEvent componentEvent = item.createComponentEvent(null);
      if (item.fireEvent(Events.BeforeAdopt, componentEvent)) {
        index = adjustIndex(item, index);
        item.removeFromParent();
View Full Code Here

    return remove(item, false);
  }

  @SuppressWarnings("unchecked")
  protected boolean remove(T component, boolean force) {
    ContainerEvent containerEvent = createContainerEvent(component);
    containerEvent.setItem(component);
    containerEvent.setIndex(indexOf(component));
    if (fireEvent(Events.BeforeRemove, containerEvent) || force) {
      ComponentEvent componentEvent = component.createComponentEvent(null);
      if (component.fireEvent(Events.BeforeOrphan, componentEvent) || force) {
        onRemove(component);
View Full Code Here

TOP

Related Classes of com.extjs.gxt.ui.client.event.ContainerEvent

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.