mirror of
https://github.com/4sval/FModel.git
synced 2026-03-24 10:44:51 -05:00
auto open mesh viewer
This commit is contained in:
parent
81fbe018d4
commit
411c0a135c
|
|
@ -168,6 +168,9 @@
|
|||
<MenuItem Header="Open Sounds" IsCheckable="True" StaysOpenOnClick="True"
|
||||
InputGestureText="{Binding AutoOpenSounds, Source={x:Static local:Settings.UserSettings.Default}}"
|
||||
IsChecked="{Binding IsAutoOpenSounds, Source={x:Static local:Settings.UserSettings.Default}}" />
|
||||
<MenuItem Header="Open Model Viewer" IsCheckable="True" StaysOpenOnClick="True"
|
||||
InputGestureText="{Binding AutoOpenMeshes, Source={x:Static local:Settings.UserSettings.Default}}"
|
||||
IsChecked="{Binding AutoOpenMeshes, Source={x:Static local:Settings.UserSettings.Default}}" />
|
||||
</MenuItem>
|
||||
</MenuItem>
|
||||
<MenuItem Header="Views">
|
||||
|
|
|
|||
|
|
@ -114,6 +114,13 @@ namespace FModel.Settings
|
|||
set => SetProperty(ref _isAutoOpenSounds, value);
|
||||
}
|
||||
|
||||
private bool _isAutoOpenMeshes = true;
|
||||
public bool IsAutoOpenMeshes
|
||||
{
|
||||
get => _isAutoOpenMeshes;
|
||||
set => SetProperty(ref _isAutoOpenMeshes, value);
|
||||
}
|
||||
|
||||
private bool _isLoggerExpanded = true;
|
||||
public bool IsLoggerExpanded
|
||||
{
|
||||
|
|
@ -518,6 +525,13 @@ namespace FModel.Settings
|
|||
set => SetProperty(ref _autoOpenSounds, value);
|
||||
}
|
||||
|
||||
private Hotkey _autoOpenMeshes = new(Key.F8);
|
||||
public Hotkey AutoOpenMeshes
|
||||
{
|
||||
get => _autoOpenMeshes;
|
||||
set => SetProperty(ref _autoOpenMeshes, value);
|
||||
}
|
||||
|
||||
private Hotkey _addAudio = new(Key.N, ModifierKeys.Control);
|
||||
public Hotkey AddAudio
|
||||
{
|
||||
|
|
|
|||
|
|
@ -668,11 +668,7 @@ namespace FModel.ViewModels
|
|||
case UStaticMesh:
|
||||
case USkeletalMesh:
|
||||
{
|
||||
if (UserSettings.Default.IsAutoSaveMeshes)
|
||||
{
|
||||
SaveExport(export);
|
||||
}
|
||||
else
|
||||
if (UserSettings.Default.IsAutoOpenMeshes)
|
||||
{
|
||||
Application.Current.Dispatcher.Invoke(() =>
|
||||
{
|
||||
|
|
@ -680,6 +676,10 @@ namespace FModel.ViewModels
|
|||
modelViewer.Load(export);
|
||||
});
|
||||
}
|
||||
if (UserSettings.Default.IsAutoSaveMeshes)
|
||||
{
|
||||
SaveExport(export);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
case USkeleton when UserSettings.Default.IsAutoSaveMeshes && UserSettings.Default.SaveSkeletonAsMesh:
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user