Allow trying pro features as far as possible

This commit is contained in:
M66B
2019-06-01 14:19:14 +02:00
parent 1845fe7a4d
commit 401b2d723a
8 changed files with 85 additions and 76 deletions

View File

@@ -324,18 +324,18 @@ public class FragmentAccount extends FragmentBase {
btnColor.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
if (!Helper.isPro(getContext())) {
LocalBroadcastManager lbm = LocalBroadcastManager.getInstance(getContext());
lbm.sendBroadcast(new Intent(ActivitySetup.ACTION_SHOW_PRO));
return;
}
int[] colors = getContext().getResources().getIntArray(R.array.colorPicker);
ColorPickerDialog colorPickerDialog = new ColorPickerDialog();
colorPickerDialog.initialize(R.string.title_account_color, colors, color, 4, colors.length);
colorPickerDialog.setOnColorSelectedListener(new ColorPickerSwatch.OnColorSelectedListener() {
@Override
public void onColorSelected(int color) {
if (!Helper.isPro(getContext())) {
LocalBroadcastManager lbm = LocalBroadcastManager.getInstance(getContext());
lbm.sendBroadcast(new Intent(ActivitySetup.ACTION_SHOW_PRO));
return;
}
setColor(color);
}
});