From fff99694ba59130f5e585f06fecc2881c39c9518 Mon Sep 17 00:00:00 2001 From: Buddy Reno Date: Wed, 27 Sep 2017 16:47:05 -0500 Subject: [PATCH 1/5] feat(music-controls): add support for next/prev track and skip forward/backward in control center (#1927) --- .../plugins/music-controls/index.ts | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/@ionic-native/plugins/music-controls/index.ts b/src/@ionic-native/plugins/music-controls/index.ts index 54336db95..033de510e 100644 --- a/src/@ionic-native/plugins/music-controls/index.ts +++ b/src/@ionic-native/plugins/music-controls/index.ts @@ -10,6 +10,10 @@ export interface MusicControlsOptions { dismissable: boolean; hasPrev: boolean; hasNext: boolean; + hasSkipForward: boolean; + hasSkipBackward: boolean; + skipForwardInterval: number; + skipBackwardInterval: number; hasClose: boolean; album: string; duration: number; @@ -50,6 +54,10 @@ export interface MusicControlsOptions { * album : 'Absolution' // optional, default: '' * duration : 60, // optional, default: 0 * elapsed : 10, // optional, default: 0 + * hasSkipForward : true, // show skip forward button, optional, default: false + * hasSkipBackward : true, // show skip backward button, optional, default: false + * skipForwardInterval: 15, // display number for skip forward, optional, default: 0 + * skipBackwardInterval: 15, // display number for skip backward, optional, default: 0 * * // Android only, optional * // text displayed in the status bar when the notification (and the ticker) are updated @@ -89,6 +97,12 @@ export interface MusicControlsOptions { * }); * // Do something * break; + * case 'music-controls-skip-forward': + * // Do something + * break; + * case 'music-controls-skip-backward': + * // Do something + * break; * * // Headset events (Android only) * // All media button events are listed below @@ -164,7 +178,7 @@ export class MusicControls extends IonicNativePlugin { /** * Update elapsed time, optionally toggle play/pause: - * @param args {Object} + * @param args {Object} */ @Cordova({ platforms: ['iOS'] From 024099a7727313af2607c504bd0fa8fcdbddc0ee Mon Sep 17 00:00:00 2001 From: Jan Piotrowski Date: Wed, 27 Sep 2017 23:47:15 +0200 Subject: [PATCH 2/5] add note about limitation (#1953) --- src/@ionic-native/plugins/bluetooth-serial/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/@ionic-native/plugins/bluetooth-serial/index.ts b/src/@ionic-native/plugins/bluetooth-serial/index.ts index 4ca599c79..7dfaeedff 100644 --- a/src/@ionic-native/plugins/bluetooth-serial/index.ts +++ b/src/@ionic-native/plugins/bluetooth-serial/index.ts @@ -4,7 +4,7 @@ import { Observable } from 'rxjs/Observable'; /** * @name Bluetooth Serial - * @description This plugin enables serial communication over Bluetooth. It was written for communicating between Android or iOS and an Arduino. + * @description This plugin enables serial communication over Bluetooth. It was written for communicating between Android or iOS and an Arduino (not Android to Android or iOS to iOS). * @usage * ```typescript * import { BluetoothSerial } from '@ionic-native/bluetooth-serial'; From 4246d47a6c12c0d884eba8718c5fd79f33daebc8 Mon Sep 17 00:00:00 2001 From: Josh Armstrong Date: Wed, 27 Sep 2017 17:47:51 -0400 Subject: [PATCH 3/5] feat(android-full-screen): add support for setSystemUiVisiblity (#1942) --- .../plugins/android-full-screen/index.ts | 38 +++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/src/@ionic-native/plugins/android-full-screen/index.ts b/src/@ionic-native/plugins/android-full-screen/index.ts index 9b442815c..8971f6dad 100644 --- a/src/@ionic-native/plugins/android-full-screen/index.ts +++ b/src/@ionic-native/plugins/android-full-screen/index.ts @@ -1,6 +1,35 @@ import { Injectable } from '@angular/core'; import { Cordova, Plugin, IonicNativePlugin } from '@ionic-native/core'; +/** + * Bit flag values for setSystemUiVisibility() + * @see https://developer.android.com/reference/android/view/View.html#setSystemUiVisibility(int) + */ +export enum AndroidSystemUiFlags { + /** View has requested the system UI (status bar) to be visible (the default). SYSTEM_UI_FLAG_VISIBLE */ + Visible = 0, + /** View has requested the system UI to enter an unobtrusive "low profile" mode. SYSTEM_UI_FLAG_LOW_PROFILE */ + LowProfile = 1, + /** View has requested that the system navigation be temporarily hidden. SYSTEM_UI_FLAG_HIDE_NAVIGATION */ + HideNavigation = 2, + /** View has requested to go into the normal fullscreen mode so that its content can take over the screen while still allowing the user to interact with the application. SYSTEM_UI_FLAG_FULLSCREEN */ + Fullscreen = 4, + /** Requests the navigation bar to draw in a mode that is compatible with light navigation bar backgrounds. SYSTEM_UI_FLAG_LIGHT_NAVIGATION_BAR */ + LightNavigationBar = 16, + /** When using other layout flags, we would like a stable view of the content insets given to fitSystemWindows(Rect). SYSTEM_UI_FLAG_LAYOUT_STABLE */ + LayoutStable = 256, + /** View would like its window to be laid out as if it has requested SYSTEM_UI_FLAG_HIDE_NAVIGATION, even if it currently hasn't. SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION */ + LayoutHideNavigation = 512, + /** View would like its window to be laid out as if it has requested SYSTEM_UI_FLAG_FULLSCREEN, even if it currently hasn't. SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN */ + LayoutFullscreen = 1024, + /** View would like to remain interactive when hiding the navigation bar with SYSTEM_UI_FLAG_HIDE_NAVIGATION. SYSTEM_UI_FLAG_IMMERSIVE */ + Immersive = 2048, + /** View would like to remain interactive when hiding the status bar with SYSTEM_UI_FLAG_FULLSCREEN and/or hiding the navigation bar with SYSTEM_UI_FLAG_HIDE_NAVIGATION. SYSTEM_UI_FLAG_IMMERSIVE_STICKY */ + ImmersiveSticky = 4096, + /** Requests the status bar to draw in a mode that is compatible with light status bar backgrounds. SYSTEM_UI_FLAG_LIGHT_STATUS_BAR */ + LightStatusBar = 8192 +} + /** * @name Android Full Screen * @description @@ -92,4 +121,13 @@ export class AndroidFullScreen extends IonicNativePlugin { */ @Cordova() immersiveMode(): Promise { return; } + + /** + * Manually set the the system UI to a custom mode. This mirrors the Android method of the same name. (Android 4.4+ only). + * @see https://developer.android.com/reference/android/view/View.html#setSystemUiVisibility(int) + * @param {AndroidSystemUiFlags} visibility Bitwise-OR of flags in AndroidSystemUiFlags + * @return {Promise} + */ + @Cordova() + setSystemUiVisibility(visibility: AndroidSystemUiFlags): Promise { return; } } From a150d4d522e853394b4519c824ea910741ea4723 Mon Sep 17 00:00:00 2001 From: mflynnKVD Date: Wed, 27 Sep 2017 17:48:23 -0400 Subject: [PATCH 4/5] fix(launch-navigator): fix navigate method (#1940) --- src/@ionic-native/plugins/launch-navigator/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/@ionic-native/plugins/launch-navigator/index.ts b/src/@ionic-native/plugins/launch-navigator/index.ts index 904792d10..79140e26f 100644 --- a/src/@ionic-native/plugins/launch-navigator/index.ts +++ b/src/@ionic-native/plugins/launch-navigator/index.ts @@ -313,8 +313,8 @@ export class LaunchNavigator extends IonicNativePlugin { * @returns {Promise} */ @Cordova({ - successIndex: 1, - errorIndex: 2 + successIndex: 2, + errorIndex: 3 }) navigate(destination: string | number[], options?: LaunchNavigatorOptions): Promise { return; } From 1b04ebb5e2f390b422b2fa47820a9ade0795f99f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20P=C3=A9rez?= Date: Wed, 27 Sep 2017 23:48:45 +0200 Subject: [PATCH 5/5] Zerconf: Action can also be `resolved` (#1924)