Browse Source

close #1605

renovate/androidx.fragment-fragment-ktx-1.x
Austin Huang 4 years ago
parent
commit
57ffd32c83
No known key found for this signature in database GPG Key ID: 84C23AA04587A91F
  1. 2
      app/src/main/java/awais/instagrabber/fragments/PostViewV2Fragment.java
  2. 7
      app/src/main/java/awais/instagrabber/fragments/StoryViewerFragment.kt

2
app/src/main/java/awais/instagrabber/fragments/PostViewV2Fragment.java

@ -755,6 +755,8 @@ public class PostViewV2Fragment extends Fragment implements EditTextDialogFragme
popupMenu.setOnMenuItemClickListener(item -> {
final int itemId = item.getItemId();
if (itemId == R.id.share_dm) {
if (profileModel.isPrivate())
Toast.makeText(context, R.string.share_private_post, Toast.LENGTH_SHORT).show();
final UserSearchNavGraphDirections.ActionGlobalUserSearch actionGlobalUserSearch = UserSearchFragmentDirections
.actionGlobalUserSearch()
.setTitle(getString(R.string.share))

7
app/src/main/java/awais/instagrabber/fragments/StoryViewerFragment.kt

@ -797,6 +797,13 @@ class StoryViewerFragment : Fragment() {
}
private fun shareStoryViaDm() {
val story = storiesViewModel.getCurrentStory().value ?: return
val context = context
if (story.user?.isPrivate == true && context != null) {
Toast.makeText(context, R.string.share_private_post, Toast.LENGTH_SHORT).show()
}
val actionBar = fragmentActivity.supportActionBar
if (actionBar != null) actionBar.subtitle = null
val actionGlobalUserSearch = UserSearchFragmentDirections.actionGlobalUserSearch().apply {
title = getString(R.string.share)
setActionLabel(getString(R.string.send))

Loading…
Cancel
Save