Removed useless code.

This commit is contained in:
Pierre HUBERT 2018-07-31 20:00:14 +02:00
parent 7b31d25846
commit 11e4cba9de
9 changed files with 0 additions and 43 deletions

View File

@ -296,16 +296,6 @@ public class MainActivity extends AppCompatActivity implements
return true; return true;
} }
/**
* Set the currently selected item in the drawer
*
* @param item The ID of the item
*/
public void setSelectedNavigationItem(int item) {
}
/** /**
* Toggle drawer state * Toggle drawer state
*/ */

View File

@ -301,10 +301,6 @@ public class ConversationFragment extends Fragment
//Update conversation title //Update conversation title
getActivity().setTitle(R.string.fragment_conversation_title); getActivity().setTitle(R.string.fragment_conversation_title);
//Update the bottom navigation menu
((MainActivity) getActivity())
.setSelectedNavigationItem(R.id.action_conversations);
//Check for conversation information //Check for conversation information
if(conversationInfo == null){ if(conversationInfo == null){

View File

@ -153,10 +153,6 @@ public class ConversationsListFragment extends Fragment implements AdapterView.O
//Update activity title //Update activity title
getActivity().setTitle(R.string.fragment_conversationslist_title); getActivity().setTitle(R.string.fragment_conversationslist_title);
//Update the bottom navigation menu
((MainActivity) getActivity())
.setSelectedNavigationItem(R.id.action_conversations);
} }
/** /**

View File

@ -167,11 +167,6 @@ public class FriendsListFragment extends Fragment
//Update the title of the application //Update the title of the application
getActivity().setTitle(R.string.fragment_friendslist_title); getActivity().setTitle(R.string.fragment_friendslist_title);
//Update the bottom navigation menu
((MainActivity) getActivity())
//.setSelectedNavigationItem(R.id.main_bottom_navigation_friends_list);
.setSelectedNavigationItem(R.id.action_latest_posts);
//Refresh the friends list //Refresh the friends list
refresh_friend_list(); refresh_friend_list();
} }

View File

@ -110,10 +110,6 @@ public class LatestPostsFragment extends Fragment
//Update dock and activity title //Update dock and activity title
getActivity().setTitle(R.string.fragment_latestposts_title); getActivity().setTitle(R.string.fragment_latestposts_title);
//Update the bottom navigation menu
((MainActivity) getActivity())
.setSelectedNavigationItem(R.id.action_latest_posts);
//Refresh the list of posts of the user //Refresh the list of posts of the user
refresh_posts_list(); refresh_posts_list();
} }

View File

@ -138,10 +138,6 @@ public class NotificationsFragment extends Fragment implements View.OnCreateCont
//Update the title of the application //Update the title of the application
getActivity().setTitle(R.string.fragment_notifications_title); getActivity().setTitle(R.string.fragment_notifications_title);
//Update the bottom navigation menu
((MainActivity) getActivity())
.setSelectedNavigationItem(R.id.action_notifications);
//Get user page opener //Get user page opener
mUserPageOpener = (onOpenUsersPageListener) getActivity(); mUserPageOpener = (onOpenUsersPageListener) getActivity();

View File

@ -230,10 +230,6 @@ public class UpdateConversationFragment extends Fragment {
public void onResume() { public void onResume() {
super.onResume(); super.onResume();
//Update title and dock
((MainActivity) getActivity()).setSelectedNavigationItem(
R.id.action_conversations);
//Set the adapted title //Set the adapted title
if(current_action == ACTION_CREATE_CONVERSATION) if(current_action == ACTION_CREATE_CONVERSATION)
getActivity().setTitle(R.string.fragment_update_conversation_title_create); getActivity().setTitle(R.string.fragment_update_conversation_title_create);

View File

@ -151,10 +151,6 @@ public class UserAccessDeniedFragment extends Fragment implements View.OnClickLi
public void onResume() { public void onResume() {
super.onResume(); super.onResume();
//Update activity dock
((MainActivity) getActivity())
.setSelectedNavigationItem(R.id.action_latest_posts);
//Check if it is required to fetch user information //Check if it is required to fetch user information
if(mUserInfo == null){ if(mUserInfo == null){
getUserInfo(); getUserInfo();

View File

@ -175,10 +175,6 @@ public class UserPageFragment extends Fragment {
//Set activity title //Set activity title
getActivity().setTitle(userInfo.getDisplayFullName()); getActivity().setTitle(userInfo.getDisplayFullName());
//Update activity menu dock
((MainActivity) getActivity()).setSelectedNavigationItem(
R.id.action_latest_posts);
//Initialize view pager //Initialize view pager
FragmentPagerBaseAdapter adapter = new FragmentPagerBaseAdapter(getChildFragmentManager()); FragmentPagerBaseAdapter adapter = new FragmentPagerBaseAdapter(getChildFragmentManager());