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 652374 - region: remove helper function not needed since GTK+ 3.0
region: remove helper function not needed since GTK+ 3.0
Status: RESOLVED FIXED
Product: gnome-control-center
Classification: Core
Component: Region & Language
unspecified
Other All
: Normal normal
: ---
Assigned To: Control-Center Maintainers
Depends on:
Blocks:
 
 
Reported: 2011-06-12 00:18 UTC by Rui Matos
Modified: 2011-06-12 13:09 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
region: remove helper function not needed since GTK+ 3.0 (2.51 KB, patch)
2011-06-12 00:18 UTC, Rui Matos
none Details | Review

Description Rui Matos 2011-06-12 00:18:07 UTC
Noticed this while doing another patch.
Comment 1 Rui Matos 2011-06-12 00:18:09 UTC
Created attachment 189743 [details] [review]
region: remove helper function not needed since GTK+ 3.0

GTK+ 3.0 introduced gtk_tree_model_iter_previous() so we no longer need to
keep this helper function.

Also, simplify the use of GtkTreeIters by allocating them on the stack.
Comment 2 Bastien Nocera 2011-06-12 00:28:37 UTC
Review of attachment 189743 [details] [review]:

Just one question. Looks fine otherwise.

::: panels/region/gnome-region-panel-xkblt.c
@@ +384,3 @@
 		return;
 
+	prev = iter;

Hmm, not certain we can copy those by value.
Comment 3 Rui Matos 2011-06-12 01:11:39 UTC
(In reply to comment #2)
> ::: panels/region/gnome-region-panel-xkblt.c
> @@ +384,3 @@
>          return;
> 
> +    prev = iter;
> 
> Hmm, not certain we can copy those by value.

We can, according to http://developer.gnome.org/gtk3/stable/GtkTreeModel.html#gtk-tree-iter-copy
Comment 4 Sergey V. Udaltsov 2011-06-12 13:09:55 UTC
Well, copying structs like that ... always looked suspicious to me. But if everybody is ok with it, I am committing.