Move back to alarmmanager for events update, add xiaomi warning

This commit is contained in:
Tommaso Berlose
2020-05-05 19:38:24 +02:00
parent f5c4ee7eb0
commit f13cee24d5
100 changed files with 525 additions and 205 deletions

View File

@ -20,7 +20,9 @@ object BitmapHelper {
view.measure(measuredWidth, measuredHeight)
return try {
Log.d("ciao", "bitmap ${view.measuredWidth}, ${view.measuredHeight} - draw = ${draw}")
if (draw) {
Log.d("ciao", "bitmap ${view.measuredWidth}, ${view.measuredHeight}")
}
val btm = Bitmap.createBitmap(
view.measuredWidth,
view.measuredHeight,

View File

@ -10,7 +10,6 @@ import com.tommasoberlose.anotherwidget.db.EventRepository
import com.tommasoberlose.anotherwidget.models.Event
import com.tommasoberlose.anotherwidget.global.Preferences
import com.tommasoberlose.anotherwidget.receivers.UpdatesReceiver
import com.tommasoberlose.anotherwidget.services.UpdatesWorker
import com.tommasoberlose.anotherwidget.ui.activities.MainActivity
import com.tommasoberlose.anotherwidget.ui.widgets.MainWidget
import com.tommasoberlose.anotherwidget.utils.checkGrantedPermission
@ -125,7 +124,7 @@ object CalendarHelper {
eventRepository.resetNextEventData()
}
UpdatesWorker.setUpdates(context)
UpdatesReceiver.setUpdates(context)
Log.d("ciao", "force update? 7")
MainWidget.updateWidget(context)

View File

@ -95,7 +95,6 @@ object IntentHelper {
return when (Preferences.openEventDetails || forceEventDetails) {
true -> {
val uri = ContentUris.withAppendedId(Events.CONTENT_URI, e.eventID)
if (Preferences.calendarAppPackage == "") {
Intent(Intent.ACTION_VIEW).apply {
data = uri