This commit is contained in:
parent
56cb0d4841
commit
f4072bcb3f
2 changed files with 6 additions and 4 deletions
|
|
@ -29,7 +29,6 @@ void clipboard(MwWidget handle, void* user_data, void* call_data) {
|
|||
(void)handle;
|
||||
(void)user_data;
|
||||
|
||||
printf("got: %s\n", clipboard);
|
||||
if(clipboard != NULL) {
|
||||
MwVaApply(text, MwNtext, clipboard, NULL);
|
||||
MwForceRender(text);
|
||||
|
|
@ -52,6 +51,8 @@ int main() {
|
|||
|
||||
MwAddUserHandler(window, MwNresizeHandler, resize, NULL);
|
||||
MwAddUserHandler(window, MwNclipboardHandler, clipboard, NULL);
|
||||
MwAddUserHandler(instructions, MwNclipboardHandler, clipboard, NULL);
|
||||
MwAddUserHandler(text, MwNclipboardHandler, clipboard, NULL);
|
||||
|
||||
resize(window, NULL, NULL);
|
||||
|
||||
|
|
|
|||
|
|
@ -228,8 +228,6 @@ static void wl_clipboard_read(wl_clipboard_device_context_t* ctx) {
|
|||
arrpush(buf, 0);
|
||||
close(fds[0]);
|
||||
|
||||
printf("sending: %s\n", buf);
|
||||
|
||||
MwLLDispatch(ctx->ll, clipboard, buf);
|
||||
arrfree(buf);
|
||||
|
||||
|
|
@ -470,7 +468,10 @@ static void pointer_button(void* data, struct wl_pointer* wl_pointer, MwU32 seri
|
|||
|
||||
p.point = self->wayland.cur_mouse_pos;
|
||||
|
||||
if(self->wayland.framebuffer.surface == self->wayland.curSurface || self->wayland.backbuffer.surface == self->wayland.curSurface) {
|
||||
// p.point.x > x && p.point.x < x + self->wayland.ww && p.point.y > y && p.point.y < y + self->wayland.wh
|
||||
if(
|
||||
self->wayland.framebuffer.surface == self->wayland.curSurface ||
|
||||
self->wayland.backbuffer.surface == self->wayland.curSurface) {
|
||||
int i;
|
||||
|
||||
switch(button) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue