On Wednesday, June 8, 2016 2:43:50 PM CEST Martin Graesslin wrote: > On Wednesday, June 8, 2016 2:04:45 PM CEST Bhavisha Dhruve wrote: > > Hello, > > > > One part of my GSoC project (Plasma mobile emulator) is to translate click > > events into touch events, for that I've already implemented touch event > > support in FakeInput interface both kwayland and kwin side as stated in my > > GSoC proposal. > > > > However I am not getting part of how and where I can translate click > > events > > into touch events in KWin? Can someone help me on this? > > As you have the fake input protocol, why would you need to translate the > clicks at all in KWin. The translation should be done by whatever > application uses the fake input protocol to inject touch events.
I just discussed a little bit with Bhushan about how the emulator should work. I think it doesn't make sense to have kwin_wayland as the "toplevel" window, we rather need to make KWin a child of the emulator window to have things like useful controls around the window. Think of e.g. the control in VirtualBox. That was kind of what I had in mind when I suggested to use the fake input protocol. The emulator window can listen for mouse events and then send them as touch events to the fake input protocol. Now on how to embed KWin into another application. It's not as difficult as it sounds and I had a neat idea in my head for some time: a declarative plugin which would allow embedding KWin. This could then look something like: KWin { id: kwin socketName: "kwin-emulator-wayland-0" anchors.fill: parent Component.onCompleted: kwin.start() } Technically the QtQuickItem needs to forward input events (which could just be done through fake input) and render what the nested KWin provides. I see two possible solutions for that: 1. another Wayland compositor 2. base it on https://phabricator.kde.org/D1231 Option 1 might be easier right now as we already have everything for that in place. If the whole thing sounds somewhat sane to you I can explain in more detail how that could work. Cheers Martin
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel