Yup, that looks about right!
Note that you can Show/Hide widget instead of Add/Remove from Viewport. Preferable in most (but not all) cases. Adding / removing is somewhat costly as the widget layout needs to be redone, and its Construct will fire every time. May not be relevant here, though.