All new images for the new edit layout

pull/14/head
Sam Bosley 11 years ago
parent 1be8194cef
commit bf8a9fff23

@ -21,6 +21,7 @@ import android.view.View.OnClickListener;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemSelectedListener;
import android.widget.ArrayAdapter;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.Spinner;
import android.widget.TextView;
@ -56,6 +57,7 @@ public class GCalControlSet extends PopupControlSet {
private boolean hasEvent = false;
private Spinner calendarSelector;
private final int title;
private final ImageView image;
public GCalControlSet(final Activity activity, int viewLayout, int displayViewLayout, int title) {
super(activity, viewLayout, displayViewLayout, title);
@ -63,6 +65,7 @@ public class GCalControlSet extends PopupControlSet {
this.title = title;
calendars = Calendars.getCalendars();
getView(); // Hack to force initialized
image = (ImageView) getDisplayView().findViewById(R.id.display_row_icon);
}
@Override
@ -228,6 +231,7 @@ public class GCalControlSet extends PopupControlSet {
protected void refreshDisplayView() {
TextView calendar = (TextView) getDisplayView().findViewById(R.id.calendar_display_which);
calendar.setTextColor(themeColor);
image.setImageResource(R.drawable.tea_icn_addcal);
if (initialized) {
if (hasEvent) {
calendar.setText(R.string.gcal_TEA_has_event);
@ -235,6 +239,7 @@ public class GCalControlSet extends PopupControlSet {
calendar.setText((String)calendarSelector.getSelectedItem());
} else {
calendar.setTextColor(unsetColor);
image.setImageResource(R.drawable.tea_icn_addcal_gray);
calendar.setText(R.string.gcal_TEA_none_selected);
}
} else {
@ -245,6 +250,7 @@ public class GCalControlSet extends PopupControlSet {
calendar.setText(calendars.calendars[index]);
} else {
calendar.setTextColor(unsetColor);
image.setImageResource(R.drawable.tea_icn_addcal_gray);
calendar.setText(R.string.gcal_TEA_none_selected);
}
}

@ -9,6 +9,7 @@ import android.app.Activity;
import android.text.TextUtils;
import android.text.format.DateUtils;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import com.timsu.astrid.R;
@ -29,6 +30,7 @@ public class TimerControlSet extends PopupControlSet implements TimerActionListe
TimeDurationTaskEditControlSet estimated, elapsed;
private final TextView displayEdit;
private final ImageView image;
public TimerControlSet(final Activity activity, int viewLayout, int displayViewLayout, int title) {
super(activity, viewLayout, displayViewLayout, title);
@ -37,6 +39,8 @@ public class TimerControlSet extends PopupControlSet implements TimerActionListe
displayEdit.setText(R.string.TEA_timer_controls);
displayEdit.setTextColor(unsetColor);
image = (ImageView) getDisplayView().findViewById(R.id.display_row_icon);
estimated = new TimeDurationTaskEditControlSet(activity, getView(), Task.ESTIMATED_SECONDS,
R.id.estimatedDuration, 0, R.string.DLG_hour_minutes
);
@ -132,9 +136,11 @@ public class TimerControlSet extends PopupControlSet implements TimerActionListe
if (!TextUtils.isEmpty(toDisplay)) {
displayEdit.setText(toDisplay);
displayEdit.setTextColor(themeColor);
image.setImageResource(R.drawable.tea_icn_timer);
} else {
displayEdit.setText(R.string.TEA_timer_controls);
displayEdit.setTextColor(unsetColor);
image.setImageResource(R.drawable.tea_icn_timer_gray);
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

@ -21,9 +21,7 @@
<ImageView android:id="@+id/display_row_icon"
android:layout_marginRight="10dip"
android:layout_width="20dip"
android:layout_height="20dip"
android:scaleType="fitCenter"
android:background="#ff0000"/>
android:layout_height="20dip"/>
<TextView
android:id="@+id/display_row_edit"
android:layout_width="fill_parent"

@ -22,8 +22,7 @@
android:layout_marginRight="10dip"
android:layout_width="20dip"
android:layout_height="20dip"
android:scaleType="fitCenter"
android:background="#ff0000"/>
android:scaleType="fitCenter"/>
<TextView
android:id="@+id/display_row_edit"
android:layout_width="fill_parent"

@ -16,9 +16,11 @@
android:layout_height="50dip"
android:paddingLeft="5dip"
android:gravity="center_vertical">
<ImageView
style="@style/EditRowImage"
android:src="@drawable/icn_edit_calendar"/>
<ImageView android:id="@+id/display_row_icon"
android:layout_marginRight="10dip"
android:layout_width="20dip"
android:layout_height="20dip"
android:scaleType="fitCenter"/>
<TextView
android:id="@+id/calendar_display_which"
android:layout_width="fill_parent"
@ -27,7 +29,6 @@
android:gravity="left"
android:maxLines="1"
android:ellipsize="end"
android:paddingLeft="5dip"
style="@style/TextAppearance.EditRowDisplay" />
</LinearLayout>
<View

@ -58,9 +58,11 @@ public class DeadlineControlSet extends PopupControlSet {
if (TextUtils.isEmpty(displayString)) {
dateDisplay.setText(R.string.TEA_deadline_hint);
dateDisplay.setTextColor(unsetColor);
image.setImageResource(R.drawable.tea_icn_date_gray);
} else {
dateDisplay.setText(displayString);
dateDisplay.setTextColor(themeColor);
image.setImageResource(R.drawable.tea_icn_date);
}
}

@ -13,6 +13,7 @@ import android.view.View.OnClickListener;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemSelectedListener;
import android.widget.ArrayAdapter;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.Spinner;
import android.widget.TextView;
@ -39,12 +40,14 @@ public class HideUntilControlSet extends PopupControlSet implements OnItemSelect
private int previousSetting = Task.HIDE_UNTIL_NONE;
private final int title;
private int selection;
private final ImageView image;
private long existingDate = EXISTING_TIME_UNSET;
public HideUntilControlSet(Activity activity, int viewLayout, int displayViewLayout, int title) {
super(activity, viewLayout, displayViewLayout, title);
this.title = title;
image = (ImageView) getDisplayView().findViewById(R.id.display_row_icon);
}
private ArrayAdapter<HideUntilValue> adapter;
@ -197,6 +200,7 @@ public class HideUntilControlSet extends PopupControlSet implements OnItemSelect
if (value.setting == Task.HIDE_UNTIL_NONE) {
auxDisplay.setText(R.string.TEA_hideUntil_label);
auxDisplay.setTextColor(unsetColor);
image.setImageResource(R.drawable.tea_icn_hide_gray);
} else {
String display = value.toString();
if (value.setting != Task.HIDE_UNTIL_SPECIFIC_DAY && value.setting != Task.HIDE_UNTIL_SPECIFIC_DAY_TIME)
@ -204,6 +208,7 @@ public class HideUntilControlSet extends PopupControlSet implements OnItemSelect
auxDisplay.setText(activity.getString(R.string.TEA_hideUntil_display, display));
auxDisplay.setTextColor(themeColor);
image.setImageResource(R.drawable.tea_icn_hide);
}
}

@ -15,6 +15,7 @@ import android.widget.AdapterView;
import android.widget.AdapterView.OnItemSelectedListener;
import android.widget.ArrayAdapter;
import android.widget.CheckBox;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.Spinner;
import android.widget.TextView;
@ -45,6 +46,9 @@ public class ReminderControlSet extends PopupControlSet {
TextView label = (TextView) getDisplayView().findViewById(R.id.display_row_edit);
label.setText(R.string.TEA_reminders_group_label);
label.setTextColor(unsetColor);
ImageView image = (ImageView) getDisplayView().findViewById(R.id.display_row_icon);
image.setImageResource(R.drawable.tea_icn_reminder_gray);
}
public void addViewToBody(View v) {

Loading…
Cancel
Save