Implemented onlcick function for the listfragment. Sharedpreferences is also working