From cd3fd49758c9980141539bf9cfd8a31d4423f032 Mon Sep 17 00:00:00 2001 From: y4my4my4m <8145020+y4my4my4m@users.noreply.github.com> Date: Fri, 25 Aug 2023 14:54:17 +0900 Subject: [PATCH] init --- src/Home/Yuugure.ZC | 29 +++++++++++++++++++++++++++++ src/HomeKeyPlugIns.ZC | 10 ++++++++++ src/MakeHome.ZC | 1 + 3 files changed, 40 insertions(+) create mode 100755 src/Home/Yuugure.ZC diff --git a/src/Home/Yuugure.ZC b/src/Home/Yuugure.ZC new file mode 100755 index 00000000..e449e4c5 --- /dev/null +++ b/src/Home/Yuugure.ZC @@ -0,0 +1,29 @@ +I64 initialWinBottom = sys_task->win_bottom; +CDoc *initialDisplayDoc = sys_task->display_doc; + +U0 Yuugure() +{ + // Hide SysLog + if (sys_task->win_bottom != 0) { + while(sys_task->win_bottom > -1){ + sys_task->win_bottom--; + Sleep(20); + } + + sys_task->display_doc = NULL; + WinBorder(OFF, sys_task); + } + // Show SysLog + else { + WinBorder(ON, sys_task); + sys_task->display_doc = initialDisplayDoc; + + while(sys_task->win_bottom != initialWinBottom){ + sys_task->win_bottom++; + Sleep(20); + } + + } + + WinZBufUpdate; +} diff --git a/src/HomeKeyPlugIns.ZC b/src/HomeKeyPlugIns.ZC index fdc3bda9..0b949635 100755 --- a/src/HomeKeyPlugIns.ZC +++ b/src/HomeKeyPlugIns.ZC @@ -110,6 +110,16 @@ Bool MyPutKey(I64 ch, I64 sc) } return TRUE; + case SC_F12: + if (!(sc & SCF_SHIFT)) + { + if (sc & SCF_KEY_DESC) + KeyDescSet("Cmd /Yuugure"); + else + Yuugure; + } + return TRUE; + case SC_DELETE: if (sc & SCF_SHIFT) { diff --git a/src/MakeHome.ZC b/src/MakeHome.ZC index 39f77698..9b650e41 100755 --- a/src/MakeHome.ZC +++ b/src/MakeHome.ZC @@ -8,6 +8,7 @@ Cd(__DIR__);; #include "~/HomeWrappers" MapFileLoad("::/Kernel/Kernel"); MapFileLoad("::/Compiler/Compiler"); +#include "~/Yuugure" #include "~/HomeKeyPlugIns" #include "~/HomeSys" Cd("..");;