+static void show_notification(const char *msg_str,
+ unsigned duration_ms, unsigned priority)
+{
+ if (msg_interface_version >= 1)
+ {
+ struct retro_message_ext msg = {
+ msg_str,
+ duration_ms,
+ 3,
+ RETRO_LOG_WARN,
+ RETRO_MESSAGE_TARGET_ALL,
+ RETRO_MESSAGE_TYPE_NOTIFICATION,
+ -1
+ };
+ environ_cb(RETRO_ENVIRONMENT_SET_MESSAGE_EXT, &msg);
+ }
+ else
+ {
+ struct retro_message msg = {
+ msg_str,
+ 180
+ };
+ environ_cb(RETRO_ENVIRONMENT_SET_MESSAGE, &msg);
+ }
+}
+