]> git.0d.be Git - empathy.git/commitdiff
Display the preview video button in the preview corner
authorEmilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>
Mon, 15 Aug 2011 23:41:56 +0000 (00:41 +0100)
committerEmilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>
Tue, 16 Aug 2011 10:13:58 +0000 (11:13 +0100)
https://bugzilla.gnome.org/show_bug.cgi?id=656571

src/empathy-call-window.c

index b56613ca5f1bbc8de473c6e79dd716bd49aeda48..5bcf4644af3f1624ef4e59a56d7d328bd12c768e 100644 (file)
@@ -931,7 +931,7 @@ static void
 create_video_preview (EmpathyCallWindow *self)
 {
   EmpathyCallWindowPriv *priv = GET_PRIV (self);
-  ClutterLayoutManager *layout, *layout_center;
+  ClutterLayoutManager *layout, *layout_center, *layout_end;
   ClutterActor *preview;
   ClutterActor *box;
   ClutterActor *b;
@@ -986,10 +986,15 @@ create_video_preview (EmpathyCallWindow *self)
   button = gtk_button_new_with_label (_("i"));
   b = gtk_clutter_actor_new_with_contents (button);
 
-  clutter_bin_layout_add (CLUTTER_BIN_LAYOUT (layout_center),
-      b,
-      CLUTTER_BIN_ALIGNMENT_END,
+  layout_end = clutter_bin_layout_new (CLUTTER_BIN_ALIGNMENT_END,
       CLUTTER_BIN_ALIGNMENT_END);
+  box = clutter_box_new (layout_end);
+  clutter_actor_set_size (box,
+      SELF_VIDEO_SECTION_WIDTH,
+      SELF_VIDEO_SECTION_HEIGTH + SELF_VIDEO_SECTION_MARGIN);
+
+  clutter_container_add_actor (CLUTTER_CONTAINER (box), b);
+  clutter_container_add_actor (CLUTTER_CONTAINER (priv->video_preview), box);
 
   g_signal_connect (button, "clicked",
       G_CALLBACK (empathy_call_window_preview_button_clicked_cb),