develop.uap-core.de/git
/
uwplayer.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add search for mpv/mplayer binary
[uwplayer.git]
/
application
/
main.c
diff --git
a/application/main.c
b/application/main.c
index
440a3f4
..
6dcca3b
100644
(file)
--- a/
application/main.c
+++ b/
application/main.c
@@
-26,6
+26,7
@@
#include "window.h"
#include "main.h"
#include "window.h"
#include "main.h"
+#include "settings.h"
#include <ucx/buffer.h>
#include <ucx/utils.h>
#include <ucx/buffer.h>
#include <ucx/utils.h>
@@
-60,6
+61,7
@@
int main(int argc, char** argv) {
// has a bug on freebsd and doesn't flush the output after a newline
setvbuf(stdout, NULL, _IONBF, 0);
// has a bug on freebsd and doesn't flush the output after a newline
setvbuf(stdout, NULL, _IONBF, 0);
+ // initialize toolkit
XtToolkitInitialize();
XtSetLanguageProc(NULL, NULL, NULL);
app = XtCreateApplicationContext();
XtToolkitInitialize();
XtSetLanguageProc(NULL, NULL, NULL);
app = XtCreateApplicationContext();
@@
-67,6
+69,11
@@
int main(int argc, char** argv) {
display = XtOpenDisplay(app, NULL, APP_NAME, APP_CLASS, NULL, 0, &argc, argv);
display = XtOpenDisplay(app, NULL, APP_NAME, APP_CLASS, NULL, 0, &argc, argv);
+ // load settings
+ if(load_settings()) {
+ return 1;
+ }
+
MainWindow *window = WindowCreate(display);
WindowShow(window);
MainWindow *window = WindowCreate(display);
WindowShow(window);
@@
-82,3
+89,7
@@
XtAppContext* GetAppContext(void) {
void ApplicationExit(void) {
XtAppSetExitFlag(app);
}
void ApplicationExit(void) {
XtAppSetExitFlag(app);
}
+
+void AppAddTimeOut(unsigned long interval, XtTimerCallbackProc proc, XtPointer data) {
+ XtAppAddTimeOut(app, interval, proc, data);
+}