mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 02:40:38 +00:00
Implement encoding
This commit is contained in:
parent
a06dc3bef4
commit
80bab3fa5a
2 changed files with 18 additions and 3 deletions
|
@ -507,6 +507,14 @@ static NSLock *_fontCollectionLock = nil;
|
|||
{
|
||||
if ([coder allowsKeyedCoding])
|
||||
{
|
||||
[coder encodeObject: _queryDescriptors
|
||||
forKey: @"NSFontCollectionFontDescriptors"];
|
||||
[coder encodeObject: _queryAttributes
|
||||
forKey: @"NSFontCollectionAttributes"];
|
||||
[coder encodeObject: _name
|
||||
forKey: @"NSFontCollectionName"];
|
||||
[coder encodeObject: _fileName
|
||||
forKey: @"NSFontCollectionFileName"];
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -519,6 +527,14 @@ static NSLock *_fontCollectionLock = nil;
|
|||
{
|
||||
if ([coder allowsKeyedCoding])
|
||||
{
|
||||
_queryDescriptors = [coder decodeObjectForKey: @"NSFontCollectionFontDescriptors"];
|
||||
RETAIN(_queryDescriptors);
|
||||
_queryAttributes = [coder decodeObjectForKey: @"NSFontCollectionAttributes"];
|
||||
RETAIN(_queryAttributes);
|
||||
_name = [coder decodeObjectForKey: @"NSFontCollectionName"];
|
||||
RETAIN(_name);
|
||||
_fileName = [coder decodeObjectForKey: @"NSFontCollectionFileName"];
|
||||
RETAIN(_fileName);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue