Browse Source

remove logging.

pull/9028/head
Dan Walmsley 4 years ago
parent
commit
42e0cdce37
  1. 1
      src/Web/Avalonia.Web.Blazor/AvaloniaView.razor.cs
  2. 4
      src/Web/Avalonia.Web/AvaloniaView.cs
  3. 4
      src/Web/Avalonia.Web/WindowingPlatform.cs
  4. 1
      src/Web/Avalonia.Web/webapp/modules/avalonia/canvas.ts

1
src/Web/Avalonia.Web.Blazor/AvaloniaView.razor.cs

@ -287,7 +287,6 @@ namespace Avalonia.Web.Blazor
// create the SkiaSharp context // create the SkiaSharp context
if (_context == null) if (_context == null)
{ {
Console.WriteLine("create glcontext");
_glInterface = GRGlInterface.Create(); _glInterface = GRGlInterface.Create();
_context = GRContext.CreateGl(_glInterface); _context = GRContext.CreateGl(_glInterface);

4
src/Web/Avalonia.Web/AvaloniaView.cs

@ -157,8 +157,6 @@ namespace Avalonia.Web
_dpi = ObserveDpi(OnDpiChanged); _dpi = ObserveDpi(OnDpiChanged);
Console.WriteLine($"Started observing dpi: {_dpi}");
_useGL = skiaOptions?.CustomGpuFactory != null; _useGL = skiaOptions?.CustomGpuFactory != null;
if (_useGL) if (_useGL)
@ -167,13 +165,11 @@ namespace Avalonia.Web
// create the SkiaSharp context // create the SkiaSharp context
if (_context == null) if (_context == null)
{ {
Console.WriteLine("create glcontext");
_glInterface = GRGlInterface.Create(); _glInterface = GRGlInterface.Create();
_context = GRContext.CreateGl(_glInterface); _context = GRContext.CreateGl(_glInterface);
// bump the default resource cache limit // bump the default resource cache limit
_context.SetResourceCacheLimit(skiaOptions?.MaxGpuResourceSizeBytes ?? 32 * 1024 * 1024); _context.SetResourceCacheLimit(skiaOptions?.MaxGpuResourceSizeBytes ?? 32 * 1024 * 1024);
Console.WriteLine("glcontext created and resource limit set");
} }
_topLevelImpl.Surfaces = new[] { new BlazorSkiaSurface(_context, _jsGlInfo, ColorType, new PixelSize((int)_canvasSize.Width, (int)_canvasSize.Height), _dpi, GRSurfaceOrigin.BottomLeft) }; _topLevelImpl.Surfaces = new[] { new BlazorSkiaSurface(_context, _jsGlInfo, ColorType, new PixelSize((int)_canvasSize.Width, (int)_canvasSize.Height), _dpi, GRSurfaceOrigin.BottomLeft) };

4
src/Web/Avalonia.Web/WindowingPlatform.cs

@ -29,12 +29,10 @@ namespace Avalonia.Web.Blazor
} }
public static KeyboardDevice Keyboard => s_keyboard ?? public static KeyboardDevice Keyboard => s_keyboard ??
throw new InvalidOperationException("123 BlazorWindowingPlatform not registered."); throw new InvalidOperationException("BlazorWindowingPlatform not registered.");
public static void Register() public static void Register()
{ {
Console.WriteLine("Registering windowing");
var instance = new BlazorWindowingPlatform(); var instance = new BlazorWindowingPlatform();
s_keyboard = new KeyboardDevice(); s_keyboard = new KeyboardDevice();
AvaloniaLocator.CurrentMutable AvaloniaLocator.CurrentMutable

1
src/Web/Avalonia.Web/webapp/modules/avalonia/canvas.ts

@ -35,7 +35,6 @@ export class Canvas {
} }
public static initGL(element: HTMLCanvasElement, elementId: string, renderFrameCallback: () => void): SKGLViewInfo | null { public static initGL(element: HTMLCanvasElement, elementId: string, renderFrameCallback: () => void): SKGLViewInfo | null {
console.log("inside initGL");
var view = Canvas.init(true, element, elementId, renderFrameCallback); var view = Canvas.init(true, element, elementId, renderFrameCallback);
if (!view || !view.glInfo) if (!view || !view.glInfo)
return null; return null;

Loading…
Cancel
Save