MainActivity: Move remaining ElementsFragment's code into ElementsFragment