Losing midi connection when clicking "Midi Ports"

Do you use a MIDI to USB adapter?

To me this looks like a driver issue. To experiment, see this thread: Loop MIDI ports not automatically discovered on Windows - #8 by npudar

Gig Performer responds to what a driver sends to it.