Add MATE support

Bug #1462186 reported by Jorge Pizarro-Callejas
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Caffeine
Fix Released
Undecided
Unassigned
mate-screensaver (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Hi!

Caffeine, by default, doesn't support MATE screensaver, so I created this patch to solve this. Hope it helps.

Thank you.

Revision history for this message
Jorge Pizarro-Callejas (jorgicio) wrote :
Revision history for this message
Reuben Thomas (rrt) wrote :

Thanks, but I'll fix this by using the next xdg-utils xdg-screensaver instead. I'll leave this bug open until that has been done.

Revision history for this message
Jorge Pizarro-Callejas (jorgicio) wrote :

Well, thanks, but I tried with xdg-utils and I couldn't find a way to that.
Also, I created an improved patch for MATE. I applied it and it works.

Revision history for this message
Reuben Thomas (rrt) wrote :

Support for xdg-utils now committed.

If caffeine does not now work in your DE, you should start by testing xdg-screensaver; if that doesn't work, file a bug against xdg-utils. Only if xdg-screensaver works, but not caffeine, file a bug against caffeine.

Changed in caffeine:
status: New → Fix Committed
Revision history for this message
Reuben Thomas (rrt) wrote :

(The fix will be released with Caffeine 2.9.0.)

Reuben Thomas (rrt)
Changed in caffeine:
status: Fix Committed → Fix Released
Revision history for this message
Bob Lawrence (pilotbob42) wrote :

@jorgicio, thanks for the patch as this still does not work even with Ubuntu Mate 18.04.1 LTS and Caffeine 2.9.4. I reverted to 2.8.3 and locked it, applied your patch and everything is working great now.

Revision history for this message
Reuben Thomas (rrt) wrote :

@pilotbob42 if you could test Ubuntu 18.04.1's xdg-screensaver under MATE, and report a bug against xdg-utils if it doesn't work, that would be great. I'm sorry that Caffeine 2.9.4 doesn't work for you, but it's no longer under Caffeine's control (conversely, fixing xdg-screensaver for MATE fixes it for everyone, not just Caffeine users!).

Revision history for this message
Bob Lawrence (pilotbob42) wrote :

@rrt, thanks, but I'm sure that scenario would work just fine and then they would refer me to report a bug against mate-screensaver who would then just suggest that I use the mate inhibit panel applet instead. Which works fine, but is not an indicator like yours and is essentially unthemeable (it sticks out like a sore thumb with my theme).

jorgicio's patch for 2.8.3 does exactly what I need it to so my issue is resolved. I'll leave y'all to do with that info what you will (I totally get why you're going the xdg-utils route moving forward).

Revision history for this message
Reuben Thomas (rrt) wrote :

@pilotbob42, if xdg-screensaver works, then the bug is in Caffeine, and you can report a bug against Caffeine. mate-screensaver is not involved.

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Add support for MATE in caffeine-screensaver" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Revision history for this message
Bob Lawrence (pilotbob42) wrote :

@rrt, looking back at my last reply, I mistyped. What I meant to say is that I'm sure it would not work (xdg-screensaver being used to inhibit mate-screensaver because mate-screensaver does not support the xdg spec). This is a known issue going back to 2014. One could argue that the xdg team should accept it as a bug to support mate better or one could say that mate should accept it as a bug to support the xdg spec correctly. In either case, both teams seem happy with where they are at and neither seem willing to move forward on this.

And now that I have 2.8.3 with jorgicio's patch (which works exactly like you would expect under mate), I'm happy with what I have too. Someone else can fight the good fight on getting these two teams to figure out why it's not working.

Revision history for this message
Jorge Pizarro-Callejas (jorgicio) wrote :

Hi! I can't believe this is still a topic at the time.

I submitted this patch 3 years ago, so it's obvious may not work in recent versions of MATE. I used caffeine for some time and with recent versions of MATE, this patch is not needed anymore.

Anyways, I stopped using caffeine and using its fork, caffeine-ng. Both work as expected with recent versions of MATE.

I'm glad that patch I submitted worked at its time.

Thanks.

Revision history for this message
Reuben Thomas (rrt) wrote :

@pilotbob42, thanks for the explanation, that makes more sense.

However, xdg-utils has explicit support for MATE, so if it's broken, it's a bug and should be fixed. (xdg-screensaver has ad hoc support for a wide range of desktop environments; there is no requirement to support a particular mechanism).

Comments in xdg-screensaver say:

# DBUS interface for mate-screensaver
# This is same as gnome's for now but may change in the future as MATE
# does not follow gnome's developement necessarily.

If this therefore is no longer the case, then the code needs updating; simple as that!

Revision history for this message
Bob Lawrence (pilotbob42) wrote :

@jorgicio, at least on Ubunutu Mate 18.04.1 LTS (which uses Mate 1.20 and XDG-Utils 1.1.2) I think you'll find (as I have) that Caffeine 2.9.4 can inhibit power management correctly, but not the screen saver (mate-screensaver). As Thomas correctly points out, this is not Caffeine's fault as it relies on the abstraction provided by XDG-Utils to do the work and there seems to be a disconnect somewhere between xdg-screensaver and mate-screensaver. In fact, any full screen app that attempts to suspend the screensaver via XDG-Utils seems unable to do so in Ubuntu Mate.

I found this thread that spans 2014 to 2017 that got at least part of the way there, but it doesn't seem like anyone ever finished it up.

http://github.com/mate-desktop/mate-screensaver/issues/57

But, the good news is that your (jorgicio's) patch for Caffeine 2.8.3 does in fact still work correctly even on the latest Ubuntu Mate 18.04.1 LTS as I've applied it myself and it works just fine. So thank you for that. :-)

And thank you too, Thomas, as Caffeine did help me solve my problem as well (even if it is an older version).

Revision history for this message
Reuben Thomas (rrt) wrote :

@pilotbob42, thanks for the extra material. From looking at the patch and MATE thread it seems the main difference is that MATE uses a different DBus path for its screen saver; unfortunately, this is already taken account of in the current xdg-screensaver, so the actual problem must be some other detail that is different.

However, it does mean that it should be easy to fix.

Changed in mate-screensaver (Ubuntu):
status: New → Invalid
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.