Fix panic at initialize window without size on windows
@@ -664,6 +664,10 @@ impl WndProc for MyWndProc {
let handle = self.handle.borrow().to_owned();
state.handler.connect(&handle.into());
+
+ if let Err(e) = state.rebuild_render_target(&self.d2d_factory, scale) {
+ error!("error building render target: {}", e);
+ }
}
Some(0)
}
