From 156ff4ec938afc24b396f8e134313f17123fadeb Mon Sep 17 00:00:00 2001 From: Milos Kozak Date: Tue, 13 Aug 2019 08:20:20 +0200 Subject: [PATCH] Remove HandlerThread from MedtronicHistoryActivity --- .../dialog/MedtronicHistoryActivity.java | 28 ++++++------------- 1 file changed, 9 insertions(+), 19 deletions(-) diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/pump/medtronic/dialog/MedtronicHistoryActivity.java b/app/src/main/java/info/nightscout/androidaps/plugins/pump/medtronic/dialog/MedtronicHistoryActivity.java index e5cf10f765..9f148ac02e 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/pump/medtronic/dialog/MedtronicHistoryActivity.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/pump/medtronic/dialog/MedtronicHistoryActivity.java @@ -1,18 +1,7 @@ package info.nightscout.androidaps.plugins.pump.medtronic.dialog; -import java.util.ArrayList; -import java.util.List; - -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -import android.app.Activity; import android.os.Bundle; -import android.os.Handler; -import android.os.HandlerThread; import android.os.SystemClock; -import androidx.recyclerview.widget.LinearLayoutManager; -import androidx.recyclerview.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; @@ -21,6 +10,15 @@ import android.widget.ArrayAdapter; import android.widget.Spinner; import android.widget.TextView; +import androidx.recyclerview.widget.LinearLayoutManager; +import androidx.recyclerview.widget.RecyclerView; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.List; + import info.nightscout.androidaps.MainApp; import info.nightscout.androidaps.R; import info.nightscout.androidaps.activities.NoSplashActivity; @@ -33,10 +31,6 @@ public class MedtronicHistoryActivity extends NoSplashActivity { private static Logger LOG = LoggerFactory.getLogger(L.PUMP); - private Handler mHandler; - - // static Profile profile = null; - Spinner historyTypeSpinner; TextView statusView; RecyclerView recyclerView; @@ -54,10 +48,6 @@ public class MedtronicHistoryActivity extends NoSplashActivity { public MedtronicHistoryActivity() { super(); - HandlerThread mHandlerThread = new HandlerThread(MedtronicHistoryActivity.class.getSimpleName()); - mHandlerThread.start(); - filterHistory(PumpHistoryEntryGroup.All); - this.mHandler = new Handler(mHandlerThread.getLooper()); }