implemented basic stylish style switch
This commit is contained in:
parent
5a85ccc150
commit
0504dbcb33
|
|
@ -57,7 +57,7 @@ public class FileFormat
|
|||
GraphicsMode = Settings.Mode.Automatic;
|
||||
ReShade = false;
|
||||
QualityLevel = Settings.Level.Automatic;
|
||||
LauncherStyle = Settings.Style.Extended;
|
||||
LauncherStyle = Settings.Style.Stylish;
|
||||
ReShadeFPSDisplay = false;
|
||||
ReShadePerformanceMode = false;
|
||||
AssetLocalizerSaveBackups = true;
|
||||
|
|
|
|||
|
|
@ -784,7 +784,7 @@ public class GlobalFuncs
|
|||
}
|
||||
|
||||
#if LAUNCHER
|
||||
public static void ResetConfigValues(bool IsInCompact = false)
|
||||
public static void ResetConfigValues(Settings.Style style)
|
||||
#else
|
||||
public static void ResetConfigValues()
|
||||
#endif
|
||||
|
|
@ -795,16 +795,9 @@ public class GlobalFuncs
|
|||
GlobalVars.UserConfiguration.MapPath = GlobalPaths.MapsDir + @"\\" + GlobalVars.ProgramInformation.DefaultMap;
|
||||
GlobalVars.UserConfiguration.MapPathSnip = GlobalPaths.MapsDirBase + @"\\" + GlobalVars.ProgramInformation.DefaultMap;
|
||||
#if LAUNCHER
|
||||
if (IsInCompact)
|
||||
{
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Compact;
|
||||
}
|
||||
else
|
||||
{
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Extended;
|
||||
}
|
||||
GlobalVars.UserConfiguration.LauncherStyle = style;
|
||||
#else
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Extended;
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Stylish;
|
||||
#endif
|
||||
GeneratePlayerID();
|
||||
GenerateTripcode();
|
||||
|
|
|
|||
|
|
@ -954,7 +954,8 @@ namespace NovetusLauncher
|
|||
this.comboBox3.FormattingEnabled = true;
|
||||
this.comboBox3.Items.AddRange(new object[] {
|
||||
"Extended",
|
||||
"Compact"});
|
||||
"Compact",
|
||||
"Stylish"});
|
||||
this.comboBox3.Location = new System.Drawing.Point(296, 28);
|
||||
this.comboBox3.Name = "comboBox3";
|
||||
this.comboBox3.Size = new System.Drawing.Size(99, 21);
|
||||
|
|
|
|||
|
|
@ -1277,7 +1277,8 @@ namespace NovetusLauncher
|
|||
this.comboBox3.FormattingEnabled = true;
|
||||
this.comboBox3.Items.AddRange(new object[] {
|
||||
"Extended",
|
||||
"Compact"});
|
||||
"Compact",
|
||||
"Stylish"});
|
||||
this.comboBox3.Location = new System.Drawing.Point(457, 2);
|
||||
this.comboBox3.Name = "comboBox3";
|
||||
this.comboBox3.Size = new System.Drawing.Size(103, 21);
|
||||
|
|
|
|||
|
|
@ -653,18 +653,27 @@ namespace NovetusLauncher
|
|||
{
|
||||
switch (StyleSelectorBox.SelectedIndex)
|
||||
{
|
||||
case 0:
|
||||
if (FormStyle != Settings.Style.Extended)
|
||||
{
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Extended;
|
||||
CloseEvent();
|
||||
Application.Restart();
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
if (FormStyle == Settings.Style.Extended)
|
||||
if (FormStyle != Settings.Style.Compact)
|
||||
{
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Compact;
|
||||
CloseEvent();
|
||||
Application.Restart();
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
default:
|
||||
if (FormStyle == Settings.Style.Compact)
|
||||
if (FormStyle != Settings.Style.Stylish)
|
||||
{
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Extended;
|
||||
GlobalVars.UserConfiguration.LauncherStyle = Settings.Style.Stylish;
|
||||
CloseEvent();
|
||||
Application.Restart();
|
||||
}
|
||||
|
|
@ -701,9 +710,12 @@ namespace NovetusLauncher
|
|||
StyleSelectorBox.SelectedIndex = 1;
|
||||
break;
|
||||
case Settings.Style.Extended:
|
||||
default:
|
||||
StyleSelectorBox.SelectedIndex = 0;
|
||||
break;
|
||||
case Settings.Style.Stylish:
|
||||
default:
|
||||
StyleSelectorBox.SelectedIndex = 2;
|
||||
break;
|
||||
}
|
||||
|
||||
GlobalFuncs.ConsolePrint("Config loaded.", 3, ConsoleBox);
|
||||
|
|
@ -741,7 +753,7 @@ namespace NovetusLauncher
|
|||
f.Close();
|
||||
}
|
||||
|
||||
GlobalFuncs.ResetConfigValues();
|
||||
GlobalFuncs.ResetConfigValues(FormStyle);
|
||||
WriteConfigValues();
|
||||
ReadConfigValues();
|
||||
if (ShowBox)
|
||||
|
|
|
|||
|
|
@ -571,7 +571,7 @@
|
|||
<Button x:Name="searchButton" Style="{DynamicResource SearchButton}" Content="" Grid.Column="2" HorizontalAlignment="Left" Margin="315.166,43,0,0" VerticalAlignment="Top" Width="19" Height="19"/>
|
||||
<Button x:Name="refreshButton" Style="{DynamicResource RefreshButton}" Content="" Grid.Column="2" HorizontalAlignment="Left" Margin="339.166,45,0,0" VerticalAlignment="Top" Width="16" Height="16"/>
|
||||
<Button x:Name="addMapButton" Content="Add Place" Grid.Column="2" HorizontalAlignment="Left" Margin="360.166,45,0,0" VerticalAlignment="Top" Width="72"/>
|
||||
<Button x:Name="customizeButton" Style="{DynamicResource ImportantButtonSmall}" Content="Customize Character" HorizontalAlignment="Left" Margin="16,105,0,0" VerticalAlignment="Top" Width="145" Grid.ColumnSpan="2"/>
|
||||
<Button x:Name="customizeButton" Style="{DynamicResource ImportantButtonSmall}" Content="Customize Character" HorizontalAlignment="Left" Margin="16,105,0,0" VerticalAlignment="Top" Width="145" Grid.ColumnSpan="2" Click="customizeButton_Click"/>
|
||||
<Label x:Name="serverPortLabel" Content="Host Port:" Grid.Column="1" HorizontalAlignment="Left" Margin="78,43,0,0" VerticalAlignment="Top" Width="68" Grid.ColumnSpan="2"/>
|
||||
<TextBox x:Name="serverPortBox" HorizontalAlignment="Left" Height="20" Margin="16.166,47,0,0" TextWrapping="Wrap" Text="53640" VerticalAlignment="Top" Width="65" Grid.Column="2"/>
|
||||
<Label x:Name="maxPlayersLabel" Content="Max Players:" Grid.Column="1" HorizontalAlignment="Left" Margin="68,64,0,0" VerticalAlignment="Top" Width="86" Grid.ColumnSpan="2"/>
|
||||
|
|
@ -579,9 +579,9 @@
|
|||
<CheckBox x:Name="uPnPBox" Content="uPnP" Grid.Column="1" HorizontalAlignment="Left" Margin="78,93,0,0" VerticalAlignment="Top"/>
|
||||
<CheckBox x:Name="NotifBox" Content="Join Alerts" Grid.Column="1" HorizontalAlignment="Left" Margin="134,93,0,0" VerticalAlignment="Top" Grid.ColumnSpan="2"/>
|
||||
<Button x:Name="serverInfoButton" Content="Server Information" Grid.Column="1" HorizontalAlignment="Left" Margin="78,113,0,0" VerticalAlignment="Top" Width="139" Grid.ColumnSpan="2"/>
|
||||
<Rectangle x:Name="hostServerBrowserGroupBox" Fill="#FFDEDCDC" HorizontalAlignment="Left" Height="110" Margin="74,145,0,0" Stroke="Black" VerticalAlignment="Top" Width="153" Grid.Column="1" Grid.ColumnSpan="2"/>
|
||||
<Rectangle x:Name="hostServerBrowserLabelBox" Fill="#FFAAA8A8" HorizontalAlignment="Left" Height="30" Margin="74,145,0,0" Stroke="Black" VerticalAlignment="Top" Width="153" Grid.Column="1" Grid.ColumnSpan="2"/>
|
||||
<Label x:Name="hostServerBrowserLabel" Content="Optional Hosting Settings" HorizontalAlignment="Left" Margin="77,148,0,0" VerticalAlignment="Top" Width="145" Grid.Column="1" RenderTransformOrigin="0.561,0.175" FontSize="11" Grid.ColumnSpan="2"/>
|
||||
<Rectangle x:Name="hostServerBrowserGroupBox" Fill="#FFDEDCDC" HorizontalAlignment="Left" Height="110" Margin="72,145,0,0" Stroke="Black" VerticalAlignment="Top" Width="153" Grid.Column="1" Grid.ColumnSpan="2"/>
|
||||
<Rectangle x:Name="hostServerBrowserLabelBox" Fill="#FFAAA8A8" HorizontalAlignment="Left" Height="30" Margin="72,145,0,0" Stroke="Black" VerticalAlignment="Top" Width="153" Grid.Column="1" Grid.ColumnSpan="2"/>
|
||||
<Label x:Name="hostServerBrowserLabel" Content="Optional Hosting Settings" HorizontalAlignment="Left" Margin="69,147,0,0" VerticalAlignment="Top" Width="156" Grid.Column="1" RenderTransformOrigin="0.561,0.175" FontSize="12" Grid.ColumnSpan="2"/>
|
||||
<Label x:Name="browserNameLabel" Content="Server Name:" Grid.Column="1" HorizontalAlignment="Left" Margin="101,171,0,0" VerticalAlignment="Top" Grid.ColumnSpan="2"/>
|
||||
<TextBox x:Name="browserNameBox" HorizontalAlignment="Left" Height="20" Margin="82,192,0,0" TextWrapping="Wrap" Text="Novetus" VerticalAlignment="Top" Width="135" Grid.Column="1" Grid.ColumnSpan="2"/>
|
||||
<Label x:Name="browserAddressLabel" Content="Browser Master Server:" Grid.Column="1" HorizontalAlignment="Left" Margin="77,206,0,0" VerticalAlignment="Top" Grid.ColumnSpan="2"/>
|
||||
|
|
|
|||
|
|
@ -179,6 +179,12 @@ namespace NovetusLauncher
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void customizeButton_Click(object sender, RoutedEventArgs e)
|
||||
{
|
||||
CharacterCustomizationExtended ccustom = new CharacterCustomizationExtended();
|
||||
ccustom.Show();
|
||||
}
|
||||
}
|
||||
|
||||
public class ClientListItem
|
||||
|
|
|
|||
|
|
@ -297,6 +297,7 @@ public partial class ItemCreationSDK : Form
|
|||
switch (GlobalVars.UserConfiguration.LauncherStyle)
|
||||
{
|
||||
case Settings.Style.Extended:
|
||||
case Settings.Style.Stylish:
|
||||
CharacterCustomizationExtended ccustom = new CharacterCustomizationExtended();
|
||||
ccustom.Show();
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -32,20 +32,18 @@ namespace NovetusLauncher
|
|||
System.Windows.Forms.Application.Run(new LauncherFormCompact());
|
||||
break;
|
||||
case Settings.Style.Extended:
|
||||
default:
|
||||
System.Windows.Forms.Application.Run(new LauncherFormExtended());
|
||||
break;
|
||||
case Settings.Style.Stylish:
|
||||
default:
|
||||
System.Windows.Forms.Application.Run(new LauncherFormStylish());
|
||||
break;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
CommandLineArguments.Arguments CommandLine = new CommandLineArguments.Arguments(args);
|
||||
|
||||
if (CommandLine["StylishTest"] != null)
|
||||
{
|
||||
System.Windows.Forms.Application.Run(new LauncherFormStylish());
|
||||
}
|
||||
|
||||
if (CommandLine["sdk"] != null)
|
||||
{
|
||||
System.Windows.Forms.Application.Run(new NovetusSDK());
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ namespace NovetusURI
|
|||
ccustom2.Show();
|
||||
break;
|
||||
case Settings.Style.Extended:
|
||||
case Settings.Style.Stylish:
|
||||
default:
|
||||
CharacterCustomizationExtended ccustom = new CharacterCustomizationExtended();
|
||||
ccustom.Show();
|
||||
|
|
|
|||
Loading…
Reference in New Issue