gfx-rs / gfx

[maintenance mode] A low-overhead Vulkan-like GPU API for Rust.
http://gfx-rs.github.io/
Apache License 2.0
5.35k stars 551 forks source link

macos: Set layerContentsPlacement to topleft #3731

Closed scoopr closed 3 years ago

scoopr commented 3 years ago

One weird thing I noticed, that when dragging a window between hidpi and lodpi screens, it tries to animate the change in scale, which I find weird. And I'm not sure how to disable, as I don't know around what I could do the CATransation. But it is a really minor thing.

scoopr commented 3 years ago

How about this?

Though I was thinking of making the layer delegate a proper instance anyway, with the idea that it would actually return NO, but set the contentScale directly itself and then call out for the layer/view display method, if that would route through the winit to actually draw the layer at that point. But it may be that this is such small corner-case that it doesn't matter.

bors[bot] commented 3 years ago

Build succeeded: