ref: Use openURLInBrowser whenever possible
This commit is contained in:
parent
8be02f9ca1
commit
45aa8606e6
|
@ -2,5 +2,4 @@
|
|||
* The URL that is the main landing page for YouTube live streaming and should
|
||||
* have a user's live stream key.
|
||||
*/
|
||||
export const YOUTUBE_LIVE_DASHBOARD_URL
|
||||
= 'https://www.youtube.com/live_dashboard';
|
||||
export const YOUTUBE_LIVE_DASHBOARD_URL = 'https://www.youtube.com/live_dashboard';
|
||||
|
|
|
@ -1,12 +1,13 @@
|
|||
// @flow
|
||||
|
||||
import React from 'react';
|
||||
import { Linking, Text, TextInput, TouchableOpacity, View } from 'react-native';
|
||||
import { Text, TextInput, TouchableOpacity, View } from 'react-native';
|
||||
|
||||
import { _abstractMapStateToProps } from '../../../../base/dialog';
|
||||
import { translate } from '../../../../base/i18n';
|
||||
import { connect } from '../../../../base/redux';
|
||||
import { StyleType } from '../../../../base/styles';
|
||||
import { openURLInBrowser } from '../../../../base/util';
|
||||
|
||||
import AbstractStreamKeyForm, {
|
||||
type Props as AbstractProps
|
||||
|
@ -120,7 +121,7 @@ class StreamKeyForm extends AbstractStreamKeyForm<Props> {
|
|||
const { helpURL } = this;
|
||||
|
||||
if (typeof helpURL === 'string') {
|
||||
Linking.openURL(helpURL);
|
||||
openURLInBrowser(helpURL);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
import React, { Component } from 'react';
|
||||
import {
|
||||
Linking,
|
||||
Text,
|
||||
TouchableHighlight,
|
||||
TouchableOpacity,
|
||||
|
@ -13,6 +12,7 @@ import { _abstractMapStateToProps } from '../../../../base/dialog';
|
|||
import { translate } from '../../../../base/i18n';
|
||||
import { connect } from '../../../../base/redux';
|
||||
import { StyleType } from '../../../../base/styles';
|
||||
import { openURLInBrowser } from '../../../../base/util';
|
||||
|
||||
import { YOUTUBE_LIVE_DASHBOARD_URL } from '../constants';
|
||||
|
||||
|
@ -153,7 +153,7 @@ class StreamKeyPicker extends Component<Props, State> {
|
|||
* @returns {void}
|
||||
*/
|
||||
_onOpenYoutubeDashboard() {
|
||||
Linking.openURL(YOUTUBE_LIVE_DASHBOARD_URL);
|
||||
openURLInBrowser(YOUTUBE_LIVE_DASHBOARD_URL);
|
||||
}
|
||||
|
||||
_onStreamPick: string => Function
|
||||
|
|
Loading…
Reference in New Issue