Files
federated-calendar/src/gui/gcal-event-popover.blp
T
Alistair Francis 6c09758633 event-popover: Support the maps URI for opening locations
Open gnome-maps (or other map application) when clicking on a map icon
next to the location address.

Resolves: https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/326
Signed-off-by: Alistair Francis <alistair@alistair23.me>
Part-of: <https://gitlab.gnome.org/GNOME/gnome-calendar/-/merge_requests/590>
2026-04-09 12:04:11 +00:00

203 lines
4.1 KiB
Plaintext

using Gtk 4.0;
using Adw 1;
template $GcalEventPopover: Popover {
default-widget: action_button;
position: top;
width-request: 250;
styles [
"event-popover",
]
child: Adw.Clamp clamp {
maximum-size: 400;
tightening-threshold: bind clamp.maximum-size;
child: Box {
orientation: vertical;
Box {
spacing: 18;
margin-top: 18;
margin-bottom: 12;
margin-start: 18;
margin-end: 18;
Box {
hexpand: true;
orientation: vertical;
spacing: 6;
Label summary_label {
selectable: true;
wrap: true;
wrap-mode: word_char;
xalign: 0.0;
lines: 6;
ellipsize: end;
styles [
"title-4",
]
}
Label date_time_label {
xalign: 0.0;
styles [
"dimmed",
]
}
}
Box {
spacing: 6;
Image read_only_icon {
tooltip-markup: _(
"<b>This event is part of a read-only calendar</b>\n You cannot delete or change this event."
);
icon-name: "changes-prevent-symbolic";
pixel-size: 18;
valign: start;
halign: end;
margin-top: 8;
margin-bottom: 8;
styles [
"dimmed",
]
}
Button ics_export_button {
valign: start;
halign: end;
icon-name: "share-symbolic";
tooltip-text: _("Export Event");
styles [
"circular",
]
clicked => $on_ics_export_button_clicked_cb(template) not-swapped;
}
Button action_button {
can-focus: true;
valign: start;
halign: end;
styles [
"circular",
]
clicked => $on_action_button_clicked_cb(template) not-swapped;
}
}
}
Separator {}
Label placeholder_label {
vexpand: true;
label: _("No event notes");
margin-top: 12;
margin-bottom: 12;
use-markup: true;
styles [
"dimmed",
"no-events",
]
}
ScrolledWindow description_scrolled_window {
hscrollbar-policy: never;
propagate-natural-height: true;
propagate-natural-width: true;
max-content-height: 350;
child: Label description_label {
use-markup: true;
selectable: true;
halign: fill;
xalign: 0.0;
wrap: true;
wrap-mode: word_char;
margin-top: 12;
margin-bottom: 18;
margin-start: 18;
margin-end: 18;
};
}
Box location_box {
orientation: vertical;
Separator {}
Box {
margin-top: 12;
margin-bottom: 12;
margin-start: 18;
margin-end: 18;
spacing: 12;
Box {
orientation: vertical;
Label {
halign: start;
label: _("Location");
styles [
"heading",
]
}
Label location_label {
halign: start;
selectable: true;
ellipsize: end;
}
}
Button {
halign: end;
hexpand: true;
valign: center;
tooltip-text: _("Open Location");
icon-name: "map-symbolic";
styles [
"circular",
]
clicked => $on_map_button_clicked_cb(template) not-swapped;
}
}
}
Box meetings_box {
orientation: vertical;
visible: false;
Separator {}
ListBox meetings_listbox {
selection-mode: none;
margin-top: 12;
margin-bottom: 12;
margin-start: 18;
margin-end: 18;
styles [
"calendar-list",
]
}
}
};
};
}