Example #1
0
        override protected void CreateDisplayObject()
        {
            _container         = new Container();
            _container.gOwner  = this;
            _container.hitArea = new Rect();
            _container.SetScale(GRoot.contentScaleFactor, GRoot.contentScaleFactor);
            displayObject = _container;

            _image = new Image();
            _container.AddChild(_image);
        }
Example #2
0
        override protected void HandleSizeChanged()
        {
            if (!_updatingLayout)
            {
                UpdateLayout();
            }
            if (_container.hitArea != null)
            {
                _container.hitArea = new Rect(0, 0, this.width, this.height);
            }

            _container.SetScale(this.scaleX * GRoot.contentScaleFactor, this.scaleY * GRoot.contentScaleFactor);
        }
Example #3
0
        override protected void HandleSizeChanged()
        {
            if (!_updatingLayout)
            {
                UpdateLayout();
            }
            if (_container.hitArea != null)
            {
                ((RectHitTest)_container.hitArea).Set(0, 0, this.width, this.height);
            }

            _container.SetScale(this.scaleX, this.scaleY);
        }
Example #4
0
        protected override void CreateDisplayObject()
        {
            _container = new Container();
            _container.gOwner = this;
            _container.hitArea = new Rect();
            _container.SetScale(GRoot.contentScaleFactor, GRoot.contentScaleFactor);
            displayObject = _container;

            _image = new Image();
            _container.AddChild(_image);
        }