* Framework/PCProject.m:

(buildTargets): Return default build targets only if project file 
doesn't contains list them.
* Framework/PCProjectBuilder.m:
(prebuildCheck): Create build directory only if preference was set.
(build:): Set initial "=== started ===" string.
* Framework/PCProjectInspector.m:
(createBuildAttributes): Set target and action for table view.
(searchOrderPopupDidChange:): Add support for "Build Targets".
(setSearchOrderButtonsState): Enable "Remove" button only if item in 
list was selected.
(syncSearchOrder): Add support for "Build Targets".
* Documentation/TODO: Add some tasks and update status of others.
* Headers/ProjectCenter/PCDefines.h: Add key for build targets support.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/apps/projectcenter/trunk@28099 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Sergii Stoian 2009-03-20 00:53:39 +00:00
parent a002b0c43c
commit d6a49c572a
6 changed files with 58 additions and 27 deletions

View file

@ -52,7 +52,10 @@ ProjectCenter 0.6
- Check all textfields if 'scrollable' attribute set [done!] - Check all textfields if 'scrollable' attribute set [done!]
- Rewrite Preferences (3rd party sections etc.) [done!] - Rewrite Preferences (3rd party sections etc.) [done!]
--- Project Builder -------------------------------------------- --- Project Builder --------------------------------------------
- Finish parsing gcc output (make errors, etc.) stoyan - Review build, compiler, linker options setting
(Build Options, Inspector) stoyan
- Finish parsing build output (compiler errors/warnings,
make errors, gnustep-make verbose mode) stoyan
- Implement interaction with Editor (errors, warnings) stoyan - Implement interaction with Editor (errors, warnings) stoyan
--- Project Editor --------------------------------------------- --- Project Editor ---------------------------------------------
- review situations when editor is opened stoyan - review situations when editor is opened stoyan
@ -60,13 +63,15 @@ ProjectCenter 0.6
- Implement interaction with Builder (errors, warnings) stoyan - Implement interaction with Builder (errors, warnings) stoyan
- Implement indentation stoyan - Implement indentation stoyan
- implement undo inside editor stoyan - implement undo inside editor stoyan
- Add and use basic editor preferences (fonts, colors, sizes) [25% done] - Add and use basic editor preferences (fonts, colors, sizes) [50% done]
- Think about imlementing pending adding/removal of files ???
- Split "Application" to "Application GORM" and - Split "Application" to "Application GORM" and
"Application Renaissance" project types ??? "Application Renaissance" project types stoyan
- Review all sections of Project Inspector for correct
behaviour stoyan
- Add "Palette" project type ??? - Add "Palette" project type ???
- Add "Component" project type ??? - Add "Component" project type ???
- Process reported bugs ??? - Process reported bugs ???
- Think about imlementing pending adding/removal of files ???
- New icons. Need volonteers!!! ??? - New icons. Need volonteers!!! ???
ProjectCenter 0.7 ProjectCenter 0.7

View file

@ -701,7 +701,18 @@ NSString
- (NSArray *)buildTargets - (NSArray *)buildTargets
{ {
return [[self projectBundleInfoTable] objectForKey:@"BuildTargets"]; NSArray *buildTargets = [projectDict objectForKey:PCBuilderTargets];
if (!buildTargets)
{
buildTargets =
[[self projectBundleInfoTable] objectForKey:@"BuildTargets"];
[self setProjectDictObject:buildTargets
forKey:PCBuilderTargets
notify:NO];
}
return buildTargets;
} }
- (NSArray *)sourceFileKeys - (NSArray *)sourceFileKeys

View file

