Examples of EditorEvent


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

      RootPanel.get().add(this);
    } else {
      ComponentHelper.doAttach(this);
    }

    EditorEvent e = new EditorEvent(this);
    e.setBoundEl(boundEl);
    e.setValue(v);
    if (!fireEvent(Events.BeforeStartEdit, e)) {
      return;
    }

    // since field may be reused, store may be filtered
    if (field instanceof ComboBox) {
      ((ComboBox) field).getStore().clearFilters();
    }

    startValue = preProcessValue(value);
    field.setValue(startValue);

    editing = true;

    show();
    doAutoSize();
    el().alignTo(boundEl.dom, alignment, new int[] {0, -1});

    field.focus();

    e.setValue(startValue);
    fireEvent(Events.StartEdit, e);
  }
View Full Code Here

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

    fireEvent(Events.StartEdit, e);
  }

  protected void cancelEdit(boolean remainVisible, boolean revertInvalid) {
    Object v = field.getValue();
    EditorEvent e = new EditorEvent(this);
    e.setValue(v);
    e.setStartValue(startValue);
    if (editing && fireEvent(Events.BeforeCancelEdit, e)) {
      editing = false;
      if (revertInvalid) {
        setValue(startValue);
      }
View Full Code Here

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

      return;
    }

    Object v = getValue();

    EditorEvent e = new EditorEvent(this);
    e.setValue(postProcessValue(v));
    e.setStartValue(startValue);

    if (fireEvent(Events.BeforeComplete, e)) {
      editing = false;
      if (updateEl && boundEl != null) {
        boundEl.setInnerHtml(v.toString());
View Full Code Here

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

    if (editorListener == null) {
      editorListener = new Listener<DomEvent>() {
        public void handleEvent(DomEvent e) {
          if (e.getType() == Events.Complete) {
            EditorEvent ee = (EditorEvent) e;
            onEditComplete((CellEditor) ee.getEditor(), ee.getValue(), ee.getStartValue());
          } else if (e.getType() == Events.SpecialKey) {
            grid.getSelectionModel().onEditorKey(e);
          } else if (e.getType() == Events.CancelEdit) {
            EditorEvent ee = (EditorEvent) e;
            onEditCancel((CellEditor) ee.getEditor(), ee.getValue(), ee.getStartValue());
          }
        }
      };
    }
View Full Code Here

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

      RootPanel.get().add(this);
    } else {
      ComponentHelper.doAttach(this);
    }

    EditorEvent e = new EditorEvent(this);
    e.setBoundEl(boundEl);
    e.setValue(v);
    if (!fireEvent(Events.BeforeStartEdit, e)) {
      return;
    }

    // since field may be reused, store may be filtered
    if (field instanceof ComboBox) {
      ((ComboBox) field).getStore().clearFilters();
    }

    startValue = preProcessValue(value);
    field.setValue(startValue);

    editing = true;

    show();
    doAutoSize();
    el().alignTo(boundEl.dom, alignment, new int[] {0, -1});

    field.focus();

    e.setValue(startValue);
    fireEvent(Events.StartEdit, e);
  }
View Full Code Here

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

    fireEvent(Events.StartEdit, e);
  }

  protected void cancelEdit(boolean remainVisible, boolean revertInvalid) {
    Object v = field.getValue();
    EditorEvent e = new EditorEvent(this);
    e.setValue(v);
    e.setStartValue(startValue);
    if (editing && fireEvent(Events.BeforeCancelEdit, e)) {
      editing = false;
      if (revertInvalid) {
        setValue(startValue);
      }
View Full Code Here

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

      return;
    }

    Object v = getValue();

    EditorEvent e = new EditorEvent(this);
    e.setValue(postProcessValue(v));
    e.setStartValue(startValue);

    if (fireEvent(Events.BeforeComplete, e)) {
      editing = false;
      if (updateEl && boundEl != null) {
        boundEl.setInnerHtml(v.toString());
View Full Code Here

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

    if (editorListener == null) {
      editorListener = new Listener<DomEvent>() {
        public void handleEvent(DomEvent e) {
          if (e.getType() == Events.Complete) {
            EditorEvent ee = (EditorEvent) e;
            onEditComplete((CellEditor) ee.getEditor(), ee.getValue(), ee.getStartValue());
          } else if (e.getType() == Events.SpecialKey) {
            grid.getSelectionModel().onEditorKey(e);
          } else if (e.getType() == Events.CancelEdit) {
            EditorEvent ee = (EditorEvent) e;
            onEditCancel((CellEditor) ee.getEditor(), ee.getValue(), ee.getStartValue());
          }
        }
      };
    }
View Full Code Here

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

      RootPanel.get().add(this);
    } else {
      ComponentHelper.doAttach(this);
    }

    EditorEvent e = new EditorEvent(this);
    e.setBoundEl(boundEl);
    e.setValue(v);
    if (!fireEvent(Events.BeforeStartEdit, e)) {
      return;
    }

    // since field may be reused, store may be filtered
    if (field instanceof ComboBox) {
      ((ComboBox) field).getStore().clearFilters();
    }

    startValue = preProcessValue(value);
    field.setValue(startValue);

    editing = true;

    show();
    doAutoSize();
    el().alignTo(boundEl.dom, alignment, new int[] {0, -1});

    field.focus();

    e.setValue(startValue);
    fireEvent(Events.StartEdit, e);
  }
View Full Code Here

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

    fireEvent(Events.StartEdit, e);
  }

  protected void cancelEdit(boolean remainVisible, boolean revertInvalid) {
    Object v = field.getValue();
    EditorEvent e = new EditorEvent(this);
    e.setValue(v);
    e.setStartValue(startValue);
    if (editing && fireEvent(Events.BeforeCancelEdit, e)) {
      editing = false;
      if (revertInvalid) {
        setValue(startValue);
      }
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.