timers work, fix crash when vscode window closes after timeout
This commit is contained in:
@@ -36,10 +36,12 @@ SpotifyNotification::SpotifyNotification(uint64_t notificationId, std::shared_pt
|
||||
|
||||
auto artistLabel = Gtk::make_managed<Gtk::Label>();
|
||||
if (!mpris.artist.empty()) {
|
||||
artistLabel->set_text(StringHelper::trimToSize(mpris.artist[0], 30));
|
||||
artistLabel->set_text(mpris.artist[0]);
|
||||
} else {
|
||||
artistLabel->set_text("Unknown Artist");
|
||||
}
|
||||
artistLabel->set_ellipsize(Pango::EllipsizeMode::END);
|
||||
artistLabel->set_max_width_chars(30);
|
||||
artistLabel->set_hexpand(true);
|
||||
artistLabel->set_halign(Gtk::Align::CENTER);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user