Fixed building on Ubuntu

This commit is contained in:
Erik Reider
2022-05-07 15:37:49 +02:00
parent da6d1efe6e
commit ec01b49319
2 changed files with 4 additions and 3 deletions

View File

@@ -242,7 +242,8 @@ namespace SwayNotificationCenter {
params.set ("app_name", app_name);
params.set ("replaces_id", replaces_id.to_string ());
params.set ("app_icon", app_icon);
params.set ("default_action", default_action ? .to_string ());
params.set ("default_action", default_action == null
? null : default_action.to_string ());
params.set ("summary", summary);
params.set ("body", "\t" + body);
string[] _hints = {};
@@ -267,7 +268,7 @@ namespace SwayNotificationCenter {
params.set ("resident", resident.to_string ());
params.set ("urgency", urgency.to_string ());
string[] _actions = {};
foreach (var _action in actions) {
foreach (var _action in actions.data) {
_actions += "\n\t" + _action.to_string ();
}
params.set ("actions", string.joinv ("", _actions));

View File

@@ -336,7 +336,7 @@ namespace SwayNotificationCenter {
alt_actions_box = new Gtk.ButtonBox (Gtk.Orientation.HORIZONTAL);
alt_actions_box.set_homogeneous (true);
alt_actions_box.set_layout (Gtk.ButtonBoxStyle.EXPAND);
foreach (var action in param.actions) {
foreach (var action in param.actions.data) {
var action_button = new Gtk.Button.with_label (action.name);
action_button.clicked.connect (() => action_clicked (action));
action_button