code: drawterm

Download patch

ref: fffa2d3f540d81b985f2f74ab6d2e5499219a9b7
parent: 7ccc433d64fe03965debb1b4950e1bd23654b1fa
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Fri Jan 6 18:31:12 EST 2023

keyboard.h: update from 9front

--- a/include/keyboard.h
+++ b/include/keyboard.h
@@ -1,27 +1,9 @@
-typedef struct 	Keyboardctl Keyboardctl;
-typedef struct	Channel	Channel;
-
-struct	Keyboardctl
-{
-	Channel	*c;	/* chan(Rune)[20] */
-
-	char		*file;
-	int		consfd;		/* to cons file */
-	int		ctlfd;		/* to ctl file */
-	int		pid;		/* of slave proc */
-};
-
-
-extern	Keyboardctl*	initkeyboard(char*);
-extern	int		ctlkeyboard(Keyboardctl*, char*);
-extern	void		closekeyboard(Keyboardctl*);
-
 enum {
 	KF=	0xF000,	/* Rune: beginning of private Unicode space */
 	Spec=	0xF800,
 	PF=	Spec|0x20,	/* num pad function key */
 	Kview=	Spec|0x00,	/* view (shift window up) */
-	/* KF|1, KF|2, ..., KF|0xC is F1, F2, ..., F12 */
+	/* KF|1, KF|2, ..., KF|0xC is *respectively* F1, F2, ..., F12 */
 	Khome=	KF|0x0D,
 	Kup=	KF|0x0E,
 	Kdown=	Kview,
@@ -42,12 +24,14 @@
 	Kscrollonedown=	KF|0x21,
 
 	/* multimedia keys - no refunds */
-	Ksbwd=	KF|0x22,
-	Ksfwd=	KF|0x23,
-	Kpause=	KF|0x24,
-	Kvoldn=	KF|0x25,
-	Kvolup=	KF|0x26,
-	Kmute=	KF|0x27,
+	Ksbwd=	KF|0x22,	/* skip backwards */
+	Ksfwd=	KF|0x23,	/* skip forward */
+	Kpause=	KF|0x24,	/* play/pause */
+	Kvoldn=	KF|0x25,	/* volume decrement */
+	Kvolup=	KF|0x26,	/* volume increment */
+	Kmute=	KF|0x27,	/* (un)mute */
+	Kbrtdn=	KF|0x28,	/* brightness decrement */
+	Kbrtup=	KF|0x29,	/* brightness increment */
 
 	Ksoh=	0x01,
 	Kstx=	0x02,