Page 1 of 6

Disabled option in meters

Posted: April 12th, 2018, 11:16 am
by Virginityrocks
It would be handy to have an easy way to disable or enable LeftMouseUpActions, etc. of a given meter, without hiding the meter entirely. It would be handy if Disabled=1 would keep a meter visible, but disable its mouse actions. Maybe Disabled=1 disables all Actions, while Disabled=2 disables only click actions, leaving MouseOverActions active.

Re: Disabled option in meters

Posted: April 12th, 2018, 11:26 am
by fonpaolo
You can use !SetOption and change it to LeftMouseUpAction "[]"

Re: Disabled option in meters

Posted: April 12th, 2018, 11:33 am
by jsmorley
Virginityrocks wrote:It would be handy to have an easy way to disable or enable LeftMouseUpActions, etc. of a given meter, without hiding the meter entirely. It would be handy if Disabled=1 would keep a meter visible, but disable its mouse actions.
I don't disagree. It can be a bit of code to use !SetOption to toggle a LeftMouseUpAction between "something" and "nothing", and that becomes a lot of code if you have multiple types of mouse actions on a meter. An easy way to turn off and on all mouse actions on a meter would be a nice touch. Maybe not "Disabled", as I think that is a bit confusing with the measure variant of that option.

Perhaps MouseDisabled, with a default of 0.

Re: Disabled option in meters

Posted: April 12th, 2018, 11:34 am
by jsmorley
fonpaolo wrote:You can use !SetOption and change it to LeftMouseUpAction "[]"
Right, but if you have a long, complicated LeftMouseUpAction, or worse, several different types of mouse actions on a meter, the !SetOption bang to turn them "back on" can get pretty beefy.

Re: Disabled option in meters

Posted: April 12th, 2018, 11:49 am
by Virginityrocks
jsmorley wrote:Right, but if you have a long, complicated LeftMouseUpAction, or worse, several different types of mouse actions on a meter, the !SetOption bang to turn them "back on" can get pretty beefy.
Exactly. :17nodding

Re: Disabled option in meters

Posted: April 12th, 2018, 11:50 am
by jsmorley
This should probably be the entire suite of option/bangs like "hidden" has.

MouseDisabled 0/1
!DisableMouse
!EnableMouse
!ToggleMouse

Re: Disabled option in meters

Posted: April 12th, 2018, 12:13 pm
by fonpaolo
jsmorley wrote:Right, but if you have a long, complicated LeftMouseUpAction, or worse, several different types of mouse actions on a meter, the !SetOption bang to turn them "back on" can get pretty beefy.
I'm probably too patient... :17oops

Re: Disabled option in meters

Posted: April 12th, 2018, 12:15 pm
by jsmorley
What we have to consider is if this means LeftMouseUpAction="" or LeftMouseUpAction=[]. They have different implications for mouse detection on meters that overlap. It also has implications with RightMouseUpAction, where you many not want turning "off" a custom skin menu to turn "on" the standard skin menu, or you might...

I would lean toward LeftMouseUpAction=[], as I think that is going to be the intent most of the time.

Re: Disabled option in meters

Posted: April 12th, 2018, 12:17 pm
by jsmorley
fonpaolo wrote:I'm probably too patient... :17oops
Make no mistake, it's not that this is a big deal. Turning mouse actions on and off today is not that hard with !SetOption, but this is a reasonably easy, low-hanging-fruit change that can, in some edge cases, save a bit of work.

Re: Disabled option in meters

Posted: April 12th, 2018, 12:39 pm
by fonpaolo
What I always do is to set up a line of commands, then I copy and paste, edit them accordingly, use "!Show" instead of "!Hide", "[]" instead of the command(s) and so on.
Even if the commands are many, it will take less than a minute.

...but this is only my opinion.