"Lock Tab" would be easier since that is a command you can find and assign hotkey to
"Lock Tab - Allow subpath change" Is harder since this is an extra command that the Explorer Panel adds to tab when it is shown.
There is no way of toggling it on/off but you can have two commands one that enables only Lock, and one that enables Lock + Allow Subpath Change
To do that, Create two user defined command of CustomCommand type. and then assign hotkeys to them.
For Lock you do
MC.Explorer.SetTabProp TABLOCK
For Lock and Allow Subpath change you do
MC.Explorer.SetTabProp TABLOCK TABLOCKALLOWSUBCHANGE