summaryrefslogtreecommitdiff
path: root/legacy
diff options
context:
space:
mode:
authorChristopher Michael <cpmichael1@comcast.net>2012-08-06 13:13:42 +0000
committerChristopher Michael <cpmichael1@comcast.net>2012-08-06 13:13:42 +0000
commit1699490f15e46049b05f4bfef8b996b3243b40b7 (patch)
treebcbd5119e5f6ca9434ca4aff04a11a04985b7149 /legacy
parent8123853195d5dff3e92cf87856287ed96c2c8c46 (diff)
Ecore_Wayland: Add missing __UNUSED__ to function paramateres ... Oh,
and also Fix Ticket #1242 where windows would resize in an incorrect direction. When resized an elm client application in Weston, and you grabbed the top of the window to resize it, all resizing action was occuring from the bottom of the window. Let's fix that ;) Now when you grab the top of the window and resize it, it actually does resize from the top :) SVN revision: 74933
Diffstat (limited to 'legacy')
-rw-r--r--legacy/ecore/src/lib/ecore_wayland/ecore_wl_window.c20
1 files changed, 16 insertions, 4 deletions
diff --git a/legacy/ecore/src/lib/ecore_wayland/ecore_wl_window.c b/legacy/ecore/src/lib/ecore_wayland/ecore_wl_window.c
index 3ebe4b26de..1632143f2c 100644
--- a/legacy/ecore/src/lib/ecore_wayland/ecore_wl_window.c
+++ b/legacy/ecore/src/lib/ecore_wayland/ecore_wl_window.c
@@ -8,8 +8,8 @@
8static void _ecore_wl_window_cb_ping(void *data __UNUSED__, struct wl_shell_surface *shell_surface, unsigned int serial); 8static void _ecore_wl_window_cb_ping(void *data __UNUSED__, struct wl_shell_surface *shell_surface, unsigned int serial);
9static void _ecore_wl_window_cb_configure(void *data, struct wl_shell_surface *shell_surface __UNUSED__, unsigned int edges, int w, int h); 9static void _ecore_wl_window_cb_configure(void *data, struct wl_shell_surface *shell_surface __UNUSED__, unsigned int edges, int w, int h);
10static void _ecore_wl_window_cb_popup_done(void *data, struct wl_shell_surface *shell_surface __UNUSED__); 10static void _ecore_wl_window_cb_popup_done(void *data, struct wl_shell_surface *shell_surface __UNUSED__);
11static void _ecore_wl_window_cb_surface_enter(void *data, struct wl_surface *surface, struct wl_output *output); 11static void _ecore_wl_window_cb_surface_enter(void *data, struct wl_surface *surface, struct wl_output *output __UNUSED__);
12static void _ecore_wl_window_cb_surface_leave(void *data, struct wl_surface *surface, struct wl_output *output); 12static void _ecore_wl_window_cb_surface_leave(void *data, struct wl_surface *surface, struct wl_output *output __UNUSED__);
13static void _ecore_wl_window_configure_send(Ecore_Wl_Window *win, int w, int h); 13static void _ecore_wl_window_configure_send(Ecore_Wl_Window *win, int w, int h);
14static char *_ecore_wl_window_id_str_get(unsigned int win_id); 14static char *_ecore_wl_window_id_str_get(unsigned int win_id);
15 15
@@ -270,6 +270,18 @@ ecore_wl_window_buffer_attach(Ecore_Wl_Window *win, struct wl_buffer *buffer, in
270 case ECORE_WL_WINDOW_BUFFER_TYPE_SHM: 270 case ECORE_WL_WINDOW_BUFFER_TYPE_SHM:
271 if (win->surface) 271 if (win->surface)
272 { 272 {
273 if (win->edges & 4) // resizing from the left
274 x = win->server_allocation.w - win->allocation.w;
275 else
276 x = 0;
277
278 if (win->edges & 1) // resizing from the top
279 y = win->server_allocation.h - win->allocation.h;
280 else
281 y = 0;
282
283 win->edges = 0;
284
273 /* if (buffer) */ 285 /* if (buffer) */
274 wl_surface_attach(win->surface, buffer, x, y); 286 wl_surface_attach(win->surface, buffer, x, y);
275 wl_surface_damage(win->surface, 0, 0, 287 wl_surface_damage(win->surface, 0, 0,
@@ -623,7 +635,7 @@ _ecore_wl_window_cb_popup_done(void *data, struct wl_shell_surface *shell_surfac
623} 635}
624 636
625static void 637static void
626_ecore_wl_window_cb_surface_enter(void *data, struct wl_surface *surface, struct wl_output *output) 638_ecore_wl_window_cb_surface_enter(void *data, struct wl_surface *surface, struct wl_output *output __UNUSED__)
627{ 639{
628 Ecore_Wl_Window *win; 640 Ecore_Wl_Window *win;
629 641
@@ -634,7 +646,7 @@ _ecore_wl_window_cb_surface_enter(void *data, struct wl_surface *surface, struct
634} 646}
635 647
636static void 648static void
637_ecore_wl_window_cb_surface_leave(void *data, struct wl_surface *surface, struct wl_output *output) 649_ecore_wl_window_cb_surface_leave(void *data, struct wl_surface *surface, struct wl_output *output __UNUSED__)
638{ 650{
639 Ecore_Wl_Window *win; 651 Ecore_Wl_Window *win;
640 652