mirror of
https://github.com/He4eT/yamf_launcher.git
synced 2026-05-05 01:47:24 +00:00
Fixed the reset button for renaming.
This commit is contained in:
parent
131acb3039
commit
ef59d905ab
2 changed files with 2 additions and 2 deletions
|
|
@ -266,7 +266,7 @@ class AppMenuActivity : AppCompatActivity(), AppMenuAdapter.OnItemClickListener,
|
||||||
oldList.forEachIndexed { index, oldItem ->
|
oldList.forEachIndexed { index, oldItem ->
|
||||||
if (newSet.contains(Pair(oldItem.first.applicationInfo.packageName, oldItem.second.second))) {
|
if (newSet.contains(Pair(oldItem.first.applicationInfo.packageName, oldItem.second.second))) {
|
||||||
val newIndex = newList.indexOfFirst { it.first.applicationInfo.packageName == oldItem.first.applicationInfo.packageName }
|
val newIndex = newList.indexOfFirst { it.first.applicationInfo.packageName == oldItem.first.applicationInfo.packageName }
|
||||||
if (oldItem.first.applicationInfo.packageName != newList[newIndex].first.applicationInfo.packageName) {
|
if (oldItem.first.componentName != newList[newIndex].first.componentName) {
|
||||||
changes.add(Change(ChangeType.UPDATE, index))
|
changes.add(Change(ChangeType.UPDATE, index))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -116,7 +116,7 @@ class AppMenuAdapter(
|
||||||
val imm = activity.getSystemService(Context.INPUT_METHOD_SERVICE) as InputMethodManager
|
val imm = activity.getSystemService(Context.INPUT_METHOD_SERVICE) as InputMethodManager
|
||||||
imm.hideSoftInputFromWindow(holder.editView.windowToken, 0)
|
imm.hideSoftInputFromWindow(holder.editView.windowToken, 0)
|
||||||
sharedPreferenceManager.resetAppName(activity, app.first.applicationInfo.packageName, app.second.second)
|
sharedPreferenceManager.resetAppName(activity, app.first.applicationInfo.packageName, app.second.second)
|
||||||
updateApp(position, app)
|
activity.updateItem(position, app)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue