diff --git a/astrid/res/drawable/check_box_1.png b/astrid/res/drawable/check_box_1.png
new file mode 100644
index 000000000..a1c34c993
Binary files /dev/null and b/astrid/res/drawable/check_box_1.png differ
diff --git a/astrid/res/drawable/check_box_2.png b/astrid/res/drawable/check_box_2.png
new file mode 100644
index 000000000..25e28d21e
Binary files /dev/null and b/astrid/res/drawable/check_box_2.png differ
diff --git a/astrid/res/drawable/check_box_3.png b/astrid/res/drawable/check_box_3.png
new file mode 100644
index 000000000..b99cfa7c7
Binary files /dev/null and b/astrid/res/drawable/check_box_3.png differ
diff --git a/astrid/res/drawable/check_box_4.png b/astrid/res/drawable/check_box_4.png
new file mode 100644
index 000000000..7cc50df94
Binary files /dev/null and b/astrid/res/drawable/check_box_4.png differ
diff --git a/astrid/res/drawable/check_box_checked_1.png b/astrid/res/drawable/check_box_checked_1.png
new file mode 100644
index 000000000..1ca386e9b
Binary files /dev/null and b/astrid/res/drawable/check_box_checked_1.png differ
diff --git a/astrid/res/drawable/check_box_checked_2.png b/astrid/res/drawable/check_box_checked_2.png
new file mode 100644
index 000000000..0f5436a66
Binary files /dev/null and b/astrid/res/drawable/check_box_checked_2.png differ
diff --git a/astrid/res/drawable/check_box_checked_3.png b/astrid/res/drawable/check_box_checked_3.png
new file mode 100644
index 000000000..df21f1010
Binary files /dev/null and b/astrid/res/drawable/check_box_checked_3.png differ
diff --git a/astrid/res/drawable/check_box_checked_4.png b/astrid/res/drawable/check_box_checked_4.png
new file mode 100644
index 000000000..de24ee2c5
Binary files /dev/null and b/astrid/res/drawable/check_box_checked_4.png differ
diff --git a/astrid/res/drawable/repeat_box_1.png b/astrid/res/drawable/check_box_repeat_1.png
similarity index 100%
rename from astrid/res/drawable/repeat_box_1.png
rename to astrid/res/drawable/check_box_repeat_1.png
diff --git a/astrid/res/drawable/repeat_box_2.png b/astrid/res/drawable/check_box_repeat_2.png
similarity index 100%
rename from astrid/res/drawable/repeat_box_2.png
rename to astrid/res/drawable/check_box_repeat_2.png
diff --git a/astrid/res/drawable/repeat_box_3.png b/astrid/res/drawable/check_box_repeat_3.png
similarity index 100%
rename from astrid/res/drawable/repeat_box_3.png
rename to astrid/res/drawable/check_box_repeat_3.png
diff --git a/astrid/res/drawable/repeat_box_4.png b/astrid/res/drawable/check_box_repeat_4.png
similarity index 100%
rename from astrid/res/drawable/repeat_box_4.png
rename to astrid/res/drawable/check_box_repeat_4.png
diff --git a/astrid/res/drawable/check_box_repeat_checked_1.png b/astrid/res/drawable/check_box_repeat_checked_1.png
new file mode 100644
index 000000000..f6b2f1122
Binary files /dev/null and b/astrid/res/drawable/check_box_repeat_checked_1.png differ
diff --git a/astrid/res/drawable/check_box_repeat_checked_2.png b/astrid/res/drawable/check_box_repeat_checked_2.png
new file mode 100644
index 000000000..1a454b786
Binary files /dev/null and b/astrid/res/drawable/check_box_repeat_checked_2.png differ
diff --git a/astrid/res/drawable/check_box_repeat_checked_3.png b/astrid/res/drawable/check_box_repeat_checked_3.png
new file mode 100644
index 000000000..4e40054dd
Binary files /dev/null and b/astrid/res/drawable/check_box_repeat_checked_3.png differ
diff --git a/astrid/res/drawable/check_box_repeat_checked_4.png b/astrid/res/drawable/check_box_repeat_checked_4.png
new file mode 100644
index 000000000..6535b94a9
Binary files /dev/null and b/astrid/res/drawable/check_box_repeat_checked_4.png differ
diff --git a/astrid/res/drawable/importance_check_1.xml b/astrid/res/drawable/importance_check_1.xml
index 68c0b6ff0..7014f0bb7 100644
--- a/astrid/res/drawable/importance_check_1.xml
+++ b/astrid/res/drawable/importance_check_1.xml
@@ -3,9 +3,9 @@
+ android:drawable="@drawable/check_box_1" />
+ android:drawable="@drawable/check_box_checked_1" />
\ No newline at end of file
diff --git a/astrid/res/drawable/importance_check_2.xml b/astrid/res/drawable/importance_check_2.xml
index a18c0215b..c865b3af6 100644
--- a/astrid/res/drawable/importance_check_2.xml
+++ b/astrid/res/drawable/importance_check_2.xml
@@ -3,9 +3,9 @@
+ android:drawable="@drawable/check_box_2" />
+ android:drawable="@drawable/check_box_checked_2" />
\ No newline at end of file
diff --git a/astrid/res/drawable/importance_check_3.xml b/astrid/res/drawable/importance_check_3.xml
index a9d2037dd..76f4d22e0 100644
--- a/astrid/res/drawable/importance_check_3.xml
+++ b/astrid/res/drawable/importance_check_3.xml
@@ -3,9 +3,9 @@
+ android:drawable="@drawable/check_box_3" />
+ android:drawable="@drawable/check_box_checked_3" />
\ No newline at end of file
diff --git a/astrid/res/drawable/importance_check_4.xml b/astrid/res/drawable/importance_check_4.xml
index f02246457..47e2eeb98 100644
--- a/astrid/res/drawable/importance_check_4.xml
+++ b/astrid/res/drawable/importance_check_4.xml
@@ -3,9 +3,9 @@
+ android:drawable="@drawable/check_box_4" />
+ android:drawable="@drawable/check_box_checked_4" />
\ No newline at end of file
diff --git a/astrid/res/drawable/importance_check_repeat_1.xml b/astrid/res/drawable/importance_check_repeat_1.xml
new file mode 100644
index 000000000..75b16aa7d
--- /dev/null
+++ b/astrid/res/drawable/importance_check_repeat_1.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/astrid/res/drawable/importance_check_repeat_2.xml b/astrid/res/drawable/importance_check_repeat_2.xml
new file mode 100644
index 000000000..76fdae066
--- /dev/null
+++ b/astrid/res/drawable/importance_check_repeat_2.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/astrid/res/drawable/importance_check_repeat_3.xml b/astrid/res/drawable/importance_check_repeat_3.xml
new file mode 100644
index 000000000..0a97e6ada
--- /dev/null
+++ b/astrid/res/drawable/importance_check_repeat_3.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/astrid/res/drawable/importance_check_repeat_4.xml b/astrid/res/drawable/importance_check_repeat_4.xml
new file mode 100644
index 000000000..421df0d11
--- /dev/null
+++ b/astrid/res/drawable/importance_check_repeat_4.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/astrid/res/layout/task_adapter_row.xml b/astrid/res/layout/task_adapter_row.xml
index baa8a41e2..573f78847 100644
--- a/astrid/res/layout/task_adapter_row.xml
+++ b/astrid/res/layout/task_adapter_row.xml
@@ -11,7 +11,7 @@
@@ -19,13 +19,14 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
- android:layout_marginTop="5dip"
+ android:layout_marginTop="10dip"
android:button="@drawable/btn_check"/>
-
diff --git a/astrid/src/com/todoroo/astrid/adapter/TaskAdapter.java b/astrid/src/com/todoroo/astrid/adapter/TaskAdapter.java
index 83da7635b..0a9f2a57f 100644
--- a/astrid/src/com/todoroo/astrid/adapter/TaskAdapter.java
+++ b/astrid/src/com/todoroo/astrid/adapter/TaskAdapter.java
@@ -129,7 +129,10 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
};
private static int[] IMPORTANCE_REPEAT_RESOURCES = new int[] {
- // stuff will go here
+ R.drawable.importance_check_repeat_1, //task_indicator_0,
+ R.drawable.importance_check_repeat_2, //task_indicator_1,
+ R.drawable.importance_check_repeat_3, //task_indicator_2,
+ R.drawable.importance_check_repeat_4, //task_indicator_3,
};
// --- instance variables
@@ -377,12 +380,24 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
final CheckBox checkBoxView = viewHolder.completeBox; {
int value = task.getValue(Task.IMPORTANCE);
if(value < IMPORTANCE_RESOURCES.length)
- if (!TextUtils.isEmpty(task.getValue(Task.RECURRENCE)))
- checkBoxView.setButtonDrawable(IMPORTANCE_RESOURCES[value]);
- else
+ if (!TextUtils.isEmpty(task.getValue(Task.RECURRENCE))) {
+ checkBoxView.setButtonDrawable(IMPORTANCE_REPEAT_RESOURCES[value]);
+ pictureView.setBackgroundResource(IMPORTANCE_REPEAT_RESOURCES[value]);
+ }
+ else {
checkBoxView.setButtonDrawable(IMPORTANCE_RESOURCES[value]);
+ pictureView.setBackgroundResource(IMPORTANCE_RESOURCES[value]);
+ }
else
+ {
checkBoxView.setBackgroundResource(R.drawable.btn_check);
+ }
+ if (pictureView.getVisibility() == View.VISIBLE){
+ checkBoxView.setVisibility(View.INVISIBLE);
+ }
+ else {
+ checkBoxView.setVisibility(View.VISIBLE);
+ }
}
String details;
@@ -410,7 +425,7 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
if(Math.abs(DateUtilities.now() - task.getValue(Task.MODIFICATION_DATE)) < 2000L)
mostRecentlyMade = task.getId();
-// // details and decorations, expanded
+ // // details and decorations, expanded
decorationManager.request(viewHolder);
}
@@ -424,7 +439,7 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
viewHolder.completeBox.measure(View.MeasureSpec.UNSPECIFIED, View.MeasureSpec.UNSPECIFIED);
rightWidth = rightWidth + viewHolder.dueDate.getPaddingRight();
float left = viewHolder.completeBox.getMeasuredWidth() +
- ((MarginLayoutParams)viewHolder.completeBox.getLayoutParams()).leftMargin;
+ ((MarginLayoutParams)viewHolder.completeBox.getLayoutParams()).leftMargin;
int availableWidth = (int) (displayMetrics.widthPixels - left - (rightWidth + 16) * displayMetrics.density);
int i = 0;
@@ -555,8 +570,8 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
continue;
} else if(Constants.DEBUG) {
System.err.println("Forced loading of details: " + task.getId() + //$NON-NLS-1$
- "\n details: " + new Date(task.getValue(Task.DETAILS_DATE)) + //$NON-NLS-1$
- "\n modified: " + new Date(task.getValue(Task.MODIFICATION_DATE))); //$NON-NLS-1$
+ "\n details: " + new Date(task.getValue(Task.DETAILS_DATE)) + //$NON-NLS-1$
+ "\n modified: " + new Date(task.getValue(Task.MODIFICATION_DATE))); //$NON-NLS-1$
}
addTaskToLoadingArray(task);
@@ -583,7 +598,7 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
private boolean detailsAreRecentAndUpToDate(Task task) {
return task.getValue(Task.DETAILS_DATE) >= task.getValue(Task.MODIFICATION_DATE) &&
- !TextUtils.isEmpty(task.getValue(Task.DETAILS));
+ !TextUtils.isEmpty(task.getValue(Task.DETAILS));
}
private void addTaskToLoadingArray(Task task) {
@@ -650,8 +665,8 @@ public class TaskAdapter extends CursorAdapter implements Filterable {
return null;
Drawable d;
if(!cache.containsKey(drawable)) {
- d = r.getDrawable(drawable);
- d.setBounds(0,0,d.getIntrinsicWidth(),d.getIntrinsicHeight());
+ d = r.getDrawable(drawable);
+ d.setBounds(0,0,d.getIntrinsicWidth(),d.getIntrinsicHeight());
cache.put(drawable, d);
} else
d = cache.get(drawable);