Square picture and refactor

Some code refactoring, added squared picture to the gallery
usare mFragmentManager