Fix small bugs of UI Foundation Integration