[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: AppIcon patch revisited
From: |
Dan Pascu |
Subject: |
Re: AppIcon patch revisited |
Date: |
Sun, 11 Feb 2001 06:36:42 +0200 (EET) |
On 10 Feb, Robert J. Slover wrote:
> Richard,
>
> Would it be reasonable for the backend to relay the
> mouse events if they occur within the outer 2 pixels
> of the tile and convert anything else to a GNUStep
> event? This should give behaviour consistent with
> the X-based 'dock apps'. The only dock app I have
> that will allow an arbitrary drag is wmclock.app. All
> of the rest expect you to drag within a 2 pixel
> border.
This is not needed to be done. window maker owns the appicon tile
window, so it will receive all events in that window. All you need to
do is make your appicon smaller than 64x64 (like 56x56). this is what
almost all dockapps do. this is why at the border you can drag the icon
clicking on those pixels, because they don't belong to the dockapp, but
to wmaker itself (just thing of the dockapp being composed of 2 stacked
windows. the bottom one belongs to wmaker being the appicon tile, while
the top one to the app. if the app's icon window is smaller than 64x64,
you can actually click on the wmaker's tile directly and the event will
directly go to wmaker, and not to the app. This is why you can't drag
the app clicking on the apps icon window (the app will get the event
and no dockapp I know of relays events back to wmaker).
There are 2 types of dockapps. Ones that don't register to receive the
events in their window (like wmtime.app, or any app that only needs to
display some info, but not to get input from the user). In this case
the events are sent to the parent of that window which is wmaker, so
you can drag them around clicking anywhere on them.
The others ask the events in their icon window to be sent to them, so
they can assign events to mouse clicks or even implement small buttons
in the icon window (like mount.app). But since no dockapp I know to
date does the relaying of the event back to wmaker, wmaker will not
drag the appicon if you try to do this in the apps icon window, just on
the border pixels, where the apps icon being smaller than 64x64, it
doesn't overlap the tile of the icon, so the event goes directly to
wmaker. Of course if dockapps would have relayed the event back to
wmaker, then you could have been able to drag it anywhere you have
clicked.
I hope that makes things a little clearer.
So if the image in the appicon is not an great issue to be exactly
64x64, you can make it smaller like 56x56 or 58x58, and then wmaker will
get the clicks on border without you being required to relay the events
back.
> Also, test for the 'Alt' modifier and relay
> those mouse events...since WindowMaker expects to be
> able to drag anything with 'Alt' (or maybe it already
> keeps these events to itself, I dunno).
You don't need to do this, and you can't do anything about the Alt+Click
event, because your app will never see that event. The Alt+Click event
is directly processed by wmaker and never passed to the app.
So Alt+Click will always go to wmaker and will always let you drag the
icon around.
--
Dan
- Re: AppIcon patch revisited, (continued)
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/09
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/09
- Re: AppIcon patch revisited, Frederic Stark, 2001/02/09
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/09
- Re: AppIcon patch revisited, Frederic Stark, 2001/02/09
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/09
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/10
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/10
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/10
- Re: AppIcon patch revisited, Richard Frith-Macdonald, 2001/02/10