url-mode: add a key binding that enables “persistent” URL mode

This is an alternative to ‘show-urls-launch’, where we stay in URL
mode after activating an URL.

Closes #964
This commit is contained in:
Daniel Eklöf 2022-03-22 19:07:06 +01:00
parent 0062f4e133
commit 501a9fbb5e
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
8 changed files with 37 additions and 11 deletions

View file

@ -113,6 +113,7 @@ static const char *const binding_action_map[] = {
[BIND_ACTION_PIPE_SELECTED] = "pipe-selected",
[BIND_ACTION_SHOW_URLS_COPY] = "show-urls-copy",
[BIND_ACTION_SHOW_URLS_LAUNCH] = "show-urls-launch",
[BIND_ACTION_SHOW_URLS_PERSISTENT] = "show-urls-persistent",
[BIND_ACTION_TEXT_BINDING] = "text-binding",
/* Mouse-specific actions */
@ -516,7 +517,7 @@ value_to_wchars(struct context *ctx, char32_t **res)
{
char32_t *s = ambstoc32(ctx->value);
if (s == NULL) {
LOG_CONTEXTUAL_ERR("not a valie string value");
LOG_CONTEXTUAL_ERR("not a valid string value");
return false;
}