-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Michael Flisar
authored and
Michael Flisar
committed
Nov 19, 2024
1 parent
a007eb8
commit 74789a3
Showing
19 changed files
with
103 additions
and
88 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
.../androidMain/kotlin/com/michaelflisar/lumberjack/extensions/composeviewer/FeedbackImpl.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package com.michaelflisar.lumberjack.extensions.composeviewer | ||
|
||
import android.content.Context | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.platform.LocalContext | ||
import com.michaelflisar.lumberjack.core.L | ||
import com.michaelflisar.lumberjack.extensions.composeviewer.internal.IFeedbackProvider | ||
import com.michaelflisar.lumberjack.extensions.feedback.sendFeedback | ||
import okio.Path | ||
|
||
internal class FeedbackImpl : IFeedbackProvider { | ||
|
||
private lateinit var context: Context | ||
|
||
override fun supported() = false | ||
|
||
@Composable | ||
override fun Init() { | ||
context = LocalContext.current | ||
} | ||
|
||
override fun sendFeedback( | ||
receiver: String, | ||
attachments: List<Path> | ||
) { | ||
L.sendFeedback( | ||
context = context, | ||
receiver = receiver, | ||
attachments = attachments.map { it.toFile() } | ||
) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
...otlin/com/michaelflisar/lumberjack/extensions/composeviewer/internal/IFeedbackProvider.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.michaelflisar.lumberjack.extensions.composeviewer.internal | ||
|
||
import androidx.compose.runtime.Composable | ||
import okio.Path | ||
|
||
internal interface IFeedbackProvider { | ||
|
||
fun supported(): Boolean | ||
|
||
@Composable | ||
fun Init() | ||
|
||
fun sendFeedback(receiver: String, attachments: List<Path>) | ||
} |
22 changes: 22 additions & 0 deletions
22
.../src/jvmMain/kotlin/com/michaelflisar/lumberjack/extensions/composeviewer/FeedbackImpl.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package com.michaelflisar.lumberjack.extensions.composeviewer | ||
|
||
import androidx.compose.runtime.Composable | ||
import com.michaelflisar.lumberjack.extensions.composeviewer.internal.IFeedbackProvider | ||
import okio.Path | ||
|
||
internal class FeedbackImpl : IFeedbackProvider { | ||
|
||
override fun supported() = false | ||
|
||
@Composable | ||
override fun Init() { | ||
// empty | ||
} | ||
|
||
override fun sendFeedback( | ||
receiver: String, | ||
attachments: List<Path> | ||
) { | ||
// empty | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters