protected void doRestoreState(RestorableSupport rs, RestorableSupport.StateObject context) {
    super.doRestoreState(rs, context);

    Iterable<LatLon> iterable = rs.getStateValueAsLatLonList(context, "locationList");
    if (iterable != null) this.setLocations(iterable);

    Boolean b = rs.getStateValueAsBoolean(context, "closed");
    if (b != null) this.setClosed(b);
  }
Exemplo n.º 2
0
  @Override
  protected void doRestoreState(RestorableSupport rs, RestorableSupport.StateObject context) {
    super.doRestoreState(rs, context);

    Boolean booleanState = rs.getStateValueAsBoolean(context, "enableCaps");
    if (booleanState != null) this.setEnableCaps(booleanState);

    List<LatLon> locations = rs.getStateValueAsLatLonList(context, "locations");
    if (locations != null) this.setLocations(locations);
  }
  protected void legacyRestoreState(RestorableSupport rs, RestorableSupport.StateObject context) {
    super.legacyRestoreState(rs, context);

    java.util.ArrayList<LatLon> locations = rs.getStateValueAsLatLonList(context, "locations");
    if (locations != null) this.setLocations(locations);
  }