fix the problem of endingPanel

fix the problem of pictures at the wrong position when entering the
ending above twice )