Is it possible to prevent LocatorPane from modifying locator positions unless Alt ket is down?

I am using the LocatorAutoCreate option which allows the user to hold Alt while clicking in order to create/remove locators. However, I need to be able to prevent the "original" functionality of LocatorPane which moves the closest locator to the current mouse position whenever you click.

To clarify, I will use a simple example:

LocatorPane[Dynamic[list], Graphics[{Gray, Disk[]}], LocatorAutoCreate -> True]


I want to prevent locators from being moved when clicking and not holding Alt, but still keep the functionality of LocatorAutoCreate which creates/removes the locators when the user holds Alt and clicks.

My guess is that I will need to use some combination of EventHandler, DynamicWrapper, and CurrentValue, but I am not experienced with these functions and have not yet been able to find a solution.

My best idea currently is to use something like this:

DynamicWrapper[
LocatorPane[Dynamic[list], Graphics[{Gray, Disk[]}], LocatorAutoCreate -> True],
If[CurrentValue["MouseButtonTest"] && ! CurrentValue["AltKey"],
CurrentValue["MouseButtonTest"] = False]]


Yet, clearly this doesn't work as you cannot manually set CurrentValue["MouseButtonTest"] to False.

Edit

A few minutes after making this post I thought of a solution (even though I had spent 2 hours prior struggling). If anyone is curious, this problem can be solved using the second argument of dynamic:

LocatorPane[
Dynamic[list,
(If[CurrentValue["MouseButtonTest"] && ! CurrentValue["AltKey"],
list = list, list = #]) &],
Graphics[{Gray, Disk[]}],
LocatorAutoCreate -> True]

• You should remove your edit post as a self-answer. – m_goldberg Oct 18 '17 at 2:37
• I am not sure I got it, so the only action allowed is locators creation right? They should always stay whey they were created? – Kuba Oct 18 '17 at 7:48
• LocatorAutoCreate also allows the user to click on a selected locator while holding alt to remove it. So the user can remove a locator and then create a new locator in the necessary position to "move" it. – user52941 Oct 18 '17 at 18:39