"javascript:" urls: clean up after aborting a page load

Problem:
  After aborting on a 204 or 205 status code, you could no longer
  follow links on the page.

Cause:
  `constellation.rs` ignores new LoadUrl requests since the aborted
  one is in its `pending_changes` list.

Solution:
  Send a message to constellation that lets it clean up its
  `pending_changes` list.
This commit is contained in:
Daniel Johnson 2017-08-27 21:42:14 -07:00
parent af41769d70
commit ff786a050a
3 changed files with 22 additions and 4 deletions

View file

@ -99,6 +99,8 @@ pub enum ScriptMsg {
/// A new load has been requested, with an option to replace the current entry once loaded
/// instead of adding a new entry.
LoadUrl(LoadData, bool),
/// Abort loading after sending a LoadUrl message.
AbortLoadUrl,
/// Post a message to the currently active window of a given browsing context.
PostMessage(BrowsingContextId, Option<ImmutableOrigin>, Vec<u8>),
/// Dispatch a mozbrowser event to the parent of a mozbrowser iframe.