Yep - that's a common method.
Dip the frame in future mask off then paint as needed.
If there's lots of glass or a larger scale (like 1/48 or 1/35) you may even want to paint the interior colour of the frame first, then the exterior colour.
By example, a lot of WW2 fighters had interior green as the internal colour of the cockpit and canopy frame, whilst the exterior of the frame was whatever the camo colour was.
Also, the pre-dipping of future would not change a colour painted over the top.