mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-01-13 11:17:33 +01:00
Misc improvelets (#45)
This commit is contained in:
parent
c9ab10e7e8
commit
1f2b0329c5
@ -76,7 +76,6 @@ public class ChartsActivity extends FragmentActivity {
|
|||||||
boolean wasBusy = mProgressBar.getVisibility() != View.GONE;
|
boolean wasBusy = mProgressBar.getVisibility() != View.GONE;
|
||||||
if (wasBusy) {
|
if (wasBusy) {
|
||||||
mProgressBar.setVisibility(View.GONE);
|
mProgressBar.setVisibility(View.GONE);
|
||||||
// TODO: refresh current fragment
|
|
||||||
LocalBroadcastManager.getInstance(this).sendBroadcast(new Intent(AbstractChartFragment.ACTION_REFRESH));
|
LocalBroadcastManager.getInstance(this).sendBroadcast(new Intent(AbstractChartFragment.ACTION_REFRESH));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -104,7 +104,8 @@ public class SleepChartFragment extends AbstractChartFragment {
|
|||||||
data.setDataSet(set);
|
data.setDataSet(set);
|
||||||
pieChart.setData(data);
|
pieChart.setData(data);
|
||||||
|
|
||||||
setupLegend(pieChart);
|
pieChart.getLegend().setEnabled(false);
|
||||||
|
//setupLegend(pieChart);
|
||||||
|
|
||||||
pieChart.invalidate();
|
pieChart.invalidate();
|
||||||
}
|
}
|
||||||
|
@ -21,6 +21,10 @@ public class CustomLegendRenderer extends LegendRenderer {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void computeLegend(ChartData<?> data) {
|
public void computeLegend(ChartData<?> data) {
|
||||||
|
if (!mLegend.isEnabled()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// don't call super to avoid computing colors and labels
|
// don't call super to avoid computing colors and labels
|
||||||
// super.computeLegend(data);
|
// super.computeLegend(data);
|
||||||
|
|
||||||
|
@ -7,6 +7,8 @@
|
|||||||
|
|
||||||
<item
|
<item
|
||||||
android:id="@+id/charts_fetch_activity_data"
|
android:id="@+id/charts_fetch_activity_data"
|
||||||
|
app:showAsAction="ifRoom"
|
||||||
|
android:icon="@android:drawable/stat_notify_sync_noanim"
|
||||||
android:title="@string/controlcenter_fetch_activity_data"/>
|
android:title="@string/controlcenter_fetch_activity_data"/>
|
||||||
|
|
||||||
</menu>
|
</menu>
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<string name="action_settings">Settings</string>
|
<string name="action_settings">Settings</string>
|
||||||
<string name="action_debug">Debug</string>
|
<string name="action_debug">Debug</string>
|
||||||
<string name="action_quit">Quit</string>
|
<string name="action_quit">Quit</string>
|
||||||
<string name="controlcenter_fetch_activity_data">Fetch Activity Data</string>
|
<string name="controlcenter_fetch_activity_data">Synchronize</string>
|
||||||
<string name="controlcenter_start_sleepmonitor">Sleep Monitor (ALPHA)</string>
|
<string name="controlcenter_start_sleepmonitor">Sleep Monitor (ALPHA)</string>
|
||||||
<string name="controlcenter_find_device">Find Device…</string>
|
<string name="controlcenter_find_device">Find Device…</string>
|
||||||
<string name="controlcenter_take_screenshot">Take Screenshot</string>
|
<string name="controlcenter_take_screenshot">Take Screenshot</string>
|
||||||
@ -137,7 +137,7 @@
|
|||||||
<string name="pref_screen_notification_profile_incoming_call">Incoming Call Notification</string>
|
<string name="pref_screen_notification_profile_incoming_call">Incoming Call Notification</string>
|
||||||
<string name="control_center_find_lost_device">Find lost Device</string>
|
<string name="control_center_find_lost_device">Find lost Device</string>
|
||||||
<string name="control_center_cancel_to_stop_vibration">Cancel to stop vibration.</string>
|
<string name="control_center_cancel_to_stop_vibration">Cancel to stop vibration.</string>
|
||||||
<string name="title_activity_charts">ChartsActivity</string>
|
<string name="title_activity_charts">Your Activity</string>
|
||||||
<string name="title_activity_set_alarm">Configure Alarms</string>
|
<string name="title_activity_set_alarm">Configure Alarms</string>
|
||||||
<string name="controlcenter_start_configure_alarms">Configure alarms</string>
|
<string name="controlcenter_start_configure_alarms">Configure alarms</string>
|
||||||
<string name="title_activity_alarm_details">Alarm Details</string>
|
<string name="title_activity_alarm_details">Alarm Details</string>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user