Browse Source

Avoid nfloat in the codebase

pull/7565/head
Max Katz 4 years ago
parent
commit
b47abdb9a1
  1. 3
      src/iOS/Avalonia.iOS/Extensions.cs
  2. 3
      src/iOS/Avalonia.iOS/LayerFbo.cs

3
src/iOS/Avalonia.iOS/Extensions.cs

@ -1,7 +1,6 @@
using System;
using Avalonia.Media;
using CoreGraphics;
using ObjCRuntime;
using UIKit;
namespace Avalonia.iOS
@ -13,7 +12,7 @@ namespace Avalonia.iOS
public static Point ToAvalonia(this CGPoint point) => new Point(point.X, point.Y);
static nfloat ColorComponent(byte c) => ((float) c) / 255;
static float ColorComponent(byte c) => (float) c / 255;
public static UIColor ToUiColor(this Color color) => new UIColor(
ColorComponent(color.R),

3
src/iOS/Avalonia.iOS/LayerFbo.cs

@ -1,7 +1,6 @@
using System;
using Avalonia.OpenGL;
using CoreAnimation;
using ObjCRuntime;
using OpenGLES;
namespace Avalonia.iOS
@ -103,7 +102,7 @@ namespace Avalonia.iOS
private readonly GlInterface _gl;
private readonly CAEAGLLayer _layer;
private LayerFbo _fbo;
private nfloat _oldLayerWidth, _oldLayerHeight, _oldLayerScale;
private double _oldLayerWidth, _oldLayerHeight, _oldLayerScale;
public SizeSynchronizedLayerFbo(EAGLContext context, GlInterface gl, CAEAGLLayer layer)
{

Loading…
Cancel
Save