-
-
Notifications
You must be signed in to change notification settings - Fork 80
/
exm-browse-page.blp
83 lines (72 loc) · 1.88 KB
/
exm-browse-page.blp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
using Gtk 4.0;
using Adw 1;
template $ExmBrowsePage : Gtk.Widget {
notify::manager => $on_bind_manager();
Gtk.ScrolledWindow {
Adw.StatusPage {
title: _("Search for extensions");
description: _("Enter a keyword to search 'extensions.gnome.org' for GNOME Shell Extensions.");
valign: start;
vexpand: true;
child: Adw.Clamp {
Gtk.Box {
orientation: vertical;
Gtk.Box {
styles ["linked"]
Gtk.SearchEntry search_entry {
hexpand: true;
realize => $on_search_entry_realize();
search-changed => $on_search_changed() swapped;
}
// Keep the same order as the ExmSearchSort enum
Gtk.DropDown search_dropdown {
model: StringList {
// Translators: dropdown items for sorting search results
strings [_("Relevance"), C_("Sort search results", "Downloads"), _("Recent"), _("Name")]
};
notify::selected => $on_search_changed() swapped;
}
}
Gtk.Stack search_stack {
Gtk.StackPage {
name: "page_spinner";
child: Gtk.Spinner {
valign: center;
halign: center;
spinning: true;
height-request: 32;
width-request: 32;
};
}
Gtk.StackPage {
name: "page_results";
child: Gtk.Box {
orientation: vertical;
Gtk.ListBox search_results {
styles ["boxed-list"]
valign: start;
selection-mode: none;
}
Gtk.Button more_results_btn {
label: _("_Load More Results");
halign: center;
margin-top: 24;
use-underline: true;
clicked => $on_load_more_results();
}
};
}
Gtk.StackPage {
name: "page_empty";
child: Gtk.Label {
label: _("No Results Found");
valign: start;
halign: center;
};
}
}
}
};
}
}
}