[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kwin
Subject:    [RFC] KWin deco API version enforcement
From:       Thomas_Lübking <thomas.luebking () gmail ! com>
Date:       2012-08-06 15:37:17
Message-ID: op.wimlofyf9bmiid () localhost ! localdomain
[Download RAW message or body]

Hi everyone.

Because of the disaster that is bug #301646 [1] I suggest to omit further  
experiments
on what might break the binary compatibility there and propose to enforce  
an exported
API version for 4.9.1 (aka "Broadsword solution" (tm))

This would have become mandatory sooner or later anyway and just scheduled  
to cover the
transition time - what did not work (see bug #301646)

Deco plugins will then be required to export the version with a "C"  
namespace like this:

// --- snip ---------------------

#include <kdecoration.h>

#ifndef KWIN_DECORATION_API_VERSION
// define invalid KWIN_DECORATION_API_VERSION to support old headers
#define KWIN_DECORATION_API_VERSION 0
#endif

extern "C"
{
     // old common factory creation export - your deco has this
     KDE_EXPORT KDecorationFactory* create_factory() { return new  
Factory(); }
     // new ADDITIONAL version export
     KDE_EXPORT int decoration_version() { return  
KWIN_DECORATION_API_VERSION; }
}

// --- /snip ---------------------


Sorry for the trouble anyone,
Thomas

[1] https://bugs.kde.org/show_bug.cgi?id=301646
_______________________________________________
kwin mailing list
kwin@kde.org
https://mail.kde.org/mailman/listinfo/kwin
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic