mirror of
https://github.com/oxen-io/session-android.git
synced 2025-04-28 07:10:47 +00:00
feat: add survey button
This commit is contained in:
parent
ef3d2bb28f
commit
ecf2308e84
@ -33,15 +33,11 @@ import org.session.libsession.utilities.SSKEnvironment.ProfileManagerProtocol
|
|||||||
import org.session.libsession.utilities.TextSecurePreferences
|
import org.session.libsession.utilities.TextSecurePreferences
|
||||||
import org.thoughtcrime.securesms.PassphraseRequiredActionBarActivity
|
import org.thoughtcrime.securesms.PassphraseRequiredActionBarActivity
|
||||||
import org.thoughtcrime.securesms.avatar.AvatarSelection
|
import org.thoughtcrime.securesms.avatar.AvatarSelection
|
||||||
import org.thoughtcrime.securesms.util.ConfigurationMessageUtilities
|
|
||||||
import org.thoughtcrime.securesms.util.UiModeUtilities
|
|
||||||
import org.thoughtcrime.securesms.util.push
|
|
||||||
import org.thoughtcrime.securesms.mms.GlideApp
|
import org.thoughtcrime.securesms.mms.GlideApp
|
||||||
import org.thoughtcrime.securesms.mms.GlideRequests
|
import org.thoughtcrime.securesms.mms.GlideRequests
|
||||||
import org.thoughtcrime.securesms.permissions.Permissions
|
import org.thoughtcrime.securesms.permissions.Permissions
|
||||||
import org.thoughtcrime.securesms.profiles.ProfileMediaConstraints
|
import org.thoughtcrime.securesms.profiles.ProfileMediaConstraints
|
||||||
import org.thoughtcrime.securesms.util.BitmapDecodingException
|
import org.thoughtcrime.securesms.util.*
|
||||||
import org.thoughtcrime.securesms.util.BitmapUtil
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.security.SecureRandom
|
import java.security.SecureRandom
|
||||||
import java.util.*
|
import java.util.*
|
||||||
@ -85,6 +81,7 @@ class SettingsActivity : PassphraseRequiredActionBarActivity() {
|
|||||||
chatsButton.setOnClickListener { showChatSettings() }
|
chatsButton.setOnClickListener { showChatSettings() }
|
||||||
sendInvitationButton.setOnClickListener { sendInvitation() }
|
sendInvitationButton.setOnClickListener { sendInvitation() }
|
||||||
faqButton.setOnClickListener { showFAQ() }
|
faqButton.setOnClickListener { showFAQ() }
|
||||||
|
surveyButton.setOnClickListener { showSurvey() }
|
||||||
helpTranslateButton.setOnClickListener { helpTranslate() }
|
helpTranslateButton.setOnClickListener { helpTranslate() }
|
||||||
seedButton.setOnClickListener { showSeed() }
|
seedButton.setOnClickListener { showSeed() }
|
||||||
clearAllDataButton.setOnClickListener { clearAllData() }
|
clearAllDataButton.setOnClickListener { clearAllData() }
|
||||||
@ -296,6 +293,16 @@ class SettingsActivity : PassphraseRequiredActionBarActivity() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun showSurvey() {
|
||||||
|
try {
|
||||||
|
val url = "https://getsession.org/survey"
|
||||||
|
val intent = Intent(Intent.ACTION_VIEW, Uri.parse(url))
|
||||||
|
startActivity(intent)
|
||||||
|
} catch (e: Exception) {
|
||||||
|
Toast.makeText(this, "Can't open URL", Toast.LENGTH_LONG).show()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private fun helpTranslate() {
|
private fun helpTranslate() {
|
||||||
try {
|
try {
|
||||||
val url = "https://crowdin.com/project/session-android"
|
val url = "https://crowdin.com/project/session-android"
|
||||||
|
@ -193,6 +193,7 @@
|
|||||||
android:background="?android:dividerHorizontal" />
|
android:background="?android:dividerHorizontal" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
android:padding="@dimen/small_spacing"
|
||||||
android:id="@+id/sendInvitationButton"
|
android:id="@+id/sendInvitationButton"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@ -203,6 +204,7 @@
|
|||||||
android:text="@string/activity_settings_invite_button_title" />
|
android:text="@string/activity_settings_invite_button_title" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
android:padding="@dimen/small_spacing"
|
||||||
android:id="@+id/faqButton"
|
android:id="@+id/faqButton"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
@ -214,6 +216,19 @@
|
|||||||
android:text="@string/activity_settings_faq_button_title" />
|
android:text="@string/activity_settings_faq_button_title" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
android:padding="@dimen/small_spacing"
|
||||||
|
android:id="@+id/surveyButton"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="@dimen/medium_spacing"
|
||||||
|
android:textColor="@color/text"
|
||||||
|
android:textSize="@dimen/medium_font_size"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="@string/activity_settings_survey_feedback" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:padding="@dimen/small_spacing"
|
||||||
android:id="@+id/helpTranslateButton"
|
android:id="@+id/helpTranslateButton"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
@ -897,5 +897,6 @@
|
|||||||
<string name="delete_message_for_me">Delete just for me</string>
|
<string name="delete_message_for_me">Delete just for me</string>
|
||||||
<string name="delete_message_for_everyone">Delete for everyone</string>
|
<string name="delete_message_for_everyone">Delete for everyone</string>
|
||||||
<string name="delete_message_for_me_and_recipient">Delete for me and %s</string>
|
<string name="delete_message_for_me_and_recipient">Delete for me and %s</string>
|
||||||
|
<string name="activity_settings_survey_feedback">Feedback/Survey</string>
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user