Subject: FVWM: Action(mouseX)

From: Adam Kopacz <[email-masked]>
Date: Fri, 25 Jul 1997 16:17:06 +0200

Hi,

thanx. it works :) but i have a little problem:

(2x1, Icon mini-exp.xpm, Title(Side) Menue, Action(mouse1) 'PopUp
Main-Menu', Action(mouse2) Nop, Action(mouse3) 'WindowList')

when i click my 'menu' with the left button then i see it and i don't
need to take my finge raway from the left mpouse button :)
but when i click with the 3th button that i need to 'unklick' (sorry my
bad englisch) to see the window list.. i see the same when i make a
funktion that open a menu and start it from fvwmbuttons.. 

-- 

Bye,                        klospatz's Linux-Place (Babes/Files)
    Adam Kopacz (klospatz)       http://www.rat.de/Adam

--
Visit the official FVWM web page at <URL:http://www.hpc.uh.edu/fvwm/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Cristian Tibirna <[email-masked]>
Date: Fri, 25 Jul 1997 13:20:49 -0400

> funktion that open a menu and start it from fvwmbuttons.. 

Hi

For menus the response is simple (? :-) read away the *simple* thing for 5 minutes):

Version 1.
PopUp SomeMenu

is a fvwm valid action which, if linked to a mouse button, occurs on
the MouseButtonXDown event. The menu will be deleted  at the consecutive
MouseButtonXUp event ONLY if this last event occurs with the mouse
pointer out of the menu. If not, another click/unclick is needed for
the menu to disappear. With other words:

click: the menu pops up
consecutive unclick: the menu stays there
click anywhere, even on the menu: nothing happens, the menu is still
there
consecutive unclick, even on the menu: the menu goes away

CONTRARY:

click: the menu appears
drag the mouse out of the menu: the menu stays there
consecutive unclick out of the menu: the menu goes away 

Version 2.
Menu SomeMenu

is another fvwm valid action which, if bound to a mouse button,
occurs on the  MouseButtonXUp event, and only an operation on the by
now onscreen-present menu or another MouseButtonXUp event will delete
it.

For the WindowList, I can observe that, when simply bound to the
Mouse 3 on the root window (the default config found in
system.fvwm2rc), it acts like if a PopUp would have been implemented
for this built-in menu.

But when bound to a button from the fvwmbuttons bar, it acts like if a
Menu would have been called. I suspect (I didn't read the code in
FvwmButtons) that Action command verifies if the next thing is a PopUp
command, and gives the control at the MouseButtonXDown if yes. If not,
it waits for the mouse button to be released, and after that it
executes whatever is given.

This is another sign of inconsequence in the code of FvwmButtons,
which is, for me, the first candidate to a complete rewrite. I was
hoping, for a year, by now, to find the time to do it. No chance :-]

As a conclusion, for the moment, Adam, you're lost. Nothing to do
(with the actual version, I mean without a fatty patch) for solving
your problem. Call simply the WindowList from anyway but not from
fvwmbuttons or menus (and there's not so much left :-).

In this specific situation, I think an organized way of doing would be
to have FvwmButtons rewritten to accept:

Action(Mouse <number> <event>)

where:
<number> would be 1 to how many buttons you have (much means better)
<action> would be: In, Out (have anybody missed the ubiquous yellow
				hints? )
		   Down, Up (obvious)
		   DoubleClick, TripleClick (also)
		   DragIn, Drag Out ( :-) reserved for further
			enhancements, and documented a la M$ :-)

This would not be too much, huh?

Hey, another half'n'hour of bla-bla. I would have to go through to the
finish on the code, in this time ;-)

				Friendly, Cristian

---

From: Adam Kopacz <[email-masked]>
Date: Fri, 25 Jul 1997 19:48:15 +0200

Cristian Tibirna wrote:
hi,

> Menu SomeMenu

yes.. i know.. but WindowList isn't a menu :( it is a module.. or ?
 
> system.fvwm2rc), it acts like if a PopUp would have been implemented

here the same.. button 3 = WinList. it works like a menu.. 
but not in FvwmButtons :(
 
> fvwmbuttons or menus (and there's not so much left :-).
:(

--