mirror of
https://github.com/tmux/tmux.git
synced 2025-09-02 21:47:01 +00:00
Popup window should not be draggable while mouse still pressed, and do
not try to work out theme if no pane. From Michael Grant in GitHub issue 4330.
This commit is contained in:
2
popup.c
2
popup.c
@ -531,7 +531,7 @@ popup_key_cb(struct client *c, void *data, struct key_event *event)
|
|||||||
(border == LEFT || border == TOP))
|
(border == LEFT || border == TOP))
|
||||||
goto menu;
|
goto menu;
|
||||||
if (((m->b & MOUSE_MASK_MODIFIERS) == MOUSE_MASK_META) ||
|
if (((m->b & MOUSE_MASK_MODIFIERS) == MOUSE_MASK_META) ||
|
||||||
border != NONE) {
|
(border != NONE && !MOUSE_DRAG(m->lb))) {
|
||||||
if (!MOUSE_DRAG(m->b))
|
if (!MOUSE_DRAG(m->b))
|
||||||
goto out;
|
goto out;
|
||||||
if (MOUSE_BUTTONS(m->lb) == MOUSE_BUTTON_1)
|
if (MOUSE_BUTTONS(m->lb) == MOUSE_BUTTON_1)
|
||||||
|
6
window.c
6
window.c
@ -1877,11 +1877,15 @@ window_pane_get_fg_control_client(struct window_pane *wp)
|
|||||||
enum client_theme
|
enum client_theme
|
||||||
window_pane_get_theme(struct window_pane *wp)
|
window_pane_get_theme(struct window_pane *wp)
|
||||||
{
|
{
|
||||||
struct window *w = wp->window;
|
struct window *w;
|
||||||
struct client *loop;
|
struct client *loop;
|
||||||
enum client_theme theme;
|
enum client_theme theme;
|
||||||
int found_light = 0, found_dark = 0;
|
int found_light = 0, found_dark = 0;
|
||||||
|
|
||||||
|
if (wp == NULL)
|
||||||
|
return (THEME_UNKNOWN);
|
||||||
|
w = wp->window;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Derive theme from pane background color, if it's not the default
|
* Derive theme from pane background color, if it's not the default
|
||||||
* colour.
|
* colour.
|
||||||
|
Reference in New Issue
Block a user