Having checked the doors were closed,and that all the lights were off是定语短语,属于完成时态,主要的动词是check,check后面的都是check+that类型的从句,类似于i think that it will be Ok,本句跟了二个从句“the doors were closed”“all the lights were off”。
主句是the boy opened the door to his bedroom