diff --git a/app/build.gradle b/app/build.gradle index 173b8558..44b8ba05 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -62,7 +62,7 @@ android { } dependencies { - implementation 'com.github.SimpleMobileTools:Simple-Commons:e79c9bba93' + implementation 'com.github.SimpleMobileTools:Simple-Commons:7f819f8a75' implementation 'com.github.tibbi:IndicatorFastScroll:4524cd0b61' implementation 'me.grantland:autofittextview:0.2.1' } diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/CallActivity.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/CallActivity.kt index 26d2e4f0..cbc3425d 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/CallActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/CallActivity.kt @@ -54,7 +54,6 @@ class CallActivity : SimpleActivity() { private var viewsUnderDialpad = arrayListOf>() override fun onCreate(savedInstanceState: Bundle?) { - supportActionBar?.hide() super.onCreate(savedInstanceState) setContentView(R.layout.activity_call) @@ -79,7 +78,7 @@ class CallActivity : SimpleActivity() { override fun onResume() { super.onResume() updateState() - updateNavigationBarColor(getBottomTabsBackgroundColor()) + updateNavigationBarColor(getBottomNavigationBackgroundColor()) } override fun onDestroy() { diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ConferenceActivity.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ConferenceActivity.kt index f3633b23..3114cd29 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ConferenceActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ConferenceActivity.kt @@ -1,6 +1,7 @@ package com.simplemobiletools.dialer.activities import android.os.Bundle +import com.simplemobiletools.commons.helpers.NavigationIcon import com.simplemobiletools.dialer.R import com.simplemobiletools.dialer.adapters.ConferenceCallsAdapter import com.simplemobiletools.dialer.helpers.CallManager @@ -14,4 +15,9 @@ class ConferenceActivity : SimpleActivity() { conference_calls_list.adapter = ConferenceCallsAdapter(this, conference_calls_list, ArrayList(CallManager.getConferenceCalls())) {} } + + override fun onResume() { + super.onResume() + setupToolbar(conference_toolbar, NavigationIcon.Arrow) + } } diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialerActivity.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialerActivity.kt index 9707b419..69c2505b 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialerActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialerActivity.kt @@ -6,7 +6,6 @@ import android.net.Uri import android.os.Bundle import android.provider.Settings import android.telecom.TelecomManager -import android.view.Menu import android.widget.Toast import com.simplemobiletools.commons.extensions.* import com.simplemobiletools.commons.helpers.REQUEST_CODE_SET_DEFAULT_DIALER @@ -34,11 +33,6 @@ class DialerActivity : SimpleActivity() { } } - override fun onCreateOptionsMenu(menu: Menu): Boolean { - updateMenuItemColors(menu) - return super.onCreateOptionsMenu(menu) - } - @SuppressLint("MissingPermission") private fun initOutgoingCall() { try { diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialpadActivity.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialpadActivity.kt index c74039d8..18d95bc9 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialpadActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/DialpadActivity.kt @@ -11,8 +11,6 @@ import android.telephony.PhoneNumberUtils import android.telephony.TelephonyManager import android.util.TypedValue import android.view.KeyEvent -import android.view.Menu -import android.view.MenuItem import android.view.View import com.reddit.indicatorfastscroll.FastScrollItemIndicator import com.simplemobiletools.commons.extensions.* @@ -43,6 +41,7 @@ class DialpadActivity : SimpleActivity() { return } + setupOptionsMenu() speedDialValues = config.getSpeedDialValues() privateCursor = getMyContactsCursor(false, true) @@ -127,21 +126,18 @@ class DialpadActivity : SimpleActivity() { super.onResume() updateTextColors(dialpad_holder) dialpad_clear_char.applyColorFilter(getProperTextColor()) - updateNavigationBarColor(getBottomTabsBackgroundColor()) + updateNavigationBarColor(getBottomNavigationBackgroundColor()) + setupToolbar(dialpad_toolbar, NavigationIcon.Arrow) } - override fun onCreateOptionsMenu(menu: Menu): Boolean { - menuInflater.inflate(R.menu.menu_dialpad, menu) - updateMenuItemColors(menu) - return true - } - - override fun onOptionsItemSelected(item: MenuItem): Boolean { - when (item.itemId) { - R.id.add_number_to_contact -> addNumberToContact() - else -> return super.onOptionsItemSelected(item) + private fun setupOptionsMenu() { + dialpad_toolbar.setOnMenuItemClickListener { menuItem -> + when (menuItem.itemId) { + R.id.add_number_to_contact -> addNumberToContact() + else -> return@setOnMenuItemClickListener false + } + return@setOnMenuItemClickListener true } - return true } private fun checkDialIntent(): Boolean { diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/MainActivity.kt index 644b6ac8..3ad7bae9 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/MainActivity.kt @@ -47,7 +47,7 @@ import me.grantland.widget.AutofitHelper class MainActivity : SimpleActivity() { private var isSearchOpen = false private var launchedDialer = false - private var searchMenuItem: MenuItem? = null + private var mSearchMenuItem: MenuItem? = null private var storedShowTabs = 0 private var searchQuery = "" var cachedContacts = ArrayList() @@ -56,6 +56,8 @@ class MainActivity : SimpleActivity() { super.onCreate(savedInstanceState) setContentView(R.layout.activity_main) appLaunched(BuildConfig.APPLICATION_ID) + setupOptionsMenu() + refreshMenuItems() launchedDialer = savedInstanceState?.getBoolean(OPEN_DIAL_PAD_AT_LAUNCH) ?: false @@ -81,11 +83,6 @@ class MainActivity : SimpleActivity() { SimpleContact.sorting = config.sorting } - override fun onSaveInstanceState(outState: Bundle) { - super.onSaveInstanceState(outState) - outState.putBoolean(OPEN_DIAL_PAD_AT_LAUNCH, launchedDialer) - } - override fun onResume() { super.onResume() val properPrimaryColor = getProperPrimaryColor() @@ -96,6 +93,7 @@ class MainActivity : SimpleActivity() { } setupTabColors() + setupToolbar(main_toolbar, searchMenuItem = mSearchMenuItem) getAllFragments().forEach { it?.setupColors(getProperTextColor(), getProperPrimaryColor(), getProperPrimaryColor()) @@ -121,31 +119,6 @@ class MainActivity : SimpleActivity() { config.lastUsedViewPagerPage = view_pager.currentItem } - override fun onCreateOptionsMenu(menu: Menu): Boolean { - menuInflater.inflate(R.menu.menu, menu) - menu.apply { - findItem(R.id.clear_call_history).isVisible = getCurrentFragment() == recents_fragment - findItem(R.id.sort).isVisible = getCurrentFragment() != recents_fragment - findItem(R.id.create_new_contact).isVisible = getCurrentFragment() == contacts_fragment - - setupSearch(this) - updateMenuItemColors(this) - } - return true - } - - override fun onOptionsItemSelected(item: MenuItem): Boolean { - when (item.itemId) { - R.id.clear_call_history -> clearCallHistory() - R.id.create_new_contact -> launchCreateNewContactIntent() - R.id.sort -> showSortingDialog(showCustomSorting = getCurrentFragment() is FavoritesFragment) - R.id.settings -> launchSettings() - R.id.about -> launchAbout() - else -> return super.onOptionsItemSelected(item) - } - return true - } - override fun onActivityResult(requestCode: Int, resultCode: Int, resultData: Intent?) { super.onActivityResult(requestCode, resultCode, resultData) // we dont really care about the result, the app can work without being the default Dialer too @@ -154,11 +127,48 @@ class MainActivity : SimpleActivity() { } } + override fun onSaveInstanceState(outState: Bundle) { + super.onSaveInstanceState(outState) + outState.putBoolean(OPEN_DIAL_PAD_AT_LAUNCH, launchedDialer) + } + override fun onConfigurationChanged(newConfig: Configuration) { super.onConfigurationChanged(newConfig) refreshItems() } + override fun onBackPressed() { + if (isSearchOpen && mSearchMenuItem != null) { + mSearchMenuItem!!.collapseActionView() + } else { + super.onBackPressed() + } + } + + private fun refreshMenuItems() { + val currentFragment = getCurrentFragment() + main_toolbar.menu.apply { + findItem(R.id.clear_call_history).isVisible = currentFragment == recents_fragment + findItem(R.id.sort).isVisible = currentFragment != recents_fragment + findItem(R.id.create_new_contact).isVisible = currentFragment == contacts_fragment + } + } + + private fun setupOptionsMenu() { + setupSearch(main_toolbar.menu) + main_toolbar.setOnMenuItemClickListener { menuItem -> + when (menuItem.itemId) { + R.id.clear_call_history -> clearCallHistory() + R.id.create_new_contact -> launchCreateNewContactIntent() + R.id.sort -> showSortingDialog(showCustomSorting = getCurrentFragment() is FavoritesFragment) + R.id.settings -> launchSettings() + R.id.about -> launchAbout() + else -> return@setOnMenuItemClickListener false + } + return@setOnMenuItemClickListener true + } + } + private fun checkContactPermissions() { handlePermission(PERMISSION_READ_CONTACTS) { initFragments() @@ -167,8 +177,8 @@ class MainActivity : SimpleActivity() { private fun setupSearch(menu: Menu) { val searchManager = getSystemService(Context.SEARCH_SERVICE) as SearchManager - searchMenuItem = menu.findItem(R.id.search) - (searchMenuItem!!.actionView as SearchView).apply { + mSearchMenuItem = menu.findItem(R.id.search) + (mSearchMenuItem!!.actionView as SearchView).apply { setSearchableInfo(searchManager.getSearchableInfo(componentName)) isSubmitButtonEnabled = false queryHint = getString(R.string.search) @@ -185,7 +195,7 @@ class MainActivity : SimpleActivity() { }) } - MenuItemCompat.setOnActionExpandListener(searchMenuItem, object : MenuItemCompat.OnActionExpandListener { + MenuItemCompat.setOnActionExpandListener(mSearchMenuItem, object : MenuItemCompat.OnActionExpandListener { override fun onMenuItemActionExpand(item: MenuItem?): Boolean { isSearchOpen = true main_dialpad_button.beGone() @@ -254,7 +264,7 @@ class MainActivity : SimpleActivity() { updateBottomTabItemColors(inactiveView, false) } - val bottomBarColor = getBottomTabsBackgroundColor() + val bottomBarColor = getBottomNavigationBackgroundColor() main_tabs_holder.setBackgroundColor(bottomBarColor) updateNavigationBarColor(bottomBarColor) } @@ -264,11 +274,7 @@ class MainActivity : SimpleActivity() { private fun initFragments() { view_pager.offscreenPageLimit = 2 view_pager.addOnPageChangeListener(object : ViewPager.OnPageChangeListener { - override fun onPageScrollStateChanged(state: Int) { - if (state == ViewPager.SCROLL_STATE_SETTLING) { - closeSearch() - } - } + override fun onPageScrollStateChanged(state: Int) {} override fun onPageScrolled(position: Int, positionOffset: Float, positionOffsetPixels: Int) {} @@ -277,7 +283,7 @@ class MainActivity : SimpleActivity() { getAllFragments().forEach { it?.finishActMode() } - invalidateOptionsMenu() + refreshMenuItems() } }) @@ -296,7 +302,7 @@ class MainActivity : SimpleActivity() { } main_tabs_holder.getTabAt(wantedTab)?.select() - invalidateOptionsMenu() + refreshMenuItems() }, 100L) } @@ -304,6 +310,10 @@ class MainActivity : SimpleActivity() { launchDialpad() } + view_pager.onGlobalLayout { + refreshMenuItems() + } + if (config.openDialPadAtLaunch && !launchedDialer) { launchDialpad() launchedDialer = true @@ -497,7 +507,7 @@ class MainActivity : SimpleActivity() { getAllFragments().forEach { it?.onSearchQueryChanged("") } - searchMenuItem?.collapseActionView() + mSearchMenuItem?.collapseActionView() } } diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ManageSpeedDialActivity.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ManageSpeedDialActivity.kt index 4e9aa01b..ab864cbf 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ManageSpeedDialActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/ManageSpeedDialActivity.kt @@ -3,6 +3,7 @@ package com.simplemobiletools.dialer.activities import android.os.Bundle import com.google.gson.Gson import com.simplemobiletools.commons.extensions.updateTextColors +import com.simplemobiletools.commons.helpers.NavigationIcon import com.simplemobiletools.commons.helpers.SimpleContactsHelper import com.simplemobiletools.commons.models.SimpleContact import com.simplemobiletools.dialer.R @@ -30,6 +31,11 @@ class ManageSpeedDialActivity : SimpleActivity(), RemoveSpeedDialListener { updateTextColors(manage_speed_dial_scrollview) } + override fun onResume() { + super.onResume() + setupToolbar(manage_speed_dial_toolbar, NavigationIcon.Arrow) + } + override fun onStop() { super.onStop() config.speedDial = Gson().toJson(speedDialValues) diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/SettingsActivity.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/SettingsActivity.kt index 61e06404..1bc55438 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/activities/SettingsActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/activities/SettingsActivity.kt @@ -25,6 +25,7 @@ class SettingsActivity : SimpleActivity() { override fun onResume() { super.onResume() + setupToolbar(settings_toolbar, NavigationIcon.Arrow) setupPurchaseThankYou() setupCustomizeColors() @@ -42,7 +43,6 @@ class SettingsActivity : SimpleActivity() { setupDisableProximitySensor() setupDisableSwipeToAnswer() updateTextColors(settings_holder) - invalidateOptionsMenu() arrayOf( settings_color_customization_label, diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ChangeSortingDialog.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ChangeSortingDialog.kt index 628d97d7..ef309efb 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ChangeSortingDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ChangeSortingDialog.kt @@ -3,6 +3,7 @@ package com.simplemobiletools.dialer.dialogs import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.activities.BaseSimpleActivity import com.simplemobiletools.commons.extensions.beGoneIf +import com.simplemobiletools.commons.extensions.getAlertDialogBuilder import com.simplemobiletools.commons.extensions.setupDialogStuff import com.simplemobiletools.commons.helpers.SORT_BY_CUSTOM import com.simplemobiletools.commons.helpers.SORT_BY_DATE_CREATED @@ -23,10 +24,10 @@ class ChangeSortingDialog( private var view = activity.layoutInflater.inflate(R.layout.dialog_change_sorting, null) init { - AlertDialog.Builder(activity) + activity.getAlertDialogBuilder() .setPositiveButton(R.string.ok) { dialog, which -> dialogConfirmed() } .setNegativeButton(R.string.cancel, null) - .create().apply { + .apply { activity.setupDialogStuff(view, this, R.string.sort_by) } diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ManageVisibleTabsDialog.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ManageVisibleTabsDialog.kt index f3874a1d..3b4c5d52 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ManageVisibleTabsDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ManageVisibleTabsDialog.kt @@ -1,11 +1,11 @@ package com.simplemobiletools.dialer.dialogs -import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.activities.BaseSimpleActivity +import com.simplemobiletools.commons.extensions.getAlertDialogBuilder import com.simplemobiletools.commons.extensions.setupDialogStuff +import com.simplemobiletools.commons.helpers.TAB_CALL_HISTORY import com.simplemobiletools.commons.helpers.TAB_CONTACTS import com.simplemobiletools.commons.helpers.TAB_FAVORITES -import com.simplemobiletools.commons.helpers.TAB_CALL_HISTORY import com.simplemobiletools.commons.views.MyAppCompatCheckbox import com.simplemobiletools.dialer.R import com.simplemobiletools.dialer.extensions.config @@ -27,10 +27,10 @@ class ManageVisibleTabsDialog(val activity: BaseSimpleActivity) { view.findViewById(value).isChecked = showTabs and key != 0 } - AlertDialog.Builder(activity) + activity.getAlertDialogBuilder() .setPositiveButton(R.string.ok) { dialog, which -> dialogConfirmed() } .setNegativeButton(R.string.cancel, null) - .create().apply { + .apply { activity.setupDialogStuff(view, this) } } diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectContactDialog.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectContactDialog.kt index 5dff81c2..0e881471 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectContactDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectContactDialog.kt @@ -7,7 +7,6 @@ import com.simplemobiletools.commons.models.SimpleContact import com.simplemobiletools.dialer.R import com.simplemobiletools.dialer.activities.SimpleActivity import com.simplemobiletools.dialer.adapters.ContactsAdapter -import com.simplemobiletools.dialer.extensions.config import kotlinx.android.synthetic.main.dialog_select_contact.view.* import java.util.* @@ -38,10 +37,12 @@ class SelectContactDialog(val activity: SimpleActivity, contacts: ArrayList + dialog = alertDialog + } } } } diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectSIMDialog.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectSIMDialog.kt index f9b8d981..34bbdb2c 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectSIMDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/SelectSIMDialog.kt @@ -7,6 +7,7 @@ import android.widget.RadioButton import android.widget.RadioGroup import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.activities.BaseSimpleActivity +import com.simplemobiletools.commons.extensions.getAlertDialogBuilder import com.simplemobiletools.commons.extensions.setupDialogStuff import com.simplemobiletools.dialer.R import com.simplemobiletools.dialer.extensions.config @@ -35,9 +36,11 @@ class SelectSIMDialog(val activity: BaseSimpleActivity, val phoneNumber: String, radioGroup!!.addView(radioButton, RadioGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT)) } - dialog = AlertDialog.Builder(activity) - .create().apply { - activity.setupDialogStuff(view, this) + activity.getAlertDialogBuilder() + .apply { + activity.setupDialogStuff(view, this) { alertDialog -> + dialog = alertDialog + } } } diff --git a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ShowGroupedCallsDialog.kt b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ShowGroupedCallsDialog.kt index 1bf8a7ff..e369a009 100644 --- a/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ShowGroupedCallsDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/dialer/dialogs/ShowGroupedCallsDialog.kt @@ -2,6 +2,7 @@ package com.simplemobiletools.dialer.dialogs import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.activities.BaseSimpleActivity +import com.simplemobiletools.commons.extensions.getAlertDialogBuilder import com.simplemobiletools.commons.extensions.setupDialogStuff import com.simplemobiletools.dialer.R import com.simplemobiletools.dialer.activities.SimpleActivity @@ -27,9 +28,11 @@ class ShowGroupedCallsDialog(val activity: BaseSimpleActivity, callIds: ArrayLis } } - dialog = AlertDialog.Builder(activity) - .create().apply { - activity.setupDialogStuff(view, this) + activity.getAlertDialogBuilder() + .apply { + activity.setupDialogStuff(view, this) { alertDialog -> + dialog = alertDialog + } } } } diff --git a/app/src/main/res/layout/activity_conference.xml b/app/src/main/res/layout/activity_conference.xml index c3496454..f07b4385 100644 --- a/app/src/main/res/layout/activity_conference.xml +++ b/app/src/main/res/layout/activity_conference.xml @@ -1,17 +1,40 @@ - - + + + + + + + app:layout_behavior="@string/appbar_scrolling_view_behavior"> - + + + + diff --git a/app/src/main/res/layout/activity_dialpad.xml b/app/src/main/res/layout/activity_dialpad.xml index 86bc9a9d..85669f68 100644 --- a/app/src/main/res/layout/activity_dialpad.xml +++ b/app/src/main/res/layout/activity_dialpad.xml @@ -1,126 +1,149 @@ - + android:layout_height="match_parent"> - + android:layout_height="wrap_content"> - + + + + + android:layout_height="match_parent" + android:layout_alignParentBottom="true" + android:focusableInTouchMode="true" + app:layout_behavior="@string/appbar_scrolling_view_behavior"> - + - + - + - + - + - + - + - + - + + + + + + diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml index 4bddc6df..a8c50105 100644 --- a/app/src/main/res/layout/activity_main.xml +++ b/app/src/main/res/layout/activity_main.xml @@ -1,38 +1,61 @@ - - + android:layout_height="wrap_content"> - + - + + + android:layout_height="match_parent" + app:layout_behavior="@string/appbar_scrolling_view_behavior"> - + + + + + + + + diff --git a/app/src/main/res/layout/activity_manage_speed_dial.xml b/app/src/main/res/layout/activity_manage_speed_dial.xml index 2c609f16..ae6d04e7 100644 --- a/app/src/main/res/layout/activity_manage_speed_dial.xml +++ b/app/src/main/res/layout/activity_manage_speed_dial.xml @@ -1,33 +1,55 @@ - + android:layout_height="match_parent"> - + + + + + + + app:layout_behavior="@string/appbar_scrolling_view_behavior"> - - - + android:layout_height="wrap_content" + android:orientation="vertical" + tools:ignore="HardcodedText"> - - + + + + + + + diff --git a/app/src/main/res/layout/activity_settings.xml b/app/src/main/res/layout/activity_settings.xml index 00ad5a09..4696282a 100644 --- a/app/src/main/res/layout/activity_settings.xml +++ b/app/src/main/res/layout/activity_settings.xml @@ -1,334 +1,357 @@ - + android:layout_height="match_parent"> - + + + + + + - - + app:layout_behavior="@string/appbar_scrolling_view_behavior"> - + android:text="@string/color_customization" /> - + + + android:background="@drawable/ripple_all_corners"> - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + diff --git a/app/src/main/res/menu/menu_dialpad.xml b/app/src/main/res/menu/menu_dialpad.xml index 2221c30f..21a849ac 100644 --- a/app/src/main/res/menu/menu_dialpad.xml +++ b/app/src/main/res/menu/menu_dialpad.xml @@ -5,5 +5,5 @@ android:id="@+id/add_number_to_contact" android:icon="@drawable/ic_plus_vector" android:title="@string/add_number_to_contact" - app:showAsAction="ifRoom" /> + app:showAsAction="always" />