mirror of
https://github.com/nextcloud/android.git
synced 2024-11-27 17:46:37 +03:00
fix codacy issues
This commit is contained in:
parent
3bea212814
commit
d19e209ab6
1 changed files with 4 additions and 2 deletions
|
@ -121,9 +121,11 @@ public class NotificationListAdapter extends RecyclerView.Adapter<NotificationLi
|
|||
|
||||
// add action buttons
|
||||
holder.buttons.removeAllViews();
|
||||
Button button;
|
||||
ExecuteActionTask executeActionTask = new ExecuteActionTask(holder);
|
||||
|
||||
for (Action action : notification.getActions()) {
|
||||
Button button = new Button(notificationsActivity);
|
||||
button = new Button(notificationsActivity);
|
||||
button.setText(action.label);
|
||||
if (action.primary) {
|
||||
button.getBackground().setColorFilter(ThemeUtils.primaryColor(notificationsActivity, true),
|
||||
|
@ -131,7 +133,7 @@ public class NotificationListAdapter extends RecyclerView.Adapter<NotificationLi
|
|||
button.setTextColor(ThemeUtils.fontColor(notificationsActivity));
|
||||
}
|
||||
|
||||
button.setOnClickListener(v -> new ExecuteActionTask(holder).execute(action));
|
||||
button.setOnClickListener(v -> executeActionTask.execute(action));
|
||||
|
||||
holder.buttons.addView(button);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue