After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 610636 - Please adapt to changed GtkSourceCompletion{Proposal,Provider} API.
Please adapt to changed GtkSourceCompletion{Proposal,Provider} API.
Status: RESOLVED FIXED
Product: anjuta
Classification: Applications
Component: plugins: editor: gtksourceview
2.29.x
Other Linux
: Normal normal
: ---
Assigned To: Johannes Schmid
Anjuta maintainers
Depends on:
Blocks:
 
 
Reported: 2010-02-21 21:58 UTC by Krzesimir Nowak
Modified: 2010-02-21 23:55 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch adapting get_name() to changed API. (986 bytes, patch)
2010-02-21 23:21 UTC, Krzesimir Nowak
none Details | Review

Description Krzesimir Nowak 2010-02-21 21:58:48 UTC
With bug 610342 fixed an API change was introduced:
gtk_source_completion_proposal_get_label(),
gtk_source_completion_proposal_get_markup(),
gtk_source_completion_proposal_get_info(),
gtk_source_completion_proposal_get_text() and gtk_source_provider_get_name()
now return a new string, which needs to be freed with g_free().

Sorry for choosing this category, but if I could, I would choose four of them.

Seems that affected are sourceview, language-support-cpp-java and language-support-js plugins. Probably IAnjutaProvider's get_name() method should be changed as well to return gchar* instead of const gchar*.
Comment 1 Krzesimir Nowak 2010-02-21 23:21:09 UTC
Created attachment 154345 [details] [review]
Patch adapting get_name() to changed API.

After having a deeper look into plugins and libanjuta interfaces I noticed that not so much changes need to be introduced. I would leave IAnjutaProvider as it is, so language-support-* plugins are unaffected.

That leaves sourceview plugin. In sourceview-provider.c there is sourceview_provider_get_name() defined, but it is probably useless, because it is used nowhere. I mean - gtk_source_completion_provider_get_name() is never called, get_name member of GtkSourceCompletionProviderIface is never used. I would just remove it. Or if it is used by something else internally then it could just g_strdup a string given by implementor of IAnjutaProvider.

In the end - I'm providing a two lines patch. Seems like a lot of fuss over nothing. :)
Comment 2 Ignacio Casal Quinteiro (nacho) 2010-02-21 23:40:00 UTC
mmm, it is weird that it is not used... I'd to check.
Comment 3 Ignacio Casal Quinteiro (nacho) 2010-02-21 23:41:56 UTC
After checking your patch looks good, please commit it.
Comment 4 Krzesimir Nowak 2010-02-21 23:55:07 UTC
Pushed to master.