-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from ptrLx/dev
feature for image import, new screenshots
- Loading branch information
Showing
28 changed files
with
182 additions
and
71 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,3 +16,5 @@ local.properties | |
*.code-workspace | ||
/app/release/* | ||
sample-database.zip | ||
todo.md | ||
thomas-sample-img |
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,20 @@ | ||
# Changelog | ||
|
||
## [1.1.0] - 2023-03-15 | ||
|
||
### New features | ||
|
||
* Added feature for image import (only via copy) | ||
* New Screenshots of updated UI with new sample pictures | ||
|
||
## [1.0.0] - 2023-02-20 | ||
|
||
Initial release including: | ||
|
||
* Implementation of base application in Kotlin and UI in Jetpack Compose: | ||
* Request for folder permission | ||
* CRUD for capture image, happiness, diary | ||
* Flashbacks, diary view, calendar view and streak-count | ||
* Room database storage and data export to JSON | ||
* Dark- / light theme aligned with system design | ||
* App Logo v1 |
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
31 changes: 31 additions & 0 deletions
31
...n/java/de/ptrlx/oneshot/feature_diary/presentation/diary/components/common/ImportImage.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,31 @@ | ||
package de.ptrlx.oneshot.feature_diary.presentation.diary.components.common | ||
|
||
import androidx.activity.compose.rememberLauncherForActivityResult | ||
import androidx.activity.result.contract.ActivityResultContracts | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.Modifier | ||
import de.ptrlx.oneshot.feature_diary.presentation.diary.DiaryEvent | ||
import de.ptrlx.oneshot.feature_diary.presentation.diary.DiaryViewModel | ||
|
||
@Composable | ||
fun ImportImageButton( | ||
modifier: Modifier = Modifier, | ||
viewModel: DiaryViewModel | ||
) { | ||
if (viewModel.fileManager != null) { | ||
val launcher = | ||
rememberLauncherForActivityResult(ActivityResultContracts.GetContent()) { | ||
it?.let { | ||
viewModel.onEvent(DiaryEvent.ImageImport(it)) | ||
} | ||
} | ||
|
||
RoundedButton( | ||
modifier = modifier, | ||
text = "Import image", | ||
onClick = { | ||
launcher.launch("image/*") | ||
} | ||
) | ||
} | ||
} |
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
Oops, something went wrong.