Fix potential ASurfaceTransactionCallback leaks

Change the rerferene to java object from global reference to weak
reference.

Bug: 188555236
Test: check number of ViewRootImpl objects from Systrace
Change-Id: I52347b9efb211691826635d046259bc3c54b194f
2 files changed