1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-10-18 17:29:35 +02:00

Improve logging

This commit is contained in:
cpfeiffer 2018-08-06 20:20:54 +02:00
parent f7c9828cc1
commit 92bd3122f3
3 changed files with 10 additions and 2 deletions

View File

@ -18,6 +18,9 @@ package nodomain.freeyourgadget.gadgetbridge.deviceevents;
public abstract class GBDeviceEvent {
@Override
public String toString() {
return getClass().getSimpleName() + ": ";
}
}

View File

@ -22,4 +22,9 @@ import nodomain.freeyourgadget.gadgetbridge.R;
public class GBDeviceEventVersionInfo extends GBDeviceEvent {
public String fwVersion = GBApplication.getContext().getString(R.string.n_a);
public String hwVersion = GBApplication.getContext().getString(R.string.n_a);
@Override
public String toString() {
return super.toString() + "fwVersion: " + fwVersion + "; hwVersion: " + hwVersion;
}
}

View File

@ -199,7 +199,7 @@ public abstract class AbstractDeviceSupport implements DeviceSupport {
protected void handleGBDeviceEvent(GBDeviceEventVersionInfo infoEvent) {
Context context = getContext();
LOG.info("Got event for VERSION_INFO");
LOG.info("Got event for VERSION_INFO: " + infoEvent);
if (gbDevice == null) {
return;
}