mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-26 05:02:36 +01:00
Merge pull request #4945 from OmrSi/assa-categories-cancel-fix
Fix categories styles changes being saved even when canceling
This commit is contained in:
commit
ef0eb7298e
@ -243,7 +243,13 @@ namespace Nikse.SubtitleEdit.Forms.Styles
|
||||
foreach (var category in storedCategories)
|
||||
{
|
||||
comboboxStorageCategories.Items.Add(category.Name);
|
||||
_storageCategories.Add(category);
|
||||
var categoryCopy = new AssaStorageCategory
|
||||
{
|
||||
IsDefault = category.IsDefault,
|
||||
Name = category.Name,
|
||||
Styles = category.Styles.ConvertAll(style => new SsaStyle(style))
|
||||
};
|
||||
_storageCategories.Add(categoryCopy);
|
||||
}
|
||||
|
||||
_currentCategory = _storageCategories.Single(category => category.IsDefault);
|
||||
|
Loading…
Reference in New Issue
Block a user