[planner: 58/61] popup-entry: fix direct access issue for entry widget in cell renderer mode




commit 92614c4fe52769df3e11b4195371dedb819179c5
Author: Mart Raudsepp <leio gentoo org>
Date:   Sun Mar 21 14:22:52 2021 +0200

    popup-entry: fix direct access issue for entry widget in cell renderer mode
    
    The old code directly accessed a member variable of GtkEntry. This
    direct access will no longer be possible with GTK3, but there is no
    public function to get/set this variable.
    
    Instead use gtk_entry_set_visible as found to be a good enough
    alternative by GnuCash developers who did this change during their
    porting of this code (originally forked from planner) to GTK3.
    
    Matches GnuCash commit 87a0cb736025269821c743d1154cf89656a54b21

 src/planner-popup-entry.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/planner-popup-entry.c b/src/planner-popup-entry.c
index 611bf56b..2d70df0c 100644
--- a/src/planner-popup-entry.c
+++ b/src/planner-popup-entry.c
@@ -86,7 +86,7 @@ planner_popup_entry_init (PlannerPopupEntry *widget)
        gtk_widget_show (widget->hbox);
 
        widget->entry = g_object_new (GTK_TYPE_ENTRY, "has_frame", FALSE, NULL);
-       GTK_ENTRY (widget->entry)->is_cell_renderer = TRUE;
+       gtk_entry_set_visibility (GTK_ENTRY (widget->entry), TRUE);
        gtk_widget_show (widget->entry);
 
        widget->button = gtk_button_new ();


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]