ui/ncurses: Move general nc init code to cui module