@@ -339,13 +339,16 @@ impl<T> Window<T> {
339
339
}
340
340
}
341
341
342
- pub fn set_scale ( & self , rect : Rect ) {
342
+ /// Sets the origin and size of the window’s frame rectangle according to a given frame rectangle,
343
+ /// thereby setting its position and size onscreen.
344
+ pub fn set_frame ( & self , rect : Rect ) {
343
345
let rect: CGRect = rect. into ( ) ;
344
346
unsafe {
345
347
let _: ( ) = msg_send ! [ & * self . objc, setFrame: rect display: YES ] ;
346
348
}
347
349
}
348
350
351
+ /// Sets whether the window is transparent to mouse events.
349
352
pub fn set_ignores_mouse_events ( & self , ignore : bool ) {
350
353
unsafe {
351
354
let _: ( ) = msg_send ! [ & * self . objc, setIgnoresMouseEvents: match ignore {
@@ -355,6 +358,7 @@ impl<T> Window<T> {
355
358
}
356
359
}
357
360
361
+ /// Sets whether the window accepts mouse-moved events.
358
362
pub fn set_accepts_mouse_moved_events ( & self , accept : bool ) {
359
363
unsafe {
360
364
let _: ( ) = msg_send ! [ & * self . objc, setAcceptsMouseMovedEvents: match accept {
@@ -364,6 +368,7 @@ impl<T> Window<T> {
364
368
}
365
369
}
366
370
371
+ /// Sets the window’s visible state to the value you specify.
367
372
pub fn set_is_visible ( & self , visible : bool ) {
368
373
unsafe {
369
374
let _: ( ) = msg_send ! [ & * self . objc, setIsVisible: match visible {
@@ -373,6 +378,7 @@ impl<T> Window<T> {
373
378
}
374
379
}
375
380
381
+ /// Sets whether the window has a shadow.
376
382
pub fn set_has_shadow ( & self , shadow : bool ) {
377
383
unsafe {
378
384
let _: ( ) = msg_send ! [ & * self . objc, setHasShadow: match shadow {
0 commit comments