Skip to content

Commit

Permalink
Fixed memoryleak, removed log and unnecessary import
Browse files Browse the repository at this point in the history
  • Loading branch information
amirzaidi committed Jun 14, 2017
1 parent b78e6bc commit 81818f0
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
5 changes: 2 additions & 3 deletions src/com/android/launcher3/SuperLauncherCallbacks.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,8 @@ public void preOnCreate() {

@Override
public void onCreate(Bundle savedInstanceState) {
SharedPreferences prefs = Utilities.getPrefs(mLauncher);
this.cD = com.android.launcher3.reflection.l.getInstance(mLauncher);
prefs.registerOnSharedPreferenceChangeListener(this);
Utilities.getPrefs(mLauncher).registerOnSharedPreferenceChangeListener(this);
}

@Override
Expand Down Expand Up @@ -64,7 +63,7 @@ public void onPause() {

@Override
public void onDestroy() {

Utilities.getPrefs(mLauncher).unregisterOnSharedPreferenceChangeListener(this);
}

@Override
Expand Down
1 change: 0 additions & 1 deletion src/com/android/launcher3/reflection/j.java
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,6 @@ public void aD(final String s) {
if (ProviderConfig.IS_DOGFOOD_BUILD && ab.size() == 0) {
FileLog.d("Reflection.SvcHandler", "predictions.size() == 0. Are every applications on the firstpage/hotseat?");
}
Log.d("j", "doing predictions");
this.aX.U(ab);
if (a != null) {
this.aQ.J(a);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
import android.os.PatternMatcher;
import android.os.Process;
import android.os.RemoteException;
import android.provider.Telephony;
import android.util.Log;
import android.view.Window;
import android.view.WindowManager;
Expand Down

0 comments on commit 81818f0

Please sign in to comment.