protected override Size MeasureOverride(Size rpConstraint)
{
var rWidth = rpConstraint.Width;
var rHeight = rpConstraint.Height;
if (IsExtracted)
{
var rZoom = DpiUtil.ScaleX + Preference.Instance.Browser.Zoom - 1.0;
rWidth = Math.Min(rWidth, GameConstants.GameWidth * rZoom / DpiUtil.ScaleX / DpiUtil.ScaleX);
rHeight = Math.Min(rHeight, GameConstants.GameHeight * rZoom / DpiUtil.ScaleY / DpiUtil.ScaleY);
}
return new Size(rWidth, rHeight);
}
}