rem: int retval;
context: main (int argc, char **argv){	Totem *totem;	char *filename;	GConfClient *gc;	GError *err = NULL;	GdkPixbuf *pix;	int retval;	bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR);	bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");	textdomain (GETTEXT_PACKAGE);	/* Please also translate your language into its native language	 * in src/languages.h	 * for example: French -> Francais	 * use C UTF-8 strings */	g_set_application_name (_("Totem Movie Player"));	/* FIXME See http://bugzilla.gnome.org/show_bug.cgi?id=111349 */	if (XInitThreads () == 0)	{		gtk_init (&argc, &argv);		totem_action_error_and_exit (_("Could not initialise the "					"thread-safe libraries.\n"					"Verify your system installation. Totem"					" will now exit."), NULL);	}	g_thread_init (NULL);	gdk_threads_init ();	gnome_program_init ("totem", VERSION,			LIBGNOMEUI_MODULE,			argc, argv,			GNOME_PARAM_APP_DATADIR, DATADIR,			GNOME_PARAM_POPT_TABLE, options,			GNOME_PARAM_NONE);	glade_init ();	gnome_vfs_init ();	if ((gc = gconf_client_get_default ()) == NULL)	{		char *str;		str = g_strdup_printf (_("Totem couln't initialise the \n"					"configuration engine:\n%s"),				err->message);		totem_action_error_and_exit (str, totem);		g_error_free (err);		g_free (str);	}	gnome_authentication_manager_init ();	filename = gnome_program_locate_file (NULL,			GNOME_FILE_DOMAIN_APP_DATADIR,			"totem/totem.glade", TRUE, NULL);	if (filename == NULL)	{		totem_action_error_and_exit (_("Couldn't load the main "					"interface (totem.glade).\n"					"Make sure that Totem"					" is properly installed."), NULL);	}	totem = g_new0 (Totem, 1);	/* IPC stuff */	totem->conn = bacon_message_connection_new (GETTEXT_PACKAGE);	if (bacon_message_connection_get_is_server (totem->conn) == TRUE)	{		bacon_message_connection_set_callback (totem->conn,				(BaconMessageReceivedFunc)				totem_message_connection_receive_cb, totem);	} else {		process_command_line (totem->conn, argc, argv);		bacon_message_connection_free (totem->conn);		g_free (totem);		gdk_notify_startup_complete ();		exit (0);	}	/* Init totem itself */	totem->prev_volume = -1;	totem->gc = gc;	/* Main window */	totem->xml = glade_xml_new (filename, NULL, NULL);	if (totem->xml == NULL)	{		g_free (filename);		totem_action_error_and_exit (_("Couldn't load the main "					"interface (totem.glade).\n"					"Make sure that Totem"					" is properly installed."), NULL);	}	g_free (filename);	totem->win = glade_xml_get_widget (totem->xml, "app1");	filename = g_build_filename (G_DIR_SEPARATOR_S, DATADIR,			"totem", "media-player-48.png", NULL);	gtk_window_set_default_icon_from_file (filename, NULL);	g_free (filename);	/* The playlist */	filename = g_build_filename (G_DIR_SEPARATOR_S, DATADIR,			"totem", "playlist-playing.png", NULL);	pix = gdk_pixbuf_new_from_file (filename, NULL);	g_free (filename);	filename = g_build_filename (G_DIR_SEPARATOR_S, DATADIR,			"totem", "playlist.glade", NULL);	totem->playlist = GTK_PLAYLIST (gtk_playlist_new (filename, pix));	g_free (filename);	if (totem->playlist == NULL)	{		totem_action_error_and_exit (_("Couldn't load the interface "					"for the playlist."					"\nMake sure that Totem"					" is properly installed."),				totem);	}	filename = g_build_filename (G_DIR_SEPARATOR_S, DATADIR,			"totem", "playlist-24.png", NULL);	gtk_window_set_icon_from_file (GTK_WINDOW (totem->playlist),			filename, NULL);	g_free (filename);	/* The rest of the widgets */	totem->seek = glade_xml_get_widget (totem->xml, "hscale1");	totem->seekadj = gtk_range_get_adjustment (GTK_RANGE (totem->seek));	totem->volume = glade_xml_get_widget (totem->xml, "hscale2");	totem->voladj = gtk_range_get_adjustment (GTK_RANGE (totem->volume));	totem->exit_popup = glade_xml_get_widget (totem->xml, "window1");	totem->control_popup = glade_xml_get_widget (totem->xml, "window2");	totem->fs_seek = glade_xml_get_widget (totem->xml, "hscale4");	totem->fs_seekadj = gtk_range_get_adjustment		(GTK_RANGE (totem->fs_seek));	totem->fs_volume = glade_xml_get_widget (totem->xml, "hscale5");	totem->fs_voladj = gtk_range_get_adjustment		(GTK_RANGE (totem->fs_volume));	totem->volume_first_time = 1;	totem->fs_pp_button = glade_xml_get_widget (totem->xml, "fs_pp_button");	totem->statusbar = glade_xml_get_widget (totem->xml, "custom4");	/* Properties */	totem->properties = bacon_video_widget_properties_new ();	totem_setup_recent (totem);	totem_callback_connect (totem);	/* Show ! gtk_main_iteration trickery to show all the widgets	 * we have so far */	gtk_widget_show_all (totem->win);	update_fullscreen_size (totem);	long_action ();	/* Show ! (again) the video widget this time. */	video_widget_create (totem);	/* The prefs after the video widget is connected */	totem_setup_preferences (totem);	if (argc > 1)	{		if (totem_action_open_files (totem, argv, TRUE))			totem_action_play_pause (totem);		else			totem_action_set_mrl (totem, NULL);	} else {		if (totem_action_restore_pl (totem) == FALSE)			totem_action_set_mrl (totem, NULL);	}#ifdef HAVE_REMOTE	totem->remote = totem_remote_new ();	g_signal_connect (totem->remote, "button_pressed",			  G_CALLBACK (totem_button_pressed_remote_cb), totem);#endif	gtk_main ();	return 0;}