Port the editor to the new g_thread stuff

This commit is contained in:
Aaron Mueller 2014-08-15 23:37:30 +02:00
parent 73849d693a
commit ae40a85ce1

View file

@ -116,7 +116,6 @@ gint main(gint argc, gchar *argv[]) {
glade_xml_signal_autoconnect(xml);
if (g_thread_supported()) {
g_thread_init(NULL);
gdk_threads_init();
} else {
g_error("Threads not supported, we die.");
@ -125,8 +124,7 @@ gint main(gint argc, gchar *argv[]) {
// Start the polling thread to try to connect to the LED-Cube.
GError *error;
g_thread_init(NULL);
connectThread = g_thread_create((GThreadFunc)connectToLEDCube, NULL, TRUE, &error);
connectThread = g_thread_new("connection_thread", (GThreadFunc)connectToLEDCube, &error);
if (connectThread == NULL) {
g_error("Can't create the thread, we stop here.");
exit(1);