Merge remote-tracking branch 'ns/dev' into wear

This commit is contained in:
Milos Kozak 2022-04-25 18:38:48 +02:00
commit 416f512a52
15 changed files with 26 additions and 23 deletions

View file

@ -57,7 +57,7 @@
<activity
android:name=".widget.WidgetConfigureActivity"
android:theme="@android:style/Theme.Material.Dialog.NoActionBar"
android:exported="true">
android:exported="false">
<intent-filter>
<action android:name="android.appwidget.action.APPWIDGET_CONFIGURE" />
</intent-filter>

View file

@ -296,6 +296,7 @@ class MainActivity : NoSplashAppCompatActivity() {
}
override fun onCreateOptionsMenu(menu: Menu): Boolean {
menu.setGroupDividerEnabled(true)
this.menu = menu
menuInflater.inflate(R.menu.menu_main, menu)
pluginPreferencesMenuItem = menu.findItem(R.id.nav_plugin_preferences)

View file

@ -59,7 +59,7 @@ class OpenAPSAMAFragment : DaggerFragment() {
setColorSchemeColors(rh.gac(context, R.attr.colorPrimaryDark), rh.gac(context, R.attr.colorPrimary), rh.gac(context, R.attr.colorSecondary))
setOnRefreshListener {
binding.lastrun.text = rh.gs(info.nightscout.androidaps.R.string.executing)
openAPSAMAPlugin.invoke("OpenAPSAMA swiperefresh", false)
Thread { openAPSAMAPlugin.invoke("OpenAPSAMA swiperefresh", false) }.start()
}
}
@ -76,7 +76,7 @@ class OpenAPSAMAFragment : DaggerFragment() {
when (item.itemId) {
ID_MENU_RUN -> {
binding.lastrun.text = rh.gs(R.string.executing)
openAPSAMAPlugin.invoke("OpenAPSAMA menu", false)
Thread { openAPSAMAPlugin.invoke("OpenAPSAMA menu", false) }.start()
true
}

View file

@ -36,6 +36,7 @@ class OpenAPSSMBFragment : DaggerFragment() {
@Inject lateinit var activePlugin: ActivePlugin
@Inject lateinit var dateUtil: DateUtil
@Inject lateinit var jsonFormatter: JSONFormatter
private lateinit var refreshDialog: Runnable
private val ID_MENU_RUN = 1
@ -58,10 +59,9 @@ class OpenAPSSMBFragment : DaggerFragment() {
setColorSchemeColors(rh.gac(context, R.attr.colorPrimaryDark), rh.gac(context, R.attr.colorPrimary), rh.gac(context, R.attr.colorSecondary))
setOnRefreshListener {
binding.lastrun.text = rh.gs(info.nightscout.androidaps.R.string.executing)
activePlugin.activeAPS.invoke("OpenAPSSMB swiperefresh", false)
Thread { activePlugin.activeAPS.invoke("OpenAPSSMB swiperefresh", false) }.start()
}
}
}
override fun onCreateOptionsMenu(menu: Menu, inflater: MenuInflater) {
@ -75,7 +75,7 @@ class OpenAPSSMBFragment : DaggerFragment() {
when (item.itemId) {
ID_MENU_RUN -> {
binding.lastrun.text = rh.gs(R.string.executing)
activePlugin.activeAPS.invoke("OpenAPSSMB menu", false)
Thread { activePlugin.activeAPS.invoke("OpenAPSSMB menu", false) }.start()
true
}

View file

@ -22,7 +22,7 @@
android:layout_marginTop="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
android:layout_gravity="center">
@ -147,7 +147,7 @@
android:layout_marginTop="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
android:layout_gravity="center">
@ -170,7 +170,7 @@
android:layout_marginTop="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
android:layout_gravity="center">
@ -323,7 +323,7 @@
android:layout_marginBottom="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
android:layout_gravity="center">

View file

@ -56,7 +56,7 @@
android:layout_marginStart="4dp"
android:layout_marginEnd="4dp"
app:cardCornerRadius="4dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
app:contentPadding="2dp">
@ -79,7 +79,7 @@
android:layout_marginTop="4dp"
android:layout_marginEnd="4dp"
app:cardCornerRadius="4dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
app:contentPadding="2dp">
@ -102,7 +102,7 @@
android:layout_marginTop="4dp"
android:layout_marginEnd="4dp"
app:cardCornerRadius="4dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
app:contentPadding="2dp">

View file

@ -11,7 +11,7 @@
android:layout_marginStart="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
android:layout_gravity="center">
<LinearLayout

View file

@ -11,7 +11,7 @@
android:layout_marginTop="16dp"
android:layout_marginEnd="16dp"
app:cardCornerRadius="4dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="true"
app:contentPadding="16dp"
android:layout_gravity="center">

View file

@ -10,7 +10,7 @@
android:layout_marginStart="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="true"
android:layout_gravity="center">

View file

@ -44,6 +44,7 @@
android:orderInCategory="1"
app:showAsAction="never"
android:title="@string/nav_profilehelper" />
<group android:id="@+id/about_exit">
<item
android:id="@+id/nav_about"
android:orderInCategory="1"
@ -54,5 +55,5 @@
android:orderInCategory="1"
app:showAsAction="never"
android:title="@string/nav_exit" />
</group>
</menu>

View file

@ -12,7 +12,7 @@
android:layout_marginTop="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
android:layout_gravity="center">

View file

@ -10,7 +10,7 @@
android:layout_marginStart="4dp"
app:cardCornerRadius="4dp"
app:contentPadding="2dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="true"
android:layout_gravity="center">

View file

@ -16,7 +16,8 @@
android:theme="@style/AppTheme" />
<activity
android:name="info.nightscout.androidaps.diaconn.activities.DiaconnG8BLEScanActivity"
android:theme="@style/AppTheme">
android:theme="@style/AppTheme"
android:exported="false">
<intent-filter>
<action android:name="info.nightscout.androidaps.plugins.PumpDiaconnG8.activities.DiaconnG8BLEScanActivity" />
<category android:name="android.intent.category.DEFAULT" />

View file

@ -9,7 +9,7 @@
android:layout_gravity="center"
android:layout_marginStart="4dp"
app:cardCornerRadius="4dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="true"
app:contentPadding="2dp">

View file

@ -21,7 +21,7 @@
android:layout_marginTop="4dp"
android:layout_marginEnd="4dp"
app:cardCornerRadius="4dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
app:contentPadding="2dp">
@ -228,7 +228,7 @@
android:layout_marginTop="4dp"
android:layout_marginEnd="4dp"
app:cardCornerRadius="4dp"
app:cardElevation="4dp"
app:cardElevation="2dp"
app:cardUseCompatPadding="false"
app:contentPadding="2dp">