public UIManager(AtlasGlobal atlas) : base(atlas) { View = new UIView(atlas, new RectangleF(0, 0, 640, 480)); Atlas.Graphics.onResolutionChange += () => { View.Frame = new RectangleF(0, 0, Atlas.Graphics.ResolutionWidth, Atlas.Graphics.ResolutionHeight); }; }
public void AddSubviews(UIView view) { if (view.SuperViews != null) throw new Exception("Element can't have multiple Views"); if (_subviews == null) _subviews = new List<UIView>(); _subviews.Add(view); view.SuperViews = this; SubViews = _subviews.ToArray(); }