Fix compiler errors.
This commit is contained in:
parent
cb4b884f89
commit
39dde288fe
2 changed files with 7 additions and 6 deletions
|
@ -3,6 +3,7 @@
|
||||||
#include <assets/assets.h>
|
#include <assets/assets.h>
|
||||||
#include <license.hpp>
|
#include <license.hpp>
|
||||||
#include <log.hpp>
|
#include <log.hpp>
|
||||||
|
using namespace Looper::Log;
|
||||||
std::string GtkBackend::get_id() {
|
std::string GtkBackend::get_id() {
|
||||||
return "gtk";
|
return "gtk";
|
||||||
}
|
}
|
||||||
|
@ -24,19 +25,19 @@ void g_log_handler(const gchar *domain, GLogLevelFlags flags, const gchar *messa
|
||||||
LogStream *stream;
|
LogStream *stream;
|
||||||
switch (level) {
|
switch (level) {
|
||||||
case GLogLevelFlags::G_LOG_LEVEL_ERROR: {
|
case GLogLevelFlags::G_LOG_LEVEL_ERROR: {
|
||||||
stream = new LogStream({domain}, {ERROR});
|
stream = new LogStream({domain}, {&ERROR});
|
||||||
} break;
|
} break;
|
||||||
case GLogLevelFlags::G_LOG_LEVEL_CRITICAL: {
|
case GLogLevelFlags::G_LOG_LEVEL_CRITICAL: {
|
||||||
stream = new LogStream({"CRITICAL", domain}, {stderr});
|
stream = new LogStream({"CRITICAL", domain}, {stderr});
|
||||||
} break;
|
} break;
|
||||||
case GLogLevelFlags::G_LOG_LEVEL_WARNING: {
|
case GLogLevelFlags::G_LOG_LEVEL_WARNING: {
|
||||||
stream = new LogStream({domain}, {WARNING});
|
stream = new LogStream({domain}, {&WARNING});
|
||||||
} break;
|
} break;
|
||||||
case GLogLevelFlags::G_LOG_LEVEL_INFO: {
|
case GLogLevelFlags::G_LOG_LEVEL_INFO: {
|
||||||
stream = new LogStream({domain}, {INFO});
|
stream = new LogStream({domain}, {&INFO});
|
||||||
} break;
|
} break;
|
||||||
case GLogLevelFlags::G_LOG_LEVEL_DEBUG: {
|
case GLogLevelFlags::G_LOG_LEVEL_DEBUG: {
|
||||||
stream = new LogStream({domain}, {DEBUG});
|
stream = new LogStream({domain}, {&DEBUG});
|
||||||
} break;
|
} break;
|
||||||
default: {
|
default: {
|
||||||
stream = new LogStream({domain}, {stderr});
|
stream = new LogStream({domain}, {stderr});
|
||||||
|
@ -51,7 +52,7 @@ int GtkBackend::run(std::vector<std::string> realArgs, int argc, char **argv) {
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
g_log_set_default_handler(g_log_handler, nullptr);
|
g_log_set_default_handler(g_log_handler, nullptr);
|
||||||
g_log_writer
|
//g_log_writer
|
||||||
Glib::set_application_name("Looper");
|
Glib::set_application_name("Looper");
|
||||||
auto app = Gtk::Application::create("com.complecwaft.Looper.GTK", Gio::Application::Flags::NON_UNIQUE);
|
auto app = Gtk::Application::create("com.complecwaft.Looper.GTK", Gio::Application::Flags::NON_UNIQUE);
|
||||||
char *gtk_frontend_css = (char*)malloc(gtk_frontend_css_size + 1);
|
char *gtk_frontend_css = (char*)malloc(gtk_frontend_css_size + 1);
|
||||||
|
|
2
dbus.cpp
2
dbus.cpp
|
@ -89,7 +89,7 @@ std::vector<meta_t> MprisAPI::GetTracksMetadata(const std::vector<track_id_t> &T
|
||||||
for (auto stream : streams) {
|
for (auto stream : streams) {
|
||||||
std::map<std::string, sdbus::Variant> meta;
|
std::map<std::string, sdbus::Variant> meta;
|
||||||
meta["mpris:trackid"] = std::format("{}{}", streamPrefix, i);
|
meta["mpris:trackid"] = std::format("{}{}", streamPrefix, i);
|
||||||
meta["xesam:title"] = stream;
|
meta["xesam:title"] = stream.name;
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue