From 155ffa8198fcddf41ed38351991b2abb97823193 Mon Sep 17 00:00:00 2001 From: pichillilorenzo Date: Fri, 14 Sep 2018 02:21:51 +0200 Subject: [PATCH] first commit --- .gitignore | 8 + .idea/codeStyles/Project.xml | 29 + .idea/libraries/Dart_SDK.xml | 19 + .idea/libraries/Flutter_Plugins.xml | 9 + .idea/libraries/Flutter_for_Android.xml | 9 + .idea/misc.xml | 29 + .idea/modules.xml | 9 + .../example_lib_main_dart.xml | 6 + .idea/workspace.xml | 777 +++++++++++++ CHANGELOG.md | 3 + LICENSE | 15 + README.md | 239 ++++ android/.gitignore | 8 + android/build.gradle | 34 + android/gradle.properties | 1 + android/settings.gradle | 1 + android/src/main/AndroidManifest.xml | 6 + .../flutter_inappbrowser/InAppBrowser.java | 934 +++++++++++++++ .../InAppBrowserClient.java | 231 ++++ .../InAppBrowserDialog.java | 53 + .../res/drawable-hdpi/ic_action_next_item.png | Bin 0 -> 593 bytes .../drawable-hdpi/ic_action_previous_item.png | Bin 0 -> 599 bytes .../res/drawable-hdpi/ic_action_remove.png | Bin 0 -> 438 bytes .../res/drawable-mdpi/ic_action_next_item.png | Bin 0 -> 427 bytes .../drawable-mdpi/ic_action_previous_item.png | Bin 0 -> 438 bytes .../res/drawable-mdpi/ic_action_remove.png | Bin 0 -> 328 bytes .../drawable-xhdpi/ic_action_next_item.png | Bin 0 -> 727 bytes .../ic_action_previous_item.png | Bin 0 -> 744 bytes .../res/drawable-xhdpi/ic_action_remove.png | Bin 0 -> 536 bytes .../drawable-xxhdpi/ic_action_next_item.png | Bin 0 -> 1021 bytes .../ic_action_previous_item.png | Bin 0 -> 1038 bytes .../res/drawable-xxhdpi/ic_action_remove.png | Bin 0 -> 681 bytes example/.gitignore | 71 ++ example/.metadata | 8 + example/README.md | 8 + example/android/app/build.gradle | 61 + .../android/app/src/main/AndroidManifest.xml | 39 + .../flutterwebviewexample/MainActivity.java | 13 + .../main/res/drawable/launch_background.xml | 12 + .../src/main/res/mipmap-hdpi/ic_launcher.png | Bin 0 -> 544 bytes .../src/main/res/mipmap-mdpi/ic_launcher.png | Bin 0 -> 442 bytes .../src/main/res/mipmap-xhdpi/ic_launcher.png | Bin 0 -> 721 bytes .../main/res/mipmap-xxhdpi/ic_launcher.png | Bin 0 -> 1031 bytes .../main/res/mipmap-xxxhdpi/ic_launcher.png | Bin 0 -> 1443 bytes .../app/src/main/res/values/styles.xml | 8 + example/android/build.gradle | 29 + example/android/gradle.properties | 1 + .../gradle/wrapper/gradle-wrapper.properties | 6 + example/android/settings.gradle | 15 + example/ios/Flutter/AppFrameworkInfo.plist | 26 + example/ios/Flutter/Debug.xcconfig | 3 + example/ios/Flutter/Release.xcconfig | 2 + example/ios/Podfile | 69 ++ example/ios/Runner.xcodeproj/project.pbxproj | 502 ++++++++ .../contents.xcworkspacedata | 7 + .../xcshareddata/xcschemes/Runner.xcscheme | 93 ++ .../contents.xcworkspacedata | 10 + .../xcshareddata/IDEWorkspaceChecks.plist | 8 + example/ios/Runner/AppDelegate.swift | 13 + .../AppIcon.appiconset/Contents.json | 122 ++ .../Icon-App-1024x1024@1x.png | Bin 0 -> 11112 bytes .../AppIcon.appiconset/Icon-App-20x20@1x.png | Bin 0 -> 564 bytes .../AppIcon.appiconset/Icon-App-20x20@2x.png | Bin 0 -> 1283 bytes .../AppIcon.appiconset/Icon-App-20x20@3x.png | Bin 0 -> 1588 bytes .../AppIcon.appiconset/Icon-App-29x29@1x.png | Bin 0 -> 1025 bytes .../AppIcon.appiconset/Icon-App-29x29@2x.png | Bin 0 -> 1716 bytes .../AppIcon.appiconset/Icon-App-29x29@3x.png | Bin 0 -> 1920 bytes .../AppIcon.appiconset/Icon-App-40x40@1x.png | Bin 0 -> 1283 bytes .../AppIcon.appiconset/Icon-App-40x40@2x.png | Bin 0 -> 1895 bytes .../AppIcon.appiconset/Icon-App-40x40@3x.png | Bin 0 -> 2665 bytes .../AppIcon.appiconset/Icon-App-60x60@2x.png | Bin 0 -> 2665 bytes .../AppIcon.appiconset/Icon-App-60x60@3x.png | Bin 0 -> 3831 bytes .../AppIcon.appiconset/Icon-App-76x76@1x.png | Bin 0 -> 1888 bytes .../AppIcon.appiconset/Icon-App-76x76@2x.png | Bin 0 -> 3294 bytes .../Icon-App-83.5x83.5@2x.png | Bin 0 -> 3612 bytes .../LaunchImage.imageset/Contents.json | 23 + .../LaunchImage.imageset/LaunchImage.png | Bin 0 -> 68 bytes .../LaunchImage.imageset/LaunchImage@2x.png | Bin 0 -> 68 bytes .../LaunchImage.imageset/LaunchImage@3x.png | Bin 0 -> 68 bytes .../LaunchImage.imageset/README.md | 5 + .../Runner/Base.lproj/LaunchScreen.storyboard | 37 + example/ios/Runner/Base.lproj/Main.storyboard | 26 + example/ios/Runner/Info.plist | 45 + example/ios/Runner/Runner-Bridging-Header.h | 1 + example/lib/main.dart | 76 ++ example/pubspec.yaml | 70 ++ flutter_inappbrowser.iml | 20 + flutter_inappbrowser_android.iml | 30 + ios/.gitignore | 36 + ios/Assets/.gitkeep | 0 ios/Classes/InAppBrowser.h | 23 + ios/Classes/InAppBrowser.m | 25 + ios/Classes/SwiftFlutterPlugin.swift | 1034 +++++++++++++++++ ios/flutter_inappbrowser.podspec | 21 + lib/flutter_inappbrowser.dart | 200 ++++ pubspec.yaml | 52 + 96 files changed, 5270 insertions(+) create mode 100644 .gitignore create mode 100644 .idea/codeStyles/Project.xml create mode 100644 .idea/libraries/Dart_SDK.xml create mode 100644 .idea/libraries/Flutter_Plugins.xml create mode 100644 .idea/libraries/Flutter_for_Android.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/runConfigurations/example_lib_main_dart.xml create mode 100644 .idea/workspace.xml create mode 100644 CHANGELOG.md create mode 100644 LICENSE create mode 100644 README.md create mode 100644 android/.gitignore create mode 100644 android/build.gradle create mode 100644 android/gradle.properties create mode 100644 android/settings.gradle create mode 100644 android/src/main/AndroidManifest.xml create mode 100644 android/src/main/java/com/pichillilorenzo/flutter_inappbrowser/InAppBrowser.java create mode 100644 android/src/main/java/com/pichillilorenzo/flutter_inappbrowser/InAppBrowserClient.java create mode 100644 android/src/main/java/com/pichillilorenzo/flutter_inappbrowser/InAppBrowserDialog.java create mode 100755 android/src/main/res/drawable-hdpi/ic_action_next_item.png create mode 100755 android/src/main/res/drawable-hdpi/ic_action_previous_item.png create mode 100755 android/src/main/res/drawable-hdpi/ic_action_remove.png create mode 100755 android/src/main/res/drawable-mdpi/ic_action_next_item.png create mode 100755 android/src/main/res/drawable-mdpi/ic_action_previous_item.png create mode 100755 android/src/main/res/drawable-mdpi/ic_action_remove.png create mode 100755 android/src/main/res/drawable-xhdpi/ic_action_next_item.png create mode 100755 android/src/main/res/drawable-xhdpi/ic_action_previous_item.png create mode 100755 android/src/main/res/drawable-xhdpi/ic_action_remove.png create mode 100755 android/src/main/res/drawable-xxhdpi/ic_action_next_item.png create mode 100755 android/src/main/res/drawable-xxhdpi/ic_action_previous_item.png create mode 100755 android/src/main/res/drawable-xxhdpi/ic_action_remove.png create mode 100644 example/.gitignore create mode 100644 example/.metadata create mode 100644 example/README.md create mode 100644 example/android/app/build.gradle create mode 100644 example/android/app/src/main/AndroidManifest.xml create mode 100644 example/android/app/src/main/java/com/pichillilorenzo/flutterwebviewexample/MainActivity.java create mode 100644 example/android/app/src/main/res/drawable/launch_background.xml create mode 100644 example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png create mode 100644 example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png create mode 100644 example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png create mode 100644 example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png create mode 100644 example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png create mode 100644 example/android/app/src/main/res/values/styles.xml create mode 100644 example/android/build.gradle create mode 100644 example/android/gradle.properties create mode 100644 example/android/gradle/wrapper/gradle-wrapper.properties create mode 100644 example/android/settings.gradle create mode 100644 example/ios/Flutter/AppFrameworkInfo.plist create mode 100644 example/ios/Flutter/Debug.xcconfig create mode 100644 example/ios/Flutter/Release.xcconfig create mode 100644 example/ios/Podfile create mode 100644 example/ios/Runner.xcodeproj/project.pbxproj create mode 100644 example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme create mode 100644 example/ios/Runner.xcworkspace/contents.xcworkspacedata create mode 100644 example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist create mode 100644 example/ios/Runner/AppDelegate.swift create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png create mode 100644 example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png create mode 100644 example/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json create mode 100644 example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png create mode 100644 example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png create mode 100644 example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png create mode 100644 example/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md create mode 100644 example/ios/Runner/Base.lproj/LaunchScreen.storyboard create mode 100644 example/ios/Runner/Base.lproj/Main.storyboard create mode 100644 example/ios/Runner/Info.plist create mode 100644 example/ios/Runner/Runner-Bridging-Header.h create mode 100644 example/lib/main.dart create mode 100644 example/pubspec.yaml create mode 100644 flutter_inappbrowser.iml create mode 100644 flutter_inappbrowser_android.iml create mode 100644 ios/.gitignore create mode 100644 ios/Assets/.gitkeep create mode 100644 ios/Classes/InAppBrowser.h create mode 100644 ios/Classes/InAppBrowser.m create mode 100644 ios/Classes/SwiftFlutterPlugin.swift create mode 100644 ios/flutter_inappbrowser.podspec create mode 100644 lib/flutter_inappbrowser.dart create mode 100644 pubspec.yaml diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..7ecebb44 --- /dev/null +++ b/.gitignore @@ -0,0 +1,8 @@ +.DS_Store +.dart_tool/ + +.packages +.pub/ +pubspec.lock + +build/ diff --git a/.idea/codeStyles/Project.xml b/.idea/codeStyles/Project.xml new file mode 100644 index 00000000..30aa626c --- /dev/null +++ b/.idea/codeStyles/Project.xml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/libraries/Dart_SDK.xml b/.idea/libraries/Dart_SDK.xml new file mode 100644 index 00000000..f376a57a --- /dev/null +++ b/.idea/libraries/Dart_SDK.xml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/libraries/Flutter_Plugins.xml b/.idea/libraries/Flutter_Plugins.xml new file mode 100644 index 00000000..53449dae --- /dev/null +++ b/.idea/libraries/Flutter_Plugins.xml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/libraries/Flutter_for_Android.xml b/.idea/libraries/Flutter_for_Android.xml new file mode 100644 index 00000000..282dba69 --- /dev/null +++ b/.idea/libraries/Flutter_for_Android.xml @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 00000000..6c6d3f4b --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,29 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 00000000..f7cd1f14 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/runConfigurations/example_lib_main_dart.xml b/.idea/runConfigurations/example_lib_main_dart.xml new file mode 100644 index 00000000..5fd9159d --- /dev/null +++ b/.idea/runConfigurations/example_lib_main_dart.xml @@ -0,0 +1,6 @@ + + + + \ No newline at end of file diff --git a/.idea/workspace.xml b/.idea/workspace.xml new file mode 100644 index 00000000..d3843bf0 --- /dev/null +++ b/.idea/workspace.xml @@ -0,0 +1,777 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Resource + (0) + closeDi + hide() + loadUrl + showWebPage + InAppBrowserClient + LOG. + preferences + getPre + client + webView + result.s + result + Client + LOAD_START_EVENT + loadstop + JSONO + closeDialog + LOAD_STOP_EVENT + com.pichillilorenzo.flutterwebview + flutter_webview + show + SELF + customscheme + EXIT + injectScriptCode + injectDeferredObject + sourceFile + + + activity.getPreferences(0) + Log. + com.pichillilorenzo.flutter_inappbrowser + flutter_inappbrowser + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +