public override void Paint(PaintContext context)
        {
            if (context.view_embedder == null)
            {
                return;
            }
            EmbeddedViewParams @params = new EmbeddedViewParams();
            SKMatrix transform = context.canvas.TotalMatrix;
            @params.offsetPixels = new SKPoint(transform.TransX, transform.TransY);
            @params.sizePoints = size_;

            context.view_embedder.CompositeEmbeddedView(view_id_, @params);
        }
Esempio n. 2
0
        //C++ TO C# CONVERTER WARNING: 'const' methods are not available in C#:
        //ORIGINAL LINE: void Paint(PaintContext& context) const override
        public override void Paint(PaintContext context)
        {
            if (context.view_embedder == null)
            {
                //C++ TO C# CONVERTER TODO TASK: There is no direct equivalent in C# to the following C++ macro:
                //!((global::fml.ShouldCreateLogMessage(global::fml.LOG_ERROR))) ? ()0 : new global::fml.LogMessageVoidify() & (new global::fml.LogMessage(global::fml.LOG_ERROR, __FILE__, __LINE__, null).stream()) << "Trying to embed a platform view but the PaintContext " + "does not support embedding";
                return;
            }
            EmbeddedViewParams @params   = new EmbeddedViewParams();
            SKMatrix           transform = context.canvas.TotalMatrix;

            @params.offsetPixels = new SKPoint(transform.TransX, transform.TransY);
            @params.sizePoints   = size_;

            context.view_embedder.CompositeEmbeddedView(view_id_, @params);
        }