Closed #5704: sync Cocos UI and correct some their mistakes 

Sync Cocos UI and correct some their mistakes