Ejemplo n.º 1
0
 protected void Init(IAvnWindowBase window, IAvnScreens screens)
 {
     _native           = window;
     _glSurface        = new GlPlatformSurface(window);
     Screen            = new ScreenImpl(screens);
     _savedLogicalSize = ClientSize;
     _savedScaling     = Scaling;
 }
Ejemplo n.º 2
0
        protected void Init(IAvnWindowBase window, IAvnScreens screens)
        {
            _native = window;

            Screen            = new ScreenImpl(screens);
            _savedLogicalSize = ClientSize;
            _savedScaling     = Scaling;
        }
        protected void Init(IAvnWindowBase window, IAvnScreens screens)
        {
            _native           = window;
            _glSurface        = new GlPlatformSurface(window);
            Screen            = new ScreenImpl(screens);
            _savedLogicalSize = ClientSize;
            _savedScaling     = Scaling;

            var monitor = Screen.AllScreens.OrderBy(x => x.PixelDensity)
                          .FirstOrDefault(m => m.Bounds.Contains(Position));

            Resize(new Size(monitor.WorkingArea.Width * 0.75d, monitor.WorkingArea.Height * 0.7d));
        }
Ejemplo n.º 4
0
        protected void Init(IAvnWindowBase window, IAvnScreens screens, IGlContext glContext)
        {
            _native    = window;
            _glContext = glContext;

            Handle = new MacOSTopLevelWindowHandle(window);
            if (_gpu)
            {
                _glSurface = new GlPlatformSurface(window, _glContext);
            }
            Screen             = new ScreenImpl(screens);
            _savedLogicalSize  = ClientSize;
            _savedScaling      = Scaling;
            _nativeControlHost = new NativeControlHostImpl(_native.CreateNativeControlHost());

            var monitor = Screen.AllScreens.OrderBy(x => x.PixelDensity)
                          .FirstOrDefault(m => m.Bounds.Contains(Position));

            Resize(new Size(monitor.WorkingArea.Width * 0.75d, monitor.WorkingArea.Height * 0.7d));
        }
Ejemplo n.º 5
0
 public void Dispose()
 {
     _native.Dispose();
     _native = null;
 }
Ejemplo n.º 6
0
 public ScreenImpl(IAvnScreens native)
 {
     _native = native;
 }