This is an odd one. Cramping is typically electrolyte shortage/imbalance or lack of hydration. But seeing as you're taking potassium and magnesium those are ruled out. What's your salt intake like? Sodium is critical to nerve function, as is potassium. So when your nerves signal muscle cell to fire, it dumps sodium in and potassium levels the cell. So too much sodium could cause it to fire easier, and too much potassium could cause it to stay contracted longer than it's supposed to. A lack of either can also cause cramping. The other big one is calcium. Calcium is released into the cell from the sarcoplasm reticulum (I think it's called) to cause the contraction and when it goes back in it stops the contraction. Magnesium actually works antagonistically against calcium and causes the fiber to relax, which is also crucial to prevent cramping. A lack of magnesium will cause cramping and prevent the muscle from relaxing properly.
Cramping can also be stimulated by stretching the muscle. There is a possibility that your muscles have gotten bigger and shortened from a lack of stretching, which could theoretically cause the touching to stretch it somewhat, inducing the spasm.
It sounds most likely that either you're not hydrated enough, or you're hydrated and don't have enough magnesium or potassium or too much of one of the others. Anything in your diet like too much salt or a lot of calcium intake?
From my experience, some DHTs, mast, winny, and anavar in particular, cause excessive cramping and it takes 3-4 weeks to go away fully once I stop them. Those cramps I get are almost always in my quads and pecs too, which is similar to yours. The pec cramping is awful. The thing I've found to help the most is dosing 2-400mg magnesium citrate or magnesium glycinate at night before bed. Magnesium citrate can act as a pretty powerful laxative, so I prefer glycinate because I can take the higher dose without crapping my brains out. I also take some extra full spectrum electrolytes before training along with taurine. Taurine is great to add as well to assist with shuttling the electrolytes to your muscle cells. I use it every day in my preworkout and when I'm dehydrated or start cramping I take it as well, 2-3g.
The way you're getting twitching from stimulation is really odd though. Almost like your nerves are overly sensitive and it's causing the spasms. That's a new one for me, and I can't even find anything related by searching for studies.