Since it is also possible to say 'She's having a baby' ,which is the present continuous used for the future, I think the sense is normally that of a planned future event. But If you see a pregnant woman in the street and say 'Oh, she's going to have a baby.' Your prediction is obviously based on her evident condition. So both reasons for using 'going to' work.