merge from trunk to javascript branch