Allowing long click on main screen, moving required functions out into
shared file