mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-29 15:52:07 +00:00
5990b7245c
When copying from the input field, when the value has already been confirmed by the user (either by picking a result or Enter), we cannot use the selected result information, because it has already been cleared by _loadURL setting the value to the final one. If the page already finished loading, pageproxystate is valid and we can use currentURI, but if the page takes a long time to load, or the load is canceled, we need a fallback, because we don't want to interrupt the copy operation. In this case, the current value can be either a valid url or a search string. If it's a valid url, we can just go through the usual URI handling, trying to make it nicer. After all, we'd do the same just after the page is done loading. Otherwise, we fallback to the currently selected value. This works also if the user is still in the process of selecting a result and tries to copy from the input field, because on result selection we set either a valid url or a non-url. Differential Revision: https://phabricator.services.mozilla.com/D50832 --HG-- extra : moz-landing-system : lando |
||
---|---|---|
.. | ||
actors | ||
app | ||
base | ||
branding | ||
components | ||
config | ||
docs | ||
extensions | ||
fonts | ||
fxr | ||
installer | ||
locales | ||
modules | ||
themes | ||
tools/mozscreenshots | ||
.eslintrc.js | ||
app.mozbuild | ||
build.mk | ||
confvars.sh | ||
defs.mk | ||
l10n-registry.manifest | ||
LICENSE | ||
Makefile.in | ||
moz.build | ||
moz.configure |