← Back to team overview

ayatana-commits team mailing list archive

[Merge] lp:~ken-vandine/indicator-me/lp_655252 into lp:indicator-me

 

Ken VanDine has proposed merging lp:~ken-vandine/indicator-me/lp_655252 into lp:indicator-me.

Requested reviews:
  Indicator Applet Developers (indicator-applet-developers)
Related bugs:
  Bug #655252 in The Me Menu: "Text Hint ("Post to..") not always hidden when the broadcast field is in use"
  https://bugs.launchpad.net/indicator-me/+bug/655252

For more details, see:
https://code.launchpad.net/~ken-vandine/indicator-me/lp_655252/+merge/52893

properly clear the text entry when selected (LP: #655252)

-- 
https://code.launchpad.net/~ken-vandine/indicator-me/lp_655252/+merge/52893
Your team ayatana-commits is subscribed to branch lp:indicator-me.
=== modified file 'src/indicator-me.c'
--- src/indicator-me.c	2011-03-02 19:22:20 +0000
+++ src/indicator-me.c	2011-03-10 18:01:38 +0000
@@ -546,12 +546,14 @@
 
   g_debug ("%s", __func__);
 
-  if (! entry_hint_is_shown (GTK_WIDGET (entry)))
-    if (gtk_entry_get_text_length (entry) == 0)
+  if (! entry_hint_is_shown (GTK_WIDGET (entry))) {
+    if (gtk_entry_get_text_length (entry) == 0) {
       /* show the hint unconditionnaly, as the focus change
          may not have propagated already and entry_maybe_show_hint
          could get confused */
       entry_hint_show_hint (entry);
+    }
+  }
 
   return FALSE;
 }
@@ -568,8 +570,7 @@
 	}
 	if (g_strcmp0 (prop, DBUSMENU_ENTRY_MENUITEM_PROP_HINT) == 0) {
     entry_set_hint (entry, g_variant_get_string (value, NULL));
-    if (entry_hint_is_shown (GTK_WIDGET (entry)))
-        entry_maybe_show_hint (entry); /* visual update */
+        entry_hint_show_hint (entry); /* visual update */
 	}
 }
 
@@ -605,7 +606,7 @@
 	}
 
   g_object_set_data (G_OBJECT (ido),
-                     "dbusmenitem",
+                     "dbusmenuitem",
                      newitem);
 
 	gtk_entry_set_width_chars (entry, 23); /* set some nice aspect ratio for the menu */

=== modified file 'src/me-service.c'
--- src/me-service.c	2011-03-02 21:07:10 +0000
+++ src/me-service.c	2011-03-10 18:01:38 +0000
@@ -191,10 +191,11 @@
     return;
   }
 
-  if (! dbusmenu_menuitem_property_get_bool (broadcast_field, DBUSMENU_MENUITEM_PROP_VISIBLE))
+  dbusmenu_menuitem_property_set (broadcast_field, DBUSMENU_ENTRY_MENUITEM_PROP_HINT, me_gwibber_service_get_accounts_string (instance));
+
+  if (! dbusmenu_menuitem_property_get_bool (broadcast_field, DBUSMENU_MENUITEM_PROP_VISIBLE)) {
     dbusmenu_menuitem_property_set_bool (broadcast_field, DBUSMENU_MENUITEM_PROP_VISIBLE, TRUE);
-
-  dbusmenu_menuitem_property_set (broadcast_field, DBUSMENU_ENTRY_MENUITEM_PROP_HINT, me_gwibber_service_get_accounts_string (instance));
+  }
 
   return;
 }


Follow ups