fixed #3877. make fadeIn and fadeOut behaviours correct
Merge pull request #5463 from andyque/refactor3877

closed #3877. make fadeIn and fadeOut behaviours correct