diff options
author | Christopher Baines <cbaines8@gmail.com> | 2012-02-16 22:35:53 +0000 |
---|---|---|
committer | Christopher Baines <cbaines8@gmail.com> | 2012-02-16 22:35:53 +0000 |
commit | 3f10264e8dba0cd972647fbe1379f148b1ee6847 (patch) | |
tree | 2219a824f9aa865c1836998eb46757db6e708545 /src/net/cbaines/suma/BusSpecificStopView.java | |
parent | 86629c735d4f7c48e1562825ca63ba3335363cbb (diff) | |
download | southamptonuniversitymap-3f10264e8dba0cd972647fbe1379f148b1ee6847.tar southamptonuniversitymap-3f10264e8dba0cd972647fbe1379f148b1ee6847.tar.gz |
More progress on the route movement stuff, identified the bus stops that need addressing manualy, however I need to redefine the concept
of direction. As all of the routes that direction applies are circular, direction is only relevent for dealing with the bus stops that
are present in the route more than once.
Diffstat (limited to 'src/net/cbaines/suma/BusSpecificStopView.java')
-rw-r--r-- | src/net/cbaines/suma/BusSpecificStopView.java | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/src/net/cbaines/suma/BusSpecificStopView.java b/src/net/cbaines/suma/BusSpecificStopView.java index 88a403c..cad7524 100644 --- a/src/net/cbaines/suma/BusSpecificStopView.java +++ b/src/net/cbaines/suma/BusSpecificStopView.java @@ -25,7 +25,7 @@ import java.text.DateFormat; import android.app.Activity; import android.content.Context; import android.content.Intent; -import android.os.Handler; +import android.util.Log; import android.view.Gravity; import android.view.View; import android.view.View.OnClickListener; @@ -39,11 +39,7 @@ import com.j256.ormlite.dao.Dao; public class BusSpecificStopView extends LinearLayout implements OnClickListener, OnLongClickListener { - // private static final String TAG = "BusSpecificStopView"; - - private Handler handler; - - private Runnable refreshData; + private static final String TAG = "BusSpecificStopView"; // private static final String TAG = "StopView"; @@ -54,7 +50,7 @@ public class BusSpecificStopView extends LinearLayout implements OnClickListener private Stop stop; - public BusSpecificStopView(Context context, Stop newStop) { + public BusSpecificStopView(Context context, Stop stop) { super(context); this.context = context; @@ -73,7 +69,6 @@ public class BusSpecificStopView extends LinearLayout implements OnClickListener addView(location, new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT)); addView(time, new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT)); - handler.post(refreshData); } public void setStop(Stop stop) { @@ -82,6 +77,16 @@ public class BusSpecificStopView extends LinearLayout implements OnClickListener this.stop = stop; + if (stop == null) { + Log.e(TAG, "stop == null"); + } + if (stop.busStop == null) { + Log.e(TAG, "stop.busStop == null"); + } + if (stop.busStop.description == null) { + Log.e(TAG, "stop.busStop.description == null"); + } + if (stop.busStop.description.length() > 20) { location.setText(stop.busStop.description.substring(0, 20)); // TODO } else { |