diff options
author | Marco Barisione <marco.barisione@collabora.co.uk> | 2013-07-29 23:20:24 +0800 |
---|---|---|
committer | Marco Barisione <marco.barisione@collabora.co.uk> | 2013-08-20 18:03:06 +0800 |
commit | f6d827a6b1006858de979d6627598fa17098ee62 (patch) | |
tree | 8ac85d9a2035213aed5e9e194bfe1047ee3094c1 /src | |
parent | 6400b739ecdf0e14ad3cc1c6c7032a4eb486bb0e (diff) | |
download | gsoc2013-empathy-f6d827a6b1006858de979d6627598fa17098ee62.tar gsoc2013-empathy-f6d827a6b1006858de979d6627598fa17098ee62.tar.gz gsoc2013-empathy-f6d827a6b1006858de979d6627598fa17098ee62.tar.bz2 gsoc2013-empathy-f6d827a6b1006858de979d6627598fa17098ee62.tar.lz gsoc2013-empathy-f6d827a6b1006858de979d6627598fa17098ee62.tar.xz gsoc2013-empathy-f6d827a6b1006858de979d6627598fa17098ee62.tar.zst gsoc2013-empathy-f6d827a6b1006858de979d6627598fa17098ee62.zip |
camera-monitor: move from Empathy to tp-account-widgets
https://bugzilla.gnome.org/show_bug.cgi?id=699492
Diffstat (limited to 'src')
-rw-r--r-- | src/empathy-call-window.c | 26 | ||||
-rw-r--r-- | src/empathy-camera-menu.c | 21 |
2 files changed, 24 insertions, 23 deletions
diff --git a/src/empathy-call-window.c b/src/empathy-call-window.c index ed5de4ee7..cac15bc66 100644 --- a/src/empathy-call-window.c +++ b/src/empathy-call-window.c @@ -26,13 +26,13 @@ #include <farstream/fs-element-added-notifier.h> #include <farstream/fs-utils.h> #include <tp-account-widgets/tpaw-builder.h> +#include <tp-account-widgets/tpaw-camera-monitor.h> #include "empathy-about-dialog.h" #include "empathy-audio-sink.h" #include "empathy-call-utils.h" #include "empathy-call-window-fullscreen.h" #include "empathy-camera-menu.h" -#include "empathy-camera-monitor.h" #include "empathy-dialpad-widget.h" #include "empathy-geometry.h" #include "empathy-gsettings.h" @@ -122,7 +122,7 @@ struct _EmpathyCallWindowPriv EmpathyContact *contact; - EmpathyCameraMonitor *camera_monitor; + TpawCameraMonitor *camera_monitor; CallState call_state; gboolean outgoing; @@ -562,17 +562,17 @@ empathy_call_window_swap_camera_cb (GtkAction *action, DEBUG ("Swapping the camera"); - cameras = empathy_camera_monitor_get_cameras (self->priv->camera_monitor); + cameras = tpaw_camera_monitor_get_cameras (self->priv->camera_monitor); current_cam = empathy_video_src_dup_device ( EMPATHY_GST_VIDEO_SRC (self->priv->video_input)); for (l = cameras; l != NULL; l = l->next) { - EmpathyCamera *camera = l->data; + TpawCamera *camera = l->data; if (!tp_strdiff (camera->device, current_cam)) { - EmpathyCamera *next; + TpawCamera *next; if (l->next != NULL) next = l->next->data; @@ -593,22 +593,22 @@ empathy_call_window_swap_camera_cb (GtkAction *action, } static void -empathy_call_window_camera_added_cb (EmpathyCameraMonitor *monitor, - EmpathyCamera *camera, +empathy_call_window_camera_added_cb (TpawCameraMonitor *monitor, + TpawCamera *camera, EmpathyCallWindow *self) { - const GList *cameras = empathy_camera_monitor_get_cameras (monitor); + const GList *cameras = tpaw_camera_monitor_get_cameras (monitor); gtk_action_set_visible (self->priv->menu_swap_camera, g_list_length ((GList *) cameras) >= 2); } static void -empathy_call_window_camera_removed_cb (EmpathyCameraMonitor *monitor, - EmpathyCamera *camera, +empathy_call_window_camera_removed_cb (TpawCameraMonitor *monitor, + TpawCamera *camera, EmpathyCallWindow *self) { - const GList *cameras = empathy_camera_monitor_get_cameras (monitor); + const GList *cameras = tpaw_camera_monitor_get_cameras (monitor); gtk_action_set_visible (self->priv->menu_swap_camera, g_list_length ((GList *) cameras) >= 2); @@ -1681,7 +1681,7 @@ empathy_call_window_init (EmpathyCallWindow *self) empathy_set_css_provider (GTK_WIDGET (self)); gtk_action_set_sensitive (priv->menu_fullscreen, FALSE); - priv->camera_monitor = empathy_camera_monitor_dup_singleton (); + priv->camera_monitor = tpaw_camera_monitor_dup_singleton (); g_object_bind_property (priv->camera_monitor, "available", priv->camera_button, "sensitive", @@ -3272,7 +3272,7 @@ empathy_call_window_state_changed_cb (EmpathyCallHandler *handler, can_send_video = priv->video_input != NULL && empathy_contact_can_voip_video (priv->contact) && - empathy_camera_monitor_get_available (priv->camera_monitor); + tpaw_camera_monitor_get_available (priv->camera_monitor); g_object_get (priv->handler, "call-channel", &call, NULL); diff --git a/src/empathy-camera-menu.c b/src/empathy-camera-menu.c index 8dc037bdb..cf18340c4 100644 --- a/src/empathy-camera-menu.c +++ b/src/empathy-camera-menu.c @@ -22,7 +22,8 @@ #include "config.h" #include "empathy-camera-menu.h" -#include "empathy-camera-monitor.h" +#include <tp-account-widgets/tpaw-camera-monitor.h> + #include "empathy-gsettings.h" #define DEBUG_FLAG EMPATHY_DEBUG_VOIP @@ -51,7 +52,7 @@ struct _EmpathyCameraMenuPrivate /* Queue of GtkRadioActions. */ GQueue *cameras; - EmpathyCameraMonitor *camera_monitor; + TpawCameraMonitor *camera_monitor; GSettings *settings; }; @@ -200,7 +201,7 @@ empathy_camera_menu_update (EmpathyCameraMenu *self) static void empathy_camera_menu_add_camera (EmpathyCameraMenu *self, - EmpathyCamera *camera) + TpawCamera *camera) { GtkRadioAction *action; GSList *group; @@ -219,8 +220,8 @@ empathy_camera_menu_add_camera (EmpathyCameraMenu *self, } static void -empathy_camera_menu_camera_added_cb (EmpathyCameraMonitor *monitor, - EmpathyCamera *camera, +empathy_camera_menu_camera_added_cb (TpawCameraMonitor *monitor, + TpawCamera *camera, EmpathyCameraMenu *self) { empathy_camera_menu_add_camera (self, camera); @@ -228,8 +229,8 @@ empathy_camera_menu_camera_added_cb (EmpathyCameraMonitor *monitor, } static void -empathy_camera_menu_camera_removed_cb (EmpathyCameraMonitor *monitor, - EmpathyCamera *camera, +empathy_camera_menu_camera_removed_cb (TpawCameraMonitor *monitor, + TpawCamera *camera, EmpathyCameraMenu *self) { GList *l; @@ -303,11 +304,11 @@ empathy_camera_menu_get_cameras (EmpathyCameraMenu *self) { const GList *cameras; - cameras = empathy_camera_monitor_get_cameras (self->priv->camera_monitor); + cameras = tpaw_camera_monitor_get_cameras (self->priv->camera_monitor); for (; cameras != NULL; cameras = g_list_next (cameras)) { - EmpathyCamera *camera = cameras->data; + TpawCamera *camera = cameras->data; empathy_camera_menu_add_camera (self, camera); } @@ -346,7 +347,7 @@ empathy_camera_menu_constructed (GObject *obj) self->priv->anchor_action); g_object_unref (self->priv->anchor_action); - self->priv->camera_monitor = empathy_camera_monitor_new (); + self->priv->camera_monitor = tpaw_camera_monitor_new (); tp_g_signal_connect_object (self->priv->camera_monitor, "added", G_CALLBACK (empathy_camera_menu_camera_added_cb), self, 0); |