Compare commits

..

No commits in common. "1e7857dfdd69aa7948ab2250737646198737e788" and "7143225fc582084630693ad6f9e455b3206f4fff" have entirely different histories.

2 changed files with 7 additions and 10 deletions

View File

@ -791,9 +791,8 @@ read_key_sequence (const char *buf, size_t len)
return ++p - buf;
return -escapes;
}
// We don't know this sequence, so just return M-Esc
if (escapes == 2)
return escapes;
return -escapes;
}
// Shift state encodings aren't going to work, though anything else should
@ -1040,16 +1039,16 @@ main (int argc, char *argv[])
opt_handler_free (&oh);
if (!isatty (STDIN_FILENO))
exit_fatal ("input is not a terminal");
print_fatal ("input is not a terminal");
if (!isatty (STDOUT_FILENO))
exit_fatal ("output is not a terminal");
print_fatal ("output is not a terminal");
setlocale (LC_CTYPE, "");
// PulseAudio uses UTF-8, let's avoid encoding conversions
if (strcasecmp (nl_langinfo (CODESET), "UTF-8"))
exit_fatal ("UTF-8 encoding required");
print_fatal ("UTF-8 encoding required");
if (setvbuf (stdout, NULL, _IOLBF, 0) || !tty_start ())
exit_fatal ("terminal initialization failed");
print_fatal ("terminal initialization failed");
// TODO: we will need a logging function aware of our rendering
g_log_message_real = log_message_custom;

View File

@ -2227,11 +2227,9 @@ g_keys[] =
// Brightness
{ Mod4Mask, XK_Home, on_brightness, 10 },
{ Mod4Mask, XK_End, on_brightness, -10 },
{ 0, XF86XK_MonBrightnessUp, on_brightness, 10 },
{ 0, XF86XK_MonBrightnessDown, on_brightness, -10 },
{ 0, XF86XK_MonBrightnessUp, on_brightness, 10 },
{ 0, XF86XK_MonBrightnessDown, on_brightness, -10 },
{ Mod4Mask, XK_F4, on_standby, 0 },
{ Mod4Mask | ShiftMask, XK_F4, on_insomnia, 0 },
{ Mod4Mask, XK_Pause, on_standby, 0 },
{ Mod4Mask | ShiftMask, XK_Pause, on_insomnia, 0 },