aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPo Lu2022-04-07 14:02:34 +0800
committerPo Lu2022-04-07 14:02:34 +0800
commit48bbc4a9a1606b76cac2382b93743fb22dc044c7 (patch)
tree7befa2f448a30f5763e73a824e506437d9147440 /src
parentc6ea0772ec1878d3d894e8b370f1272f88a97ea3 (diff)
downloademacs-48bbc4a9a1606b76cac2382b93743fb22dc044c7.tar.gz
emacs-48bbc4a9a1606b76cac2382b93743fb22dc044c7.zip
Fix DND bugs on GTK
* src/xterm.c (handle_one_xevent): Don't let some client messages reach the toolkit.
Diffstat (limited to 'src')
-rw-r--r--src/xterm.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/xterm.c b/src/xterm.c
index 58a4fc6117a..4e2091a0de9 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -13540,6 +13540,8 @@ handle_one_xevent (struct x_display_info *dpyinfo,
13540 else 13540 else
13541 x_dnd_action = None; 13541 x_dnd_action = None;
13542 } 13542 }
13543
13544 goto done;
13543 } 13545 }
13544 13546
13545 if (event->xclient.message_type == dpyinfo->Xatom_XdndFinished 13547 if (event->xclient.message_type == dpyinfo->Xatom_XdndFinished
@@ -13554,6 +13556,8 @@ handle_one_xevent (struct x_display_info *dpyinfo,
13554 if (x_dnd_waiting_for_finish_proto >= 5 13556 if (x_dnd_waiting_for_finish_proto >= 5
13555 && !(event->xclient.data.l[1] & 1)) 13557 && !(event->xclient.data.l[1] & 1))
13556 x_dnd_action = None; 13558 x_dnd_action = None;
13559
13560 goto done;
13557 } 13561 }
13558 13562
13559 if ((event->xclient.message_type 13563 if ((event->xclient.message_type
@@ -13579,7 +13583,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
13579 && operation != XM_DRAG_LINK) 13583 && operation != XM_DRAG_LINK)
13580 { 13584 {
13581 x_dnd_waiting_for_finish = false; 13585 x_dnd_waiting_for_finish = false;
13582 goto OTHER; 13586 goto done;
13583 } 13587 }
13584 13588
13585 if (status != XM_DROP_SITE_VALID 13589 if (status != XM_DROP_SITE_VALID
@@ -13587,7 +13591,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
13587 || action == XM_DROP_ACTION_DROP_HELP)) 13591 || action == XM_DROP_ACTION_DROP_HELP))
13588 { 13592 {
13589 x_dnd_waiting_for_finish = false; 13593 x_dnd_waiting_for_finish = false;
13590 goto OTHER; 13594 goto done;
13591 } 13595 }
13592 13596
13593 switch (operation) 13597 switch (operation)
@@ -13606,7 +13610,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
13606 } 13610 }
13607 13611
13608 x_dnd_waiting_for_motif_finish = 2; 13612 x_dnd_waiting_for_motif_finish = 2;
13609 goto OTHER; 13613 goto done;
13610 } 13614 }
13611 } 13615 }
13612 13616