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

Incompatible with cordova-plugin-kiosk 0.2 #266

Open
JoseGeorges8 opened this issue Aug 7, 2019 · 0 comments
Open

Incompatible with cordova-plugin-kiosk 0.2 #266

JoseGeorges8 opened this issue Aug 7, 2019 · 0 comments

Comments

@JoseGeorges8
Copy link

Expected Behaviour

Open third party app while on kiosk mode

Actual Behaviour

Does not launch

Steps to Reproduce

Try to open a file while using this plugin https://github.com/hkalina/cordova-plugin-kiosk

Platform and Version (eg. Android 5.0 or iOS 9.2.1)

Android 6.0.1

(Android) What device vendor (e.g. Samsung, HTC, Sony...)

Cordova CLI info

cordova info

Here is the output:

cordova-lib@9.0.1 with:
  cordova-common@3.2.0
  cordova-create@2.0.0
  cordova-fetch@2.0.1
  cordova-serve@3.0.0

Environment: 
  OS: darwin
  Node: v10.15.0
  npm: 6.10.1

Plugins:
  com-sarriaroman-photoviewer
  com.moust.cordova.videoplayer
  cordova-plugin-android-permissions
  cordova-plugin-app-version
  cordova-plugin-device
  cordova-plugin-dialogs
  cordova-plugin-document-viewer
  cordova-plugin-fcm-with-dependecy-updated
  cordova-plugin-file
  cordova-plugin-file-opener2
  cordova-plugin-file-transfer
  cordova-plugin-filechooser
  cordova-plugin-inappbrowser
  cordova-plugin-insomnia
  cordova-plugin-ionic-keyboard
  cordova-plugin-ionic-webview
  cordova-plugin-kiosk
  cordova-plugin-native-keyboard
  cordova-plugin-splashscreen
  cordova-plugin-statusbar
  cordova-plugin-streaming-media
  cordova-plugin-video-editor
  cordova-plugin-whitelist
  cordova-sqlite-storage

Android platform:
  *************************************************************************
  The "android" command is deprecated.
  For manual SDK, AVD, and project management, please use Android Studio.
  For command-line tools, use tools/bin/sdkmanager and tools/bin/avdmanager
  *************************************************************************

  Available Android targets:==============] 100% Fetch remote repository...       
  ----------
  id: 1 or "android-22"
       Name: Android API 22
       Type: Platform
       API level: 22
       Revision: 2
  ----------
  id: 2 or "android-25"
       Name: Android API 25
       Type: Platform
       API level: 25
       Revision: 3
  ----------
  id: 3 or "android-26"
       Name: Android API 26
       Type: Platform
       API level: 26
       Revision: 2
  ----------
  id: 4 or "android-27"
       Name: Android API 27
       Type: Platform
       API level: 27
       Revision: 3
  ----------
  id: 5 or "android-28"
       Name: Android API 28
       Type: Platform
       API level: 28
       Revision: 6



iOS platform:
  Xcode 10.2.1
  Build version 10E1001

