quick action add favorite bugs fixes
This commit is contained in:
parent
efb24f7c03
commit
cde0be4de1
3 changed files with 8 additions and 9 deletions
|
@ -163,7 +163,7 @@ public class FavoritePointEditorFragment extends PointEditorFragment {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (builder != null) {
|
if (builder != null && !autoFill) {
|
||||||
builder.setPositiveButton(R.string.shared_string_ok, new DialogInterface.OnClickListener() {
|
builder.setPositiveButton(R.string.shared_string_ok, new DialogInterface.OnClickListener() {
|
||||||
@Override
|
@Override
|
||||||
public void onClick(DialogInterface dialog, int which) {
|
public void onClick(DialogInterface dialog, int which) {
|
||||||
|
|
|
@ -360,14 +360,13 @@ public class QuickActionFactory {
|
||||||
|
|
||||||
private void fillGroupParams(View root, String name, int color) {
|
private void fillGroupParams(View root, String name, int color) {
|
||||||
|
|
||||||
|
if (color == 0) color = R.color.color_favorite;
|
||||||
|
|
||||||
((AutoCompleteTextViewEx) root.findViewById(R.id.category_edit)).setText(name);
|
((AutoCompleteTextViewEx) root.findViewById(R.id.category_edit)).setText(name);
|
||||||
|
((ImageView) root.findViewById(R.id.category_image)).setColorFilter(color);
|
||||||
|
|
||||||
getParams().put(KEY_CATEGORY_NAME, name);
|
getParams().put(KEY_CATEGORY_NAME, name);
|
||||||
|
getParams().put(KEY_CATEGORY_COLOR, String.valueOf(color));
|
||||||
if (color > 0) {
|
|
||||||
|
|
||||||
((ImageView) root.findViewById(R.id.category_image)).setColorFilter(color);
|
|
||||||
getParams().put(KEY_CATEGORY_COLOR, String.valueOf(color));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -426,7 +425,7 @@ public class QuickActionFactory {
|
||||||
|
|
||||||
PoiFiltersHelper pf = activity.getMyApplication().getPoiFilters();
|
PoiFiltersHelper pf = activity.getMyApplication().getPoiFilters();
|
||||||
|
|
||||||
if (pf.getSelectedPoiFilters().isEmpty()){
|
if (pf.getSelectedPoiFilters().isEmpty()) {
|
||||||
|
|
||||||
pf.loadSelectedPoiFilters();
|
pf.loadSelectedPoiFilters();
|
||||||
|
|
||||||
|
|
|
@ -131,7 +131,7 @@ public class QuickActionRegistry {
|
||||||
|
|
||||||
number++;
|
number++;
|
||||||
|
|
||||||
action.setName(name + "(" + number + ")");
|
action.setName(name + " (" + number + ")");
|
||||||
|
|
||||||
if (isNameUnique(action, context)) return action;
|
if (isNameUnique(action, context)) return action;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue