Fix compilation
This commit is contained in:
parent
865f4c00a7
commit
716705472e
3 changed files with 3 additions and 13 deletions
|
@ -943,13 +943,12 @@ public class SettingsHelper {
|
|||
String name = object.getString("name");
|
||||
// FIXME QA: make type string
|
||||
int actionType = object.getInt("type");
|
||||
QuickActionType tp = QuickActionRegistry.getActionTypeById(actionType);
|
||||
if(tp != null) {
|
||||
QuickAction quickAction = QuickActionRegistry.newActionByType(actionType);
|
||||
if (quickAction.getType() != 0) {
|
||||
|
||||
String paramsString = object.getString("params");
|
||||
HashMap<String, String> params = gson.fromJson(paramsString, type);
|
||||
|
||||
QuickAction quickAction = new QuickAction(actionType);
|
||||
if (!name.isEmpty()) {
|
||||
quickAction.setName(name);
|
||||
}
|
||||
|
|
|
@ -65,7 +65,7 @@ public class QuickAction {
|
|||
return id;
|
||||
}
|
||||
|
||||
public long getType() {
|
||||
public int getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
|
|
|
@ -258,15 +258,6 @@ public class QuickActionRegistry {
|
|||
}
|
||||
}
|
||||
|
||||
public static QuickActionType getActionTypeById(int type) {
|
||||
for (QuickActionType t : getActionTypes()) {
|
||||
if (t.getId() == type) {
|
||||
return t;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public static QuickAction newActionByType(int type) {
|
||||
for (QuickActionType t : getActionTypes()) {
|
||||
if (t.getId() == type) {
|
||||
|
|
Loading…
Reference in a new issue