1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-12-25 01:55:50 +01:00

only allow starting AppManager after device is initalized (else platform cant be determined)

This commit is contained in:
Andreas Shimokawa 2016-03-03 14:29:46 +01:00
parent 902ff39c0b
commit 864e0953d9

View File

@ -131,7 +131,7 @@ public class ControlCenter extends Activity {
@Override
public void onItemClick(AdapterView parent, View v, int position, long id) {
GBDevice gbDevice = deviceList.get(position);
if (gbDevice.isConnected()) {
if (gbDevice.isInitialized()) {
DeviceCoordinator coordinator = DeviceHelper.getInstance().getCoordinator(gbDevice);
Class<? extends Activity> primaryActivity = coordinator.getPrimaryActivity();
if (primaryActivity != null) {