Bug 26058 (add_lxde_support) - add lxde support to xdg-utils
Summary: add lxde support to xdg-utils
Status: RESOLVED FIXED
Alias: add_lxde_support
Product: Portland
Classification: Unclassified
Component: xdg-utils (show other bugs)
Version: 1.0
Hardware: Other All
: medium normal
Assignee: Fathi Boudra
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-01-15 03:04 UTC by Andrea Florio
Modified: 2010-10-28 13:54 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
lxde support patch (5.02 KB, patch)
2010-01-15 03:05 UTC, Andrea Florio
Details | Splinter Review
Improved patch. (3.90 KB, patch)
2010-10-15 17:22 UTC, vcap
Details | Splinter Review
Improved patch #2. (4.09 KB, patch)
2010-10-16 02:08 UTC, vcap
Details | Splinter Review
Improved patch #3. (4.43 KB, patch)
2010-10-16 03:39 UTC, vcap
Details | Splinter Review

Description Andrea Florio 2010-01-15 03:04:22 UTC
This patch want ot add lxde support to xdg-utils
Comment 1 Andrea Florio 2010-01-15 03:05:34 UTC
Created attachment 32655 [details] [review]
lxde support patch
Comment 2 vcap 2010-10-15 17:22:11 UTC
Created attachment 39473 [details] [review]
Improved patch.

this one is against the 'xdg-*.in' files in the cvs.
Comment 3 vcap 2010-10-15 18:08:04 UTC
(In reply to comment #2)
> Created an attachment (id=39473) [details]
> Improved patch.
> 
> this one is against the 'xdg-*.in' files in the cvs.

Also, it adds support for pcmanfm in xdg-open, which was actually my main motivation.
Comment 4 vcap 2010-10-16 02:08:42 UTC
Created attachment 39477 [details] [review]
Improved patch #2.

Like the above except it now handles relative filepaths in the xdg-open/lxde case.
So, now it does pass the full test suite...

Well... ok, it fails in the xdg-email tests but since i still use the generic handler, the breakage is none of my doing (in my case it calls firefox, which calls sylpheed, but it fails to open a compose window). Ideally, i should use the preferred email client as configured in lxde but i don't know how to get that info without grepping config files which does not seem like a good idea (better would be a lxde command that output that info on stdout and is guaranteed to be future-proof).
Comment 5 Andrea Florio 2010-10-16 02:29:58 UTC
(In reply to comment #4)
> Created an attachment (id=39477) [details]
> Improved patch #2.
> 
> Like the above except it now handles relative filepaths in the xdg-open/lxde
> case.
> So, now it does pass the full test suite...
> 
> Well... ok, it fails in the xdg-email tests but since i still use the generic
> handler, the breakage is none of my doing (in my case it calls firefox, which
> calls sylpheed, but it fails to open a compose window). Ideally, i should use
> the preferred email client as configured in lxde but i don't know how to get
> that info without grepping config files which does not seem like a good idea
> (better would be a lxde command that output that info on stdout and is
> guaranteed to be future-proof).


souldn't we consider lxterminal as lxde terminal?

if lxterminal is not found, open generic terminal.

in the same way.. isn't my "su" approach beeter than your?

+su_lxde()
+{
+    if which gnomesu &>/dev/null ; then
+        su_gnome
+    else
+        su_generic
+    fi
+}
Comment 6 vcap 2010-10-16 03:39:06 UTC
Created attachment 39478 [details] [review]
Improved patch #3.

Now use lxterminal as the default terminal in xdg-terminal; if lxterminal is not available, fallback to terminal_generic. (ideally it should use whatever preferred term emulator has been configured in pcmanfm, but see my note about xdg-email above).

About xdg_su: as discussed with Andrea on irc; su_gnome now does proper error handling and fallback (if not gnomesu then xsu; if not xsu then su_generic) so it is safe to use directly.
Comment 7 Rex Dieter 2010-10-28 13:50:02 UTC
Thanks, patch looks good, I'll incorporate it asap.
Comment 8 Rex Dieter 2010-10-28 13:54:47 UTC
patch commited to cvs, thanks!


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.