Skip to content

Commit

Permalink
Merge branch 'main' into v2
Browse files Browse the repository at this point in the history
  • Loading branch information
natsuk4ze authored Aug 8, 2023
2 parents 54b14b4 + b30fc69 commit 336d785
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 32 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,8 @@ jobs:
key: avd-${{ matrix.api-level }}

- name: Create AVD and generate snapshot for caching
if: steps.avd-cache.outputs.cache-hit != 'true'
if: steps.avd-cache.outputs.cache-hit != 'true' && github.ref == 'refs/heads/main'
timeout-minutes: 10
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.api-level }}
Expand All @@ -119,6 +120,7 @@ jobs:
- name: Run integration tests
id: Run-integration-tests
continue-on-error: true
timeout-minutes: 10
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.api-level }}
Expand All @@ -135,6 +137,7 @@ jobs:
- name: Retry integration tests
id: Retry-integration-tests
continue-on-error: true
timeout-minutes: 10
if: steps.Run-integration-tests.outcome == 'failure'
uses: reactivecircus/android-emulator-runner@v2
with:
Expand All @@ -155,6 +158,7 @@ jobs:
- name: Re:Retry integration tests
if: steps.Retry-integration-tests.outcome == 'failure'
timeout-minutes: 10
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: ${{ matrix.api-level }}
Expand Down
36 changes: 7 additions & 29 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ migrate_working_dir/
*.iws
.idea/

.vscode/

# Flutter/Dart/Pub related
# Libraries should not include pubspec.lock, per https://dart.dev/guides/libraries/private-files#pubspeclock.
pubspec.lock
Expand All @@ -32,10 +30,9 @@ build/
# Android related
*.iml
.gradle
/local.properties
local.properties
/.idea/workspace.xml
/.idea/libraries
/build
/captures
.cxx
/android/app/release
Expand All @@ -54,16 +51,11 @@ key.properties
.vagrant/
.sconsign.dblite
.svn/

.DS_Store
*.swp
profile

DerivedData/
build/
GeneratedPluginRegistrant.h
GeneratedPluginRegistrant.m

.generated/

*.pbxuser
Expand All @@ -86,38 +78,24 @@ Icon?
.tags*

**/Flutter/Generated.xcconfig
/Flutter/ephemeral/
**/Flutter/flutter_export_environment.sh
**/dgph
*.mode1v3
*.mode2v3
*.moved-aside
*.pbxuser
*.perspectivev3
**/*sync/
ios/Flutter/ephemeral/
.sconsign.dblite
.tags*
**/.vagrant/
**/DerivedData/
Icon?
**/Pods/
**/.symlinks/
profile
xcuserdata
**/.generated/
Flutter/App.framework
Flutter/Flutter.framework

App.framework
Flutter.framework
Flutter.podspec
Generated.xcconfig
Flutter/ephemeral/
flutter_export_environment.sh
Runner/GeneratedPluginRegistrant.*

# Exceptions to above rules.
!default.mode1v3
!default.mode2v3
!default.pbxuser
!default.perspectivev3
ServiceDefinitions.json
GeneratedPluginRegistrant.*

# Example related
**/doc/api/
Expand Down
6 changes: 4 additions & 2 deletions android/src/main/java/studio/midoridesign/gal/GalPlugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,9 @@ public void onMethodCall(@NonNull MethodCall call, @NonNull Result result) {
new Thread(() -> {
try {
putMedia(pluginBinding.getApplicationContext(),
(String) call.argument("path"), (String) call.argument("album"),
call.argument("path"), call.argument("album"),
call.method.contains("Image"));

new Handler(Looper.getMainLooper()).post(() -> result.success(null));
} catch (Exception e) {
handleError(e, result);
Expand All @@ -79,7 +80,8 @@ public void onMethodCall(@NonNull MethodCall call, @NonNull Result result) {
new Thread(() -> {
try {
putMediaBytes(pluginBinding.getApplicationContext(),
(byte[]) call.argument("bytes"), (String) call.argument("album"));
call.argument("bytes"), call.argument("album"));

new Handler(Looper.getMainLooper()).post(() -> result.success(null));
} catch (Exception e) {
handleError(e, result);
Expand Down

0 comments on commit 336d785

Please sign in to comment.