From 768c5c82ba4e4ac9c9dde7f1ba7d1e6f57e01a5e Mon Sep 17 00:00:00 2001 From: Jeremy Jao Date: Wed, 24 May 2017 19:14:40 -0400 Subject: [PATCH 1/2] creating a 7.0.6 release to remove the dialog from code, semver'ing versioncode --- app/build.gradle | 4 ++-- .../com/pittsburghrealtimetracker/BusMapFragment.java | 2 +- .../ui/serverdown/ServerDownDialogFragment.java | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 2041747f..198656f0 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -17,8 +17,8 @@ android { applicationId "rectangledbmi.com.pittsburghrealtimetracker" minSdkVersion 16 targetSdkVersion 23 - versionCode 80 - versionName "7.0.5" + versionCode 160070006 + versionName "7.0.6" } lintOptions { warning 'InvalidPackage' diff --git a/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/BusMapFragment.java b/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/BusMapFragment.java index f6cd7d97..75427cce 100644 --- a/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/BusMapFragment.java +++ b/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/BusMapFragment.java @@ -223,7 +223,7 @@ public View onCreateView(LayoutInflater inflater, ViewGroup container, @Override public void onResume() { super.onResume(); - ServerDownDialogFragment.newInstance().show(getFragmentManager(), getString(R.string.servers_down_title)); +// ServerDownDialogFragment.newInstance().show(getFragmentManager(), getString(R.string.servers_down_title)); Timber.d("resuming map fragment"); if (mapView != null) { mapView.onResume(); diff --git a/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/ui/serverdown/ServerDownDialogFragment.java b/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/ui/serverdown/ServerDownDialogFragment.java index e2210ea2..529de92c 100644 --- a/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/ui/serverdown/ServerDownDialogFragment.java +++ b/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/ui/serverdown/ServerDownDialogFragment.java @@ -18,6 +18,7 @@ public class ServerDownDialogFragment extends AppCompatDialogFragment { + @SuppressWarnings("unused") public static ServerDownDialogFragment newInstance() { return new ServerDownDialogFragment(); } From 7bdcce501cc84be6ff6116b89589ee92fae183ed Mon Sep 17 00:00:00 2001 From: Jeremy Jao Date: Wed, 24 May 2017 19:24:55 -0400 Subject: [PATCH 2/2] add a 3 dot menu `No buses?` for future reference --- .../com/pittsburghrealtimetracker/SelectTransit.java | 10 ++++++++++ app/src/main/res/menu/select_transit.xml | 5 +++++ 2 files changed, 15 insertions(+) diff --git a/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/SelectTransit.java b/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/SelectTransit.java index 5bce1fbe..08586472 100644 --- a/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/SelectTransit.java +++ b/app/src/main/java/rectangledbmi/com/pittsburghrealtimetracker/SelectTransit.java @@ -460,4 +460,14 @@ public void onClickDetourInfo(MenuItem item) { public void onClickAppDetails(MenuItem item) { openPermissionsPage(); } + + private void openNoBusesWebpage() { + Uri url = Uri.parse("https://github.com/rectangle-dbmi/Realtime-Port-Authority/wiki/Port-Authority-Server-Downtimes"); + Intent internetBrowser = new Intent(Intent.ACTION_VIEW, url); + startActivity(internetBrowser); + } + + public void onClickNoBuses(MenuItem item) { + openNoBusesWebpage(); + } } diff --git a/app/src/main/res/menu/select_transit.xml b/app/src/main/res/menu/select_transit.xml index 77dc7211..5b0f929b 100644 --- a/app/src/main/res/menu/select_transit.xml +++ b/app/src/main/res/menu/select_transit.xml @@ -23,5 +23,10 @@ android:title="@string/action_about" android:orderInCategory="400" appcompat:showAsAction="never" /> +