[gnome-contacts] Add Call icon for regular IM contacts



commit 2a3d02c19526ea9e941af9e975819ae713974776
Author: Raul Gutierrez Segales <rgs collabora co uk>
Date:   Sat Aug 27 20:11:48 2011 +0100

    Add Call icon for regular IM contacts
    
    We need to find a different icon for this and also
    add support for video. We should actually check with
    the Design folks how to expose the different options (audio,
    audio and video, etc).

 src/contacts-contact-pane.vala |   14 ++++++++++++++
 1 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/src/contacts-contact-pane.vala b/src/contacts-contact-pane.vala
index 1ae8e90..bba6fa0 100644
--- a/src/contacts-contact-pane.vala
+++ b/src/contacts-contact-pane.vala
@@ -1231,6 +1231,20 @@ public class Contacts.ContactPane : EventBox {
 	      Utils.start_chat (contact, protocol, id.value);
 	    });
 	}
+
+	var callable_account = contact.is_callable (protocol, id.value);
+	if (callable_account != null) {
+	  Button? button_call = fields_layout.add_button (null);
+	  var phone_image = new Image ();
+	  phone_image.set_no_show_all (true);
+	  phone_image.set_from_icon_name ("audio-input-microphone-symbolic",
+	      IconSize.MENU);
+	  phone_image.show ();
+	  button_call.add (phone_image);
+	  button_call.clicked.connect ( () => {
+		Utils.start_call_with_account (id.value, callable_account);
+	      });
+	}
       }
     }
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]