File tree 2 files changed +5
-2
lines changed
2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -144,7 +144,7 @@ public class Scratch.Dialogs.Preferences : Granite.Dialog {
144
144
main_box. add (stackswitcher);
145
145
main_box. add (stack);
146
146
147
- plugins. hook_preferences_dialog (this );
147
+ plugins. hook_preferences_dialog (this ); // Unused?
148
148
149
149
if (plugins. get_n_plugins () > 0 ) {
150
150
var pbox = plugins. get_view ();
Original file line number Diff line number Diff line change @@ -162,7 +162,10 @@ namespace Scratch.Services {
162
162
163
163
// Bind the engine ListModel and use a row factory
164
164
list_box. bind_model (engine, get_widget_for_plugin_info);
165
- // Cannot sort a ListModel so sort the ListBox (is there a better way?)
165
+ // Cannot sort a ListModel so sort the ListBox (is there a better way?)
166
+ // Gtk warns the function will be ignored but it does in fact work, at least
167
+ // on initial display. We know the model will not change while the view is used
168
+ // In Gtk4 could use SortListModel
166
169
list_box. set_sort_func ((r1, r2) = > {
167
170
return strcmp (
168
171
r1. get_child (). get_data< string > (" name" ),
You can’t perform that action at this time.
0 commit comments