Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 533160 | Differences between
and this patch

Collapse All | Expand All

(-)a/vcl/unx/generic/desktopdetect/desktopdetector.cxx (-1 / +21 lines)
Lines 272-277 static bool is_kde4_desktop( Display* pDisplay ) Link Here
272
    return false;
272
    return false;
273
}
273
}
274
274
275
static bool is_kde5_desktop( Display* pDisplay )
276
{
277
    if ( NULL != getenv( "KDE_FULL_SESSION" ) )
278
    {
279
        OUString aVer( "5" );
280
281
        const char *pVer = getenv( "KDE_SESSION_VERSION" );
282
        if ( pVer && aVer.equalsIgnoreAsciiCaseAscii( pVer ) )
283
            return true;
284
    }
285
286
    if ( KDEVersion( pDisplay ) == 5 )
287
        return true;
288
289
    return false;
290
}
291
275
extern "C"
292
extern "C"
276
{
293
{
277
294
Lines 285-290 DESKTOP_DETECTOR_PUBLIC DesktopType get_desktop_environment() Link Here
285
302
286
        if ( aOver.equalsIgnoreAsciiCase( "tde" ) )
303
        if ( aOver.equalsIgnoreAsciiCase( "tde" ) )
287
            return DESKTOP_TDE;
304
            return DESKTOP_TDE;
305
        if ( aOver.equalsIgnoreAsciiCase( "kde5" ) )
306
            return DESKTOP_KDE4;
288
        if ( aOver.equalsIgnoreAsciiCase( "kde4" ) )
307
        if ( aOver.equalsIgnoreAsciiCase( "kde4" ) )
289
            return DESKTOP_KDE4;
308
            return DESKTOP_KDE4;
290
        if ( aOver.equalsIgnoreAsciiCase( "gnome" ) )
309
        if ( aOver.equalsIgnoreAsciiCase( "gnome" ) )
Lines 371-376 DESKTOP_DETECTOR_PUBLIC DesktopType get_desktop_environment() Link Here
371
390
372
    // these guys can be slower, with X property fetches,
391
    // these guys can be slower, with X property fetches,
373
    // round-trips etc. and so are done later.
392
    // round-trips etc. and so are done later.
393
    else if ( is_kde5_desktop( pDisplay ) )
394
        ret = DESKTOP_KDE4;
374
    else if ( is_kde4_desktop( pDisplay ) )
395
    else if ( is_kde4_desktop( pDisplay ) )
375
        ret = DESKTOP_KDE4;
396
        ret = DESKTOP_KDE4;
376
    else if ( is_gnome_desktop( pDisplay ) )
397
    else if ( is_gnome_desktop( pDisplay ) )
377
- 

Return to bug 533160