public void Dispose() { texture = null; onClicked = null; guiColor = null; var disposing = this; Pool.Dispose(ref disposing); }
public void Dispose() { onClicked = null; onRightClicked = null; texture = null; guiColor = null; overrideCalculatePosition = null; var disposing = this; Pool.Dispose(ref disposing); }
private void Setup(HeaderPart headerPart, bool drawsSelectionRect, bool drawsMouseoverRect, string tooltip, OnHeaderPartClicked onPartClicked, OnHeaderPartClicked onPartRightClicked, bool isSelectable) { part = headerPart; rect = default(Rect); drawSelectionRect = drawsSelectionRect; drawMouseoverRect = drawsMouseoverRect; onClicked = onPartClicked; onRightClicked = onPartRightClicked; selectable = isSelectable; label.image = null; label.tooltip = tooltip; }
private void Setup(HeaderPart headerPart, bool drawsSelectionRect, bool drawsMouseoverRect, [CanBeNull] Texture drawTexture, string tooltip, [CanBeNull] OnHeaderPartClicked onPartClicked, [CanBeNull] OnHeaderPartClicked onPartRightClicked, bool isSelectable) { part = headerPart; rect = default(Rect); drawSelectionRect = drawsSelectionRect; drawMouseoverRect = drawsMouseoverRect; texture = drawTexture; onClicked = onPartClicked; onRightClicked = onPartRightClicked; selectable = isSelectable; label.image = drawTexture; label.tooltip = tooltip == null ? "" : tooltip; }
private void Setup(HeaderPart headerPart, bool drawsSelectionRect, bool drawsMouseoverRect, string tooltip, [CanBeNull] OnHeaderPartClicked onPartClicked, [CanBeNull] OnHeaderPartClicked onPartRightClicked, bool isSelectable, CalculatePosition setOverrideCalculatePosition) { part = headerPart; rect = default(Rect); drawSelectionRect = drawsSelectionRect; drawMouseoverRect = drawsMouseoverRect; onClicked = onPartClicked; onRightClicked = onPartRightClicked; selectable = isSelectable; overrideCalculatePosition = setOverrideCalculatePosition; label.image = null; label.tooltip = tooltip == null ? "" : tooltip; }
public static HeaderPartDrawer Create([NotNull] Texture icon, [NotNull] OnHeaderPartClicked onPartClicked, string tooltip = "", bool selectable = true) { Debug.Assert(icon != null); Debug.Assert(onPartClicked != null); HeaderPartDrawer result; if (!Pool.TryGet(out result)) { result = new HeaderPartDrawer(); } NthCustomHeaderButton++; if (NthCustomHeaderButton >= 10) { NthCustomHeaderButton = 0; } var headerPart = (HeaderPart)(NthCustomHeaderButton + ((int)HeaderPart.CustomHeaderButton1)); result.Setup(headerPart, true, true, icon, tooltip, onPartClicked, onPartClicked, selectable); return(result); }
public static HeaderPartDrawer Create(HeaderPart headerPart, bool drawSelectionRect, bool drawMouseoverRect, [CanBeNull] Texture drawTexture, string tooltip, OnHeaderPartClicked onPartClicked, OnHeaderPartClicked onPartRightClicked = null, bool selectable = true) { HeaderPartDrawer result; if (!Pool.TryGet(out result)) { result = new HeaderPartDrawer(); } result.Setup(headerPart, drawSelectionRect, drawMouseoverRect, drawTexture, tooltip, onPartClicked, onPartRightClicked, selectable); return(result); }
public static HeaderPartDrawer Create(HeaderPart headerPart, bool drawSelectionRect, bool drawMouseoverRect, string tooltip, OnHeaderPartClicked onPartClicked, OnHeaderPartClicked onPartRightClicked = null, bool selectable = true, CalculatePosition overrideCalculatePosition = null) { HeaderPartDrawer result; if (!Pool.TryGet(out result)) { result = new HeaderPartDrawer(); } result.Setup(headerPart, drawSelectionRect, drawMouseoverRect, tooltip, onPartClicked, onPartRightClicked, selectable, overrideCalculatePosition); return(result); }