bool originalKeepWithinPanel = _itemGrid.keepWithinPanel;
_itemGrid.keepWithinPanel = false; //Need to set this to false or else buttons will not properly be at top if player scrolls past bottom then switch tabs
_itemGrid.keepWithinPanel = false; //Need to set this to false or else buttons will not properly be at top if player scrolls past bottom then switch tabs
_scrollView.ResetPosition (); //Reset and move scroll panel back to original start position or else buttons keep shifting when changing tabs
_itemGrid.Reposition();
_scrollView.ResetPosition (); //Reset and move scroll panel back to original start position, required before and after tabbing - see ngui docs
_itemGrid.keepWithinPanel = originalKeepWithinPanel;