Clear measurements on text size changes

pull/184/head
M66B 4 years ago
parent 2a5ce4f2b8
commit 1b5970a483

@ -4109,6 +4109,7 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
int zoom = prefs.getInt("view_zoom", compact ? 0 : 1);
zoom = ++zoom % 3;
prefs.edit().putInt("view_zoom", zoom).apply();
clearMeasurements();
adapter.setZoom(zoom);
}
@ -4122,9 +4123,17 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
adapter.setCompact(compact);
adapter.setZoom(zoom);
clearMeasurements();
getActivity().invalidateOptionsMenu();
}
private void clearMeasurements() {
scales.clear();
sizes.clear();
heights.clear();
positions.clear();
}
private void onMenuSelectLanguage() {
Bundle args = new Bundle();
args.putLong("account", account);

Loading…
Cancel
Save