Skip to content

Instantly share code, notes, and snippets.

@gabrielschulhof
Created January 14, 2016 20:34
Show Gist options
  • Save gabrielschulhof/12f2d6c47197c7b91d35 to your computer and use it in GitHub Desktop.
Save gabrielschulhof/12f2d6c47197c7b91d35 to your computer and use it in GitHub Desktop.
#include <stdio.h>
#include <sol-platform.h>
#include <sol-mainloop.h>
static void localeHasChanged(void *nothing, enum sol_platform_locale_category category, const char *locale) {
printf("%d, %s\n", category, locale);
}
static void startup() {
sol_platform_add_locale_monitor(localeHasChanged, NULL);
}
static void shutdown() {
sol_platform_del_locale_monitor(localeHasChanged, NULL);
}
SOL_MAIN_DEFAULT(startup, shutdown);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment