Skip to content

Commit

Permalink
Release 2.5.4
Browse files Browse the repository at this point in the history
  • Loading branch information
Alain M committed Oct 12, 2020
1 parent f113425 commit d8f60e4
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/Views/Completed.vala
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
public class Views.Completed : Gtk.EventBox {
public Gee.HashMap <string, Widgets.ItemRow> items_loaded;
private Gtk.ListBox listbox;
private Gtk.Stack view_stack;

construct {
items_loaded = new Gee.HashMap <string, Widgets.ItemRow> ();
Expand Down Expand Up @@ -70,11 +71,11 @@ public class Views.Completed : Gtk.EventBox {
var placeholder_view = new Widgets.Placeholder (
_("All clear"),
_("No tasks in this filter at the moment."),
"tag-symbolic"
"emblem-default-symbolic"
);
placeholder_view.reveal_child = true;

var view_stack = new Gtk.Stack ();
view_stack = new Gtk.Stack ();
view_stack.expand = true;
view_stack.transition_type = Gtk.StackTransitionType.CROSSFADE;
view_stack.add_named (box_scrolled, "listbox");
Expand Down Expand Up @@ -110,8 +111,11 @@ public class Views.Completed : Gtk.EventBox {
listbox.show_all ();
}

//listbox.set_sort_func (sort_function);
//listbox.set_header_func (update_headers);
if (items_loaded.size > 0) {
view_stack.visible_child_name = "listbox";
} else {
view_stack.visible_child_name = "placeholder";
}
}

private void header_function (Gtk.ListBoxRow lbrow, Gtk.ListBoxRow? lbbefore) {
Expand Down

0 comments on commit d8f60e4

Please sign in to comment.