fixed setbgimg's bug