diff --git a/config.xml b/config.xml
index 7ab400932..7f66b8c7d 100644
--- a/config.xml
+++ b/config.xml
@@ -214,6 +214,11 @@
+
+
+
+
+
diff --git a/package-lock.json b/package-lock.json
index 0c73afaf9..7144ebf97 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,6 +1,6 @@
{
"name": "moodlemobile",
- "version": "3.9.2",
+ "version": "3.9.3",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@@ -172,6 +172,11 @@
"resolved": "https://registry.npmjs.org/@ionic-native/local-notifications/-/local-notifications-4.20.0.tgz",
"integrity": "sha512-Ht/0zau8/2+G/bH/okXXhhWB6YrkCNL2QxVJHQ2dophXFGxQPOZAN3CKWhuQSjfbr76fa2nvQXF6jsXLpIR/ng=="
},
+ "@ionic-native/media": {
+ "version": "4.20.0",
+ "resolved": "https://registry.npmjs.org/@ionic-native/media/-/media-4.20.0.tgz",
+ "integrity": "sha512-uhuTvy7MT6zFMSTDX/0aIrGu8IeRGi2FWJbWE+6o5wttAeVA6hNISSbtj4OQZhL3sUXYNCczDayV1VsOcXbdUg=="
+ },
"@ionic-native/media-capture": {
"version": "4.20.0",
"resolved": "https://registry.npmjs.org/@ionic-native/media-capture/-/media-capture-4.20.0.tgz",
@@ -3169,9 +3174,9 @@
"dev": true
},
"compare-func": {
- "version": "1.3.2",
- "resolved": "https://registry.npmjs.org/compare-func/-/compare-func-1.3.2.tgz",
- "integrity": "sha1-md0LpFfh+bxyKxLAjsM+6rMfpkg=",
+ "version": "1.3.4",
+ "resolved": "https://registry.npmjs.org/compare-func/-/compare-func-1.3.4.tgz",
+ "integrity": "sha512-sq2sWtrqKPkEXAC8tEJA1+BqAH9GbFkGBtUOqrUX57VSfwp8xyktctk+uLoRy5eccTdxzDcVIztlYDpKs3Jv1Q==",
"requires": {
"array-ify": "^1.0.0",
"dot-prop": "^3.0.0"
@@ -3728,6 +3733,11 @@
"version": "git+https://github.com/moodlemobile/cordova-plugin-local-notification.git#0bb96b757fb484553ceabf35a59802f7983a2836",
"from": "git+https://github.com/moodlemobile/cordova-plugin-local-notification.git#moodle"
},
+ "cordova-plugin-media": {
+ "version": "5.0.3",
+ "resolved": "https://registry.npmjs.org/cordova-plugin-media/-/cordova-plugin-media-5.0.3.tgz",
+ "integrity": "sha512-UQPFlpk1zL4BY44zGi8RVmYCvcKBCN4Dyf8ovxqGYCC8zR1yhbTRWYDdO9vJdERwbfgWV7+z7FMWiSUfqWm9bQ=="
+ },
"cordova-plugin-media-capture": {
"version": "3.0.3",
"resolved": "https://registry.npmjs.org/cordova-plugin-media-capture/-/cordova-plugin-media-capture-3.0.3.tgz",
diff --git a/package.json b/package.json
index 5c1928f60..9d33f3e83 100644
--- a/package.json
+++ b/package.json
@@ -70,6 +70,7 @@
"@ionic-native/in-app-browser": "^4.20.0",
"@ionic-native/keyboard": "^4.20.0",
"@ionic-native/local-notifications": "^4.20.0",
+ "@ionic-native/media": "^4.20.0",
"@ionic-native/media-capture": "^4.20.0",
"@ionic-native/network": "^4.20.0",
"@ionic-native/push": "^4.20.0",
@@ -105,6 +106,7 @@
"cordova-plugin-ionic-keyboard": "2.1.3",
"cordova-plugin-ionic-webview": "git+https://github.com/moodlemobile/cordova-plugin-ionic-webview.git#500-moodle",
"cordova-plugin-local-notification": "git+https://github.com/moodlemobile/cordova-plugin-local-notification.git#moodle",
+ "cordova-plugin-media": "^5.0.3",
"cordova-plugin-media-capture": "^3.0.3",
"cordova-plugin-network-information": "^2.0.2",
"cordova-plugin-qrscanner": "git+https://github.com/moodlemobile/cordova-plugin-qrscanner.git#dist",
@@ -213,7 +215,10 @@
"cordova-plugin-wkwebview-cookies": {},
"cordova-plugin-qrscanner": {},
"cordova-plugin-chooser": {},
- "cordova-plugin-wkuserscript": {}
+ "cordova-plugin-wkuserscript": {},
+ "cordova-plugin-media": {
+ "KEEP_AVAUDIOSESSION_ALWAYS_ACTIVE": "NO"
+ }
}
},
"main": "desktop/electron.js",
@@ -276,4 +281,4 @@
"engines": {
"node": ">=11.x"
}
-}
\ No newline at end of file
+}
diff --git a/src/core/emulator/emulator.module.ts b/src/core/emulator/emulator.module.ts
index aad88cbfd..c63c94120 100644
--- a/src/core/emulator/emulator.module.ts
+++ b/src/core/emulator/emulator.module.ts
@@ -29,6 +29,7 @@ import { Globalization } from '@ionic-native/globalization';
import { InAppBrowser } from '@ionic-native/in-app-browser';
import { Keyboard } from '@ionic-native/keyboard';
import { LocalNotifications } from '@ionic-native/local-notifications';
+import { Media } from '@ionic-native/media';
import { MediaCapture } from '@ionic-native/media-capture';
import { Network } from '@ionic-native/network';
import { Push } from '@ionic-native/push';
@@ -196,6 +197,7 @@ export const IONIC_NATIVE_PROVIDERS = [
return appProvider.isMobile() ? new MediaCapture() : new MediaCaptureMock(captureHelper);
}
},
+ Media,
{
provide: Network,
deps: [Platform],
diff --git a/src/core/emulator/pages/capture-media/capture-media.html b/src/core/emulator/pages/capture-media/capture-media.html
index 5e2fd78ec..5d7816891 100644
--- a/src/core/emulator/pages/capture-media/capture-media.html
+++ b/src/core/emulator/pages/capture-media/capture-media.html
@@ -24,9 +24,18 @@
-
+
@@ -37,7 +46,7 @@
-