Search in sources :

Example 1 with SubscriptionsChangeListener

use of com.android.settings.network.SubscriptionsChangeListener in project Resurrection_packages_apps_Settings by ResurrectionRemix.

the class SimDialogFragment method onAttach.

@Override
public void onAttach(Context context) {
    super.onAttach(context);
    mChangeListener = new SubscriptionsChangeListener(context, this);
}
Also used : SubscriptionsChangeListener(com.android.settings.network.SubscriptionsChangeListener)

Example 2 with SubscriptionsChangeListener

use of com.android.settings.network.SubscriptionsChangeListener in project android_packages_apps_Settings by omnirom.

the class SimDialogFragment method onAttach.

@Override
public void onAttach(Context context) {
    super.onAttach(context);
    Log.d(TAG, "Dialog Attached.");
    mWasDismissed = false;
    mChangeListener = new SubscriptionsChangeListener(context, this);
}
Also used : SubscriptionsChangeListener(com.android.settings.network.SubscriptionsChangeListener)

Example 3 with SubscriptionsChangeListener

use of com.android.settings.network.SubscriptionsChangeListener in project android_packages_apps_Settings by omnirom.

the class DataDuringCallsPreferenceController method onResume.

@OnLifecycleEvent(ON_RESUME)
public void onResume() {
    if (mChangeListener == null) {
        mChangeListener = new SubscriptionsChangeListener(mContext, this);
    }
    mChangeListener.start();
    if (mMobileDataContentObserver == null) {
        mMobileDataContentObserver = new MobileDataContentObserver(new Handler(Looper.getMainLooper()));
        mMobileDataContentObserver.setOnMobileDataChangedListener(() -> refreshPreference());
    }
    mMobileDataContentObserver.register(mContext, mSubId);
}
Also used : MobileDataContentObserver(com.android.settings.network.MobileDataContentObserver) SubscriptionsChangeListener(com.android.settings.network.SubscriptionsChangeListener) Handler(android.os.Handler) OnLifecycleEvent(androidx.lifecycle.OnLifecycleEvent)

Aggregations

SubscriptionsChangeListener (com.android.settings.network.SubscriptionsChangeListener)3 Handler (android.os.Handler)1 OnLifecycleEvent (androidx.lifecycle.OnLifecycleEvent)1 MobileDataContentObserver (com.android.settings.network.MobileDataContentObserver)1