From ddd0260a19bfa113b58e6b4bfd2ac96612480724 Mon Sep 17 00:00:00 2001 From: Jeremy Wootten Date: Mon, 25 Nov 2024 21:47:13 +0000 Subject: [PATCH 1/3] Fix warning on startup --- src/MainWindow.vala | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/MainWindow.vala b/src/MainWindow.vala index 34fe7d93db..c4d913ea2b 100644 --- a/src/MainWindow.vala +++ b/src/MainWindow.vala @@ -618,7 +618,10 @@ namespace Scratch { title = _("%s - %s").printf (doc.get_basename (), base_title); toolbar.set_document_focus (doc); - git_manager.active_project_path = doc.source_view.project.path; + if (doc.source_view.project != null) { + git_manager.active_project_path = doc.source_view.project.path; + } + folder_manager_view.select_path (doc.file.get_path ()); // Must follow setting focus document for editorconfig plug From 744a0f6bc93df32c89aaa26b49db2bf3aea5d363 Mon Sep 17 00:00:00 2001 From: Jeremy Wootten Date: Mon, 25 Nov 2024 21:47:22 +0000 Subject: [PATCH 2/3] Fix warning on rename --- src/Widgets/SourceList/SourceList.vala | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Widgets/SourceList/SourceList.vala b/src/Widgets/SourceList/SourceList.vala index 0ecff6daea..06fdcc783b 100644 --- a/src/Widgets/SourceList/SourceList.vala +++ b/src/Widgets/SourceList/SourceList.vala @@ -870,7 +870,11 @@ public class SourceList : Gtk.ScrolledWindow { return items.has_key (item); } - public void update_item (Item item) requires (has_item (item)) { + public void update_item (Item item) { + if (!has_item (item)) { + return; + } + assert (root != null); // Emitting row_changed() for this item's row in the child model causes the filter From 80ca8d3d031a0958233d1eddfa8811ffb1bce395 Mon Sep 17 00:00:00 2001 From: Jeremy Wootten Date: Fri, 7 Mar 2025 15:42:14 +0000 Subject: [PATCH 3/3] Remove stray pasted text --- src/MainWindow.vala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MainWindow.vala b/src/MainWindow.vala index f5c48bfa90..37a9199f8a 100644 --- a/src/MainWindow.vala +++ b/src/MainWindow.vala @@ -601,7 +601,7 @@ namespace Scratch { content_stack.visible_child = view_grid; toolbar.document_available (true); set_widgets_sensitive (true); - update_find_actions ();jeremypw/silence-some-warnings + update_find_actions (); }); document_view.tab_removed.connect ((doc) => {