Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5f08c979 authored by Myles Watson's avatar Myles Watson
Browse files

OPP: Standardize date in dump()

Match the output in logcat/bug reports.

"MM-dd HH:mm:ss"

Profile: BluetoothOppService
  Shares:
    01-16 22:38:40 -> 0/1800301
    01-16 22:39:23 -> 0/1800301
    01-17 17:43:34 -> 1800301/1800301

Test: adb shell dumpsys bluetooth_manager
Change-Id: I39f904afe8a7b245cdf4fe6d1a6e93ef584f13a9
parent f29d578e
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -255,10 +255,10 @@ public class BluetoothOppService extends ProfileService implements IObexConnecti
            println(sb, "Shares:");
            for (BluetoothOppShareInfo info : mShares) {
                String dir = info.mDirection == BluetoothShare.DIRECTION_OUTBOUND ? " -> " : " <- ";
                SimpleDateFormat format = new SimpleDateFormat("MM'.'dd'@'HH':'mm':'ss", Locale.US);
                SimpleDateFormat format = new SimpleDateFormat("MM-dd HH:mm:ss", Locale.US);
                Date date = new Date(info.mTimestamp);
                println(sb, "  " + format.format(date) + ": " + dir + " " + info.mCurrentBytes + "/"
                        + info.mTotalBytes + "B ");
                println(sb, "  " + format.format(date) + dir + info.mCurrentBytes + "/"
                        + info.mTotalBytes);
            }
        }
    }