Refactor BeforeInstallPromptEvent to use ScriptPromiseProperty

This stops the event holding a ScriptPromise as a member, which may 
lead to a memory leak. Instead, ScriptPromiseProperty members are held
as members in the event. A WebCallbacks subclass is used to store a
pointer to the necessary ScriptPromiseProperty in the associated event,
with the interface exposed to Chromium. When a banner event is resolved,
the WebCallbacks implementation in modules/app_banner looks up the 
ScriptPromiseProperty and resolves its promise. This also makes
resolving the prompt promise simpler as well, as it occurs entirely in the
event.

This CL also removes the app-banner-event-prompt.html test from 
LeakExpectations, and fixes some bugs in the test relating to promise
resolution.

BUG=504675

Review URL: https://codereview.chromium.org/1247283004

git-svn-id: svn://svn.chromium.org/blink/trunk@199472 bbb929c8-8fbe-4397-9dbb-9b2b20218538
11 files changed
tree: bda3a8748ce99aaa35f369d35651c5d1d7e8b80d
  1. third_party/