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 160807 - Use GTK+ 2.5/2.6 features in Totem
Use GTK+ 2.5/2.6 features in Totem
Status: RESOLVED FIXED
Product: totem
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
Depends on: 163292 169772 338954 353560
Blocks:
 
 
Reported: 2004-12-08 22:39 UTC by Bastien Nocera
Modified: 2006-09-04 21:02 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proposed patch. (2.71 KB, patch)
2005-01-06 02:17 UTC, Dennis Cranston
committed Details | Review
HIG dialogs patch (8.94 KB, patch)
2005-01-11 04:50 UTC, William Jon McCann
committed Details | Review

Description Bastien Nocera 2004-12-08 22:39:57 UTC
This is a checklist of what needs to be done to port Totem to GTK+ 2.6 and
associated libraries:
- Use gtk+ about box
- Use new HIG dialogs
- Skim out the DND code using gtk_drag_source_add_uri_targets
- Use the GKeyFile .ini style parser for the .pls file parser
- Use GOption for arguments parsing
- Use GTK_STOCK_MEDIA_* stock icons

Feel free to add more to this bug.
Comment 1 Bastien Nocera 2004-12-08 22:44:03 UTC
- Use GtkLabel's ellipsising instead of our own widget (gtk_label_set_ellipsize())
Comment 2 Bastien Nocera 2004-12-08 22:46:22 UTC
- Use focus stealing prevention:
http://mail.gnome.org/archives/desktop-devel-list/2004-December/msg00306.html
Comment 3 Bastien Nocera 2005-01-03 22:19:18 UTC
2005-01-03  Bastien Nocera  <hadess@hadess.net>

        * configure.in:
        * src/Makefile.am:
        * src/rb-ellipsizing-label.c:
        * src/rb-ellipsizing-label.h:
        * src/totem.c: (update_mrl_label), (on_about1_activate),
        (totem_callback_connect), (label_create):
        Require GTK+ 2.6, convert the about box, and the ellipsising labels
        (Helps: #160807)
Comment 4 Dennis Cranston 2005-01-04 02:08:36 UTC
Here is an item to add to your list.
- Migrate from GtkOptionMenu to GtkComboBox
Comment 5 Bastien Nocera 2005-01-05 17:04:48 UTC
We won't be able to port the .pls parser to GKeyFile because of bug 63029 and
bug 63030. We'll see whether they can be fixed.
Comment 6 Bastien Nocera 2005-01-05 23:39:15 UTC
2005-01-05  Bastien Nocera  <hadess@hadess.net>

        * data/totem.glade:
        * src/totem-preferences.c: (totem_prefs_set_show_visuals),
        (connection_combobox_changed), (visual_menu_changed),
        (visual_quality_menu_changed), (audio_out_menu_changed),
        (totem_setup_preferences): Migrate the Option Menus in the preferences
        dialog to Combo Boxes (Helps: #160807)

(CANT) - Skim out the DND code using gtk_drag_source_add_uri_targets (there's no
special support for _NETSCAPE_URL which we support)
(CANT) - Use the GKeyFile .ini style parser for the .pls file parser (the groups
and keys are case-sensitive)

(DONE) - Use GTK_STOCK_MEDIA_* stock icons
(DONE) - Use GtkLabel's ellipsising instead of our own widget
(gtk_label_set_ellipsize())
(DONE) - Use gtk+ about box
(DONE) - Migrate from GtkOptionMenu to GtkComboBox

(TODO) - Use new HIG dialogs
(TODO) - Use GOption for arguments parsing
Comment 7 Dennis Cranston 2005-01-06 02:17:13 UTC
Created attachment 35521 [details] [review]
Proposed patch.

The recent change from Option Menus to Combo Boxes broke their mnemonics.  This
patch fixes the problem.  Thanks!
Comment 8 Bastien Nocera 2005-01-06 10:01:54 UTC
Yeah, they were broken. Patch committed, thanks.
Comment 9 Christian Rose 2005-01-07 12:22:34 UTC
Danilo, are entries in combo boxes supposed to be marked for translation this
way (all in one message)? I vaguely remember some problems with this in the
past, where the contents of the combo boxes would end up untranslated if their
contents had been marked for translation all in one message, but I'm not sure
about it.
Comment 10 Bastien Nocera 2005-01-07 12:41:34 UTC
Christian, this is the way glade does it...
Comment 11 Christian Neumair 2005-01-07 17:15:07 UTC
Bastien: Please use gtk_combo_box_append_text for each line in the construction
code instead of putting this info directly into glade. If you aren't lazy enough
(who isn't?), you could even use a custom tree model for the combo box and use
gtk_combo_box_get_active_iter instead of gtk_combo_box_get_active for getting
the current entry, comparing the value of a enum'ed column against some enum {
FIRST_ENTRY, 2ND_ENTRY, ..., N_TH_ENTRY };
Christian: Please file a bug report against glade if it doesn't already exist.
Probably they use something like g_strsplit (compound_string, "\n"), which
really sucks translation-wise.
Comment 12 Christian Rose 2005-01-07 23:23:39 UTC
Ok, added bug 163292.
Comment 13 William Jon McCann 2005-01-11 04:50:22 UTC
Created attachment 35803 [details] [review]
HIG dialogs patch
Comment 14 Bastien Nocera 2005-03-09 21:12:28 UTC
I've looked at the focus stealing prevention, and it looks like Totem is a good
citizen, with the error dialogs only shown following a user interaction.
The only thing left is using GOption instead of popt. We're going to wait for
GStreamer to use GOption before we switch all the apps to it.
Comment 15 Bastien Nocera 2005-03-14 12:07:43 UTC
gtk_list_store_insert_with_values() looks fast:
http://developer.gnome.org/doc/API/2.0/gtk/GtkListStore.html#gtk-list-store-insert-with-values
Comment 16 Bastien Nocera 2005-03-15 11:08:23 UTC
We need to use gnome_vfs_read_entire_file instead of our own version in the
totem-playlist-parser.
Comment 17 Luis Menina 2006-04-19 01:13:15 UTC
This bug depends on bug 338954 for the popt -> GOption migration part. I don't have rights to change the dependencies, though.
Comment 18 Bastien Nocera 2006-09-04 21:02:05 UTC
As there is only the GOption migration left, and bug 338954 already includes it, closing this.