mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Replace current session entry for reloads
This commit is contained in:
parent
0b0495cff4
commit
e9b2f1b916
10 changed files with 89 additions and 57 deletions
|
@ -1410,11 +1410,12 @@ impl Window {
|
|||
}
|
||||
|
||||
/// Commence a new URL load which will either replace this window or scroll to a fragment.
|
||||
pub fn load_url(&self, url: Url) {
|
||||
pub fn load_url(&self, url: Url, replace: bool) {
|
||||
let doc = self.Document();
|
||||
self.main_thread_script_chan().send(
|
||||
MainThreadScriptMsg::Navigate(self.id,
|
||||
LoadData::new(url, doc.get_referrer_policy(), Some(doc.url().clone())))).unwrap();
|
||||
LoadData::new(url, doc.get_referrer_policy(), Some(doc.url().clone())),
|
||||
replace)).unwrap();
|
||||
}
|
||||
|
||||
pub fn handle_fire_timer(&self, timer_id: TimerEventId) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue