desktop: Add Bookmark dialog should use the opened url, not a movies internal url

This commit is contained in:
Nathan Adams 2024-04-06 00:23:11 +02:00
parent bf7a88d63f
commit e5fc56429e
1 changed files with 1 additions and 11 deletions

View File

@ -313,17 +313,7 @@ impl RuffleGui {
if Button::new(text(locale, "bookmarks-menu-add")).ui(ui).clicked() {
ui.close_menu();
let initial_url = if let Some(player) = &player {
match Url::parse(player.swf().url()) {
Ok(url) => Some(url),
Err(e) => {
tracing::warn!("Failed to parse SWF url for bookmark: {e}");
None
}
}
} else {
None
};
let initial_url = self.currently_opened.as_ref().map(|(url, _)| url.clone());
self.open_add_bookmark(initial_url);
}