Commit Graph

1861 Commits

Author SHA1 Message Date
Kristian Høgsberg
19ce462217 xwm: Update window title when window property change 2012-05-15 10:55:56 -04:00
Kristian Høgsberg
2a088867ab xwm: Put a title bar on it 2012-05-15 10:30:05 -04:00
Kristian Høgsberg
13e8e4717e xwm: Reparent X windows, paint a red decoration frame
It's red, and that's about it.
2012-05-15 09:28:38 -04:00
Kristian Høgsberg
c7ca355ec5 compositor: Only call weston_surface_update_transform from repaint 2012-05-14 16:18:54 -04:00
Kristian Høgsberg
c2d16000b9 compositor: Remove a few leftover screenshooter declarations 2012-05-14 15:23:57 -04:00
Scott Moreau
f7e498cb89 toytoolkit: Recalculate input region if client has modified it's size.
If a client changes it's width/height values in it's widget resize handler,
the input region will be wrong because of the assumptions toytoolkit makes
in frame_resize_handler(). So far, gears is the only client that does this.
2012-05-14 14:30:01 -04:00
Pekka Paalanen
79b5652de6 window: fix missed xkb API adaptation
Oddly enough, this failed to build on Android, but not otherwise.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-05-14 10:02:12 -04:00
Scott Moreau
7c8b116065 simple-shm: Handle ping event.
Since simple-shm does not use toytoolkit, it needs to respond to ping events so it is not deemed unresponsive.
2012-05-14 10:02:12 -04:00
Kristian Høgsberg
4c3dac9c66 clients: Remove superfluous #includes
In particular window.c and many clients were including glib.h without
using it and without the right cflags.
2012-05-11 16:40:22 -04:00
Kristian Høgsberg
bef52d1423 Update to new libxkbcommon API
We no longer depend on xproto, we use xkbcommon keycodes now. Yay!
2012-05-11 11:24:35 -04:00
Kristian Høgsberg
d174521b56 resizor: More resizing
Interacts better with interactive resizing, left/right keys now
changes window width.
2012-05-10 23:10:54 -04:00
Kristian Høgsberg
3593f81a5d simple-egl: Add option -o to make surface opaque 2012-05-10 20:40:51 -04:00
Jonas Ådahl
df211839dd clients: Add motion event trails to clickdot
Useful for testing pointer device.

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
2012-05-10 19:06:04 -04:00
Jonas Ådahl
c0ca399f22 evdev: Use wl_fixed_t for relative motions
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
2012-05-10 16:46:48 -04:00
Martin Minarik
1998b154a7 window.c: frame_button: Maximize, minimize, close, icon buttons in window frame 2012-05-10 16:19:33 -04:00
Kristian Høgsberg
80680c7b75 window.c: Just use float instead of GLfloat, remove GLES2.h include 2012-05-10 14:11:44 -04:00
Kristian Høgsberg
b71302e1db Fix a few -pedantic warnings
We're not enabling -pedantic by default, but a quick test brought up a few
issues that we should fix.
2012-05-10 14:11:44 -04:00
Kristian Høgsberg
c4621b07f6 compositor: Report refresh rates in mHz
We compute the higher resolution from the mode timing parameters.
2012-05-10 14:09:48 -04:00
Kristian Høgsberg
34829dec71 compositor: Simplify clip_pointer_motion() and make it handle dead areas
We were testing if the pointer were outside any output and doing a lot of
work to compute the bounding box of all output and then clip against that.
Just clip against previous (valid) output and don't bother with the
bounding box.
2012-05-09 22:21:27 -04:00
Jonas Ådahl
f647c5a5d5 compositor: When clipping pointer motions, don't loose precision
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
2012-05-09 22:21:27 -04:00
Kristian Høgsberg
e11bbe4cc8 compositor: Use wl_fixed_t for incoming input events
This changes notify_motion, notify_pointer_focus and notify_touch to take
wl_fixed_t types for input coordinates.
2012-05-09 12:19:04 -04:00
Kristian Høgsberg
1f37601850 compositor: Move pointer motion clipping to its own function 2012-05-09 11:43:11 -04:00
Jonas Ådahl
c39aa5afca evdev: Convert wl_fixed_t to int before using internally
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
2012-05-09 11:30:49 -04:00
Dima Ryazanov
ff1c2d7914 window: Don't crash if a cursor image failed to load.
Signed-off-by: Dima Ryazanov <dima@gmail.com>
2012-05-09 11:25:11 -04:00
Rafal Mielniczuk
87e4c9354e window: fix check of cursor image load result 2012-05-08 16:22:31 -04:00
Daniel Stone
d42f457b66 Load an XKB keymap and state in the compositor
Not used yet, but will be in future commits.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-08 16:04:24 -04:00
Daniel Stone
db095ff3c3 Link compositors to xkbcommon as well
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-08 16:04:21 -04:00
Daniel Stone
855028fec9 Add xkb_names member plus config + X11 support
Add an xkb_names member to the base compositor info which contains the
RMLVO to use when building an XKB keymap.  Add support for filling this
from the config file or from the underlying X11 server, with the usual
defaults.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-08 16:02:48 -04:00
Kristian Høgsberg
7016313778 Port Wayland clients to new xkbcommon API
A little different from Daniels initial patch.  We look up the common
modifiers at xkb init time and convert the xkb serialized modifier mask
to our own modifier bitmask.
2012-05-08 15:55:39 -04:00
Daniel Stone
103db7fb56 Convert wire input co-ordinates to fixed-point
To add greater precision when working with transformed surfaces and/or
high-resolution input devices.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-08 14:41:01 -04:00
Daniel Stone
b230a7ee58 Convert internal input co-ordinates to GLfloat
Change all client motion handlers to take GLfloat for co-ordinates,
rather than int32_t.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-08 14:40:57 -04:00
Daniel Stone
bd3489b6e1 Add fixed-point versions of weston_surface_{to, from}_global
To be used by input code, paralleling the existing integer versions.

