Ensure that native WindowAndroid outlives native AwContents.
ContentViewCore holds a window pointer that is used during destruction of native AwContents to remove observers. However the current CleanupReference based finalization scheme does not enforce an ordering on the destruction of native WindowAndroid and AwContents instances. Satisfaction of the constraint that AwContents is destroyed before WindowAndroid is therefore dependent on the CleanupReference implementation, and possibly the implementation of the JVM as well. Making the AwContents DestroyRunnable strongly reference the associated WindowAndroidWrapper enforces the correct ordering. BUG=595336 Review URL: https://codereview.chromium.org/1809643002 Cr-Commit-Position: refs/heads/master@{#381675}
Showing
Please register or sign in to comment