Looks like we can't reproduce the issue or there's a problem in the test case provided.
  1. #1
    Sencha Premium Member
    Join Date
    Mar 2012
    Posts
    75
    Vote Rating
    2
    tby is on a distinguished road

      0  

    Default NullPointerException in Store.PropertyChange

    NullPointerException in Store.PropertyChange


    The method
    Code:
    public boolean isCurrentValue(M model) {      
        return (access.getValue(model) == null && value == null) || access.getValue(model).equals(value);
    }
    in Store.PropertyChange will throw a NullPointerException if the model value is null and the new value is not null.

  2. #2
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    9,075
    Vote Rating
    467
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    Where is 'value' coming from?

    Regards,
    Scott.

  3. #3
    Sencha Premium Member
    Join Date
    Mar 2012
    Posts
    75
    Vote Rating
    2
    tby is on a distinguished road

      0  

    Default


    Stack trace:

    Caused by: java.lang.NullPointerException: null
    at com.sencha.gxt.data.shared.Store$PropertyChange.isCurrentValue(Store.java:126)
    at com.sencha.gxt.data.shared.Store$Record.addChange(Store.java:164)
    at com.sencha.gxt.widget.core.client.grid.editing.GridInlineEditing.doCompleteEditing(GridInlineEditing.java:172)
    at com.sencha.gxt.widget.core.client.grid.editing.GridInlineEditing.completeEditing(GridInlineEditing.java:104)
    at com.sencha.gxt.widget.core.client.grid.editing.GridInlineEditing$3$2.onValueChange(GridInlineEditing.java:285)
    at com.google.gwt.event.logical.shared.ValueChangeEvent.dispatch(ValueChangeEvent.java:128)
    at com.google.gwt.event.logical.shared.ValueChangeEvent.dispatch(ValueChangeEvent.java:1)
    at com.google.gwt.event.shared.GwtEvent.dispatch(GwtEvent.java:1)
    at com.google.web.bindery.event.shared.EventBus.dispatchEvent(EventBus.java:40)
    at com.google.web.bindery.event.shared.SimpleEventBus.doFire(SimpleEventBus.java:193)
    at com.google.web.bindery.event.shared.SimpleEventBus.fireEvent(SimpleEventBus.java:88)
    at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java:127)
    at com.google.gwt.user.client.ui.Widget.fireEvent(Widget.java:129)
    at com.sencha.gxt.widget.core.client.Component.fireEvent(Component.java:292)
    at com.google.gwt.event.logical.shared.ValueChangeEvent.fire(ValueChangeEvent.java:43)
    at com.sencha.gxt.widget.core.client.cell.CellComponent.setValue(CellComponent.java:263)
    at com.sencha.gxt.widget.core.client.form.Field.setValue(Field.java:378)
    at com.sencha.gxt.widget.core.client.cell.CellComponent$2.update(CellComponent.java:90)
    at com.sencha.gxt.cell.core.client.form.TriggerFieldCell.finishEditing(TriggerFieldCell.java:135)
    at com.google.gwt.cell.client.AbstractInputCell.onEnterKeyDown(AbstractInputCell.java:155)
    at com.google.gwt.cell.client.AbstractCell.onBrowserEvent(AbstractCell.java:111)
    at com.google.gwt.cell.client.AbstractInputCell.onBrowserEvent(AbstractInputCell.java:99)
    at com.sencha.gxt.cell.core.client.form.FieldCell.onBrowserEvent(FieldCell.java:264)
    at com.sencha.gxt.cell.core.client.form.TriggerFieldCell.onBrowserEvent(TriggerFieldCell.java:199)
    at com.sencha.gxt.widget.core.client.cell.CellComponent.onBrowserEvent(CellComponent.java:192)
    at com.sencha.gxt.widget.core.client.form.Field.onBrowserEvent(Field.java:255)
    at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1351)
    at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1307)
    at sun.reflect.GeneratedMethodAccessor70.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

  4. #4
    Sencha Premium Member
    Join Date
    Mar 2012
    Posts
    75
    Vote Rating
    2
    tby is on a distinguished road

      0  

    Default


    Not to get me wrong:

    In my case "access.getValue(model)" is null and "value" is the new value entered in the field.

  5. #5
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    9,075
    Vote Rating
    467
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    I have moved this thread to GWT forums so you can get the proper attention.

    Scott.

  6. #6

Thread Participants: 2

Tags for this Thread