Commit Graph

982 Commits

Author SHA1 Message Date
Kristian Høgsberg
cab9aeaff5 multi-resource: Don't include non-existing xmalloc.h
It existed on my local disk, of course.  Just copy over xzmalloc().
2013-10-10 19:21:05 -07:00
Kristian Høgsberg
e8344e3dbc nested: Cast away warnings for differing arguments to eglQueryWaylandBufferWL 2013-10-10 16:50:18 -07:00
Kristian Høgsberg
6773394000 nested: Free client struct on launch_client error paths 2013-10-10 16:50:18 -07:00
Kristian Høgsberg
f1144dd0dc nested-client: Exit if we fail to create the nested client struct 2013-10-10 16:50:18 -07:00
Kristian Høgsberg
b24d590e8f multi-resource: Use xzmalloc() instead of malloc+memset and calloc 2013-10-10 16:50:18 -07:00
Kristian Høgsberg
d58e395bf2 tablet-shell: Avoid leaking icon or path strings from invalid launcher section 2013-10-10 16:50:18 -07:00
Kristian Høgsberg
b5c973c8c2 window.c: Free cursor theme name once we're done with it 2013-10-10 16:50:18 -07:00
Kristian Høgsberg
6a11a8ab54 Revert "Resize the shell when the mode is switched"
This breaks panel resizing as it doesn't account for output rotation.

https://bugs.freedesktop.org/show_bug.cgi?id=70249

This reverts commit a356f7b1ef.
2013-10-09 15:23:16 -07:00
Hardening
a356f7b1ef Resize the shell when the mode is switched
Resize the panel and the background when we're notified of a mode
switch.
2013-09-29 14:23:54 -07:00
Stefan Schmidt
639fd86493 clients: Include and link against math lib for new multi-resource
Linking failed with missing ceil() here. Making sure that we include
the header and add the missing -lm.

Signed-off-by: Stefan Schmidt <s.schmidt@samsung.com>
2013-09-23 10:10:48 -07:00
Emilio Pozuelo Monfort
7f951e1117 Update .gitignore 2013-09-23 10:08:03 -07:00
Kristian Høgsberg
1abe0486bb config-parser: Make weston_config_parse() tkae a file name
Take a basename of the config file to parse instead of an fd.
2013-09-21 23:05:45 -07:00
Kristian Høgsberg
b159560da2 tablet-shell: Use new weston_config instead of old config parse 2013-09-21 22:35:13 -07:00
Kristian Høgsberg
8c079ae052 window.c: Port to use weston_config instead of old parser 2013-09-21 22:26:10 -07:00
Kristian Høgsberg
9c3dee18ce terminal: Port to new weston_config parse 2013-09-21 22:23:08 -07:00
Neil Roberts
f428d25779 Add a test client to test multiple pointer/keyboard resources
This adds a hacked version of simple-shm which can create multiple
pointer and keyboard resources. The resources are created with the
command line options -p and -k. Both take an integer argument which
specifies the time in seconds after the program is started when the
resource should be created. It can also take a second time with a
colon separator to specify when the resource should be released.

For example:

 weston-multi-resource -p5 -p7 -k9 -p12:14

That would create a pointer after 5 seconds, a second pointer 2
seconds later, a keyboard 2 seconds after that, a third pointer after
a further 3 seconds and finally after 2 more seconds it would release
that final pointer resource.

This can be used along with WAYLAND_DEBUG to check that it gets the
right events for example if the pointer is created while the client's
surface already has focus and so on.
2013-09-21 20:57:46 -07:00
José Bollo
4a4704a7d0 Minor improvement of weston-terminal resizing 2013-09-13 15:42:28 -07:00
Peter Hutterer
f97a68079b clients: remove superfluous call 2013-09-13 15:12:23 -07:00
Peter Hutterer
e2a9eff77b clients: de-duplicate demo clients list 2013-09-13 15:12:14 -07:00
Kristian Høgsberg
8a20500847 terminal: Stop complaining about OSC escape code 7
This is the current working directory of the shell as an URI.  We
don't use that for anythign at the moment, but let's not complain
about it at least.
2013-09-11 11:52:56 -07:00
Kristian Høgsberg
735bda25da dnd: Support dropping as text/plain;charset=utf-8 2013-09-09 15:03:27 -07:00
Kristian Høgsberg
0749e3f470 terminal: Accept utf-8 text drop 2013-09-04 20:41:06 -07:00
Kristian Høgsberg
938f102a97 dnd: Only accept dnd with the application/x-wayland-dnd-flower mime-type
Currently, the dnd sample client accepts all mime-types and assumes they
are the custom flower mime-type.  Only accept if the offer has the right
mime-type.
2013-09-04 19:36:49 -07:00
Brian J Lovin
a8e627f4f2 keyboard: Add rudimentary touch support to keyboard.
At this time there is no way to have a key be activated when
touch_up is called, so all this patch does is activate they
key on touch_down.

Signed-off-by: Brian J Lovin <brian.j.lovin@intel.com>
2013-09-03 22:49:16 -07:00
Rob Bradford
080311879e window: Use new wl_pointer/keyboard_release request
Since we bump the version we ask for from the compositor it is also
necessary to implement the new "name" event in the seat listener.
2013-08-30 14:58:04 -07:00
Bryce W. Harrington
eec6aee490 .gitignore: Reflect recent client binary rename
Commit 77ab1721 renamed the client binaries; this change updates
.gitignore to follow this change.

