Support Application Indicators

Bug #497870 reported by Jorge Castro
20
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gnome-power
In Progress
Wishlist
gnome-media (Ubuntu)
Invalid
Medium
Unassigned
gnome-power-manager (Ubuntu)
Fix Released
Medium
Ken VanDine

Bug Description

This application should be investigated to be ported to use Application
Indicators for Lucid - https://edge.launchpad.net/indicator-application

 affects ubuntu/gnome-media
 affects ubuntu/gnome-power-manager

 assignee canonical-dx-team
 tag indicator-application

Changed in gnome-power-manager (Ubuntu):
importance: Undecided → Wishlist
status: New → Triaged
Changed in gnome-media (Ubuntu):
assignee: nobody → Canonical Desktop Experience Team (canonical-dx-team)
status: New → Triaged
importance: Undecided → Wishlist
David Barth (dbarth)
Changed in gnome-media (Ubuntu):
assignee: Canonical Desktop Experience Team (canonical-dx-team) → Conor Curran (cjcurran)
importance: Wishlist → Medium
milestone: none → lucid-alpha-3
Changed in gnome-power-manager (Ubuntu):
assignee: Canonical Desktop Experience Team (canonical-dx-team) → Ted Gould (ted)
importance: Wishlist → Medium
milestone: none → lucid-alpha-3
Changed in gnome-power-manager (Ubuntu):
assignee: Ted Gould (ted) → Jan Arne Petersen (jpetersen)
status: Triaged → In Progress
Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

Patch against upstream git.

Changed in gnome-media (Ubuntu):
assignee: Conor Curran (cjcurran) → Jan Arne Petersen (jpetersen)
status: Triaged → In Progress
Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

The gnome-media part is bug 519345 now

Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

This patch uses an AppIndicator instead of the GtkStatusIcon.

There is a second GtkStatusIcon only shown when the display server is broken (blanking problem). I cannot replace it with an AppIndicator because currently only one AppIndicator is supported per application. So that will require some additional thoughts.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Personally, I would just get rid of the status icon that indicates a blanking problem. It seems to appear when there isn't really an issue (eg, if gpm is not on the active console) If there is a real issue with display blanking, users will notice it anyway and report a bug. The message is misleading and not applicable in Ubuntu, as we carry the patches referred to in the linked blog anyway

Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

Yes, that is my proposed solution also. I will attach a separate patch for that issue so that it is easier to get the main application indicator patch upstream.

Revision history for this message
Jan Arne Petersen (jpetersen) wrote :
Changed in gnome-power-manager (Ubuntu):
status: In Progress → Fix Committed
assignee: Jan Arne Petersen (jpetersen) → Ken VanDine (ken-vandine)
Revision history for this message
Ken VanDine (ken-vandine) wrote :

I just update the wiki page with a better example of the autotools bits needed. Specifically to allow developers/packages to disable appindicator support even if they have it installed.

https://wiki.ubuntu.com/DesktopExperienceTeam/ApplicationIndicators#Automake fu

Revision history for this message
Ken VanDine (ken-vandine) wrote :

I think the patch looks good, just modify the autotools bits like i posted on the wiki.

There is a problem with the icon, which we think needs to be fixed in the theme. The battery icon is scaled down to much, can you please file a bug against the humanity icon theme for that? Unless you have other ideas why it is too small.

tags: added: patch
Revision history for this message
Jan Arne Petersen (jpetersen) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gnome-power-manager - 2.29.2-0ubuntu4

---------------
gnome-power-manager (2.29.2-0ubuntu4) lucid; urgency=low

  * debian/patches/12-add-appindicators.patch
    - Adds support for application indicators (LP: #497870)
  * debian/rules
    - Enable appindicator
 -- Ken VanDine <email address hidden> Tue, 16 Feb 2010 21:11:43 -0500

Changed in gnome-power-manager (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

This g-p-m patch now causes a crash at startup, bug 523041.

Revision history for this message
Martin Pitt (pitti) wrote :

This patch should be written more robustly. It initializes icon->priv->app_indicator = app_indicator_new() without ever checking for success, or NULL, and all the new code which accesses this does not do anything like g_assert() or g_return_if_fail() if the indicator is NULL. It should just fall back to the current upstream behaviour (showing its own tray icon) if initializing the indicator fails.

It causes g-p-m to crash on startup (see bug 523041), thus I'm backing out this patch for now.

Changed in gnome-power-manager (Ubuntu):
status: Fix Released → Triaged
Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

app_indicator_new() never fails, so it does not make sense to check it.

Revision history for this message
Ken VanDine (ken-vandine) wrote :

It would fail if the indicator-applet isn't loaded and indicator-application-service isn't running.

Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

app_indicator_new() just calls g_object_new and there is no special constructor set in AppIndicator, so it will only fails in OOM condition which we usually do not check for. Sure there is a bug somewhere in indicator-application, but it does not make sense to check for something which is always valid and will not prevent that bug from happen.

From the stacktrace it is obvious that the AppIndicator instance is not NULL:

dbus_g_connection_register_g_object (connection=0x8438d0c,
check_connect (self=0x840e000)
app_indicator_set_menu (self=0x840e000, menu=0x845caf0)

affects: gnome-media → gnome-power
Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

The crash is fixed in indicator-application trunk. So the patch should work as soon as indicator-application package is updated.

Revision history for this message
Jan Arne Petersen (jpetersen) wrote :

Can we please reapply the patch to gnome-power-manager. The bug in application-indicator is fixed now. Thanks

Revision history for this message
Martin Pitt (pitti) wrote :

Closing gnome-media task as per comment 2 (and obsolete)

Changed in gnome-media (Ubuntu):
assignee: Jan Arne Petersen (jpetersen) → nobody
milestone: lucid-alpha-3 → none
status: In Progress → Invalid
Revision history for this message
Martin Pitt (pitti) wrote :

Re-enabled in bzr, will upload once Seb uploads fixed i-a.

Changed in gnome-power-manager (Ubuntu):
status: Triaged → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gnome-power-manager - 2.29.2-0ubuntu7

---------------
gnome-power-manager (2.29.2-0ubuntu7) lucid; urgency=low

  * Re-enable appindicator, indicator-application was fixed. (LP: #497870)
 -- Martin Pitt <email address hidden> Mon, 22 Feb 2010 17:48:14 +0100

Changed in gnome-power-manager (Ubuntu):
status: Fix Committed → Fix Released
Changed in gnome-power:
status: Unknown → New
Changed in gnome-power:
status: New → In Progress
Changed in gnome-power:
importance: Unknown → Wishlist
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.