After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 683377 - AutorunManager: fix regression from the components rewrite
AutorunManager: fix regression from the components rewrite
Status: RESOLVED FIXED
Product: gnome-shell
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2012-09-05 00:27 UTC by Giovanni Campagna
Modified: 2012-09-05 15:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
AutorunManager: fix regression from the components rewrite (2.07 KB, patch)
2012-09-05 00:27 UTC, Giovanni Campagna
none Details | Review
AutorunManager: fix regression from the components rewrite (3.28 KB, patch)
2012-09-05 14:23 UTC, Giovanni Campagna
committed Details | Review

Description Giovanni Campagna 2012-09-05 00:27:30 UTC
Message tray sources cannot be reused after destruction. Reinstate
the code that created a new source when the previous one was destroyed.
Comment 1 Giovanni Campagna 2012-09-05 00:27:33 UTC
Created attachment 223486 [details] [review]
AutorunManager: fix regression from the components rewrite
Comment 2 Jasper St. Pierre (not reading bugmail) 2012-09-05 00:40:29 UTC
Review of attachment 223486 [details] [review]:

How would the source be destroyed? I never liked this hack in the first place.
Comment 3 Giovanni Campagna 2012-09-05 10:39:54 UTC
(In reply to comment #2)
> Review of attachment 223486 [details] [review]:
> 
> How would the source be destroyed? I never liked this hack in the first place.

The source is destroyed because the notification is destroyed. The notification is destroyed when the last mount is removed.
If you don't destroy the notification, you get an empty list of mounts.
If you don't destroy the source, you get an icon with no notification.
Comment 4 Jasper St. Pierre (not reading bugmail) 2012-09-05 13:07:27 UTC
(In reply to comment #3)
> (In reply to comment #2)
> > Review of attachment 223486 [details] [review] [details]:
> > 
> > How would the source be destroyed? I never liked this hack in the first place.
> 
> The source is destroyed because the notification is destroyed. The notification
> is destroyed when the last mount is removed.
> If you don't destroy the notification, you get an empty list of mounts.
> If you don't destroy the source, you get an icon with no notification.

This is correct, right? So what we want is not to recreate the source when destroyed, but ensure that we create a new one if we're going from 0 mounts to 1 mount.
Comment 5 Giovanni Campagna 2012-09-05 14:23:25 UTC
Created attachment 223545 [details] [review]
AutorunManager: fix regression from the components rewrite

Message tray sources cannot be reused after destruction, so connect
to 'destroy' signal and clear out the previous one.
Also, fix some code paths that used the autorun manager incorrectly.

Need moar regressions, moar regressions!
Comment 6 Jasper St. Pierre (not reading bugmail) 2012-09-05 14:28:21 UTC
Review of attachment 223545 [details] [review]:

Yes.
Comment 7 Giovanni Campagna 2012-09-05 15:03:51 UTC
Attachment 223545 [details] pushed as 09c81f7 - AutorunManager: fix regression from the components rewrite