mirror of
https://github.com/tateisu/SubwayTooter
synced 2025-01-26 16:56:28 +01:00
リファクタ
This commit is contained in:
parent
ef7110cbd9
commit
49ee5696d4
@ -250,14 +250,7 @@ class Column(
|
||||
|
||||
}
|
||||
|
||||
// 短い名前
|
||||
fun getColumnTypeName(context : Context, type : Int) =
|
||||
when(val item = columnTypeProcMap[type]) {
|
||||
null -> "?"
|
||||
else -> item.name(context)
|
||||
}
|
||||
|
||||
internal fun getIconId(acct : String, type : Int) =
|
||||
fun getIconId(acct : String, type : Int) =
|
||||
when(val item = columnTypeProcMap[type]) {
|
||||
null -> R.drawable.ic_info
|
||||
else -> item.iconId(acct)
|
||||
|
@ -217,7 +217,10 @@ object Action_Account {
|
||||
bAuto = true,
|
||||
message = activity.getString(
|
||||
R.string.account_picker_add_timeline_of,
|
||||
Column.getColumnTypeName(activity, type)
|
||||
when(val ctp = columnTypeProcMap[type]) {
|
||||
null -> "?"
|
||||
else -> ctp.name(activity)
|
||||
}
|
||||
)
|
||||
) { ai ->
|
||||
when(type) {
|
||||
|
Loading…
Reference in New Issue
Block a user