fix build

This commit is contained in:
sonora 2014-12-20 17:33:55 +01:00
parent a0ff8756a5
commit 7aa955c980

View file

@ -682,27 +682,30 @@ public class WaypointHelper {
} else if(((AlarmInfo) point).getType().toString() == "BORDER_CONTROL") {
R.drawable.mx_barrier_border_control;
} else if(((AlarmInfo) point).getType().toString() == "RAILWAY") {
if(app.getSettings.DRIVING_REGION.get().americanSigns){
return R.drawable.list_warnings_railways_us;
} else {
//this produces error: non-static variable app cannot be referenced from a static context
//if(app.getSettings.DRIVING_REGION.get().americanSigns){
// return R.drawable.list_warnings_railways_us;
//} else {
return R.drawable.list_warnings_railways;
}
//}
} else if(((AlarmInfo) point).getType().toString() == "TRAFFIC_CALMING") {
if(app.getSettings.DRIVING_REGION.get().americanSigns){
return R.drawable.list_traffic_calming_us;
} else {
//this produces error: non-static variable app cannot be referenced from a static context
//if(app.getSettings.DRIVING_REGION.get().americanSigns){
// return R.drawable.list_traffic_calming_us;
//} else {
return R.drawable.list_traffic_calming;
}
//}
} else if(((AlarmInfo) point).getType().toString() == "TOLL_BOOTH") {
return R.drawable.mx_barrier_toll_booth;
} else if(((AlarmInfo) point).getType().toString() == "STOP") {
return R.drawable.list_stop;
} else if(((AlarmInfo) point).getType().toString() == "PEDESTRIAN") {
if(app.getSettings.DRIVING_REGION.get().americanSigns){
return R.drawable.list_warnings_pedestrian_us;
} else {
//this produces error: non-static variable app cannot be referenced from a static context
//if(app.getSettings.DRIVING_REGION.get().americanSigns){
// return R.drawable.list_warnings_pedestrian_us;
//} else {
return R.drawable.list_warnings_pedestrian;
}
//}
} else {
return 0;
}
@ -738,27 +741,30 @@ public class WaypointHelper {
} else if(((AlarmInfo) point).getType().toString() == "BORDER_CONTROL") {
return uiCtx.getResources().getDrawable(R.drawable.mx_barrier_border_control);
} else if(((AlarmInfo) point).getType().toString() == "RAILWAY") {
if(app.getSettings.DRIVING_REGION.get().americanSigns){
return uiCtx.getResources().getDrawable(R.drawable.list_warnings_railways_us);
} else {
//this produces error: non-static variable app cannot be referenced from a static context
//if(app.getSettings.DRIVING_REGION.get().americanSigns){
// return uiCtx.getResources().getDrawable(R.drawable.list_warnings_railways_us);
//} else {
return uiCtx.getResources().getDrawable(R.drawable.list_warnings_railways);
}
//}
} else if(((AlarmInfo) point).getType().toString() == "TRAFFIC_CALMING") {
if(app.getSettings.DRIVING_REGION.get().americanSigns){
return uiCtx.getResources().getDrawable(R.drawable.list_traffic_calming_us);
} else {
//this produces error: non-static variable app cannot be referenced from a static context
//if(app.getSettings.DRIVING_REGION.get().americanSigns){
// return uiCtx.getResources().getDrawable(R.drawable.list_traffic_calming_us);
//} else {
return uiCtx.getResources().getDrawable(R.drawable.list_traffic_calming);
}
//}
} else if(((AlarmInfo) point).getType().toString() == "TOLL_BOOTH") {
return uiCtx.getResources().getDrawable(R.drawable.mx_barrier_toll_booth);
} else if(((AlarmInfo) point).getType().toString() == "STOP") {
return uiCtx.getResources().getDrawable(R.drawable.list_stop);
} else if(((AlarmInfo) point).getType().toString() == "PEDESTRIAN") {
if(app.getSettings.DRIVING_REGION.get().americanSigns){
return uiCtx.getResources().getDrawable(R.drawable.list_warnings_pedestrian_us);
} else {
//this produces error: non-static variable app cannot be referenced from a static context
//if(app.getSettings.DRIVING_REGION.get().americanSigns){
// return uiCtx.getResources().getDrawable(R.drawable.list_warnings_pedestrian_us);
//} else {
return uiCtx.getResources().getDrawable(R.drawable.list_warnings_pedestrian);
}
//}
} else {
return null;
}