config.xml <<EOF
<?xml version='1.0' encoding='utf-8'?>
<widget android-versionCode="1" id="com.gopackdashboard.gopack" version="1.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
    <name>GoPack</name>
    <description>Training Videos</description>
    <author email="vince@mcecomputing.com" href="https://mcecomputing.com/">MCE Computing</author>
    <content src="index.html" />
    <access origin="*" />
    <allow-intent href="http://*/*" />
    <allow-intent href="https://*/*" />
    <allow-intent href="tel:*" />
    <allow-intent href="sms:*" />
    <allow-intent href="mailto:*" />
    <allow-intent href="geo:*" />
    <preference name="ScrollEnabled" value="false" />
    <preference name="android-minSdkVersion" value="19" />
    <preference name="BackupWebStorage" value="none" />
    <preference name="SplashMaintainAspectRatio" value="true" />
    <preference name="FadeSplashScreenDuration" value="100" />
    <preference name="SplashShowOnlyFirstTime" value="false" />
    <preference name="SplashScreen" value="screen" />
    <preference name="InAppBrowserStorageEnabled" value="true" />
    <platform name="android">
        <resource-file src="build-extras.gradle" target="build-extras.gradle" />
        <allow-intent href="market:*" />
        <icon density="ldpi" src="resources/android/icon/drawable-ldpi-icon.png" />
        <icon density="mdpi" src="resources/android/icon/drawable-mdpi-icon.png" />
        <icon density="hdpi" src="resources/android/icon/drawable-hdpi-icon.png" />
        <icon density="xhdpi" src="resources/android/icon/drawable-xhdpi-icon.png" />
        <icon density="xxhdpi" src="resources/android/icon/drawable-xxhdpi-icon.png" />
        <icon density="xxxhdpi" src="resources/android/icon/drawable-xxxhdpi-icon.png" />
        <splash density="land-ldpi" src="resources/android/splash/drawable-land-ldpi-screen.png" />
        <splash density="land-mdpi" src="resources/android/splash/drawable-land-mdpi-screen.png" />
        <splash density="land-hdpi" src="resources/android/splash/drawable-land-hdpi-screen.png" />
        <splash density="land-xhdpi" src="resources/android/splash/drawable-land-xhdpi-screen.png" />
        <splash density="land-xxhdpi" src="resources/android/splash/drawable-land-xxhdpi-screen.png" />
        <splash density="land-xxxhdpi" src="resources/android/splash/drawable-land-xxxhdpi-screen.png" />
        <splash density="port-ldpi" src="resources/android/splash/drawable-port-ldpi-screen.png" />
        <splash density="port-mdpi" src="resources/android/splash/drawable-port-mdpi-screen.png" />
        <splash density="port-hdpi" src="resources/android/splash/drawable-port-hdpi-screen.png" />
        <splash density="port-xhdpi" src="resources/android/splash/drawable-port-xhdpi-screen.png" />
        <splash density="port-xxhdpi" src="resources/android/splash/drawable-port-xxhdpi-screen.png" />
        <splash density="port-xxxhdpi" src="resources/android/splash/drawable-port-xxxhdpi-screen.png" />
    </platform>
    <platform name="ios">
        <allow-intent href="itms:*" />
        <allow-intent href="itms-apps:*" />
        <icon height="57" src="resources/ios/icon/icon.png" width="57" />
        <icon height="114" src="resources/ios/icon/icon@2x.png" width="114" />
        <icon height="40" src="resources/ios/icon/icon-40.png" width="40" />
        <icon height="80" src="resources/ios/icon/icon-40@2x.png" width="80" />
        <icon height="120" src="resources/ios/icon/icon-40@3x.png" width="120" />
        <icon height="50" src="resources/ios/icon/icon-50.png" width="50" />
        <icon height="100" src="resources/ios/icon/icon-50@2x.png" width="100" />
        <icon height="60" src="resources/ios/icon/icon-60.png" width="60" />
        <icon height="120" src="resources/ios/icon/icon-60@2x.png" width="120" />
        <icon height="180" src="resources/ios/icon/icon-60@3x.png" width="180" />
        <icon height="72" src="resources/ios/icon/icon-72.png" width="72" />
        <icon height="144" src="resources/ios/icon/icon-72@2x.png" width="144" />
        <icon height="76" src="resources/ios/icon/icon-76.png" width="76" />
        <icon height="152" src="resources/ios/icon/icon-76@2x.png" width="152" />
        <icon height="167" src="resources/ios/icon/icon-83.5@2x.png" width="167" />
        <icon height="29" src="resources/ios/icon/icon-small.png" width="29" />
        <icon height="58" src="resources/ios/icon/icon-small@2x.png" width="58" />
        <icon height="87" src="resources/ios/icon/icon-small@3x.png" width="87" />
        <icon height="1024" src="resources/ios/icon/icon-1024.png" width="1024" />
        <splash height="1136" src="resources/ios/splash/Default-568h@2x~iphone.png" width="640" />
        <splash height="1334" src="resources/ios/splash/Default-667h.png" width="750" />
        <splash height="2208" src="resources/ios/splash/Default-736h.png" width="1242" />
        <splash height="1242" src="resources/ios/splash/Default-Landscape-736h.png" width="2208" />
        <splash height="1536" src="resources/ios/splash/Default-Landscape@2x~ipad.png" width="2048" />
        <splash height="2048" src="resources/ios/splash/Default-Landscape@~ipadpro.png" width="2732" />
        <splash height="768" src="resources/ios/splash/Default-Landscape~ipad.png" width="1024" />
        <splash height="2048" src="resources/ios/splash/Default-Portrait@2x~ipad.png" width="1536" />
        <splash height="2732" src="resources/ios/splash/Default-Portrait@~ipadpro.png" width="2048" />
        <splash height="1024" src="resources/ios/splash/Default-Portrait~ipad.png" width="768" />
        <splash height="960" src="resources/ios/splash/Default@2x~iphone.png" width="640" />
        <splash height="480" src="resources/ios/splash/Default~iphone.png" width="320" />
        <splash height="2732" src="resources/ios/splash/Default@2x~universal~anyany.png" width="2732" />
    </platform>
    <plugin name="cordova-plugin-whitelist" spec="1.3.3" />
    <plugin name="cordova-plugin-statusbar" spec="2.4.2" />
    <plugin name="cordova-plugin-device" spec="2.0.2" />
    <plugin name="cordova-plugin-ionic-webview" spec="^2.0.0" />
    <plugin name="cordova-plugin-dialogs" spec="^2.0.1" />
    <plugin name="cordova-plugin-insomnia" spec="^4.3.0" />
    <plugin name="com.moust.cordova.videoplayer" spec="https://github.com/moust/cordova-plugin-videoplayer.git" />
    <plugin name="com-sarriaroman-photoviewer" spec="1.1.18" />
    <plugin name="cordova-plugin-inappbrowser" spec="~3.0.0" />
    <plugin name="cordova-plugin-file-opener2" spec="~2.2.0">
        <variable name="ANDROID_SUPPORT_V4_VERSION" value="27.+" />
    </plugin>
    <plugin name="cordova-plugin-file-transfer" spec="^1.7.1" />
    <plugin name="cordova-plugin-native-keyboard" spec="~2.0.3">
        <variable name="LICENSE" value="TRIAL" />
        <variable name="LIC_ANDROID" value="TRIAL" />
        <variable name="LIC_IOS" value="TRIAL" />
    </plugin>
    <plugin name="cordova-plugin-ionic-keyboard" spec="^2.1.3" />
    <plugin name="cordova-plugin-splashscreen" spec="^5.0.2" />
    <preference name="SplashScreenDelay" value="3000" />
    <plugin name="cordova-plugin-fcm-with-dependecy-updated" spec="^2.4.0" />
    <plugin name="cordova-plugin-streaming-media" spec="^2.2.0" />
    <plugin name="cordova-plugin-app-version" spec="0.1.9" />
    <engine name="browser" spec="5.0.4" />
    <engine name="ios" spec="4.5.5" />
</widget>

EOF

package.json <<EOF
{
  "name": "cpc",
  "version": "0.0.1",
  "author": "Ionic Framework",
  "homepage": "http://ionicframework.com/",
  "private": true,
  "scripts": {
    "clean": "ionic-app-scripts clean",
    "build": "ionic-app-scripts build",
    "lint": "ionic-app-scripts lint",
    "ionic:build": "ionic-app-scripts build",
    "ionic:serve": "ionic-app-scripts serve",
    "browser": "ionic-app-scripts serve --sourceMap source-map --iscordovaserve --wwwDir platforms/browser/www/ --buildDir platforms/browser/www/build"
  },
  "dependencies": {
    "@angular/animations": "^5.2.11",
    "@angular/common": "5.2.11",
    "@angular/compiler": "5.2.11",
    "@angular/compiler-cli": "5.2.11",
    "@angular/core": "5.2.11",
    "@angular/forms": "5.2.11",
    "@angular/http": "5.2.11",
    "@angular/platform-browser": "5.2.11",
    "@angular/platform-browser-dynamic": "5.2.11",
    "@ionic-native/android-permissions": "^4.9.0",
    "@ionic-native/app-version": "^5.8.0",
    "@ionic-native/core": "^5.0.0",
    "@ionic-native/diagnostic": "^5.0.0",
    "@ionic-native/dialogs": "^5.0.0",
    "@ionic-native/document-viewer": "^5.0.0",
    "@ionic-native/fcm": "^5.5.0",
    "@ionic-native/file": "^5.0.0",
    "@ionic-native/file-chooser": "^5.0.0",
    "@ionic-native/file-opener": "^5.4.0",
    "@ionic-native/file-transfer": "^5.0.0",
    "@ionic-native/in-app-browser": "^5.0.0",
    "@ionic-native/insomnia": "^5.0.0",
    "@ionic-native/keyboard": "^4.12.0",
    "@ionic-native/photo-viewer": "^5.0.0",
    "@ionic-native/push": "^5.0.0",
    "@ionic-native/splash-screen": "^5.3.0",
    "@ionic-native/sqlite": "^5.0.0",
    "@ionic-native/status-bar": "^5.0.0",
    "@ionic-native/streaming-media": "^5.0.0",
    "@ionic-native/video-editor": "^5.0.0",
    "@ionic-native/video-player": "^5.0.0",
    "@ionic/storage": "^2.1.3",
    "@ng-idle/core": "^2.0.0-beta.15",
    "@ng-idle/keepalive": "^2.0.0-beta.15",
    "@types/pouchdb": "6.3.2",
    "angular2-moment": "^1.9.0",
    "chart.js": "^2.7.3",
    "chartjs-plugin-zoom": "^0.6.5",
    "com-sarriaroman-photoviewer": "^1.1.18",
    "com.moust.cordova.videoplayer": "https://github.com/moust/cordova-plugin-videoplayer.git",
    "cordova-android": "8.0.0",
    "cordova-browser": "5.0.4",
    "cordova-ios": "4.5.5",
    "cordova-plugin-android-permissions": "^1.0.0",
    "cordova-plugin-app-version": "0.1.9",
    "cordova-plugin-device": "^2.0.2",
    "cordova-plugin-dialogs": "^2.0.1",
    "cordova-plugin-document-viewer": "^0.9.10",
    "cordova-plugin-fcm-with-dependecy-updated": "^2.4.0",
    "cordova-plugin-file": "^6.0.1",
    "cordova-plugin-file-opener2": "^2.2.0",
    "cordova-plugin-file-transfer": "^1.7.1",
    "cordova-plugin-filechooser": "^1.2.0",
    "cordova-plugin-inappbrowser": "^3.0.0",
    "cordova-plugin-insomnia": "^4.3.0",
    "cordova-plugin-ionic-keyboard": "^2.1.3",
    "cordova-plugin-ionic-webview": "^1.2.1",
    "cordova-plugin-kiosk": "git+https://github.com/hkalina/cordova-plugin-kiosk.git",
    "cordova-plugin-native-keyboard": "^2.0.3",
    "cordova-plugin-splashscreen": "^5.0.2",
    "cordova-plugin-statusbar": "^2.4.2",
    "cordova-plugin-streaming-media": "^2.2.0",
    "cordova-plugin-video-editor": "^1.1.3",
    "cordova-plugin-video-player": "git+https://github.com/moust/cordova-plugin-videoplayer.git",
    "cordova-plugin-whitelist": "^1.3.3",
    "cordova-sqlite-storage": "^2.6.0",
    "hammerjs": "^2.0.8",
    "intro.js": "^2.9.3",
    "ion2-calendar": "^2.2.0",
    "ionic": "^4.1.2",
    "ionic-angular": "3.9.2",
    "ionic-img-viewer": "^2.9.0",
    "ionic-long-press": "^1.5.0",
    "ionic2-zoom-area": "^1.0.16",
    "ionicons": "3.0.0",
    "mime-types": "2.1.18",
    "moment": "^2.24.0",
    "moment-duration-format": "^2.2.2",
    "ng-ripple-module": "0.0.18",
    "ng2-charts": "^1.6.0",
    "pouchdb": "^7.0.0",
    "rxjs": "5.5.11",
    "sw-toolbox": "3.6.0",
    "zone.js": "0.8.26"
  },
  "devDependencies": {
    "@ionic/app-scripts": "3.2.0",
    "@ionic/lab": "2.0.6",
    "@types/moment-duration-format": "^2.2.2",
    "typescript": "~2.6.2"
  },
  "description": "An Ionic project",
  "cordova": {
    "plugins": {
      "cordova-plugin-whitelist": {},
      "cordova-plugin-device": {},
      "cordova-plugin-splashscreen": {},
      "cordova-plugin-ionic-webview": {},
      "cordova-plugin-ionic-keyboard": {},
      "cordova-plugin-file": {},
      "cordova-plugin-statusbar": {},
      "com.moust.cordova.videoplayer": {},
      "cordova-plugin-video-editor": {},
      "cordova-plugin-android-permissions": {},
      "cordova-sqlite-storage": {},
      "cordova-plugin-filechooser": {},
      "cordova-plugin-document-viewer": {},
      "cordova-plugin-dialogs": {},
      "cordova-plugin-insomnia": {},
      "cordova-plugin-file-transfer": {},
      "com-sarriaroman-photoviewer": {},
      "cordova-plugin-inappbrowser": {},
      "cordova-plugin-file-opener2": {
        "ANDROID_SUPPORT_V4_VERSION": "27.+"
      },
      "cordova-plugin-native-keyboard": {
        "LICENSE": "TRIAL",
        "LIC_ANDROID": "TRIAL",
        "LIC_IOS": "TRIAL"
      },
      "cordova-plugin-fcm-with-dependecy-updated": {},
      "cordova-plugin-streaming-media": {},
      "cordova-plugin-app-version": {},
      "cordova-plugin-kiosk": {}
    },
    "platforms": [
      "browser",
      "ios"
    ]
  }
}
EOF

Plugin version

cordova plugin version | grep cordova-plugin-file-opener2

Here is the output:

cordova-plugin-file-opener2 2.2.0 "File Opener2"

Another thing that is worth mentioning, is that if two or more capable apps are installed (Let's say trying to open a pdf file and there's two pdf viewers available) then the action sheet will display and the plugin will work, HOWEVER if there is only one OR even if the user selects 'always' for default one of those apps, then the app won't open anymore

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant