[gnome-maps/wip/contacts: 77/81] placeBubble: Do not add favorite button for contacts



commit bf5721cb411b2823c5e8527881f7c79e32f41ba9
Author: Jonas Danielsson <jonas threetimestwo org>
Date:   Mon Jan 12 06:52:33 2015 -0500

    placeBubble: Do not add favorite button for contacts
    
    https://bugzilla.gnome.org/show_bug.cgi?id=741591

 src/placeBubble.js |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/src/placeBubble.js b/src/placeBubble.js
index 1b8eb6e..6bcc26f 100644
--- a/src/placeBubble.js
+++ b/src/placeBubble.js
@@ -26,6 +26,7 @@ const Format = imports.format;
 const Lang = imports.lang;
 
 const Application = imports.application;
+const ContactPlace = imports.contactPlace;
 const MapBubble = imports.mapBubble;
 const Overpass = imports.overpass;
 const Place = imports.place;
@@ -42,8 +43,10 @@ const PlaceBubble = new Lang.Class({
                                                      'box-content',
                                                      'label-title']);
         params.buttons = (MapBubble.Button.ROUTE |
-                          MapBubble.Button.SHARE |
-                          MapBubble.Button.FAVORITE);
+                          MapBubble.Button.SHARE);
+
+        if (!params.place instanceof ContactPlace.ContactPlace)
+            params.buttons |= MapBubble.Button.FAVORITE;
 
         this.parent(params);
 


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