Revert "Migrate to CompoundButton.OnCheckedChangeListener"

Revert submission 25147565-onSwitchChanged-CompoundButton

Reason for revert: breaking builds 

Bug:309601476

Reverted changes: /q/submissionid:25147565-onSwitchChanged-CompoundButton

Change-Id: Ie746db87d9c642599593aa3d5e5baf6b7ba89c0e
This commit is contained in:
Sebastian Pickl
2023-11-07 13:26:36 +00:00
committed by Android (Google) Code Review
parent 71d1f021af
commit 8979681a8d
49 changed files with 188 additions and 174 deletions

View File

@@ -38,8 +38,7 @@ import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.CompoundButton;
import android.widget.CompoundButton.OnCheckedChangeListener;
import android.widget.Switch;
import androidx.appcompat.app.AlertDialog;
import androidx.preference.Preference;
@@ -56,6 +55,7 @@ import com.android.settings.Utils;
import com.android.settings.core.SubSettingLauncher;
import com.android.settings.network.ims.WifiCallingQueryImsState;
import com.android.settings.widget.SettingsMainSwitchPreference;
import com.android.settingslib.widget.OnMainSwitchChangeListener;
import java.util.List;
@@ -64,7 +64,7 @@ import java.util.List;
* The preference screen lets you enable/disable Wi-Fi Calling and change Wi-Fi Calling mode.
*/
public class WifiCallingSettingsForSub extends SettingsPreferenceFragment
implements OnCheckedChangeListener,
implements OnMainSwitchChangeListener,
Preference.OnPreferenceChangeListener {
private static final String TAG = "WifiCallingForSub";
@@ -463,7 +463,7 @@ public class WifiCallingSettingsForSub extends SettingsPreferenceFragment
* Listens to the state change of the switch.
*/
@Override
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
public void onSwitchChanged(Switch switchView, boolean isChecked) {
Log.d(TAG, "onSwitchChanged(" + isChecked + ")");
if (!isChecked) {