@ -187,9 +187,9 @@
[errorOutput addTableColumn:errorColumn]; [errorOutput addTableColumn:errorColumn];
[errorOutput setDataSource:self]; [errorOutput setDataSource:self];
[errorOutput setBackgroundColor:[NSColor colorWithDeviceRed:0.88 [errorOutput setBackgroundColor:[NSColor colorWithDeviceRed:0.88
green:0.76 green:0.76
blue:0.60 blue:0.60
alpha:1.0]]; alpha:1.0]];
[errorOutput setDrawsGrid:NO]; [errorOutput setDrawsGrid:NO];
[errorOutput setTarget:self]; [errorOutput setTarget:self];
[errorOutput setAction:@selector(errorItemClick:)]; [errorOutput setAction:@selector(errorItemClick:)];
@ -206,8 +206,7 @@
/* /*
* Log output * Log output
*/ */
logScroll = [[NSScrollView alloc] logScroll = [[NSScrollView alloc] initWithFrame:NSMakeRect(0,0,480,133)];
initWithFrame:NSMakeRect (0, 0, 480, 133)];
[logScroll setHasHorizontalScroller:NO]; [logScroll setHasHorizontalScroller:NO];
[logScroll setHasVerticalScroller:YES]; [logScroll setHasVerticalScroller:YES];
[logScroll setBorderType:NSBezelBorder]; [logScroll setBorderType:NSBezelBorder];
@ -237,9 +236,9 @@
* Split view * Split view
*/ */
[split addSubview:errorScroll]; [split addSubview:errorScroll];
RELEASE (errorScroll); RELEASE(errorScroll);
[split addSubview:logScroll]; [split addSubview:logScroll];
RELEASE (logScroll); RELEASE(logScroll);
// [split adjustSubviews]; // [split adjustSubviews];
// [componentView addSubview:split]; // [componentView addSubview:split];
@ -532,11 +531,16 @@
} }
// Create root build directory if not exist // Create root build directory if not exist
buildDir = [NSString stringWithFormat:@"%@.build", [project projectName]]; if (rootBuildDir && ![rootBuildDir isEqualToString:@""])
buildDir = [rootBuildDir stringByAppendingPathComponent:buildDir];
if (![fm fileExistsAtPath:rootBuildDir] || ![fm fileExistsAtPath:buildDir])
{ {
[pcfm createDirectoriesIfNeededAtPath:buildDir]; buildDir = [NSString
stringWithFormat:@"%@.build", [project projectName]];
buildDir = [rootBuildDir stringByAppendingPathComponent:buildDir];
if (![fm fileExistsAtPath:rootBuildDir] ||
![fm fileExistsAtPath:buildDir])
{
[pcfm createDirectoriesIfNeededAtPath:buildDir];
}
} }
return YES; return YES;
@ -597,6 +601,11 @@
[makeTask setStandardOutput:logPipe]; [makeTask setStandardOutput:logPipe];
[makeTask setStandardError:errorPipe]; [makeTask setStandardError:errorPipe];
[self logString:
[NSString stringWithFormat:@"=== %@ started ===", buildStatusTarget]
error:NO
newLine:YES];
NS_DURING NS_DURING
{ {
[makeTask launch]; [makeTask launch];

View file

@ -377,6 +377,9 @@
// Table // Table
[searchOrderList setCornerView:nil]; [searchOrderList setCornerView:nil];
[searchOrderList setHeaderView:nil]; [searchOrderList setHeaderView:nil];
[searchOrderList setTarget:self];
[searchOrderList setAction:@selector(searchOrderClick:)];
// [searchOrderColumn setEditable:NO];
// Buttons // Buttons
[self setSearchOrderButtonsState]; [self setSearchOrderButtonsState];
@ -390,14 +393,18 @@
{ {
NSString *selectedTitle = [sender titleOfSelectedItem]; NSString *selectedTitle = [sender titleOfSelectedItem];
if ([selectedTitle isEqualToString: @"Header Directories Search Order"]) if ([selectedTitle isEqualToString:@"Header Directories Search Order"])
{ {
ASSIGN(searchItems, searchHeaders); ASSIGN(searchItems, searchHeaders);
} }
else if ([selectedTitle isEqualToString: @"Library Directories Search Order"]) else if ([selectedTitle isEqualToString:@"Library Directories Search Order"])
{ {
ASSIGN(searchItems, searchLibs); ASSIGN(searchItems, searchLibs);
} }
else if ([selectedTitle isEqualToString:@"Build Targets"])
{
ASSIGN(searchItems,[project buildTargets]);
}
else else
{ {
ASSIGN(searchItems,nil); ASSIGN(searchItems,nil);
@ -415,8 +422,6 @@
- (void)searchOrderClick:(id)sender - (void)searchOrderClick:(id)sender
{ {
// Warning! NSTableView doesn't call action method
// TODO: Fix NSTableView (NSCell/NSActionCell?)
[self setSearchOrderButtonsState]; [self setSearchOrderButtonsState];
} }
@ -425,8 +430,6 @@
// Disable until implemented // Disable until implemented
[searchOrderSet setEnabled:NO]; [searchOrderSet setEnabled:NO];
return; // See searchOrderClick
if ([searchOrderList selectedRow] == -1) if ([searchOrderList selectedRow] == -1)
{ {
[searchOrderRemove setEnabled:NO]; [searchOrderRemove setEnabled:NO];
@ -472,17 +475,20 @@
pIndex = [searchOrderPopup indexOfSelectedItem]; pIndex = [searchOrderPopup indexOfSelectedItem];
switch (pIndex) switch (pIndex)
{ {
case 0: case 0: // Headers
[project setProjectDictObject:searchItems [project setProjectDictObject:searchItems
forKey:PCSearchHeaders forKey:PCSearchHeaders
notify:YES]; notify:YES];
break; break;
case 1: case 1: // Libraries
[project setProjectDictObject:searchItems [project setProjectDictObject:searchItems
forKey:PCSearchLibs forKey:PCSearchLibs
notify:YES]; notify:YES];
break; break;
case 2: case 2: // Targets
[project setProjectDictObject:searchItems
forKey:PCBuilderTargets
notify:YES];
return; return;
} }
} }

View file

@ -163,7 +163,7 @@ static NSString * const PCSearchHeaders = @"SEARCH_HEADER_DIRS";
static NSString * const PCSearchLibs = @"SEARCH_LIB_DIRS"; static NSString * const PCSearchLibs = @"SEARCH_LIB_DIRS";
// Project Builder options // Project Builder options
static NSString * const PCBuilderOptions = @"BUILDER_OPTIONS"; static NSString * const PCBuilderTargets = @"BUILDER_TARGETS";
static NSString * const PCBuilderArguments = @"BUILDER_ARGS"; static NSString * const PCBuilderArguments = @"BUILDER_ARGS";
static NSString * const PCBuilderDebug = @"BUILDER_DEBUG"; static NSString * const PCBuilderDebug = @"BUILDER_DEBUG";
static NSString * const PCBuilderStrip = @"BUILDER_STRIP"; static NSString * const PCBuilderStrip = @"BUILDER_STRIP";