From 01c3eadcf5eb5950ef6290ad66b4b0061f5aa6fa Mon Sep 17 00:00:00 2001 From: Gregory John Casamento Date: Wed, 22 Apr 2009 20:32:36 +0000 Subject: [PATCH] * Framework/PCProject.m: Changes to make plist output in human readable format. * Resources/Info-gnustep.plist: Changes to read C++ files using C editor. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/apps/projectcenter/trunk@28239 72102866-910b-0410-8b05-ffd578937521 --- ChangeLog | 10 +++++++++- Framework/PCProject.m | 10 ++++++---- Resources/Info-gnustep.plist | 2 +- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 942eb24..554f78c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2009-04-22 16:31-EDT Gregory John Casamento + + * Framework/PCProject.m: Changes to make plist output in + human readable format. + * Resources/Info-gnustep.plist: Changes to read C++ files using + C editor. + 2009-04-15 Sergii Stoian * Framework/PCProjectBuilder.m: @@ -11,7 +18,8 @@ 2009-03-31 Riccardo Mottola - * PCSplitView: removed and replaced with standard NSSplitView in all instances + * PCSplitView: removed and replaced with standard NSSplitView in all + instances 2009-03-28 Sergii Stoian diff --git a/Framework/PCProject.m b/Framework/PCProject.m index 25e3136..da745f3 100644 --- a/Framework/PCProject.m +++ b/Framework/PCProject.m @@ -476,6 +476,7 @@ NSString NSString *file = @"PC.project"; NSString *backup = [wrapperPath stringByAppendingPathExtension:@"backup"]; NSMutableDictionary *dict = [projectDict mutableCopy]; + NSData *dictData = nil; // remove key.. [dict removeObjectForKey: @"PC_WINDOWS"]; @@ -515,11 +516,12 @@ NSString } // Save project file + dictData = [NSPropertyListSerialization dataFromPropertyList: dict + format: NSPropertyListOpenStepFormat + errorDescription: NULL]; [projectDict setObject: [[NSCalendarDate date] description] - forKey: PCLastEditing]; - [projectFileWrapper addRegularFileWithContents: - [NSData dataWithBytes: [[dict description] cString] - length: [[dict description] length]] + forKey: PCLastEditing]; + [projectFileWrapper addRegularFileWithContents: dictData preferredFilename: file]; if ([projectFileWrapper writeToFile:wrapperPath diff --git a/Resources/Info-gnustep.plist b/Resources/Info-gnustep.plist index 0bdae63..00329b6 100644 --- a/Resources/Info-gnustep.plist +++ b/Resources/Info-gnustep.plist @@ -58,7 +58,7 @@ NSIcon = ProjectCenter.editor/Resources/FileC.tiff; NSName = GSPCCType; NSRole = Editor; - NSUnixExtensions = ( c ); + NSUnixExtensions = ( c, C, cp, cpp, c++ ); } ); URL = "See http://www.gnustep.org/";