Make sure all users of GtkCMCList do not blindly assume that a button-press-event...
authorAndrej Kacian <ticho@claws-mail.org>
Mon, 5 Nov 2018 23:05:17 +0000 (00:05 +0100)
committerAndrej Kacian <ticho@claws-mail.org>
Mon, 5 Nov 2018 23:05:17 +0000 (00:05 +0100)
commite0981338ea10b5216764d66663298026fa30cab8
tree4b3c30e99bd7a72c431f38a05266a336f13f2fc9
parent09541526d2781d4adfed9108ecb254dd517af3a2
Make sure all users of GtkCMCList do not blindly assume that a button-press-event happens inside of the tree view.

If clicking on the header row, the event's x,y coordinates
were pointing to a different spot than what the event handler
code expected, since those coordinates are relative to the
relevant GDK window, and header row has its own. Calls to
gtk_cmclist_get_selection_info() or gtk_sctree_is_hot_spot()
in such cases therefore returned bogus info.

This fixes things like folderview expanding/collapsing
selected folder when double-clicking its header column, or
selecting first row when single-clicking it.
src/addressbook.c
src/editgroup.c
src/folderview.c
src/grouplistdialog.c
src/gtk/gtkcmctree.h
src/gtk/gtksctree.h
src/summaryview.c