diff --git a/src/Artemis.Core/Services/Storage/ProfileService.cs b/src/Artemis.Core/Services/Storage/ProfileService.cs
index 82e91c674..5cdf00f06 100644
--- a/src/Artemis.Core/Services/Storage/ProfileService.cs
+++ b/src/Artemis.Core/Services/Storage/ProfileService.cs
@@ -246,6 +246,16 @@ namespace Artemis.Core.Services
{
lock (_profileCategories)
{
+ ProfileConfiguration? editedProfileConfiguration = _profileCategories.SelectMany(c => c.ProfileConfigurations).FirstOrDefault(p => p.IsBeingEdited);
+ if (editedProfileConfiguration != null)
+ {
+ editedProfileConfiguration.Profile?.Render(canvas, SKPointI.Empty);
+ return;
+ }
+
+ if (RenderForEditor)
+ return;
+
// Iterate the children in reverse because the first category must be rendered last to end up on top
for (int i = _profileCategories.Count - 1; i > -1; i--)
{
@@ -255,15 +265,9 @@ namespace Artemis.Core.Services
try
{
ProfileConfiguration profileConfiguration = profileCategory.ProfileConfigurations[j];
- // Always render profiles being edited
- if (profileConfiguration.IsBeingEdited)
+ // Ensure all criteria are met before rendering
+ if (!profileConfiguration.IsSuspended && !profileConfiguration.IsMissingModule && profileConfiguration.ActivationConditionMet)
profileConfiguration.Profile?.Render(canvas, SKPointI.Empty);
- else
- {
- // Ensure all criteria are met before rendering
- if (!profileConfiguration.IsSuspended && !profileConfiguration.IsMissingModule && profileConfiguration.ActivationConditionMet)
- profileConfiguration.Profile?.Render(canvas, SKPointI.Empty);
- }
}
catch (Exception e)
{
@@ -395,13 +399,6 @@ namespace Artemis.Core.Services
}
}
- ///
- /// Creates a new profile configuration and adds it to the provided
- ///
- /// The profile category to add the profile to
- /// The name of the new profile configuration
- /// The icon of the new profile configuration
- /// The newly created profile configuration
public ProfileConfiguration CreateProfileConfiguration(ProfileCategory category, string name, string icon)
{
ProfileConfiguration configuration = new(category, name, icon);
@@ -413,10 +410,6 @@ namespace Artemis.Core.Services
return configuration;
}
- ///
- /// Removes the provided profile configuration from the
- ///
- ///
public void RemoveProfileConfiguration(ProfileConfiguration profileConfiguration)
{
profileConfiguration.Category.RemoveProfileConfiguration(profileConfiguration);
diff --git a/src/Artemis.UI/Screens/ProfileEditor/LayerProperties/LayerPropertiesViewModel.cs b/src/Artemis.UI/Screens/ProfileEditor/LayerProperties/LayerPropertiesViewModel.cs
index 54a144305..944111d23 100644
--- a/src/Artemis.UI/Screens/ProfileEditor/LayerProperties/LayerPropertiesViewModel.cs
+++ b/src/Artemis.UI/Screens/ProfileEditor/LayerProperties/LayerPropertiesViewModel.cs
@@ -570,7 +570,7 @@ namespace Artemis.UI.Screens.ProfileEditor.LayerProperties
{
if (!ProfileEditorService.Playing)
{
- Pause();
+ CoreService.FrameRendering -= CoreServiceOnFrameRendering;
return;
}
diff --git a/src/Artemis.UI/Screens/ProfileEditor/ProfileEditorView.xaml b/src/Artemis.UI/Screens/ProfileEditor/ProfileEditorView.xaml
index 4c71321df..d63979f9d 100644
--- a/src/Artemis.UI/Screens/ProfileEditor/ProfileEditorView.xaml
+++ b/src/Artemis.UI/Screens/ProfileEditor/ProfileEditorView.xaml
@@ -27,7 +27,7 @@
-
+
@@ -105,10 +105,10 @@
Command="{s:Action ToggleSuspend}"
InputGestureText="F5" />
+ InputGestureText="Shift+F5" />