Don't keep a reference to context here,
it's a leak and not used anyway.
This commit is contained in:
parent
6fca6d918c
commit
d4c0f62b1d
|
@ -3,7 +3,6 @@ package org.moire.ultrasonic.view;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.os.Handler;
|
import android.os.Handler;
|
||||||
import android.os.Looper;
|
import android.os.Looper;
|
||||||
import timber.log.Timber;
|
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.AbsListView;
|
import android.widget.AbsListView;
|
||||||
import android.widget.LinearLayout;
|
import android.widget.LinearLayout;
|
||||||
|
@ -14,6 +13,8 @@ import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.WeakHashMap;
|
import java.util.WeakHashMap;
|
||||||
|
|
||||||
|
import timber.log.Timber;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A View that is periodically refreshed
|
* A View that is periodically refreshed
|
||||||
* @deprecated
|
* @deprecated
|
||||||
|
@ -26,12 +27,10 @@ public class UpdateView extends LinearLayout
|
||||||
private static Handler backgroundHandler;
|
private static Handler backgroundHandler;
|
||||||
private static Handler uiHandler;
|
private static Handler uiHandler;
|
||||||
private static Runnable updateRunnable;
|
private static Runnable updateRunnable;
|
||||||
private static Context context;
|
|
||||||
|
|
||||||
public UpdateView(Context context)
|
public UpdateView(Context context)
|
||||||
{
|
{
|
||||||
super(context);
|
super(context);
|
||||||
UpdateView.context = context;
|
|
||||||
|
|
||||||
setLayoutParams(new AbsListView.LayoutParams(ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT));
|
setLayoutParams(new AbsListView.LayoutParams(ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT));
|
||||||
INSTANCES.put(this, null);
|
INSTANCES.put(this, null);
|
||||||
|
|
Loading…
Reference in New Issue