Closed Bug 201501 Opened 21 years ago Closed 17 years ago

string arguments in gtk signals are wrong

Categories

(Core Graveyard :: Embedding: GTK Widget, defect)

x86
Linux
defect
Not set
major

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: jdahlin, Assigned: mpgritti)

References

Details

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4a) Gecko/20030305 Phoenix/0.5
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4a) Gecko/20030305 Phoenix/0.5

When trying to use gtkmozembed throught the python bindings I found the
following problem:

In a few of the signals, strings are used, but marked as GTK_TYPE_POINTER
So when pygtk tries to demarshal them it thinks it's a bogus pointer object
instead of a string.

The solution is to mark all strings as GTK_TYPE_STRING instead.

Reproducible: Always

Steps to Reproduce:
Attached patch v1: First takeSplinter Review
Untested with gtk+1 (I don't have a build to test with)
Added a generate-marshals target in the Makefile to make it easier to update
marshallers.
Summary: gtk signals are wrong → string arguments in gtk signals are wrong
I thought I already fixed this at one point?
Blocks: gtk2
This is still broken. (Verified on the 1.7-branch )

For example; the open_uri-signal has got two arguments, the embed widget and the
URI. 
With mozilla straight from CVS the URI is a pointer, not a string.

With the Python bindings:
AttributeError: 'gobject.GPointer' object has no attribute 'find'

I am about to use mozilla and python bindings in a commercial product, so I
would really like to see this in the tree, instead of having to apply patches :)

Attached patch applies cleanly and works as expected.
Blizzard, no it's not fixed. (just checked
http://lxr.mozilla.org/seamonkey/source/embedding/browser/gtk/src/gtkmozembed2.cpp)

I know that other bindings (gtk# for instance) has also run into the same issue.

(Can't confirm, since I don't have power to do so)
Is there anything that still needs to be done to commit this patch?
(In reply to comment #6)
> Is there anything that still needs to be done to commit this patch?

Yes, it needs to get reviews. Unfortunately blizzard (the gtkembed owner, see
<http://www.mozilla.org/owners.html#gtk-embedding-widget>) says "not doing
reviews", so I'm not sure who could review this.
jdahlin@async.com.br: Does attachment 120078 [details] [diff] [review] work on trunk, and have you tested
it with GTK1?
Vidar: No idea, I don't have a tree which I can easily test.
Comment on attachment 120078 [details] [diff] [review]
v1: First take

Actually, I think marco can do gtkembed reviews.
Attachment #120078 - Flags: review?(caillon) → review?(mpgritti)
Comment on attachment 120078 [details] [diff] [review]
v1: First take

As far as I can see, this patch is obsolete; the bug was already fixed on trunk/1.8 by the patch from bug 297238.
-> Embedding: GTK Widget
Assignee: blizzard → mpgritti
Component: GFX: Gtk → Embedding: GTK Widget
QA Contact: ian → pavlov
Yup, the patch is obsolete and the bug is fixed on the trunk.
Status: UNCONFIRMED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Attachment #120078 - Flags: review?(mpgritti)
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: