mirror of
https://github.com/DorkSquadRR/DorkNet.git
synced 2026-10-26 23:48:45 -07:00
launcher: Photon AppId setup walkthrough
The two empty "REALTIME APPID / VOICE APPID" textboxes assumed the user already knew what Photon was, where to sign up, and which app type to create. New 5-step wizard fills that gap: 1. What's Photon? — one-paragraph explanation tying back to DorkNet 2. Make an account — Open Dashboard button launches browser 3. Create a Realtime app — numbered click-by-click instructions 4. Create a Voice app — same, with a Skip button (voice is optional) 5. Paste your AppIds — text fields with live regex validation, region picker, Save commits to AppState Hyphens optional on input; we normalise to canonical 8-4-4-4-12 form before writing back. The existing Photon section keeps its three fields for advanced users, with a "Setup walkthrough" button at the top opening the wizard prefilled with current values.
This commit is contained in:
@@ -231,6 +231,22 @@ public partial class MainWindow : Window
|
||||
_state.Save();
|
||||
}
|
||||
|
||||
private void OnOpenPhotonWizard(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var wiz = new PhotonWizard(_state.PhotonAppId, _state.PhotonVoiceAppId, _state.PhotonRegion)
|
||||
{
|
||||
Owner = this,
|
||||
};
|
||||
if (wiz.ShowDialog() == true && wiz.Result is not null)
|
||||
{
|
||||
_state.PhotonAppId = wiz.Result.RealtimeAppId;
|
||||
_state.PhotonVoiceAppId = wiz.Result.VoiceAppId;
|
||||
_state.PhotonRegion = wiz.Result.Region;
|
||||
_state.Save();
|
||||
ReflectStateInUi();
|
||||
}
|
||||
}
|
||||
|
||||
private void OnHostingModeChanged(object sender, RoutedEventArgs e)
|
||||
{
|
||||
// RadioButton.Checked fires twice on selection-change (once for
|
||||
|
||||
Reference in New Issue
Block a user