cargo: Update glycin version
This commit is contained in:
parent
e4ee49c2a1
commit
3f1c247f41
5 changed files with 184 additions and 282 deletions
|
|
@ -48,7 +48,7 @@ impl Glycin {
|
|||
let (next_frame_send, next_frame_recv) = async_channel::bounded(2);
|
||||
|
||||
updater.clone().spawn_error_handled(async move {
|
||||
let mut image_request = glycin::ImageRequest::new(file);
|
||||
let mut image_request = glycin::Loader::new(file);
|
||||
|
||||
#[cfg(feature = "disable-glycin-sandbox")]
|
||||
image_request.sandbox_mechanism(Some(glycin::SandboxMechanism::NotSandboxed));
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ impl Svg {
|
|||
let (wakeup, wakeup_resv) = mpsc::unbounded();
|
||||
|
||||
updater.clone().spawn_error_handled(async move {
|
||||
let mut image_request = glycin::ImageRequest::new(file);
|
||||
let mut image_request = glycin::Loader::new(file);
|
||||
|
||||
#[cfg(feature = "disable-glycin-sandbox")]
|
||||
image_request.sandbox_mechanism(Some(glycin::SandboxMechanism::NotSandboxed));
|
||||
|
|
@ -174,7 +174,7 @@ impl Svg {
|
|||
|
||||
pub fn render_print(file: &gio::File, width: i32, height: i32) -> anyhow::Result<gdk::Texture> {
|
||||
#[allow(unused_mut)]
|
||||
let mut image_request = glycin::ImageRequest::new(file.clone());
|
||||
let mut image_request = glycin::Loader::new(file.clone());
|
||||
|
||||
#[cfg(feature = "disable-glycin-sandbox")]
|
||||
image_request.sandbox_mechanism(Some(glycin::SandboxMechanism::NotSandboxed));
|
||||
|
|
|
|||
|
|
@ -453,7 +453,7 @@ impl LpImageView {
|
|||
}
|
||||
|
||||
fn scroll_sliding_view(&self, file: &gio::File) {
|
||||
let Some(current_page) = self.sliding_view().pages().remove(&file.uri()) else {
|
||||
let Some(current_page) = self.sliding_view().pages().swap_remove(&file.uri()) else {
|
||||
log::error!(
|
||||
"Current path not available in sliding_view for scrolling: {}",
|
||||
file.uri()
|
||||
|
|
@ -626,7 +626,7 @@ impl LpImageView {
|
|||
// Reset zoom and rotation of other pages
|
||||
if let Some(new_page) = ¤t_page {
|
||||
let mut other_pages = self.sliding_view().pages();
|
||||
other_pages.remove(&new_page.file().uri());
|
||||
other_pages.swap_remove(&new_page.file().uri());
|
||||
for (_, page) in other_pages {
|
||||
let image = page.image();
|
||||
image.reset_rotation();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue