Adobe-Runtime-Support
Adobe-Runtime-Support copied to clipboard
[Windows][macOS] HTMLLoader.isSupported returns true
Problem Description
HTMLLoader.isSupported utility returns true with Windows and macOS but HTMLLoader now legacy and removed. So it should returns false I think.
Tested with latest AIR 33.1.1.821 with multiple Windows and macOS devices.
Related issue (no the same): https://github.com/airsdk/Adobe-Runtime-Support/issues/1106
Steps to Reproduce
Launch code below.
Application example with sources attached. htmlloader_issupported_bug.zip
trace(HTMLLoader.isSupported);//returns true
Actual Result:
true will be traced.
Expected Result:
false will be traced.
Known Workarounds
Just not use HTMLLoader.
The same issue with Linux too. Checked with latest AIR 50.0.0.1.
HTMLLoader.isSupported returns true.
But var html:HTMLLoader = new HTMLLoader(); cause error:
Error: Error #1001: The method StageWebView is not implemented.
at flash.media::StageWebView/init()
at flash.media::StageWebView()
at flash.html::HTMLLoader()
I take the point on Linux, but am wondering whether we should keep the HTMLLoader.isSupported true even when it's just backed by the native StageWebView..
@ajwfrost My opinion - HTMLLoader.isSupported should return false if WebKit (current legacy implementation) not supported anymore. If you have another opinion - ok, just write that such behavior expected.
But for Linux it should return false anyway until any webview implementation (StageWebView too) not supported.
And ideally legacy HTMLLoader should be replaced by something modern. Many discussions about it: https://github.com/airsdk/Adobe-Runtime-Support/issues/1438 https://github.com/airsdk/Adobe-Runtime-Support/issues/1854 https://github.com/airsdk/Adobe-Runtime-Support/issues/1428 https://github.com/airsdk/Adobe-Runtime-Support/issues/223 https://github.com/airsdk/Adobe-Runtime-Support/issues/214 https://github.com/airsdk/Adobe-Runtime-Support/issues/143 https://github.com/airsdk/Adobe-Runtime-Support/issues/1453
With latest AIR 50.0.1.1 for Linux HTMLLoader.isSupported returns false. Thanks!
@ajwfrost, if no plans to make similar changes for Windows/macOS cause it "by design" - I think this issue should be closed.
Yes, right now we're looking to keep HTMLLoader.isSupported to be true on Windows/macOS, if you need to know whether the functionality is backed by the WebKit or the StageWebView component then you could perhaps also query the runtime version number (33.1.1.758 and later do not have it...)