mirror of
https://github.com/SimpleMobileTools/Simple-Dialer.git
synced 2025-06-05 21:49:23 +02:00
Changed arrow colors and removed an old way
This commit is contained in:
@ -98,20 +98,7 @@ class CallActivity : SimpleActivity() {
|
||||
}
|
||||
|
||||
private fun initButtons() {
|
||||
if (config.enableSwipeToAnswer) {
|
||||
handleSwipe()
|
||||
} else {
|
||||
call_draggable.beGone()
|
||||
call_draggable_background.beGone()
|
||||
|
||||
call_decline.setOnClickListener {
|
||||
endCall()
|
||||
}
|
||||
|
||||
call_accept.setOnClickListener {
|
||||
acceptCall()
|
||||
}
|
||||
}
|
||||
handleSwipe()
|
||||
|
||||
call_toggle_microphone.setOnClickListener {
|
||||
toggleMicrophone()
|
||||
@ -183,6 +170,9 @@ class CallActivity : SimpleActivity() {
|
||||
leftArrowTranslation = -call_decline.x
|
||||
rightArrowTranslation = call_decline.x
|
||||
|
||||
call_left_arrow.applyColorFilter(getColor(R.color.md_red_400))
|
||||
call_right_arrow.applyColorFilter(getColor(R.color.md_green_400))
|
||||
|
||||
startArrowAnimation(call_left_arrow, initialLeftArrowX, initialLeftArrowScaleX, initialLeftArrowScaleY, leftArrowTranslation)
|
||||
startArrowAnimation(call_right_arrow, initialRightArrowX, initialRightArrowScaleX, initialRightArrowScaleY, rightArrowTranslation)
|
||||
}
|
||||
|
@ -40,7 +40,6 @@ class SettingsActivity : SimpleActivity() {
|
||||
setupStartNameWithSurname()
|
||||
setupShowCallConfirmation()
|
||||
setupDisableProximitySensor()
|
||||
setupEnableSwipeToAnswer()
|
||||
updateTextColors(settings_holder)
|
||||
invalidateOptionsMenu()
|
||||
|
||||
@ -221,12 +220,4 @@ class SettingsActivity : SimpleActivity() {
|
||||
config.disableProximitySensor = settings_disable_proximity_sensor.isChecked
|
||||
}
|
||||
}
|
||||
|
||||
private fun setupEnableSwipeToAnswer() {
|
||||
settings_enable_swipe_to_answer.isChecked = config.enableSwipeToAnswer
|
||||
settings_enable_swipe_to_answer_holder.setOnClickListener {
|
||||
settings_enable_swipe_to_answer.toggle()
|
||||
config.enableSwipeToAnswer = settings_enable_swipe_to_answer.isChecked
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -52,10 +52,6 @@ class Config(context: Context) : BaseConfig(context) {
|
||||
get() = prefs.getBoolean(DISABLE_PROXIMITY_SENSOR, false)
|
||||
set(disableProximitySensor) = prefs.edit().putBoolean(DISABLE_PROXIMITY_SENSOR, disableProximitySensor).apply()
|
||||
|
||||
var enableSwipeToAnswer: Boolean
|
||||
get() = prefs.getBoolean(ENABLE_SWIPE_TO_ANSWER, false)
|
||||
set(enableSwipeToAnswer) = prefs.edit().putBoolean(ENABLE_SWIPE_TO_ANSWER, enableSwipeToAnswer).apply()
|
||||
|
||||
var showTabs: Int
|
||||
get() = prefs.getInt(SHOW_TABS, ALL_TABS_MASK)
|
||||
set(showTabs) = prefs.edit().putInt(SHOW_TABS, showTabs).apply()
|
||||
|
@ -10,7 +10,6 @@ const val REMEMBER_SIM_PREFIX = "remember_sim_"
|
||||
const val GROUP_SUBSEQUENT_CALLS = "group_subsequent_calls"
|
||||
const val OPEN_DIAL_PAD_AT_LAUNCH = "open_dial_pad_at_launch"
|
||||
const val DISABLE_PROXIMITY_SENSOR = "disable_proximity_sensor"
|
||||
const val ENABLE_SWIPE_TO_ANSWER = "enable_swipe_to_answer"
|
||||
const val SHOW_TABS = "show_tabs"
|
||||
|
||||
const val ALL_TABS_MASK = TAB_CONTACTS or TAB_FAVORITES or TAB_CALL_HISTORY
|
||||
|
Reference in New Issue
Block a user