core/commands/native_tap/android_native_tap
library
Functions
-
androidUiDumpFileFor({required int pid, required int timestampMs})
→ String
-
Where
uiautomator dump writes when /dev/tty doesn't work: unique per
fdb invocation so concurrent runs never read each other's dump. Under
/data/local/tmp because the shell user can always write there, unlike
/sdcard on some devices.
-
classifyAndroidInputTap({required int exitCode, required String stdout, required String stderr})
→ NativeTapResult?
-
Classifies the output of
adb shell input tap. Returns null when the tap
went through.
-
isAndroidIdleStateError(String reason)
→ bool
-
True for uiautomator's "could not get idle state" error: the screen kept
changing while it waited.
-
logicalToPhysical(double x, double y, double devicePixelRatio)
→ ({int x, int y})
-
Converts Flutter logical pixels to the physical pixels
input tap takes.
-
nativeTapAndroid(NativeTapInput input, {required String? deviceId, AdbRunner? adb, AppDevicePixelRatioReader? appDevicePixelRatio, DateTime now()?, Future<void> sleep(Duration)?, String? dumpFile})
→ Future<NativeTapResult>
-
Android side of
fdb native-tap: by coordinates (--at, optionally
--logical) or by label (--text).
-
parseWmDensity(String output)
→ int?
-
Reads the density Android uses for layout from
adb shell wm density:
the override density when set, else the physical density. Returns null
when neither is present.
-
readAppDevicePixelRatio()
→ Future<double?>
-
Asks the running app for its FlutterView's device pixel ratio via
ext.fdb.lifecycle. Null when there is no app session, fdb_helper is
older than the field, or the call takes over 2 s.