[gimp/wip/Jehan/layers-dockable-refresh: 24/58] 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: 24/58] app: more coordinate conversion in GimpContainerTreeView.
- Date: Fri, 22 Oct 2021 21:36:49 +0000 (UTC)
commit 85d3e1e4f1022c4651356006cd1150fb3e5213d5
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 9b7947d81e..b7b0579e47 100644
--- a/app/widgets/gimpcontainertreeview.c
+++ b/app/widgets/gimpcontainertreeview.c
@@ -467,6 +467,9 @@ gimp_container_tree_view_menu_position (GtkMenu *menu,
path = gtk_tree_model_get_path (tree_view->model, &selected_iter);
gtk_tree_view_get_cell_area (tree_view->view, path,
tree_view->main_column, &cell_rect);
+ gtk_tree_view_convert_bin_window_to_widget_coords (tree_view->view,
+ cell_rect.x, cell_rect.y,
+ &cell_rect.x, &cell_rect.y);
gtk_tree_path_free (path);
center = cell_rect.y + cell_rect.height / 2;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]