Fix crash on exit: PageClickTracker is deleted twice
Support media enumerable API from upstream 30

sync with upstream c129874dc579801d403c521fe0ebe38fbc1cf2f2
Fix #632
[test] Test-case for crash dump