Commit 9011dadb authored by Bastien Nocera's avatar Bastien Nocera

plugins: Use non-obsolete public functions

parent 5334f6a8
......@@ -88,7 +88,7 @@ totem_disc_recorder_plugin_start_burning (TotemDiscRecorderPlugin *pi,
GError *error = NULL;
char *xid_arg;
main_window = totem_get_main_window (pi->priv->totem);
main_window = totem_object_get_main_window (pi->priv->totem);
screen = gtk_widget_get_screen (GTK_WIDGET (main_window));
display = gdk_display_get_default ();
......@@ -130,7 +130,7 @@ totem_disc_recorder_plugin_start_burning (TotemDiscRecorderPlugin *pi,
return TRUE;
error:
main_window = totem_get_main_window (pi->priv->totem);
main_window = totem_object_get_main_window (pi->priv->totem);
if (copy != FALSE)
totem_interface_error (_("The video disc could not be duplicated."), error->message, main_window);
......@@ -215,7 +215,7 @@ totem_disc_recorder_plugin_write_video_project (TotemDiscRecorderPlugin *pi,
if (success < 0)
goto error;
uri = totem_get_current_mrl (pi->priv->totem);
uri = totem_object_get_current_mrl (pi->priv->totem);
escaped = (unsigned char *) g_uri_escape_string (uri, NULL, FALSE);
g_free (uri);
......@@ -282,7 +282,7 @@ totem_disc_recorder_plugin_burn (GtkAction *action,
if (!path) {
totem_interface_error (_("The movie could not be recorded."),
error,
totem_get_main_window (pi->priv->totem));
totem_object_get_main_window (pi->priv->totem));
g_free (error);
return;
}
......@@ -299,7 +299,7 @@ totem_disc_recorder_plugin_copy (GtkAction *action,
{
char *mrl;
mrl = totem_get_current_mrl (pi->priv->totem);
mrl = totem_object_get_current_mrl (pi->priv->totem);
if (!g_str_has_prefix (mrl, "dvd:") && !g_str_has_prefix (mrl, "vcd:")) {
g_free (mrl);
g_assert_not_reached ();
......@@ -410,7 +410,7 @@ impl_activate (PeasActivatable *plugin)
G_N_ELEMENTS (totem_disc_recorder_plugin_actions),
pi);
uimanager = totem_get_ui_manager (priv->totem);
uimanager = totem_object_get_ui_manager (priv->totem);
gtk_ui_manager_insert_action_group (uimanager, priv->action_group, -1);
g_object_unref (priv->action_group);
......@@ -440,7 +440,7 @@ impl_activate (PeasActivatable *plugin)
GTK_UI_MANAGER_MENUITEM,
TRUE);
if (!totem_is_paused (priv->totem) && !totem_is_playing (priv->totem)) {
if (!totem_object_is_paused (priv->totem) && !totem_object_is_playing (priv->totem)) {
action = gtk_action_group_get_action (priv->action_group, "VideoBurnToDisc");
gtk_action_set_visible (action, FALSE);
action = gtk_action_group_get_action (priv->action_group, "VideoDVDCopy");
......@@ -450,7 +450,7 @@ impl_activate (PeasActivatable *plugin)
else {
char *mrl;
mrl = totem_get_current_mrl (priv->totem);
mrl = totem_object_get_current_mrl (priv->totem);
totem_disc_recorder_file_opened (priv->totem, mrl, pi);
g_free (mrl);
}
......@@ -466,7 +466,7 @@ impl_deactivate (PeasActivatable *plugin)
g_signal_handlers_disconnect_by_func (priv->totem, totem_disc_recorder_file_opened, plugin);
g_signal_handlers_disconnect_by_func (priv->totem, totem_disc_recorder_file_closed, plugin);
uimanager = totem_get_ui_manager (priv->totem);
uimanager = totem_object_get_ui_manager (priv->totem);
gtk_ui_manager_remove_ui (uimanager, priv->ui_merge_id);
gtk_ui_manager_remove_action_group (uimanager, priv->action_group);
......
......@@ -321,7 +321,7 @@ totem_file_opened_result_cb (GObject *source_object,
if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_NOT_FOUND) &&
!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED) &&
!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_NOT_MOUNTED)) {
totem_action_error (plugin->priv->totem, _("Error while reading file with chapters"),
totem_object_action_error (plugin->priv->totem, _("Error while reading file with chapters"),
error->message);
g_error_free (error);
......@@ -417,7 +417,7 @@ chapter_edit_dialog_response_cb (GtkDialog *dialog,
g_object_unref (G_OBJECT (plugin->priv->last_frame));
if (plugin->priv->was_played)
totem_action_play (plugin->priv->totem);
totem_object_action_play (plugin->priv->totem);
return;
}
......@@ -435,7 +435,7 @@ chapter_edit_dialog_response_cb (GtkDialog *dialog,
gtk_widget_destroy (GTK_WIDGET (plugin->priv->edit_chapter));
if (plugin->priv->was_played)
totem_action_play (plugin->priv->totem);
totem_object_action_play (plugin->priv->totem);
}
static void
......@@ -532,8 +532,8 @@ show_chapter_edit_dialog (TotemChaptersPlugin *plugin)
return;
}
main_window = totem_get_main_window (plugin->priv->totem);
plugin->priv->was_played = totem_is_playing (plugin->priv->totem);
main_window = totem_object_get_main_window (plugin->priv->totem);
plugin->priv->was_played = totem_object_is_playing (plugin->priv->totem);
totem_action_pause (plugin->priv->totem);
/* adding a new one, check if it's time available */
......@@ -544,13 +544,13 @@ show_chapter_edit_dialog (TotemChaptersPlugin *plugin)
main_window);
g_object_unref (main_window);
if (plugin->priv->was_played)
totem_action_play (plugin->priv->totem);
totem_object_action_play (plugin->priv->totem);
return;
}
plugin->priv->last_time = _time;
/* capture frame */
bvw = BACON_VIDEO_WIDGET (totem_get_video_widget (plugin->priv->totem));
bvw = BACON_VIDEO_WIDGET (totem_object_get_video_widget (plugin->priv->totem));
plugin->priv->last_frame = bacon_video_widget_get_current_frame (bvw);
g_object_add_weak_pointer (G_OBJECT (plugin->priv->last_frame), (gpointer *) &plugin->priv->last_frame);
g_object_unref (bvw);
......@@ -699,7 +699,7 @@ save_chapters_result_cb (gpointer data,
plugin = TOTEM_CHAPTERS_PLUGIN (adata->user_data);
if (G_UNLIKELY (!adata->successful && !g_cancellable_is_cancelled (adata->cancellable))) {
totem_action_error (plugin->priv->totem, _("Error while writing file with chapters"),
totem_object_action_error (plugin->priv->totem, _("Error while writing file with chapters"),
adata->error);
gtk_widget_set_sensitive (plugin->priv->save_button, TRUE);
}
......@@ -823,7 +823,7 @@ save_button_clicked_cb (GtkButton *button,
(gpointer *) &(plugin->priv->cancellable[1]));
if (G_UNLIKELY (totem_cmml_write_file_async (data) < 0)) {
totem_action_error (plugin->priv->totem, _("Error occurred while saving chapters"),
totem_object_action_error (plugin->priv->totem, _("Error occurred while saving chapters"),
_("Please check you have permission to write to the folder containing the movie."));
g_free (data);
} else
......@@ -846,7 +846,7 @@ tree_view_row_activated_cb (GtkTreeView *tree_view,
g_return_if_fail (path != NULL);
store = gtk_tree_view_get_model (tree_view);
seekable = totem_is_seekable (plugin->priv->totem);
seekable = totem_object_is_seekable (plugin->priv->totem);
if (!seekable) {
g_warning ("chapters: unable to seek stream!");
return;
......@@ -855,7 +855,7 @@ tree_view_row_activated_cb (GtkTreeView *tree_view,
gtk_tree_model_get_iter (store, &iter, path);
gtk_tree_model_get (store, &iter, CHAPTERS_TIME_PRIV_COLUMN, &_time, -1);
totem_action_seek_time (plugin->priv->totem, _time, TRUE);
totem_object_action_seek_time (plugin->priv->totem, _time, TRUE);
}
gboolean
......@@ -952,11 +952,11 @@ load_button_clicked_cb (GtkButton *button,
g_return_if_fail (TOTEM_IS_CHAPTERS_PLUGIN (plugin));
plugin->priv->was_played = totem_is_playing (plugin->priv->totem);
plugin->priv->was_played = totem_object_is_playing (plugin->priv->totem);
totem_action_pause (plugin->priv->totem);
mrl = totem_get_current_mrl (plugin->priv->totem);
main_window = totem_get_main_window (plugin->priv->totem);
mrl = totem_object_get_current_mrl (plugin->priv->totem);
main_window = totem_object_get_main_window (plugin->priv->totem);
dialog = gtk_file_chooser_dialog_new (_("Open Chapter File"), main_window, GTK_FILE_CHOOSER_ACTION_OPEN,
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
GTK_STOCK_OPEN, GTK_RESPONSE_ACCEPT,
......@@ -995,7 +995,7 @@ load_button_clicked_cb (GtkButton *button,
}
if (plugin->priv->was_played)
totem_action_play (plugin->priv->totem);
totem_object_action_play (plugin->priv->totem);
gtk_widget_destroy (dialog);
g_object_unref (main_window);
......@@ -1053,7 +1053,7 @@ impl_activate (PeasActivatable *plugin)
cplugin = TOTEM_CHAPTERS_PLUGIN (plugin);
totem = g_object_get_data (G_OBJECT (plugin), "object");
main_window = totem_get_main_window (totem);
main_window = totem_object_get_main_window (totem);
builder = totem_plugin_load_interface ("chapters", "chapters-list.ui", TRUE,
main_window, cplugin);
......@@ -1119,7 +1119,7 @@ impl_activate (PeasActivatable *plugin)
set_no_data_visible (TRUE, FALSE, cplugin);
totem_add_sidebar_page (totem, "chapters", _("Chapters"), main_box);
totem_object_add_sidebar_page (totem, "chapters", _("Chapters"), main_box);
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (cplugin->priv->tree));
gtk_tree_selection_set_mode (selection, GTK_SELECTION_MULTIPLE);
......@@ -1137,7 +1137,7 @@ impl_activate (PeasActivatable *plugin)
G_CALLBACK (chapter_selection_changed_cb),
plugin);
mrl = totem_get_current_mrl (cplugin->priv->totem);
mrl = totem_object_get_current_mrl (cplugin->priv->totem);
if (mrl != NULL)
totem_file_opened_async_cb (cplugin->priv->totem, mrl, cplugin);
......@@ -1220,5 +1220,5 @@ impl_deactivate (PeasActivatable *plugin)
g_object_unref (cplugin->priv->totem);
g_free (cplugin->priv->cmml_mrl);
totem_remove_sidebar_page (totem, "chapters");
totem_object_remove_sidebar_page (totem, "chapters");
}
......@@ -221,7 +221,7 @@ load_icon (TotemGriloPlugin *self, IconType icon_type, gint thumb_size)
static GdkPixbuf *pixbuf[G_N_ELEMENTS(icon_name)] = { NULL };
if (pixbuf[icon_type] == NULL) {
screen = gtk_window_get_screen (totem_get_main_window (self->priv->totem));
screen = gtk_window_get_screen (totem_object_get_main_window (self->priv->totem));
theme = gtk_icon_theme_get_for_screen (screen);
pixbuf[icon_type] = gtk_icon_theme_load_icon (theme,
icon_name[icon_type],
......@@ -433,7 +433,7 @@ browse_cb (GrlSource *source,
g_error_matches (error,
GRL_CORE_ERROR,
GRL_CORE_ERROR_OPERATION_CANCELLED) == FALSE) {
window = totem_get_main_window (self->priv->totem);
window = totem_object_get_main_window (self->priv->totem);
totem_interface_error (_("Browse Error"), error->message, window);
}
......@@ -549,7 +549,7 @@ play (TotemGriloPlugin *self,
url = grl_media_get_url (media);
if (url != NULL) {
totem_add_to_playlist_and_play (self->priv->totem, url,
totem_object_add_to_playlist_and_play (self->priv->totem, url,
grl_media_get_title (media));
return;
}
......@@ -602,7 +602,7 @@ search_cb (GrlSource *source,
g_error_matches (error,
GRL_CORE_ERROR,
GRL_CORE_ERROR_OPERATION_CANCELLED) == FALSE) {
window = totem_get_main_window (self->priv->totem);
window = totem_object_get_main_window (self->priv->totem);
totem_interface_error (_("Search Error"), error->message, window);
}
......@@ -1170,7 +1170,7 @@ setup_sidebar_browse (TotemGriloPlugin *self,
G_CALLBACK (get_more_browse_results_cb),
self);
totem_add_sidebar_page (self->priv->totem,
totem_object_add_sidebar_page (self->priv->totem,
"grilo-browse", _("Browse"),
GTK_WIDGET (gtk_builder_get_object (builder, "gw_browse_window")));
}
......@@ -1213,7 +1213,7 @@ setup_sidebar_search (TotemGriloPlugin *self,
G_CALLBACK (adjustment_changed_cb),
self);
totem_add_sidebar_page (self->priv->totem,
totem_object_add_sidebar_page (self->priv->totem,
"grilo-search", _("Search"),
GTK_WIDGET (gtk_builder_get_object (builder, "gw_search")));
}
......@@ -1221,7 +1221,7 @@ setup_sidebar_search (TotemGriloPlugin *self,
static void
add_to_pls_cb (GtkAction *action, TotemGriloPlugin *self)
{
totem_add_to_playlist_and_play (self->priv->totem,
totem_object_add_to_playlist_and_play (self->priv->totem,
grl_media_get_url (self->priv->selected_media),
grl_media_get_title (self->priv->selected_media));
}
......@@ -1314,7 +1314,7 @@ impl_activate (PeasActivatable *plugin)
TotemGriloPlugin *self = TOTEM_GRILO_PLUGIN (plugin);
TotemGriloPluginPrivate *priv = self->priv;
priv->totem = g_object_ref (g_object_get_data (G_OBJECT (plugin), "object"));
main_window = totem_get_main_window (priv->totem);
main_window = totem_object_get_main_window (priv->totem);
priv->cache_thumbnails = g_hash_table_new_full (g_str_hash,
g_str_equal,
g_free,
......@@ -1336,8 +1336,8 @@ impl_deactivate (PeasActivatable *plugin)
GList *s;
GrlRegistry *registry;
totem_remove_sidebar_page (self->priv->totem, "grilo-browse");
totem_remove_sidebar_page (self->priv->totem, "grilo-search");
totem_object_remove_sidebar_page (self->priv->totem, "grilo-browse");
totem_object_remove_sidebar_page (self->priv->totem, "grilo-search");
registry = grl_registry_get_default ();
g_signal_handlers_disconnect_by_func (registry, source_added_cb, self);
......
......@@ -234,7 +234,7 @@ impl_activate (PeasActivatable *plugin)
#endif
}
window = totem_get_main_window (g_object_get_data (G_OBJECT (plugin), "object"));
window = totem_object_get_main_window (g_object_get_data (G_OBJECT (plugin), "object"));
pi->priv->handler_id = g_signal_connect (G_OBJECT(window), "key-press-event",
G_CALLBACK (on_window_key_press_event), plugin);
g_object_unref (window);
......@@ -247,7 +247,7 @@ impl_deactivate (PeasActivatable *plugin)
GtkWindow *window;
if (pi->priv->handler_id != 0) {
window = totem_get_main_window (g_object_get_data (G_OBJECT (plugin), "object"));
window = totem_object_get_main_window (g_object_get_data (G_OBJECT (plugin), "object"));
g_signal_handler_disconnect (G_OBJECT(window), pi->priv->handler_id);
pi->priv->handler_id = 0;
g_object_unref (window);
......
......@@ -97,7 +97,7 @@ totem_im_status_update_from_state (TotemObject *totem,
if (pi->priv->proxy == NULL)
return;
if (totem_is_playing (totem) != FALSE
if (totem_object_is_playing (totem) != FALSE
&& totem_is_fullscreen (totem) != FALSE) {
totem_im_status_set_idleness (pi, TRUE);
} else {
......
......@@ -210,12 +210,12 @@ totem_lirc_read_code (GIOChannel *source, GIOCondition condition, TotemLircPlugi
if (setting >= 0) {
gboolean value;
value = totem_action_remote_get_setting (pi->priv->totem, setting);
totem_action_remote_set_setting (pi->priv->totem, setting, !value);
value = totem_object_action_remote_get_setting (pi->priv->totem, setting);
totem_object_action_remote_set_setting (pi->priv->totem, setting, !value);
}
} else {
cmd = totem_lirc_to_command (str, &url);
totem_action_remote (pi->priv->totem, cmd, url);
totem_object_action_remote (pi->priv->totem, cmd, url);
}
g_free (url);
} while (TRUE);
......
......@@ -63,27 +63,27 @@ on_media_player_key_pressed (TotemObject *totem,
const gchar *key)
{
if (strcmp ("Play", key) == 0)
totem_action_play_pause (totem);
totem_object_action_play_pause (totem);
else if (strcmp ("Previous", key) == 0)
totem_action_previous (totem);
totem_object_action_previous (totem);
else if (strcmp ("Next", key) == 0)
totem_action_next (totem);
totem_object_action_next (totem);
else if (strcmp ("Stop", key) == 0)
totem_action_pause (totem);
else if (strcmp ("FastForward", key) == 0)
totem_action_remote (totem, TOTEM_REMOTE_COMMAND_SEEK_FORWARD, NULL);
totem_object_action_remote (totem, TOTEM_REMOTE_COMMAND_SEEK_FORWARD, NULL);
else if (strcmp ("Rewind", key) == 0)
totem_action_remote (totem, TOTEM_REMOTE_COMMAND_SEEK_BACKWARD, NULL);
totem_object_action_remote (totem, TOTEM_REMOTE_COMMAND_SEEK_BACKWARD, NULL);
else if (strcmp ("Repeat", key) == 0) {
gboolean value;
value = totem_action_remote_get_setting (totem, TOTEM_REMOTE_SETTING_REPEAT);
totem_action_remote_set_setting (totem, TOTEM_REMOTE_SETTING_REPEAT, !value);
value = totem_object_action_remote_get_setting (totem, TOTEM_REMOTE_SETTING_REPEAT);
totem_object_action_remote_set_setting (totem, TOTEM_REMOTE_SETTING_REPEAT, !value);
} else if (strcmp ("Shuffle", key) == 0) {
gboolean value;
value = totem_action_remote_get_setting (totem, TOTEM_REMOTE_SETTING_SHUFFLE);
totem_action_remote_set_setting (totem, TOTEM_REMOTE_SETTING_SHUFFLE, !value);
value = totem_object_action_remote_get_setting (totem, TOTEM_REMOTE_SETTING_SHUFFLE);
totem_object_action_remote_set_setting (totem, TOTEM_REMOTE_SETTING_SHUFFLE, !value);
}
}
......@@ -250,7 +250,7 @@ impl_activate (PeasActivatable *plugin)
g_object_ref (pi), (GDestroyNotify) g_object_unref);
totem = g_object_get_data (G_OBJECT (plugin), "object");
window = totem_get_main_window (totem);
window = totem_object_get_main_window (totem);
pi->priv->handler_id = g_signal_connect (G_OBJECT (window), "focus-in-event",
G_CALLBACK (on_window_focus_in_event), pi);
......@@ -280,7 +280,7 @@ impl_deactivate (PeasActivatable *plugin)
TotemObject *totem;
totem = g_object_get_data (G_OBJECT (plugin), "object");
window = totem_get_main_window (totem);
window = totem_object_get_main_window (totem);
if (window == NULL)
return;
......
......@@ -64,7 +64,7 @@ update_from_state (TotemOntopPluginPrivate *priv)
bacon_video_widget_get_metadata (priv->bvw, BVW_INFO_HAS_VIDEO, &has_video);
gtk_window_set_keep_above (priv->window,
(totem_is_playing (priv->totem) != FALSE &&
(totem_object_is_playing (priv->totem) != FALSE &&
g_value_get_boolean (&has_video) != FALSE));
g_value_unset (&has_video);
}
......@@ -89,8 +89,8 @@ impl_activate (PeasActivatable *plugin)
TotemOntopPlugin *pi = TOTEM_ONTOP_PLUGIN (plugin);
pi->priv->totem = g_object_get_data (G_OBJECT (plugin), "object");
pi->priv->window = totem_get_main_window (pi->priv->totem);
pi->priv->bvw = BACON_VIDEO_WIDGET (totem_get_video_widget (pi->priv->totem));
pi->priv->window = totem_object_get_main_window (pi->priv->totem);
pi->priv->bvw = BACON_VIDEO_WIDGET (totem_object_get_video_widget (pi->priv->totem));
pi->priv->handler_id = g_signal_connect (G_OBJECT (pi->priv->totem),
"notify::playing",
......
......@@ -197,7 +197,7 @@ totem_movie_properties_plugin_file_opened (TotemObject *totem,
{
GtkWidget *bvw;
bvw = totem_get_video_widget (totem);
bvw = totem_object_get_video_widget (totem);
update_properties_from_bvw
(BACON_VIDEO_WIDGET_PROPERTIES (plugin->priv->props), bvw);
g_object_unref (bvw);
......@@ -224,7 +224,7 @@ totem_movie_properties_plugin_metadata_updated (TotemObject *totem,
{
GtkWidget *bvw;
bvw = totem_get_video_widget (totem);
bvw = totem_object_get_video_widget (totem);
update_properties_from_bvw
(BACON_VIDEO_WIDGET_PROPERTIES (plugin->priv->props), bvw);
g_object_unref (bvw);
......@@ -241,7 +241,7 @@ impl_activate (PeasActivatable *plugin)
pi->priv->props = bacon_video_widget_properties_new ();
gtk_widget_show (pi->priv->props);
totem_add_sidebar_page (totem,
totem_object_add_sidebar_page (totem,
"properties",
_("Properties"),
pi->priv->props);
......@@ -285,6 +285,6 @@ impl_deactivate (PeasActivatable *plugin)
totem_movie_properties_plugin_file_closed,
plugin);
pi->priv->handler_id_stream_length = 0;
totem_remove_sidebar_page (totem, "properties");
totem_object_remove_sidebar_page (totem, "properties");
}
......@@ -127,7 +127,7 @@ totem_save_file_plugin_copy (GtkAction *action,
fs = gtk_file_chooser_dialog_new (_("Save a Copy"),
totem_get_main_window (pi->priv->totem),
totem_object_get_main_window (pi->priv->totem),
GTK_FILE_CHOOSER_ACTION_SAVE,
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
GTK_STOCK_SAVE, GTK_RESPONSE_ACCEPT,
......@@ -276,7 +276,7 @@ impl_activate (PeasActivatable *plugin)
g_free (path);
priv->totem = g_object_get_data (G_OBJECT (plugin), "object");
priv->bvw = totem_get_video_widget (priv->totem);
priv->bvw = totem_object_get_video_widget (priv->totem);
g_signal_connect (priv->totem,
"file-opened",
......@@ -299,7 +299,7 @@ impl_activate (PeasActivatable *plugin)
G_N_ELEMENTS (totem_save_file_plugin_actions),
pi);
uimanager = totem_get_ui_manager (priv->totem);
uimanager = totem_object_get_ui_manager (priv->totem);
gtk_ui_manager_insert_action_group (uimanager, priv->action_group, -1);
g_object_unref (priv->action_group);
......@@ -323,7 +323,7 @@ impl_activate (PeasActivatable *plugin)
action = gtk_action_group_get_action (priv->action_group, "SaveFile");
gtk_action_set_sensitive (action, FALSE);
mrl = totem_get_current_mrl (priv->totem);
mrl = totem_object_get_current_mrl (priv->totem);
totem_save_file_file_opened (priv->totem, mrl, pi);
totem_save_file_download_filename (NULL, NULL, pi);
g_free (mrl);
......@@ -340,7 +340,7 @@ impl_deactivate (PeasActivatable *plugin)
g_signal_handlers_disconnect_by_func (priv->totem, totem_save_file_file_closed, plugin);
g_signal_handlers_disconnect_by_func (priv->bvw, totem_save_file_download_filename, plugin);
uimanager = totem_get_ui_manager (priv->totem);
uimanager = totem_object_get_ui_manager (priv->totem);
gtk_ui_manager_remove_ui (uimanager, priv->ui_merge_id);
gtk_ui_manager_remove_action_group (uimanager, priv->action_group);
......
......@@ -80,17 +80,17 @@ totem_screensaver_update_from_state (TotemObject *totem,
gboolean lock_screensaver_on_audio, has_video_frames;
BaconVideoWidget *bvw;
bvw = BACON_VIDEO_WIDGET (totem_get_video_widget ((Totem *)(totem)));
bvw = BACON_VIDEO_WIDGET (totem_object_get_video_widget ((Totem *)(totem)));
lock_screensaver_on_audio = g_settings_get_boolean (pi->priv->settings, "lock-screensaver-on-audio");
has_video_frames = has_video (bvw);
if ((totem_is_playing (totem) != FALSE && has_video_frames) ||
(totem_is_playing (totem) != FALSE && !lock_screensaver_on_audio)) {
if ((totem_object_is_playing (totem) != FALSE && has_video_frames) ||
(totem_object_is_playing (totem) != FALSE && !lock_screensaver_on_audio)) {
if (pi->priv->inhibit_cookie == 0) {
GtkWindow *window;
window = totem_get_main_window (totem);
window = totem_object_get_main_window (totem);
pi->priv->inhibit_cookie = gtk_application_inhibit (GTK_APPLICATION (totem),
window,
GTK_APPLICATION_INHIBIT_IDLE,
......@@ -132,7 +132,7 @@ impl_activate (PeasActivatable *plugin)
TotemObject *totem;
totem = g_object_get_data (G_OBJECT (plugin), "object");
pi->priv->bvw = BACON_VIDEO_WIDGET (totem_get_video_widget (totem));
pi->priv->bvw = BACON_VIDEO_WIDGET (totem_object_get_video_widget (totem));
pi->priv->settings = g_settings_new (TOTEM_GSETTINGS_SCHEMA);
g_signal_connect (pi->priv->settings, "changed::lock-screensaver-on-audio", (GCallback) lock_screensaver_on_audio_changed_cb, plugin);
......
......@@ -165,7 +165,7 @@ dialog_response_callback (GtkDialog *dialog, gint response_id, TotemGallery *sel
screenshot_count = gtk_spin_button_get_value_as_int (self->priv->screenshot_count);
filename = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (self));
video_mrl = totem_get_current_mrl (self->priv->totem);
video_mrl = totem_object_get_current_mrl (self->priv->totem);
totem_screenshot_plugin_update_file_chooser (filename);
/* Build the command and arguments to pass it */
......
......@@ -217,7 +217,7 @@ take_screenshot_action_cb (GtkAction *action, TotemScreenshotPlugin *self)
if (err == NULL)
return;
totem_action_error (priv->totem, _("Totem could not get a screenshot of the video."), err->message);
totem_object_action_error (priv->totem, _("Totem could not get a screenshot of the video."), err->message);
g_error_free (err);
return;
}
......@@ -226,7 +226,7 @@ take_screenshot_action_cb (GtkAction *action, TotemScreenshotPlugin *self)
pixbuf = bacon_video_widget_get_current_frame (priv->bvw);
if (pixbuf == NULL) {
totem_action_error (priv->totem, _("Totem could not get a screenshot of the video."), _("This is not supposed to happen; please file a bug report."));
totem_object_action_error (priv->totem, _("Totem could not get a screenshot of the video."), _("This is not supposed to happen; please file a bug report."));
return;
}
......@@ -336,7 +336,7 @@ impl_activate (PeasActivatable *plugin)
};
priv->totem = g_object_get_data (G_OBJECT (plugin), "object");
priv->bvw = BACON_VIDEO_WIDGET (totem_get_video_widget (priv->totem));
priv->bvw = BACON_VIDEO_WIDGET (totem_object_get_video_widget (priv->totem));
priv->got_metadata_signal = g_signal_connect (G_OBJECT (priv->bvw),
"got-metadata",
G_CALLBACK (got_metadata_cb),
......@@ -347,7 +347,7 @@ impl_activate (PeasActivatable *plugin)
self);
/* Key press handler */
window = totem_get_main_window (priv->totem);
window = totem_object_get_main_window (priv->totem);
priv->key_press_event_signal = g_signal_connect (G_OBJECT (window),
"key-press-event",
G_CALLBACK (window_key_press_event_cb),
......@@ -360,7 +360,7 @@ impl_activate (PeasActivatable *plugin)
gtk_action_group_add_actions (priv->action_group, menu_entries,
G_N_ELEMENTS (menu_entries), self);
manager = totem_get_ui_manager (priv->totem);
manager = totem_object_get_ui_manager (priv->totem);
gtk_ui_manager_insert_action_group (manager, priv->action_group, -1);
g_object_unref (priv->action_group);
......@@ -396,7 +396,7 @@ impl_deactivate (PeasActivatable *plugin)
g_signal_handler_disconnect (G_OBJECT (priv->bvw), priv->got_metadata_signal);
g_signal_handler_disconnect (G_OBJECT (priv->bvw), priv->notify_logo_mode_signal);
window = totem_get_main_window (priv->totem);
window = totem_object_get_main_window (priv->totem);
g_signal_handler_disconnect (G_OBJECT (window), priv->key_press_event_signal);
g_object_unref (window);
......@@ -404,7 +404,7 @@ impl_deactivate (PeasActivatable *plugin)
g_object_unref (priv->settings);
/* Remove the menu */
manager = totem_get_ui_manager (priv->totem);
manager = totem_object_get_ui_manager (priv->totem);
gtk_ui_manager_remove_ui (manager, priv->ui_merge_id);
gtk_ui_manager_remove_action_group (manager, priv->action_group);
......
......@@ -56,7 +56,7 @@ impl_activate (PeasActivatable *plugin)
label = gtk_label_new ("This is a test sidebar main widget");
gtk_widget_show (label);
totem_add_sidebar_page (g_object_get_data (G_OBJECT (plugin), "object"),
totem_object_add_sidebar_page (g_object_get_data (G_OBJECT (plugin), "object"),
"sidebar-test",
"Sidebar Test",
label);
......@@ -69,7 +69,7 @@ impl_deactivate (PeasActivatable *plugin)
TotemObject *totem;
totem = g_object_get_data (G_OBJECT (plugin), "object");
totem_remove_sidebar_page (totem, "sidebar-test");
totem_object_remove_sidebar_page (totem, "sidebar-test");
g_message ("Just removed a test sidebar");
}
......@@ -112,7 +112,7 @@ skip_to_response_callback (GtkDialog *dialog, gint response, TotemSkiptoPlugin *
gtk_widget_hide (GTK_WIDGET (dialog));
totem_action_seek_time (plugin->priv->totem,
totem_object_action_seek_time (plugin->priv->totem,
totem_skipto_get_range (plugin->priv->st),
TRUE);
destroy_dialog (plugin);
......@@ -123,7 +123,7 @@ run_skip_to_dialog (TotemSkiptoPlugin *plugin)
{
TotemSkiptoPluginPrivate *priv = plugin->priv;
if (totem_is_seekable (priv->totem) == FALSE)
if (totem_object_is_seekable (priv->totem) == FALSE)
return;
if (priv->st != NULL) {
......@@ -193,7 +193,7 @@ impl_activate (PeasActivatable *plugin)
pi);
/* Key press handler */
window = totem_get_main_window (priv->totem);
window = totem_object_get_main_window (priv->totem);
priv->handler_id_key_press = g_signal_connect (G_OBJECT(window),
"key-press-event",
G_CALLBACK (on_window_key_press_event),
......@@ -206,7 +206,7 @@ impl_activate (PeasActivatable *plugin)
gtk_action_group_add_actions (priv->action_group, menu_entries,
G_N_ELEMENTS (menu_entries), pi);
manager = totem_get_ui_manager (priv->totem);
manager = totem_object_get_ui_manager (priv->totem);
gtk_ui_manager_insert_action_group (manager, priv->action_group, -1);
g_object_unref (priv->action_group);
......@@ -235,7 +235,7 @@ impl_deactivate (PeasActivatable *plugin)
priv->handler_id_seekable);
if (priv->handler_id_key_press != 0) {
window = totem_get_main_window (totem);
window = totem_object_get_main_window (totem);
g_signal_handler_disconnect (G_OBJECT(window),
priv->handler_id_key_press);
priv->handler_id_key_press = 0;
......@@ -243,7 +243,7 @@ impl_deactivate (PeasActivatable *plugin)
}
/* Remove the menu */
manager = totem_get_ui_manager (totem);
manager = totem_object_get_ui_manager (totem);
gtk_ui_manager_remove_ui (manager, priv->ui_merge_id);
gtk_ui_manager_remove_action_group (manager, priv->action_group);
......
......@@ -213,7 +213,7 @@ totem_skipto_new (TotemObject *totem)
0); /* padding */
gtk_window_set_transient_for (GTK_WINDOW (skipto),
totem_get_main_window (totem));
totem_object_get_main_window (totem));
gtk_widget_show_all (GTK_WIDGET (skipto));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment