make resize event only emitted by windows
@@ -2,8 +2,8 @@ use fltk::{app::*, button::*, frame::*, window::*};
fn main() {
let app = App::default();
- let mut wind = Window::new(100, 100, 400, 300, "Hello from rust");
- let mut frame = Frame::new(0, 0, 400, 200, "");
+ let mut wind = Window::default().with_size(400, 300);
+ let mut frame = Frame::default().size_of(&wind);
let mut but = Button::new(160, 210, 80, 40, "Click me!");
wind.end();