Signed-off-by: Bryce Harrington <b.harrington@samsung.com>
2013-08-30 13:00:16 -07:00
Paul Winwood
b22bf57e21 window.c: Fix SIGSEGV in pointer_handle_motion
Move null pointer check and assignments before first window dereference.
2013-08-29 21:17:51 -07:00
Stanislav Vorobiov
6346e501ac subsurfaces: fix rendering problem with cairo-glesv2
when using cairo-glesv2 subsurface rendering code
implicitly calls eglMakeCurrent(dpy, NULL, NULL, ctx)
(since EGL_KHR_surfaceless_context is used), thus,
triangle_frame_callback:eglSwapBuffers returns EGL_BAD_SURFACE
error for all invocations other that the first one
2013-08-28 22:31:33 -07:00
Brian J Lovin
c4df4082c2 desktop-shell: Add support for touch unlock
Add support for unlocking on touch up using the
green button on the unlock dialog

Signed-off-by: Brian J Lovin <brian.j.lovin@intel.com>
2013-08-26 22:11:11 -07:00
Kristian Høgsberg
777874350b simple-egl: Handle missing EGL_EXT_buffer_age better
Including src/weston-egl-ext.h breaks distcheck, so lets just copy the
one EGL_EXT_buffer_age into simple-egl.c.
2013-08-26 15:30:42 -07:00
Kristian Høgsberg
c7d2c4c147 Add more missing config.h #includes
Now that we use AC_SYS_LARGEFILE, we need to pull in config.h at least
whereever we use mmap().  Fixes at least the test-suite and simple-shm
on 32 bit systems.
2013-08-26 14:59:14 -07:00
Kristian Høgsberg
0b36d9780f terminal: Include config.h instead of defining _XOPEN_SOURCE 2013-08-21 22:13:17 -07:00
Daiki Ueno
3e9df07269 autotools: Don't use wayland-scanner.m4 2013-08-20 11:15:19 -07:00
Peng Wu
cfcc111070 Fixes CJK wide character display
By jumping two columns when wide character prints,
and draw wide background under wide character.
2013-08-19 15:37:19 -07:00
Rusty Lynch
1084da506e Add touch support for wl_shell_surface_move 2013-08-16 10:56:00 -07:00
Ander Conselvan de Oliveira
d224bb9218 nested: Fix skipping frames due to texture update without a context
Calls into cairo-gles may change the current context, so it was only by
chance that sometimes we had the proper one as current and updated the
correct texture in surface_attach().

In order to fix this, calling display_acquire_window_surface() before
binding the texture for setup is necessary. However this call has the
side effect of allocating a cairo surface for the window. At flush time,
the existence of this surface will cause an eglSwapBuffers(), even
if no rendering was done to it, leading to undefined contents on the
screen. This happens when the idle redraw task runs while there is a
pending frame callback.

Workaround this by moving the texture setup from surface_attach() to the
redraw handler, so that the cairo surface is only allocated when
redering is done.
2013-08-16 10:56:00 -07:00
Kristian Høgsberg
0d5fe3a231 nested: The wl_resouce is the buffer, not the wl_resource user data 2013-08-16 10:56:00 -07:00
Kristian Høgsberg
69594ccf9c window: Use xzalloc() instead of silently failing to add output 2013-08-16 10:55:59 -07:00
Kristian Høgsberg
06b16c2a0b weston-info: Use xmalloc() in weston-info 2013-08-16 10:55:59 -07:00
Kristian Høgsberg
adcd54bc3c window: Use xzalloc() instead of failing to add input device 2013-08-16 10:55:59 -07:00
Kristian Høgsberg
1a5f0c34ff window: Fix logic for looking up widget default cursor
We may deref a NULL pointer if there is no grab and no focus widget.
2013-08-16 10:55:59 -07:00
Kristian Høgsberg
980b018825 window: Don't check for subcompositor in window_add_subsurface()
Client should check for subcompositor support up front.  Now
window_add_surface() can never return NULL.
2013-08-15 11:56:41 -07:00
Kristian Høgsberg
b20b00923a window: Add API to check for subcompositor, use in subsurface example
This way we can fail with a nice error message.
2013-08-15 11:54:03 -07:00
Kristian Høgsberg
c85a9178c7 simple-touch: Handle OOM when allocating struct touch 2013-08-15 11:40:30 -07:00
Kristian Høgsberg
96c619af43 simple-shm: Handle OOM when allocating struct display 2013-08-15 11:39:52 -07:00
Kristian Høgsberg
20ffdffc03 keyboard: Don't use next_utf8_char() to go back where we came from
We go one utf8 char back and then one forward.  Just remember the original
position instead, which also avoids a warning about potentially
dereferencing a NULL return value from next_utf8_char().
2013-08-15 11:37:14 -07:00
Kristian Høgsberg
3e125830a5 terminal: Make utf-8 state machine assemble unicode code point value 2013-08-13 17:23:54 -07:00
Kristian Høgsberg
e9cabc1bc3 nested: Use a void * to avoid warnings with EGL_WL_bind_wayland_display 2013-08-12 22:21:22 -07:00
Kristian Høgsberg
473f248d7e screenshooter: Add missing newline and use program_invocation_short_name 2013-08-12 22:15:38 -07:00
Kristian Høgsberg
bdd8377312 screenshooter: Only link to $(CLIENT_LIBS) not libtoytoolkit.la
This application doesn't use toytoolkit, so don't link to it.  We have to
add a copy of xmalloc, to link without toytoolkit.
2013-08-12 22:12:32 -07:00