[embedlite-components] Improve user-agent override handling. Contributes to JB#39252
Try also map URI of the nsILoadInfo's loadingPrincipal to overrides. The URI of channel is tested first if that does not have override, then loading principal's uri is tested. Final fallback is the default user agent. Now we do not need double bookkeeping as all bookkeeping is done now by UserAgentOverrides.jsm. Thus, related code has been cleaned.
Showing with 47 additions and 71 deletions