aboutsummaryrefslogtreecommitdiffstats
path: root/src/term.c
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2016-05-01 20:48:59 -0400
committerJesse Luehrs <doy@tozt.net>2016-05-01 20:48:59 -0400
commit3e8d4ab0235aba332c8183462de4106795496b20 (patch)
tree87f2feb164c1aaab777ff10e60bb99781f3e434b /src/term.c
parenta7d1e85a0b13b7a6f4d8a7be69410da2cc7d4d03 (diff)
downloadrunes-3e8d4ab0235aba332c8183462de4106795496b20.tar.gz
runes-3e8d4ab0235aba332c8183462de4106795496b20.zip
the event loop should own the terminal, not the other way around
this way, we should be able to have multiple terminals in the same process
Diffstat (limited to 'src/term.c')
-rw-r--r--src/term.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/term.c b/src/term.c
index 6a66460..44cd4ac 100644
--- a/src/term.c
+++ b/src/term.c
@@ -2,7 +2,7 @@
#include "runes.h"
-void runes_term_init(RunesTerm *t, int argc, char *argv[])
+void runes_term_init(RunesTerm *t, RunesLoop *loop, int argc, char *argv[])
{
memset((void *)t, 0, sizeof(*t));
@@ -16,12 +16,11 @@ void runes_term_init(RunesTerm *t, int argc, char *argv[])
vt100_screen_set_scrollback_length(&t->scr, t->config.scrollback_length);
runes_display_set_window_size(t);
- runes_loop_init(t);
+ runes_loop_init_term(loop, t);
}
void runes_term_cleanup(RunesTerm *t)
{
- runes_loop_cleanup(t);
runes_config_cleanup(t);
runes_display_cleanup(t);
vt100_screen_cleanup(&t->scr);