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 454242 - Move UIManager code to GtkBuilder
Move UIManager code to GtkBuilder
Status: RESOLVED FIXED
Product: totem
Classification: Core
Component: Movie player
2.19.x
Other Linux
: Normal normal
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
Depends on:
Blocks: 484126
 
 
Reported: 2007-07-06 11:41 UTC by Philip Withnall
Modified: 2007-10-06 13:28 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Move UIManager stuff to GtkBuilder (not yet working) (43.54 KB, patch)
2007-07-23 14:50 UTC, Philip Withnall
needs-work Details | Review
Move UIManager stuff to GtkBuilder (50.23 KB, patch)
2007-07-23 17:53 UTC, Philip Withnall
none Details | Review
Move UIManager stuff to GtkBuilder (updated) (55.86 KB, patch)
2007-07-25 17:02 UTC, Philip Withnall
needs-work Details | Review
Move UIManager stuff to GtkBuilder (updated) (55.97 KB, patch)
2007-07-25 22:35 UTC, Philip Withnall
none Details | Review
Move UIManager stuff to GtkBuilder (updated) (54.65 KB, patch)
2007-09-26 17:31 UTC, Philip Withnall
committed Details | Review

Description Philip Withnall 2007-07-06 11:41:07 UTC
SSIA.
Comment 1 Philip Withnall 2007-07-23 14:50:13 UTC
Created attachment 92212 [details] [review]
Move UIManager stuff to GtkBuilder (not yet working)

This patch has most of the grunt work done, but it's not quite working (there are some possible memory bugs), and some work still needs to be done to re-enable the LTR-/RTL-dependent actions.
Comment 2 Philip Withnall 2007-07-23 17:53:01 UTC
Created attachment 92222 [details] [review]
Move UIManager stuff to GtkBuilder

This patch fixes all the issues I can find, and should be pretty much ready for committing.
Comment 3 Philip Withnall 2007-07-25 17:02:25 UTC
Created attachment 92406 [details] [review]
Move UIManager stuff to GtkBuilder (updated)

This patch fixes a Makefile issue I introduced, and also moves the playlist UIManager stuff to GtkBuilder.
Comment 4 Philip Withnall 2007-07-25 17:41:15 UTC
I've just noticed I made a typo with the "gtk-preferences" stock ID. I'll submit a new patch once I've got the actions which use custom stock items working, as I've just noticed they're not displaying icons. :-\
Comment 5 Philip Withnall 2007-07-25 22:35:12 UTC
Created attachment 92420 [details] [review]
Move UIManager stuff to GtkBuilder (updated)

There we go. Everything should be finished and working in this patch. :-)
Comment 6 Philip Withnall 2007-09-26 17:31:27 UTC
Created attachment 96239 [details] [review]
Move UIManager stuff to GtkBuilder (updated)

Here's a version updated to SVN head.
Comment 7 Bastien Nocera 2007-09-26 21:08:10 UTC
Comment on attachment 96239 [details] [review]
Move UIManager stuff to GtkBuilder (updated)

>Index: src/backend/bacon-video-widget.h
>===================================================================
>--- src/backend/bacon-video-widget.h	(revision 4735)
>+++ src/backend/bacon-video-widget.h	(working copy)
>@@ -238,11 +238,11 @@
> } BaconVideoWidgetVideoProperty;
> 
> typedef enum {
>-	BVW_RATIO_AUTO,
>-	BVW_RATIO_SQUARE,
>-	BVW_RATIO_FOURBYTHREE,
>-	BVW_RATIO_ANAMORPHIC,
>-	BVW_RATIO_DVB
>+	BVW_RATIO_AUTO = 1,
>+	BVW_RATIO_SQUARE = 2,
>+	BVW_RATIO_FOURBYTHREE = 3,
>+	BVW_RATIO_ANAMORPHIC = 4,
>+	BVW_RATIO_DVB = 5
> } BaconVideoWidgetAspectRatio;

What's 0 used for? What's the point of an enum where we list the values, might as well used defines.

Rest looks alright, needs testing obviously.
Comment 8 Philip Withnall 2007-09-27 21:55:20 UTC
Unfortunately we have to list the values in the enum so that they can be referenced in the UI file; it doesn't like the enum names.

Numbering can start with 0 if you want, but I thought we could reserve that for "unknown". :-)
Comment 9 Bastien Nocera 2007-09-27 22:26:09 UTC
I think you need to register the enum with the GType system, just like you did for the ones that needed it in the bindings.
Comment 10 Philip Withnall 2007-09-30 14:09:26 UTC
I've talked to Johan about this, and it currently isn't supported in GtkBuilder; only integers are allowed, so this hack has to remain. There's little possibility of adding support for using enums in this situation to GtkBuilder, as it would have to search through every single GEnumClass to find the right enum, which would be too inefficient.
Comment 11 Bastien Nocera 2007-10-01 09:03:47 UTC
Could you just change that to start at 0 then. Looks ok to commit afterwards.
Comment 12 Philip Withnall 2007-10-06 13:28:00 UTC
2007-10-06  Philip Withnall  <pwithnall@svn.gnome.org>

	* data/Makefile.am:
	* data/playlist-ui.xml:
	* data/playlist.ui:
	* data/totem-ui.xml:
	* data/totem.ui:
	* src/backend/bacon-video-widget.h:
	* src/totem-menu.c: (totem_ui_manager_setup):
	* src/totem-playlist.c: (playlist_copy_location_action_callback),
	(playlist_remove_action_callback), (totem_playlist_init):
	* src/totem.c: (update_seekable), (totem_callback_connect): Move
	UIManager stuff to GtkBuilder (Closes: #454242)