summaryrefslogtreecommitdiffhomepage
path: root/gui
diff options
context:
space:
mode:
Diffstat (limited to 'gui')
-rw-r--r--gui/src/renderer/components/AdvancedSettings.tsx47
-rw-r--r--gui/src/renderer/containers/AdvancedSettingsPage.tsx2
-rw-r--r--gui/tasks/distribution.js1
3 files changed, 18 insertions, 32 deletions
diff --git a/gui/src/renderer/components/AdvancedSettings.tsx b/gui/src/renderer/components/AdvancedSettings.tsx
index 334da211a8..dd9568bed5 100644
--- a/gui/src/renderer/components/AdvancedSettings.tsx
+++ b/gui/src/renderer/components/AdvancedSettings.tsx
@@ -43,7 +43,6 @@ interface IProps {
wireguard: { port?: number };
mssfix?: number;
bridgeState: BridgeState;
- enableWireguardKeysPage: boolean;
setBridgeState: (value: BridgeState) => void;
setEnableIpv6: (value: boolean) => void;
setBlockWhenDisconnected: (value: boolean) => void;
@@ -226,18 +225,14 @@ export default class AdvancedSettings extends Component<IProps, IState> {
)}
</Cell.Footer>
- {process.platform !== 'win32' ? (
- <View style={styles.advanced_settings__content}>
- <Selector
- title={messages.pgettext('advanced-settings-view', 'Tunnel protocol')}
- values={this.tunnelProtocolItems}
- value={this.props.tunnelProtocol}
- onSelect={this.onSelectTunnelProtocol}
- />
- </View>
- ) : (
- undefined
- )}
+ <View style={styles.advanced_settings__content}>
+ <Selector
+ title={messages.pgettext('advanced-settings-view', 'Tunnel protocol')}
+ values={this.tunnelProtocolItems}
+ value={this.props.tunnelProtocol}
+ onSelect={this.onSelectTunnelProtocol}
+ />
+ </View>
{this.props.tunnelProtocol !== 'wireguard' ? (
<View style={styles.advanced_settings__content}>
@@ -277,7 +272,7 @@ export default class AdvancedSettings extends Component<IProps, IState> {
undefined
)}
- {this.props.tunnelProtocol === 'wireguard' && process.platform !== 'win32' ? (
+ {this.props.tunnelProtocol === 'wireguard' ? (
<View style={styles.advanced_settings__content}>
<Selector
// TRANSLATORS: The title for the shadowsocks bridge selector section.
@@ -336,7 +331,14 @@ export default class AdvancedSettings extends Component<IProps, IState> {
)}
</Cell.FooterText>
</Cell.Footer>
- {this.wireguardKeysButton()}
+ <View style={styles.advanced_settings__wgkeys_cell}>
+ <Cell.CellButton onPress={this.props.onViewWireguardKeys}>
+ <Cell.Label>
+ {messages.pgettext('advanced-settings-view', 'WireGuard key')}
+ </Cell.Label>
+ <Cell.Icon height={12} width={7} source="icon-chevron" />
+ </Cell.CellButton>
+ </View>
</NavigationScrollbars>
</View>
</NavigationContainer>
@@ -346,21 +348,6 @@ export default class AdvancedSettings extends Component<IProps, IState> {
);
}
- private wireguardKeysButton() {
- if (this.props.enableWireguardKeysPage) {
- return (
- <View style={styles.advanced_settings__wgkeys_cell}>
- <Cell.CellButton onPress={this.props.onViewWireguardKeys}>
- <Cell.Label>{messages.pgettext('advanced-settings-view', 'WireGuard key')}</Cell.Label>
- <Cell.Icon height={12} width={7} source="icon-chevron" />
- </Cell.CellButton>
- </View>
- );
- } else {
- return null;
- }
- }
-
private onSelectTunnelProtocol = (protocol?: TunnelProtocol) => {
this.props.setTunnelProtocol(protocol);
};
diff --git a/gui/src/renderer/containers/AdvancedSettingsPage.tsx b/gui/src/renderer/containers/AdvancedSettingsPage.tsx
index e31365b86d..fad5704a97 100644
--- a/gui/src/renderer/containers/AdvancedSettingsPage.tsx
+++ b/gui/src/renderer/containers/AdvancedSettingsPage.tsx
@@ -12,14 +12,12 @@ import { IReduxState, ReduxDispatch } from '../redux/store';
const mapStateToProps = (state: IReduxState) => {
const protocolAndPort = mapRelaySettingsToProtocolAndPort(state.settings.relaySettings);
- const enableWireguardKeysPage = process.platform === 'linux' || process.platform === 'darwin';
return {
enableIpv6: state.settings.enableIpv6,
blockWhenDisconnected: state.settings.blockWhenDisconnected,
mssfix: state.settings.openVpn.mssfix,
bridgeState: state.settings.bridgeState,
- enableWireguardKeysPage,
...protocolAndPort,
};
};
diff --git a/gui/tasks/distribution.js b/gui/tasks/distribution.js
index be262cf80e..7ae4dc3296 100644
--- a/gui/tasks/distribution.js
+++ b/gui/tasks/distribution.js
@@ -93,6 +93,7 @@ const config = {
{ from: root('windows/winutil/bin/x64-Release/winutil.dll'), to: '.' },
{ from: distAssets('binaries/x86_64-pc-windows-msvc/openvpn.exe'), to: '.' },
{ from: distAssets('binaries/x86_64-pc-windows-msvc/sslocal.exe'), to: '.' },
+ { from: distAssets('binaries/x86_64-pc-windows-msvc/wireguard/libwg.dll'), to: '.' },
],
},