[Bf-python] Logical Window.GetMouseButtons()

Joe Eagar joeedh at gmail.com
Wed May 2 22:07:40 CEST 2007


Michael Schardt wrote:
> Hello again,
>  
> I got no replies on my previous mail, but hopefully this time...
> Window.GetMouseButtons() allways returns the physical button state. A 
> option to respect the user preferences (Select with Right / Left 
> mousebutton) might be nice.
> Here's a modification to the Window.GetMouseButtons() - function. It 
> now takes an optional argument if you want it to return not the 
> physical but the logical button state. I made the argument optional so 
> no existing scripts will break. The returned value is still compared 
> against Window.MButs.
> In logical mode, Window.Mbuts.R refers to the Select button (Could be 
> the physical left mousebutton if user changed preferences to "Select 
> with: Left Mouse".
> Any arguments against? If not, could anyone put it in? (i do not have 
> CVS-access)
>  
> Michael
>  
Seems kindof odd.  Maybe adding a new functions, 
Window.GetMouseSelectButtonState() would make sense, but changing 
getMouseButtons seems like bad form.  Though I suppose since it's an 
option it could work. . .

Joe



More information about the Bf-python mailing list