public void SaveDisplayPreferences(DisplayPreferences prefs) { string file = GetDisplayPrefsFile(prefs.Id); using (Stream fs = WriteExclusiveFileStream(file)) { prefs.WriteToStream(new BinaryWriter(fs)); } }
public void SaveDisplayPreferences(DisplayPreferences prefs) { string file = GetDisplayPrefsFile(prefs.Id); using (Stream fs = WriteExclusiveFileStream(file)) { prefs.WriteToStream(new BinaryWriter(fs)); } //also save the thumb size in a way we can access outside of MC thumbSizes[prefs.Id] = new ThumbSize(prefs.ThumbConstraint.Value.Width, prefs.ThumbConstraint.Value.Height); }