talons

Fork of Claws Mail https://www.claws-mail
Log | Files | Refs | README | LICENSE

commit 4a0f97d327ceba2e40c575ddba66349a9c23ff13
parent dd815043d89b0f936984ddf396e37eef7be00d67
Author: Ricardo Mones <ricardo@mones.org>
Date:   Thu, 30 Jan 2025 00:47:28 +0100

Remove some deprecation warnings from python-shell

Removes 11 instances of “warning: Deprecated pre-processor symbol:
replace with "G_ADD_PRIVATE"”

Diffstat:
Msrc/plugins/python/python-shell.c | 8+++++---
1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/plugins/python/python-shell.c b/src/plugins/python/python-shell.c @@ -33,8 +33,7 @@ #define MAX_HISTORY_LENGTH 20 #define PARASITE_PYTHON_SHELL_GET_PRIVATE(obj) \ - (G_TYPE_INSTANCE_GET_PRIVATE((obj), PARASITE_TYPE_PYTHON_SHELL, \ - ParasitePythonShellPrivate)) + parasite_python_shell_get_instance_private((ParasitePythonShell *) (obj)) typedef struct { @@ -421,7 +420,10 @@ parasite_python_shell_append_text(ParasitePythonShell *python_shell, void parasite_python_shell_focus(ParasitePythonShell *python_shell) { - gtk_widget_grab_focus(PARASITE_PYTHON_SHELL_GET_PRIVATE(python_shell)->textview); + ParasitePythonShellPrivate *priv = + PARASITE_PYTHON_SHELL_GET_PRIVATE(python_shell); + + gtk_widget_grab_focus(priv->textview); } // vim: set et ts=4: