Prefer to use object members directly instead of accessors.
authorTravis Reitter <travis.reitter@collabora.co.uk>
Tue, 28 Sep 2010 23:23:32 +0000 (16:23 -0700)
committerTravis Reitter <travis.reitter@collabora.co.uk>
Tue, 28 Sep 2010 23:23:43 +0000 (16:23 -0700)
Patch by Patryk Zawadzki.

backends/telepathy/lib/tpf-persona-store.vala
backends/telepathy/lib/tpf-persona.vala

index c03f1d1..7aa0795 100644 (file)
@@ -393,7 +393,7 @@ public class Tpf.PersonaStore : Folks.PersonaStore
       else if (new_status != TelepathyGLib.ConnectionStatus.CONNECTED)
         return;
 
-      var conn = this.account.get_connection ();
+      var conn = this.account.connection;
       conn.notify["connection-ready"].connect (this.connection_ready_cb);
 
       /* Deal with the case where the connection is already ready
@@ -921,7 +921,7 @@ public class Tpf.PersonaStore : Folks.PersonaStore
         {
           /* the changes queued above will be resolve in the NewChannels handler
            */
-          this.ll.connection_create_group_async (this.account.get_connection (),
+          this.ll.connection_create_group_async (this.account.connection,
               group);
         }
       else
index 8e9fa03..994af54 100644 (file)
@@ -213,7 +213,7 @@ public class Tpf.Persona : Folks.Persona,
         throw new Tpf.PersonaError.INVALID_ARGUMENT ("contact has an " +
             "invalid ID");
 
-      unowned Connection connection = contact.get_connection ();
+      unowned Connection connection = contact.connection;
       var account = account_for_connection (connection);
       string uid = this.build_uid ("telepathy", account.get_protocol (), id);
 
@@ -304,7 +304,7 @@ public class Tpf.Persona : Folks.Persona,
       accounts.foreach ((l) =>
         {
           unowned Account account = (Account) l;
-          if (account.get_connection () == conn)
+          if (account.connection == conn)
             {
               account_found = account;
               return;
@@ -355,7 +355,7 @@ public class Tpf.Persona : Folks.Persona,
 
   private void contact_notify_avatar ()
     {
-      var file = this.contact.get_avatar_file ();
+      var file = this.contact.avatar_file;
       if (this.avatar != file)
         this.avatar = file;
     }