From: Christophe CURIS <christophe.cu...@free.fr>

The x coordinate is not needed by the function because menu are a vertical
stacking on items, which means only y coordinate matters.

This patch removes the x parameter to fix a compilation warning.

Signed-off-by: Christophe CURIS <christophe.cu...@free.fr>
---
 WPrefs.app/editmenu.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/WPrefs.app/editmenu.c b/WPrefs.app/editmenu.c
index da71db4..f562209 100644
--- a/WPrefs.app/editmenu.c
+++ b/WPrefs.app/editmenu.c
@@ -1001,7 +1001,7 @@ static WEditMenu *findMenuInWindow(Display * dpy, Window 
toplevel, int x, int y)
        return NULL;
 }
 
-static void handleDragOver(WEditMenu * menu, WMView * view, WEditMenuItem * 
item, int x, int y)
+static void handleDragOver(WEditMenu *menu, WMView *view, WEditMenuItem *item, 
int y)
 {
        WMScreen *scr = W_VIEW_SCREEN(menu->view);
        Window blaw;
@@ -1019,7 +1019,7 @@ static void handleDragOver(WEditMenu * menu, WMView * 
view, WEditMenuItem * item
        }
 }
 
-static void handleItemDrop(WEditMenu * menu, WEditMenuItem * item, int x, int 
y)
+static void handleItemDrop(WEditMenu *menu, WEditMenuItem *item, int y)
 {
        WMScreen *scr = W_VIEW_SCREEN(menu->view);
        Window blaw;
@@ -1225,7 +1225,7 @@ static void dragItem(WEditMenu * menu, WEditMenuItem * 
item, Bool copy)
                        dmenu = findMenuInWindow(dpy, win, x, y);
 
                        if (dmenu) {
-                               handleDragOver(dmenu, dview, dritem, x - dx, y 
- dy);
+                               handleDragOver(dmenu, dview, dritem, y - dy);
                                if (!enteredMenu) {
                                        enteredMenu = True;
                                        XRecolorCursor(dpy, scr->defaultCursor, 
&green, &back);
@@ -1271,7 +1271,7 @@ static void dragItem(WEditMenu * menu, WEditMenuItem * 
item, Bool copy)
 
                        if (!menu->flags.isFactory && !copy) {
                                WRemoveEditMenuItem(menu, dritem);
-                               handleItemDrop(dmenu ? dmenu : menu, dritem, 
orix, oriy);
+                               handleItemDrop(dmenu ? dmenu : menu, dritem, 
oriy);
                        }
                } else {
                        WRemoveEditMenuItem(menu, dritem);
@@ -1283,7 +1283,7 @@ static void dragItem(WEditMenu * menu, WEditMenuItem * 
item, Bool copy)
                        (*menu->delegate->itemCloned) (menu->delegate, menu, 
item, dritem);
                }
 
-               handleItemDrop(dmenu, dritem, x - dy, y - dy);
+               handleItemDrop(dmenu, dritem, y - dy);
 
                if (item->submenu && (menu->flags.isFactory || copy)) {
                        WEditMenu *submenu;
-- 
1.8.4.rc3


-- 
To unsubscribe, send mail to wmaker-dev-unsubscr...@lists.windowmaker.org.

Reply via email to