ExpandAll/CollapseAll implementation
Add expanded memory