SpreadsheetCell sc = book.get(sheet.getName(graph), r.startRow, r.startColumn);
sc.setContent(value);
// book.accept(new InvalidateAll());
- List<SpreadsheetCell> changed = book.invalidate(sc);
+// List<SpreadsheetCell> changed = book.invalidate(sc); //Invalidation handled by SpreadsheetNodeManager
realm.asyncExec(new Runnable() {
@Override
private CellEditor<Write> getPossibleCellEditor(WriteGraph graph, String location, Variant value) throws DatabaseException {
SpreadsheetResource SHEET = SpreadsheetResource.getInstance(graph);
- Range range = SpreadsheetUtils.decodeCellAbsolute(location);
-
- List<Variable> cells = SpreadsheetGraphUtils.possibleConfigurationCellVariables(graph, sheet, range);
- if (cells.isEmpty()) {
- if (value == null) {
- return null;
- } else {
- cells = SpreadsheetGraphUtils.getOrCreateConfigurationCellVariables(graph, sheet, range);
- }
- }
- if (cells.size() != 1)
- throw new DatabaseException("Can edit only one cell at a time!");
-
- return cells.iterator().next().getPropertyValue(graph, SHEET.cellEditor);
+ Range range = SpreadsheetUtils.decodePossibleCellAbsolute(location);
+ if(range == null) return null; //No editor found
+
+ List<Variable> cells = SpreadsheetGraphUtils.possibleConfigurationCellVariables(graph, sheet, range);
+ if (cells.isEmpty()) {
+ if (value == null) {
+ return null;
+ } else {
+ cells = SpreadsheetGraphUtils.getOrCreateConfigurationCellVariables(graph, sheet, range);
+ }
+ }
+ if (cells.size() != 1)
+ throw new DatabaseException("Can edit only one cell at a time!");
+
+ return cells.iterator().next().getPropertyValue(graph, SHEET.cellEditor);
}
@Override