mirror of
https://github.com/KokaKiwi/BarInsta
synced 2024-11-22 06:37:30 +00:00
disable unfinished dm share profile
This commit is contained in:
parent
f83bd32866
commit
f04a5bd2c6
@ -130,7 +130,8 @@ public class ProfileFragment extends Fragment implements SwipeRefreshLayout.OnRe
|
|||||||
private HighlightsViewModel highlightsViewModel;
|
private HighlightsViewModel highlightsViewModel;
|
||||||
private MenuItem blockMenuItem, restrictMenuItem, chainingMenuItem;
|
private MenuItem blockMenuItem, restrictMenuItem, chainingMenuItem;
|
||||||
private MenuItem muteStoriesMenuItem, mutePostsMenuItem, removeFollowerMenuItem;
|
private MenuItem muteStoriesMenuItem, mutePostsMenuItem, removeFollowerMenuItem;
|
||||||
private MenuItem shareLinkMenuItem, shareDmMenuItem;
|
private MenuItem shareLinkMenuItem;
|
||||||
|
// private MenuItem shareDmMenuItem;
|
||||||
private boolean accountIsUpdated = false;
|
private boolean accountIsUpdated = false;
|
||||||
private boolean postsSetupDone = false;
|
private boolean postsSetupDone = false;
|
||||||
private Set<Media> selectedFeedModels;
|
private Set<Media> selectedFeedModels;
|
||||||
@ -469,10 +470,10 @@ public class ProfileFragment extends Fragment implements SwipeRefreshLayout.OnRe
|
|||||||
if (shareLinkMenuItem != null) {
|
if (shareLinkMenuItem != null) {
|
||||||
shareLinkMenuItem.setVisible(profileModel != null && !TextUtils.isEmpty(profileModel.getUsername()));
|
shareLinkMenuItem.setVisible(profileModel != null && !TextUtils.isEmpty(profileModel.getUsername()));
|
||||||
}
|
}
|
||||||
shareDmMenuItem = menu.findItem(R.id.share_dm);
|
// shareDmMenuItem = menu.findItem(R.id.share_dm);
|
||||||
if (shareDmMenuItem != null) {
|
// if (shareDmMenuItem != null) {
|
||||||
shareDmMenuItem.setVisible(profileModel != null && profileModel.getPk() != 0L);
|
// shareDmMenuItem.setVisible(profileModel != null && profileModel.getPk() != 0L);
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -585,20 +586,21 @@ public class ProfileFragment extends Fragment implements SwipeRefreshLayout.OnRe
|
|||||||
startActivity(sharingIntent);
|
startActivity(sharingIntent);
|
||||||
return true;
|
return true;
|
||||||
} else if (itemId == R.id.share_dm) {
|
} else if (itemId == R.id.share_dm) {
|
||||||
final UserSearchNavGraphDirections.ActionGlobalUserSearch actionGlobalUserSearch = UserSearchFragmentDirections
|
// final UserSearchNavGraphDirections.ActionGlobalUserSearch actionGlobalUserSearch = UserSearchFragmentDirections
|
||||||
.actionGlobalUserSearch()
|
// .actionGlobalUserSearch()
|
||||||
.setTitle(getString(R.string.share))
|
// .setTitle(getString(R.string.share))
|
||||||
.setActionLabel(getString(R.string.send))
|
// .setActionLabel(getString(R.string.send))
|
||||||
.setShowGroups(true)
|
// .setShowGroups(true)
|
||||||
.setMultiple(true)
|
// .setMultiple(true)
|
||||||
.setSearchMode(UserSearchFragment.SearchMode.RAVEN);
|
// .setSearchMode(UserSearchFragment.SearchMode.RAVEN);
|
||||||
final NavController navController = NavHostFragment.findNavController(ProfileFragment.this);
|
// final NavController navController = NavHostFragment.findNavController(ProfileFragment.this);
|
||||||
try {
|
// try {
|
||||||
navController.navigate(actionGlobalUserSearch);
|
// navController.navigate(actionGlobalUserSearch);
|
||||||
} catch (Exception e) {
|
// } catch (Exception e) {
|
||||||
Log.e(TAG, "setupShare: ", e);
|
// Log.e(TAG, "setupShare: ", e);
|
||||||
}
|
// }
|
||||||
return true;
|
// return true;
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
return super.onOptionsItemSelected(item);
|
return super.onOptionsItemSelected(item);
|
||||||
}
|
}
|
||||||
@ -1061,9 +1063,9 @@ public class ProfileFragment extends Fragment implements SwipeRefreshLayout.OnRe
|
|||||||
if (shareLinkMenuItem != null) {
|
if (shareLinkMenuItem != null) {
|
||||||
shareLinkMenuItem.setVisible(!TextUtils.isEmpty(profileModel.getUsername()));
|
shareLinkMenuItem.setVisible(!TextUtils.isEmpty(profileModel.getUsername()));
|
||||||
}
|
}
|
||||||
if (shareDmMenuItem != null) {
|
// if (shareDmMenuItem != null) {
|
||||||
shareDmMenuItem.setVisible(profileModel.getPk() != 0L);
|
// shareDmMenuItem.setVisible(profileModel.getPk() != 0L);
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user