[Extension core]TODO: Handle the window resizing.