Loading src/com/android/settings/bluetooth/BluetoothDetailsButtonsController.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -79,7 +79,7 @@ public class BluetoothDetailsButtonsController extends BluetoothDetailsControlle .setButton2Text(R.string.bluetooth_device_context_connect) .setButton2Text(R.string.bluetooth_device_context_connect) .setButton2Icon(R.drawable.ic_add_24dp) .setButton2Icon(R.drawable.ic_add_24dp) .setButton2OnClickListener( .setButton2OnClickListener( view -> mCachedDevice.connect(true /* connectAllProfiles */)); view -> mCachedDevice.connect()); mConnectButtonInitialized = true; mConnectButtonInitialized = true; } } } } Loading src/com/android/settings/bluetooth/BluetoothDevicePreference.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -241,7 +241,7 @@ public final class BluetoothDevicePreference extends GearPreference implements } else if (bondState == BluetoothDevice.BOND_BONDED) { } else if (bondState == BluetoothDevice.BOND_BONDED) { metricsFeatureProvider.action(context, metricsFeatureProvider.action(context, SettingsEnums.ACTION_SETTINGS_BLUETOOTH_CONNECT); SettingsEnums.ACTION_SETTINGS_BLUETOOTH_CONNECT); mCachedDevice.connect(true); mCachedDevice.connect(); } else if (bondState == BluetoothDevice.BOND_NONE) { } else if (bondState == BluetoothDevice.BOND_NONE) { metricsFeatureProvider.action(context, metricsFeatureProvider.action(context, SettingsEnums.ACTION_SETTINGS_BLUETOOTH_PAIR); SettingsEnums.ACTION_SETTINGS_BLUETOOTH_PAIR); Loading src/com/android/settings/bluetooth/SavedBluetoothDeviceUpdater.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -57,7 +57,7 @@ public class SavedBluetoothDeviceUpdater extends BluetoothDeviceUpdater mMetricsFeatureProvider.logClickedPreference(preference, mFragment.getMetricsCategory()); mMetricsFeatureProvider.logClickedPreference(preference, mFragment.getMetricsCategory()); final CachedBluetoothDevice device = ((BluetoothDevicePreference) preference) final CachedBluetoothDevice device = ((BluetoothDevicePreference) preference) .getBluetoothDevice(); .getBluetoothDevice(); device.connect(true); device.connect(); return true; return true; } } Loading tests/robotests/src/com/android/settings/bluetooth/BluetoothDetailsButtonsControllerTest.java +2 −3 Original line number Original line Diff line number Diff line Loading @@ -22,7 +22,6 @@ import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.anyBoolean; import static org.mockito.ArgumentMatchers.anyBoolean; import static org.mockito.ArgumentMatchers.anyInt; import static org.mockito.ArgumentMatchers.anyInt; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.ArgumentMatchers.eq; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; import static org.mockito.Mockito.when; Loading Loading @@ -103,7 +102,7 @@ public class BluetoothDetailsButtonsControllerTest extends BluetoothDetailsContr verify(mButtonsPref).setButton2Text(R.string.bluetooth_device_context_connect); verify(mButtonsPref).setButton2Text(R.string.bluetooth_device_context_connect); mConnectButton.callOnClick(); mConnectButton.callOnClick(); verify(mCachedDevice).connect(eq(true)); verify(mCachedDevice).connect(); } } @Test @Test Loading @@ -119,7 +118,7 @@ public class BluetoothDetailsButtonsControllerTest extends BluetoothDetailsContr // Click the button and make sure that connect (not disconnect) gets called. // Click the button and make sure that connect (not disconnect) gets called. mConnectButton.callOnClick(); mConnectButton.callOnClick(); verify(mCachedDevice).connect(eq(true)); verify(mCachedDevice).connect(); } } @Test @Test Loading tests/robotests/src/com/android/settings/bluetooth/SavedBluetoothDeviceUpdaterTest.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -122,6 +122,6 @@ public class SavedBluetoothDeviceUpdaterTest { public void onClick_Preference_setConnect() { public void onClick_Preference_setConnect() { mBluetoothDeviceUpdater.onPreferenceClick(mPreference); mBluetoothDeviceUpdater.onPreferenceClick(mPreference); verify(mCachedBluetoothDevice).connect(true); verify(mCachedBluetoothDevice).connect(); } } } } Loading
src/com/android/settings/bluetooth/BluetoothDetailsButtonsController.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -79,7 +79,7 @@ public class BluetoothDetailsButtonsController extends BluetoothDetailsControlle .setButton2Text(R.string.bluetooth_device_context_connect) .setButton2Text(R.string.bluetooth_device_context_connect) .setButton2Icon(R.drawable.ic_add_24dp) .setButton2Icon(R.drawable.ic_add_24dp) .setButton2OnClickListener( .setButton2OnClickListener( view -> mCachedDevice.connect(true /* connectAllProfiles */)); view -> mCachedDevice.connect()); mConnectButtonInitialized = true; mConnectButtonInitialized = true; } } } } Loading
src/com/android/settings/bluetooth/BluetoothDevicePreference.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -241,7 +241,7 @@ public final class BluetoothDevicePreference extends GearPreference implements } else if (bondState == BluetoothDevice.BOND_BONDED) { } else if (bondState == BluetoothDevice.BOND_BONDED) { metricsFeatureProvider.action(context, metricsFeatureProvider.action(context, SettingsEnums.ACTION_SETTINGS_BLUETOOTH_CONNECT); SettingsEnums.ACTION_SETTINGS_BLUETOOTH_CONNECT); mCachedDevice.connect(true); mCachedDevice.connect(); } else if (bondState == BluetoothDevice.BOND_NONE) { } else if (bondState == BluetoothDevice.BOND_NONE) { metricsFeatureProvider.action(context, metricsFeatureProvider.action(context, SettingsEnums.ACTION_SETTINGS_BLUETOOTH_PAIR); SettingsEnums.ACTION_SETTINGS_BLUETOOTH_PAIR); Loading
src/com/android/settings/bluetooth/SavedBluetoothDeviceUpdater.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -57,7 +57,7 @@ public class SavedBluetoothDeviceUpdater extends BluetoothDeviceUpdater mMetricsFeatureProvider.logClickedPreference(preference, mFragment.getMetricsCategory()); mMetricsFeatureProvider.logClickedPreference(preference, mFragment.getMetricsCategory()); final CachedBluetoothDevice device = ((BluetoothDevicePreference) preference) final CachedBluetoothDevice device = ((BluetoothDevicePreference) preference) .getBluetoothDevice(); .getBluetoothDevice(); device.connect(true); device.connect(); return true; return true; } } Loading
tests/robotests/src/com/android/settings/bluetooth/BluetoothDetailsButtonsControllerTest.java +2 −3 Original line number Original line Diff line number Diff line Loading @@ -22,7 +22,6 @@ import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.anyBoolean; import static org.mockito.ArgumentMatchers.anyBoolean; import static org.mockito.ArgumentMatchers.anyInt; import static org.mockito.ArgumentMatchers.anyInt; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.ArgumentMatchers.eq; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; import static org.mockito.Mockito.when; Loading Loading @@ -103,7 +102,7 @@ public class BluetoothDetailsButtonsControllerTest extends BluetoothDetailsContr verify(mButtonsPref).setButton2Text(R.string.bluetooth_device_context_connect); verify(mButtonsPref).setButton2Text(R.string.bluetooth_device_context_connect); mConnectButton.callOnClick(); mConnectButton.callOnClick(); verify(mCachedDevice).connect(eq(true)); verify(mCachedDevice).connect(); } } @Test @Test Loading @@ -119,7 +118,7 @@ public class BluetoothDetailsButtonsControllerTest extends BluetoothDetailsContr // Click the button and make sure that connect (not disconnect) gets called. // Click the button and make sure that connect (not disconnect) gets called. mConnectButton.callOnClick(); mConnectButton.callOnClick(); verify(mCachedDevice).connect(eq(true)); verify(mCachedDevice).connect(); } } @Test @Test Loading
tests/robotests/src/com/android/settings/bluetooth/SavedBluetoothDeviceUpdaterTest.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -122,6 +122,6 @@ public class SavedBluetoothDeviceUpdaterTest { public void onClick_Preference_setConnect() { public void onClick_Preference_setConnect() { mBluetoothDeviceUpdater.onPreferenceClick(mPreference); mBluetoothDeviceUpdater.onPreferenceClick(mPreference); verify(mCachedBluetoothDevice).connect(true); verify(mCachedBluetoothDevice).connect(); } } } }