35 lines
787 B
C++
35 lines
787 B
C++
#pragma once
|
|
|
|
#include <cstdint>
|
|
#include <functional>
|
|
#include <string>
|
|
#include <map>
|
|
#include <sys/types.h>
|
|
#include <vector>
|
|
#include "glibmm/variant.h"
|
|
|
|
|
|
|
|
struct MprisPlayer2Message {
|
|
std::string title;
|
|
std::string artist;
|
|
std::string artwork_url;
|
|
uint32_t length_ms;
|
|
|
|
std::function<void()> play_pause;
|
|
std::function<void()> next;
|
|
std::function<void()> previous;
|
|
};
|
|
|
|
struct NotifyMessage {
|
|
std::string app_name;
|
|
uint32_t replaces_id;
|
|
std::string app_icon;
|
|
std::string summary;
|
|
std::string body;
|
|
std::vector<std::string> actions;
|
|
std::map<std::string, Glib::VariantBase> hints;
|
|
int32_t expire_timeout;
|
|
// Callback to invoke when an action is triggered
|
|
std::function<void(const std::string& action_id)> on_action;
|
|
}; |