Generating a long-press even only when it's expected

I'm pretty sure that accidental long-presses are a result of fundamental
flaws in UIAutomator. The fix is tracked separately and is unlikely to
happen at all.

For now, just placing the generation under a condition.

Bug: 156113558
Change-Id: I8f369f934f9f576cf672b7fa98fbc9a63135602b
1 file changed