diff --git a/CHANGELOG.md b/CHANGELOG.md index ef8dbf97..d9bdad8a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ ###Changelog +###Version next +* Applied some material design guidelines to Charts and (pebble) app management + ###Version 0.18.4 * Mi Band 2: Display realtime steps in Live Activity * Mi Band: Attempt to recognize Mi Band model with hwVersion = 8 diff --git a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/AbstractGBFragment.java b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/AbstractGBFragment.java index 66858bf1..d9939ba0 100644 --- a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/AbstractGBFragment.java +++ b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/AbstractGBFragment.java @@ -18,7 +18,6 @@ package nodomain.freeyourgadget.gadgetbridge.activities; import android.support.annotation.Nullable; import android.support.v4.app.Fragment; -import android.support.v4.app.FragmentActivity; /** * Abstract base class for fragments. Provides hooks that are called when @@ -37,7 +36,6 @@ public abstract class AbstractGBFragment extends Fragment { * @see #onMadeInvisibleInActivity() */ protected void onMadeVisibleInActivity() { - updateActivityTitle(); } /** @@ -58,15 +56,6 @@ public abstract class AbstractGBFragment extends Fragment { return mVisibleInactivity; } - protected void updateActivityTitle() { - FragmentActivity activity = getActivity(); - if (activity != null && !activity.isFinishing() && !activity.isDestroyed()) { - if (getTitle() != null) { - activity.setTitle(getTitle()); - } - } - } - @Nullable protected abstract CharSequence getTitle(); diff --git a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/ChartsActivity.java b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/ChartsActivity.java index d5dedfc2..2b73b192 100644 --- a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/ChartsActivity.java +++ b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/ChartsActivity.java @@ -27,7 +27,6 @@ import android.support.v4.app.Fragment; import android.support.v4.app.FragmentManager; import android.support.v4.app.FragmentStatePagerAdapter; import android.support.v4.content.LocalBroadcastManager; -import android.support.v4.view.PagerTabStrip; import android.support.v4.view.ViewPager; import android.support.v4.widget.SwipeRefreshLayout; import android.view.Menu; @@ -67,7 +66,6 @@ public class ChartsActivity extends AbstractGBFragmentActivity implements Charts private Date mStartDate; private Date mEndDate; private SwipeRefreshLayout swipeLayout; - private PagerTabStrip mPagerTabStrip; private ViewPager viewPager; LimitedQueue mActivityAmountCache = new LimitedQueue(60); @@ -200,7 +198,6 @@ public class ChartsActivity extends AbstractGBFragmentActivity implements Charts handleNextButtonClicked(); } }); - mPagerTabStrip = (PagerTabStrip) findViewById(R.id.charts_pagerTabStrip); LinearLayout mainLayout = (LinearLayout) findViewById(R.id.charts_main_layout); } diff --git a/app/src/main/res/layout/activity_charts.xml b/app/src/main/res/layout/activity_charts.xml index bce48082..6321f441 100644 --- a/app/src/main/res/layout/activity_charts.xml +++ b/app/src/main/res/layout/activity_charts.xml @@ -1,56 +1,59 @@ - - + android:layout_height="match_parent" + tools:context="nodomain.freeyourgadget.gadgetbridge.activities.charts.ChartsActivity"> -