improved swap and insert interface to support selection stack; fixed some minor TaskPrompt bugs