mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-17 00:44:19 +00:00
Fix global scale factor bug on iOS
This commit is contained in:
parent
5ee02150e1
commit
4ef190cc5e
1 changed files with 8 additions and 3 deletions
|
|
@ -659,7 +659,7 @@ void UIViewComponentPeer::setFullScreen (bool shouldBeFullScreen)
|
|||
|
||||
// (can't call the component's setBounds method because that'll reset our fullscreen flag)
|
||||
if (! r.isEmpty())
|
||||
setBounds (r, shouldBeFullScreen);
|
||||
setBounds (ScalingHelpers::scaledScreenPosToUnscaled (component, r), shouldBeFullScreen);
|
||||
|
||||
component.repaint();
|
||||
}
|
||||
|
|
@ -700,8 +700,13 @@ void UIViewComponentPeer::updateTransformAndScreenBounds()
|
|||
|
||||
bool UIViewComponentPeer::contains (Point<int> localPos, bool trueIfInAChildWindow) const
|
||||
{
|
||||
if (! component.getLocalBounds().contains (localPos))
|
||||
return false;
|
||||
{
|
||||
Rectangle<int> localBounds =
|
||||
ScalingHelpers::scaledScreenPosToUnscaled (component, component.getLocalBounds());
|
||||
|
||||
if (! localBounds.contains (localPos))
|
||||
return false;
|
||||
}
|
||||
|
||||
UIView* v = [view hitTest: convertToCGPoint (localPos)
|
||||
withEvent: nil];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue