Dana: make clickable whole layout
This commit is contained in:
parent
4cea57acf6
commit
2e78566b41
2 changed files with 5 additions and 4 deletions
|
@ -109,7 +109,7 @@ class DanaFragment : DaggerFragment() {
|
|||
}
|
||||
binding.stats.setOnClickListener { startActivity(Intent(context, TDDStatsActivity::class.java)) }
|
||||
binding.userOptions.setOnClickListener { startActivity(Intent(context, DanaUserOptionsActivity::class.java)) }
|
||||
binding.btconnection.setOnClickListener {
|
||||
binding.btConnectionLayout.setOnClickListener {
|
||||
aapsLogger.debug(LTag.PUMP, "Clicked connect to pump")
|
||||
danaPump.reset()
|
||||
commandQueue.readStatus("Clicked connect to pump", null)
|
||||
|
@ -117,7 +117,7 @@ class DanaFragment : DaggerFragment() {
|
|||
if (activePlugin.activePump.pumpDescription.pumpType == PumpType.DANA_RS ||
|
||||
activePlugin.activePump.pumpDescription.pumpType == PumpType.DANA_I
|
||||
)
|
||||
binding.btconnection.setOnLongClickListener {
|
||||
binding.btConnectionLayout.setOnLongClickListener {
|
||||
activity?.let {
|
||||
OKDialog.showConfirmation(it, rh.gs(R.string.resetpairing)) {
|
||||
uel.log(Action.CLEAR_PAIRING_KEYS, Sources.Dana)
|
||||
|
@ -167,7 +167,7 @@ class DanaFragment : DaggerFragment() {
|
|||
else ->
|
||||
"{fa-bluetooth-b}"
|
||||
}
|
||||
binding.btconnection.text = pumpStatusIcon
|
||||
binding.btConnection.text = pumpStatusIcon
|
||||
pumpStatus = it.getStatus(rh)
|
||||
binding.pumpStatus.text = pumpStatus
|
||||
binding.pumpStatusLayout.visibility = (pumpStatus != "").toVisibility()
|
||||
|
|
|
@ -67,6 +67,7 @@
|
|||
android:background="@color/list_delimiter" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/bt_connection_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
@ -93,7 +94,7 @@
|
|||
tools:ignore="HardcodedText" />
|
||||
|
||||
<com.joanzapata.iconify.widget.IconTextView
|
||||
android:id="@+id/btconnection"
|
||||
android:id="@+id/bt_connection"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
|
|
Loading…
Reference in a new issue