Skip to content
This repository was archived by the owner on Apr 3, 2020. It is now read-only.

Commit 2581ef0

Browse files
committed
Work towards making the extension available for Firefox
1 parent f3e32da commit 2581ef0

File tree

6 files changed

+42
-1
lines changed

6 files changed

+42
-1
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ output/
88
netcode.io.wininstall/package.zip
99
*.user
1010
netcode.io.demoserver/.kube/
11+
netcode.io.wininstall/.vs/

browser/hostapp/Install-Windows.ps1

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@ $ManifestJson = @{
1010
allowed_origins = @(
1111
"chrome-extension://fkcdbgdmpjenlkecdjadcpnkchaecbpn/",
1212
"chrome-extension://hpecmifakhimhidjpcpjmihpacijicbd/"
13-
)
13+
);
14+
allowed_extensions = @(
15+
"webext@netcode.redpoint.games"
16+
);
1417
}
1518
ConvertTo-Json $ManifestJson | Out-File -Encoding UTF8 $ManifestJsonPath
1619

browser/hostapp/manifest.windows.relative.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,8 @@
66
"chrome-extension://fkcdbgdmpjenlkecdjadcpnkchaecbpn/",
77
"chrome-extension://hpecmifakhimhidjpcpjmihpacijicbd/"
88
],
9+
"allowed_extensions": [
10+
"webext@netcode.redpoint.games"
11+
],
912
"type": "stdio"
1013
}

browser/webext/manifest.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@
33
"name": "netcode.io support",
44
"version": "0.1.3",
55
"description": "Provides netcode.io APIs to websites",
6+
"applications": {
7+
"gecko": {
8+
"id": "webext@netcode.redpoint.games",
9+
"strict_min_version": "42.0"
10+
}
11+
},
612
"content_scripts": [
713
{
814
"matches": ["*://*/*"],

netcode.io.wininstall/HelperForm.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,12 @@ private void InstallNetcode()
5555
.CreateSubKey("NativeMessagingHosts")
5656
.CreateSubKey("netcode.io");
5757
registryKey.SetValue(null, Path.Combine(netcodePath, "manifest.windows.relative.json"));
58+
registryKey = Registry.CurrentUser
59+
.CreateSubKey("Software")
60+
.CreateSubKey("Mozilla")
61+
.CreateSubKey("NativeMessagingHosts")
62+
.CreateSubKey("netcode.io");
63+
registryKey.SetValue(null, Path.Combine(netcodePath, "manifest.windows.relative.json"));
5864

5965
Thread.Sleep(1000);
6066
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
2+
Microsoft Visual Studio Solution File, Format Version 12.00
3+
# Visual Studio 15
4+
VisualStudioVersion = 15.0.26430.15
5+
MinimumVisualStudioVersion = 10.0.40219.1
6+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "netcode.io.wininstall", "netcode.io.wininstall.csproj", "{25609529-0734-46EF-A4A6-E73F02E5C032}"
7+
EndProject
8+
Global
9+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
10+
Debug|Any CPU = Debug|Any CPU
11+
Release|Any CPU = Release|Any CPU
12+
EndGlobalSection
13+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
14+
{25609529-0734-46EF-A4A6-E73F02E5C032}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15+
{25609529-0734-46EF-A4A6-E73F02E5C032}.Debug|Any CPU.Build.0 = Debug|Any CPU
16+
{25609529-0734-46EF-A4A6-E73F02E5C032}.Release|Any CPU.ActiveCfg = Release|Any CPU
17+
{25609529-0734-46EF-A4A6-E73F02E5C032}.Release|Any CPU.Build.0 = Release|Any CPU
18+
EndGlobalSection
19+
GlobalSection(SolutionProperties) = preSolution
20+
HideSolutionNode = FALSE
21+
EndGlobalSection
22+
EndGlobal

0 commit comments

Comments
 (0)