static method for get a instance of abstractwindowinterface

NOTE: WaylandWindowInterface has not been implemented
v0.6
audoban 8 years ago
parent 693b332521
commit 433f6a6352

@ -1,8 +1,11 @@
#include "abstractwindowinterface.h" #include "abstractwindowinterface.h"
#include "xwindowinterface.h"
#include <QObject> #include <QObject>
#include <QQuickWindow> #include <QQuickWindow>
#include <KWindowSystem>
namespace Latte { namespace Latte {
AbstractWindowInterface::AbstractWindowInterface(QQuickWindow *const view, QObject *parent) AbstractWindowInterface::AbstractWindowInterface(QQuickWindow *const view, QObject *parent)
@ -13,9 +16,18 @@ AbstractWindowInterface::AbstractWindowInterface(QQuickWindow *const view, QObje
AbstractWindowInterface::~AbstractWindowInterface() AbstractWindowInterface::~AbstractWindowInterface()
{ {
} }
AbstractWindowInterface *AbstractWindowInterface::getInstance(QQuickWindow * const view, QObject *parent)
{
if (KWindowSystem::isPlatformWayland()) {
//! TODO: WaylandWindowInterface
return nullptr;
}
/* if(KWindowSystem::isPlatformX11) */
return new XWindowInterface(view, parent);
}
} }

Loading…
Cancel
Save