papers/papers-47.0-fast-navigation.patch
Marek Kasik bb4d8b6878 Fix fast navigation
+ enable libspelling support since it was added to buildroot recently.

Resolves: RHEL-76523
2025-02-03 12:42:10 +01:00

38 lines
1.3 KiB
Diff

From ee88fa8e3488b64f930632cefbc5115cf3a406e0 Mon Sep 17 00:00:00 2001
From: Marek Kasik <mkasik@redhat.com>
Date: Fri, 31 Jan 2025 12:57:37 +0100
Subject: [PATCH 2/2] shell: Extend fast navigation
Enable navigation to the beginning of the document for "go-backwards" action
even if the page number is lower than 10.
Enable the same for "go-forward" action for the end of the document.
---
shell/src/document_view/actions.rs | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/shell/src/document_view/actions.rs b/shell/src/document_view/actions.rs
index a4036ab92..006b9f58f 100644
--- a/shell/src/document_view/actions.rs
+++ b/shell/src/document_view/actions.rs
@@ -655,6 +655,8 @@ impl imp::PpsDocumentView {
if current_page + 10 < n_pages {
obj.model.set_page(current_page + 10);
+ } else {
+ obj.model.set_page(n_pages - 1);
}
}
))
@@ -668,6 +670,8 @@ impl imp::PpsDocumentView {
if current_page - 10 >= 0 {
obj.model.set_page(current_page - 10);
+ } else {
+ obj.model.set_page(0);
}
}
))
--
2.48.1