]> Dogcows Code - chaz/tint2/blobdiff - src/panel.c
*fix* issue 282
[chaz/tint2] / src / panel.c
index ee531677805e381d5ba39fa9299630ca1c1e7d4b..61b4b2025a01a36be364a4abf90b257d79653b7c 100644 (file)
@@ -510,7 +510,7 @@ void set_panel_properties(Panel *p)
        XChangeProperty(server.dsp, p->main_win, server.atom._MOTIF_WM_HINTS, server.atom._MOTIF_WM_HINTS, 32, PropModeReplace, (unsigned char *) prop, 5);
 
        // XdndAware - Register for Xdnd events
-       long version=5;
+       Atom version=4;
        XChangeProperty(server.dsp, p->main_win, server.atom.XdndAware, XA_ATOM, 32, PropModeReplace, (unsigned char*)&version, 1);
 
        update_strut(p);
@@ -688,8 +688,8 @@ LauncherIcon *click_launcher_icon (Panel *panel, int x, int y)
                LauncherIcon *icon;
                for (l0 = launcher->list_icons; l0 ; l0 = l0->next) {
                        icon = l0->data;
-                       if (x >= (launcher->area.posx + icon->x) && x <= (launcher->area.posx + icon->x + icon->width) &&
-                               y >= (launcher->area.posy + icon->y) && y <= (launcher->area.posy + icon->y + icon->height)) {
+                       if (x >= (launcher->area.posx + icon->x) && x <= (launcher->area.posx + icon->x + icon->icon_size) &&
+                               y >= (launcher->area.posy + icon->y) && y <= (launcher->area.posy + icon->y + icon->icon_size)) {
                                //printf("Hit rect x=%d y=%d xmax=%d ymax=%d\n", launcher->area.posx + icon->x, launcher->area.posy + icon->y, launcher->area.posx + icon->x + icon->width, launcher->area.posy + icon->y + icon->height);
                                return icon;
                        }
This page took 0.020718 seconds and 4 git commands to generate.