[gimp/wip/Jehan/layers-dockable-refresh: 71/126] app: more coordinate conversion in GimpContainerTreeView.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/wip/Jehan/layers-dockable-refresh: 71/126] app: more coordinate conversion in GimpContainerTreeView.
- Date: Wed, 15 Dec 2021 23:16:47 +0000 (UTC)
commit 2c8a96fc9f5649c4c943c287dd54e6d7b5facb2e
Author: Jehan <jehan girinstud io>
Date: Tue Mar 9 22:12:51 2021 +0100
app: more coordinate conversion in GimpContainerTreeView.
app/widgets/gimpcontainertreeview-dnd.c | 3 +++
app/widgets/gimpcontainertreeview.c | 3 +++
2 files changed, 6 insertions(+)
---
diff --git a/app/widgets/gimpcontainertreeview-dnd.c b/app/widgets/gimpcontainertreeview-dnd.c
index 37aec76ebf..da073f27a6 100644
--- a/app/widgets/gimpcontainertreeview-dnd.c
+++ b/app/widgets/gimpcontainertreeview-dnd.c
@@ -253,6 +253,9 @@ gimp_container_tree_view_drop_status (GimpContainerTreeView *tree_view,
g_object_unref (renderer);
gtk_tree_view_get_cell_area (tree_view->view, drop_path, NULL, &cell_area);
+ gtk_tree_view_convert_bin_window_to_widget_coords (tree_view->view,
+ cell_area.x, cell_area.y, &cell_area.x,
&cell_area.y);
+
if (gimp_viewable_get_children (dest_viewable))
{
diff --git a/app/widgets/gimpcontainertreeview.c b/app/widgets/gimpcontainertreeview.c
index c346ba5699..6177aa0621 100644
--- a/app/widgets/gimpcontainertreeview.c
+++ b/app/widgets/gimpcontainertreeview.c
@@ -451,6 +451,9 @@ gimp_container_tree_view_popup_menu (GtkWidget *widget)
path = gtk_tree_model_get_path (tree_view->model, &iter);
gtk_tree_view_get_cell_area (tree_view->view, path,
tree_view->main_column, &rect);
+ gtk_tree_view_convert_bin_window_to_widget_coords (tree_view->view,
+ rect.x, rect.y,
+ &rect.x, &rect.y);
gtk_tree_path_free (path);
return gimp_editor_popup_menu_at_rect (GIMP_EDITOR (widget),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]