improve performance
This commit is contained in:
parent
9edd86dff5
commit
0919bf58f5
|
@ -13,10 +13,7 @@ import org.jetbrains.annotations.NotNull;
|
||||||
import org.jetbrains.annotations.Nullable;
|
import org.jetbrains.annotations.Nullable;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.Calendar;
|
import java.util.*;
|
||||||
import java.util.Collection;
|
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.Objects;
|
|
||||||
|
|
||||||
import static org.cutem.cutecalendar.model.TodoItem.*;
|
import static org.cutem.cutecalendar.model.TodoItem.*;
|
||||||
|
|
||||||
|
@ -117,8 +114,9 @@ public abstract class NewItemBuilder extends VBox {
|
||||||
|
|
||||||
|
|
||||||
protected boolean autoCheck() {
|
protected boolean autoCheck() {
|
||||||
for (String key : mAutoSet.keySet()) {
|
for (Map.Entry<String, ReadOnlyStringProperty> e : mAutoSet.entrySet()) {
|
||||||
String val = mAutoSet.get(key).getValue();
|
String key = e.getKey();
|
||||||
|
String val = e.getValue().getValue();
|
||||||
if (!checkFormation(key, val)) {
|
if (!checkFormation(key, val)) {
|
||||||
String info = mAutoAlertInfo.get(key);
|
String info = mAutoAlertInfo.get(key);
|
||||||
showAlert(info);
|
showAlert(info);
|
||||||
|
@ -148,8 +146,9 @@ public abstract class NewItemBuilder extends VBox {
|
||||||
protected TodoItemFactory autoBuild() {
|
protected TodoItemFactory autoBuild() {
|
||||||
TodoItemFactory factory = new TodoItemFactory();
|
TodoItemFactory factory = new TodoItemFactory();
|
||||||
|
|
||||||
for (String key : mAutoSet.keySet()) {
|
for (Map.Entry<String, ReadOnlyStringProperty> e : mAutoSet.entrySet()) {
|
||||||
String val = mAutoSet.get(key).getValue();
|
String key = e.getKey();
|
||||||
|
String val = e.getValue().getValue();
|
||||||
factory.stringProperties(key, val);
|
factory.stringProperties(key, val);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue