Merge "Remove unncessary attachedToWindow check" into sc-dev