Enlarge the surface_{to,from}_global_float input types to GLfloat to
avoid losing precision.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-08 14:40:51 -04:00
Rob Bradford
eb95d0de7e build: Tighten mtdev dependency to reflect requirement
The mtdev_new_open symbol was added in 1.1.0.
2012-05-08 10:02:32 -04:00
Tiago Vignatti
52e598cf51 shell: use own struct for transient surfaces
No functional changes; it's only opening space for modifications coming along
on the next commits.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
2012-05-07 16:54:53 -04:00
Tiago Vignatti
70e5c9cc42 shell: fix uninitialized variable warning
and shut-up valgrind:
 Conditional jump or move depends on uninitialised value(s)
    at 0xB5AFB05: shell_surface_configure (shell.c:2162)
    by 0x407B0C: surface_attach (compositor.c:1225)
    by 0x621FA13: ffi_call_unix64
    by 0x621F434: ffi_call
    by 0x4E3D3F5: wl_closure_invoke (connection.c:758)
    by 0x4E3786C: wl_client_connection_data (wayland-server.c:255)
    by 0x4E3AA19: wl_event_source_fd_dispatch (event-loop.c:78)
    by 0x4E3B533: wl_event_loop_dispatch (event-loop.c:460)
    by 0x4E38D2C: wl_display_run (wayland-server.c:907)
    by 0x40B5DD: main (compositor.c:2748)

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
2012-05-07 16:54:32 -04:00
Ander Conselvan de Oliveira
001de54ea1 window: use only one shm pool for all the cursor images
Cursor images are fairly small and having one pool for each image adds
a lot of unnecessary overhead. Instead, create one large pool and
allocated all cursor images from that.

In order to do that, however, the code that creates shm surface needed
some refactoring. This patch adds a new struct shm_pool that is used
by the cursor and also changes struct window to use it.
2012-05-07 14:44:02 -04:00
Daniel Stone
e5a0120757 Rename 'state' in axis (or ambiguous) bindings to 'value'
Since it's usually an axis value rather than a boolean, be slightly more
explicit about it.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-07 13:03:48 -04:00
Daniel Stone
5d66371743 Change button from int to uint32_t
Since you can't really have a negative button number.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-07 12:57:11 -04:00
Daniel Stone
da5b93c8d7 Change key/button grab bindings to take unsigned state
'state' here meaning 'is it up or down?', obviously.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-07 12:54:14 -04:00
Daniel Stone
7ceeb7dd43 test-client: Include poll.h to silence warning
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-07 10:59:08 -04:00
Kristian Høgsberg
8e1f77fee3 drm: Make KMS hw cursors work again 2012-05-03 11:39:35 -04:00
Ander Conselvan de Oliveira
1493d2ae1c window: use libXcursor for loading pointer images 2012-05-03 10:14:04 -04:00
Ander Conselvan de Oliveira
d51624f915 simple-egl: add option for running fullscreen 2012-05-02 10:04:31 -04:00
Ander Conselvan de Oliveira
a64b15d160 compositor-drm: alow scanning out of buffers with XRGB8888 format 2012-05-02 10:04:28 -04:00
Ander Conselvan de Oliveira
555c17ddd8 compositor-drm: refactor to avoid unnecessary allocation of KMS FBs
Currently, the drm backend will create and destroy a KMS FB for each
frame. However, the bos for a gbm surface are reused (at least with
mesa) so we can store the fb_id on it and destroy it only on the bo's
destroy callback.

To use the same path for scanning out client buffers, some refactor
was needed. Previously, the bo for the client buffer was destroyed
early so that gbm_surface_release_buffer() would not be called with
it, since at the page flip handler output->scanout_buffer can be
NULL even if the current frame is a client buffer.

This was solved by adding a drm_fb structure that holds a gbm_bo,
an fb_id, and information about the fb coming from a client buffer
or not. A drm_fb is created in such a way that it is destroyed
whenever the bo it references is destroyed. The fields current_*
and next_* in drm_output are changed into only two pointers to
drm_fb's.
2012-05-02 10:04:26 -04:00
Kristian Høgsberg
3e0fe5c0df window: Set window title and class 2012-05-02 09:47:55 -04:00
Kristian Høgsberg
e7afd919c9 shell: Handle set_title and set_class 2012-05-02 09:47:44 -04:00
Cooper Yuan
4577adce8c Use the dummy pbuffer we create to make current 2012-04-30 14:16:46 -04:00
Ander Conselvan de Oliveira
5f5f31939d compositor-drm: call EGL cleanup functions on exit 2012-04-30 10:44:18 -04:00
Kristian Høgsberg
f7e23d5c88 shell: Always configure when surface type changes
We can drop the force_configure hack.
2012-04-27 17:51:59 -04:00