aboutsummaryrefslogtreecommitdiffstats
path: root/src/config
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2021-08-08 21:01:47 +0200
committerbptato <nincsnevem662@gmail.com>2021-08-08 21:01:47 +0200
commitd7cb6d7d610df886d028ca6d6aecf3d9a3ba54ff (patch)
tree5eb75d8b95ed9e6eab1e7f3d72b8afd1adc0e283 /src/config
parentfa4560f63e38886b2b7541642b9aa1656dc40508 (diff)
downloadchawan-d7cb6d7d610df886d028ca6d6aecf3d9a3ba54ff.tar.gz
Implement CSS display none in box renderer etc.
Other changes being bugfixes and a temporary implementation of "view source"
Diffstat (limited to 'src/config')
-rw-r--r--src/config/config.nim9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/config/config.nim b/src/config/config.nim
index 5a49bb34..dab5347f 100644
--- a/src/config/config.nim
+++ b/src/config/config.nim
@@ -21,7 +21,7 @@ type
ACTION_SCROLL_DOWN, ACTION_SCROLL_UP, ACTION_SCROLL_LEFT, ACTION_SCROLL_RIGHT,
ACTION_CLICK,
ACTION_CHANGE_LOCATION,
- ACTION_RELOAD, ACTION_RESHAPE, ACTION_REDRAW,
+ ACTION_RELOAD, ACTION_RESHAPE, ACTION_REDRAW, ACTION_TOGGLE_SOURCE,
ACTION_CURSOR_FIRST_LINE, ACTION_CURSOR_LAST_LINE,
ACTION_CURSOR_TOP, ACTION_CURSOR_MIDDLE, ACTION_CURSOR_BOTTOM,
ACTION_CENTER_LINE, ACTION_LINE_INFO,
@@ -49,7 +49,6 @@ func getConfig(s: StaticConfig): Config =
func getRealKey(key: string): string =
var realk: string
- var currchar: char
var control = 0
var meta = 0
var skip = false
@@ -59,12 +58,10 @@ func getRealKey(key: string): string =
elif skip:
realk &= c
skip = false
- elif c == 'M':
+ elif c == 'M' and meta == 0:
inc meta
- currchar = c
- elif c == 'C':
+ elif c == 'C' and control == 0:
inc control
- currchar = c
elif c == '-' and control == 1:
inc control
elif c == '-' and meta == 1: