mirror of
https://github.com/sudoxnym/habitica-android.git
synced 2026-07-08 13:35:10 +00:00
improve task display
This commit is contained in:
parent
42c97f29e0
commit
e43629101e
3 changed files with 6 additions and 6 deletions
|
|
@ -23,7 +23,6 @@ public class DailiesRecyclerViewHolder extends BaseTasksRecyclerViewAdapter<Dail
|
|||
|
||||
@Override
|
||||
public void onBindViewHolder(DailyViewHolder holder, int position) {
|
||||
holder.displayChecklist = false;
|
||||
super.onBindViewHolder(holder, position);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -125,9 +125,11 @@ public abstract class ChecklistedViewHolder extends BaseTaskViewHolder implement
|
|||
} else {
|
||||
this.setDisplayChecklist(true);
|
||||
}
|
||||
RecyclerView recyclerView = (RecyclerView)this.checklistView.getParent().getParent();
|
||||
LinearLayoutManager layoutManager = (LinearLayoutManager)recyclerView.getLayoutManager();
|
||||
layoutManager.scrollToPositionWithOffset(this.getAdapterPosition(), 15);
|
||||
if (this.displayChecklist) {
|
||||
RecyclerView recyclerView = (RecyclerView)this.checklistView.getParent().getParent();
|
||||
LinearLayoutManager layoutManager = (LinearLayoutManager)recyclerView.getLayoutManager();
|
||||
layoutManager.scrollToPositionWithOffset(this.getAdapterPosition(), 15);
|
||||
}
|
||||
}
|
||||
|
||||
public void expandCheckboxTouchArea(final View expandedView, final View checkboxView){
|
||||
|
|
@ -151,7 +153,6 @@ public abstract class ChecklistedViewHolder extends BaseTaskViewHolder implement
|
|||
EventBus.getDefault().post(event);
|
||||
task.completed =event.completed;
|
||||
task.save();
|
||||
|
||||
}
|
||||
} else {
|
||||
View v = (View) buttonView.getParent();
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ public class TodoViewHolder extends ChecklistedViewHolder {
|
|||
this.checklistIndicatorWrapper.setBackgroundResource(this.task.getLightTaskColor());
|
||||
}
|
||||
if (task.duedate != null) {
|
||||
this.duedateTextView.setText(itemView.getContext().getString(R.string.todo_due, task.streak));
|
||||
this.duedateTextView.setText(itemView.getContext().getString(R.string.todo_due, task.duedate));
|
||||
this.duedateTextView.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
this.duedateTextView.setVisibility(View.GONE);
|
||||
|
|
|
|||
Loading…
Reference in a new issue