Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies to the newer versions #242

Merged
merged 8 commits into from
Jan 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .fvm/fvm_config.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"flutterSdkVersion": "2.10.3",
"flutterSdkVersion": "3.7.12",
"flavors": {}
}
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ android {
if (System.getenv("ANDROID_NDK_HOME") != null) {
ndkPath "$System.env.ANDROID_NDK_HOME"
}
compileSdkVersion 31
compileSdkVersion 33

sourceSets {
main.java.srcDirs += 'src/main/kotlin'
Expand Down Expand Up @@ -101,7 +101,7 @@ def coroutinesVersion = "1.6.0"
def lifecycleVersion = "2.2.0"
def timberVersion = "4.7.1"
def androidxCoreVersion = '1.3.2'
def daggerVersion = '2.41'
def daggerVersion = '2.50'
def workManagerVersion = '2.4.0'
def okioVersion = '2.4.0'
def serializationJsonVersion = '1.3.2'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ class NotificationsFlutterBridge @Inject constructor(
val activeNotifs: MutableMap<UUID, StatusBarNotification> = mutableMapOf()

private val notifUtils = object : Pigeons.NotificationUtils {
override fun openNotification(arg: Pigeons.StringWrapper?) {
override fun openNotification(arg: Pigeons.StringWrapper) {
val id = UUID.fromString(arg?.value)
activeNotifs[id]?.notification?.contentIntent?.send()
}

override fun executeAction(arg: Pigeons.NotifActionExecuteReq?) {
override fun executeAction(arg: Pigeons.NotifActionExecuteReq) {
if (arg != null) {
val id = UUID.fromString(arg.itemId)
val action = activeNotifs[id]?.notification?.let { NotificationCompat.getAction(it, arg.actionId!!.toInt()) }
Expand All @@ -64,16 +64,16 @@ class NotificationsFlutterBridge @Inject constructor(
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
val bundle = Bundle()
bundle.putString(key, arg.responseText)
RemoteInput.addResultsToIntent(action?.remoteInputs, intent, bundle)
action?.actionIntent.send(context, 0, intent)
RemoteInput.addResultsToIntent(action?.remoteInputs!!, intent, bundle)
action?.actionIntent?.send(context, 0, intent)
return
}
}
action?.actionIntent?.send()
}
}

override fun dismissNotificationWatch(arg: Pigeons.StringWrapper?) {
override fun dismissNotificationWatch(arg: Pigeons.StringWrapper) {
val id = UUID.fromString(arg?.value)
val command = BlobCommand.DeleteCommand(Random.nextInt(0, UShort.MAX_VALUE.toInt()).toUShort(), BlobCommand.BlobDatabase.Notification, SUUID(StructMapper(), id).toBytes())
GlobalScope.launch {
Expand All @@ -86,7 +86,7 @@ class NotificationsFlutterBridge @Inject constructor(
}
}

override fun dismissNotification(arg: Pigeons.StringWrapper?, result: Pigeons.Result<Pigeons.BooleanWrapper>?) {
override fun dismissNotification(arg: Pigeons.StringWrapper, result: Pigeons.Result<Pigeons.BooleanWrapper>?) {
if (arg != null) {
val id = UUID.fromString(arg.value)
try {
Expand Down Expand Up @@ -204,4 +204,4 @@ class NotificationsFlutterBridge @Inject constructor(
pigeon.channelDesc = desc
notifListening?.updateChannel(pigeon) {}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -100,14 +100,14 @@ class TimelineControlFlutterBridge @Inject constructor(
)).responseValue
}

override fun addPin(pin: Pigeons.TimelinePinPigeon?, result: Pigeons.Result<Pigeons.NumberWrapper>?) {
override fun addPin(pin: Pigeons.TimelinePinPigeon, result: Pigeons.Result<Pigeons.NumberWrapper>?) {
coroutineScope.launchPigeonResult(result!!, coroutineScope.coroutineContext) {
val res = addTimelinePin(pin!!)
NumberWrapper(res.value.toInt())
}
}

override fun removePin(pinUuid: Pigeons.StringWrapper?, result: Pigeons.Result<Pigeons.NumberWrapper>?) {
override fun removePin(pinUuid: Pigeons.StringWrapper, result: Pigeons.Result<Pigeons.NumberWrapper>?) {
coroutineScope.launchPigeonResult(result!!, coroutineScope.coroutineContext) {
val res = removeTimelinePin(UUID.fromString(pinUuid?.value!!))
NumberWrapper(res.value.toInt())
Expand All @@ -122,4 +122,4 @@ class TimelineControlFlutterBridge @Inject constructor(
}

}
}
}
Loading
Loading