summaryrefslogtreecommitdiff
path: root/new/init_unix.c
blob: 67954c0cc8300c5344637085f90cafa352856ba6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// 6 april 2015
#include "uipriv_unix.h"

struct uiInitError {
	GError *err;
};

uiInitError *uiInit(uiInitOptions *o)
{
	uiInitError *err;

	err = uiNew(uiInitError);
	if (gtk_init_with_args(NULL, NULL, NULL, NULL, NULL, &(err->err)) == FALSE)
		return err;
	uiFree(err);
	return NULL;
}

const char *uiInitErrorMessage(uiInitError *err)
{
	return err->err->message;
}

void uiInitErrorFree(uiInitError *err)
{
	g_error_free(err->err);
	uiFree(err);
}