Browse Source

tooltip for story viewer buttons

renovate/androidx.fragment-fragment-ktx-1.x
Austin Huang 4 years ago
parent
commit
94ea7269e2
No known key found for this signature in database GPG Key ID: 84C23AA04587A91F
  1. 9
      app/src/main/java/awais/instagrabber/fragments/StoryViewerFragment.kt
  2. 2
      app/src/main/res/values/strings.xml

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

@ -15,6 +15,7 @@ import androidx.appcompat.app.AlertDialog
import androidx.appcompat.app.AppCompatActivity import androidx.appcompat.app.AppCompatActivity
import androidx.appcompat.view.ContextThemeWrapper import androidx.appcompat.view.ContextThemeWrapper
import androidx.appcompat.widget.PopupMenu import androidx.appcompat.widget.PopupMenu
import androidx.appcompat.widget.TooltipCompat
import androidx.core.view.GestureDetectorCompat import androidx.core.view.GestureDetectorCompat
import androidx.fragment.app.Fragment import androidx.fragment.app.Fragment
import androidx.lifecycle.MutableLiveData import androidx.lifecycle.MutableLiveData
@ -78,8 +79,6 @@ class StoryViewerFragment : Fragment() {
private var profileVisible: Boolean = false private var profileVisible: Boolean = false
private var player: SimpleExoPlayer? = null private var player: SimpleExoPlayer? = null
private var actionBarTitle: String? = null
private var actionBarSubtitle: String? = null
private var shouldRefresh = true private var shouldRefresh = true
private var currentFeedStoryIndex = 0 private var currentFeedStoryIndex = 0
private var sliderValue = 0.0 private var sliderValue = 0.0
@ -258,6 +257,12 @@ class StoryViewerFragment : Fragment() {
binding.storiesList.visibility = if (binding.storiesList.visibility == View.GONE) View.VISIBLE binding.storiesList.visibility = if (binding.storiesList.visibility == View.GONE) View.VISIBLE
else View.GONE else View.GONE
}) })
TooltipCompat.setTooltipText(binding.btnDownload, getString(R.string.action_download))
TooltipCompat.setTooltipText(binding.btnShare, getString(R.string.share))
TooltipCompat.setTooltipText(binding.btnReply, getString(R.string.reply_story))
TooltipCompat.setTooltipText(binding.stickers, getString(R.string.story_stickers))
TooltipCompat.setTooltipText(binding.listToggle, getString(R.string.story_list))
} }
@SuppressLint("ClickableViewAccessibility") @SuppressLint("ClickableViewAccessibility")

2
app/src/main/res/values/strings.xml

@ -486,4 +486,6 @@
<string name="disable_screen_transitions">Disable screen transitions</string> <string name="disable_screen_transitions">Disable screen transitions</string>
<string name="invalid_format">Invalid format</string> <string name="invalid_format">Invalid format</string>
<string name="no_directory_picker_activity">Barinsta cannot launch Android\'s file manager. Please make sure it is installed and enabled on your device.</string> <string name="no_directory_picker_activity">Barinsta cannot launch Android\'s file manager. Please make sure it is installed and enabled on your device.</string>
<string name="story_stickers">Stickers</string>
<string name="story_list">Story list</string>
</resources> </resources>
Loading…
Cancel
Save