From: Michael D. Lowis Date: Thu, 17 Nov 2016 01:43:17 +0000 (-0500) Subject: implemented save shortcut X-Git-Url: https://git.mdlowis.com/?a=commitdiff_plain;h=cfd9f4fd60887b4ee0123be0eb2532a69b3bef70;p=projs%2Ftide.git implemented save shortcut --- diff --git a/xedit.c b/xedit.c index 8ebcc74..2d85f98 100644 --- a/xedit.c +++ b/xedit.c @@ -107,10 +107,10 @@ static void quit(void) { if (!getbuf(EDIT)->modified || num_clicks >= 2) exit(0); } -// -//static void write(void) { -// buf_save(&Buffer); -//} + +static void save(void) { + buf_save(getbuf(EDIT)); +} // //static void undo(void) { // SelBeg = SelEnd = buf_undo(&Buffer, SelEnd); @@ -236,7 +236,7 @@ static KeyBinding Insert[] = { { KEY_END, cursor_eol }, { KEY_CTRL_T, change_focus }, { KEY_CTRL_Q, quit }, - //{ KEY_CTRL_S, write }, + { KEY_CTRL_S, save }, //{ KEY_CTRL_Z, undo }, //{ KEY_CTRL_Y, redo }, //{ KEY_CTRL_X, cut },