mirror of
https://github.com/gnustep/apps-projectcenter.git
synced 2025-02-21 19:01:18 +00:00
Fixed some mem leaks
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/apps/projectcenter/trunk@8596 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
e5c8b3045a
commit
af27b15e84
1 changed files with 59 additions and 40 deletions
|
@ -76,8 +76,6 @@
|
||||||
[browserController setBrowser:browser];
|
[browserController setBrowser:browser];
|
||||||
[browserController setProject:self];
|
[browserController setProject:self];
|
||||||
|
|
||||||
RELEASE(browser);
|
|
||||||
|
|
||||||
box = [[NSBox alloc] initWithFrame:NSMakeRect (0,-1,560,252)];
|
box = [[NSBox alloc] initWithFrame:NSMakeRect (0,-1,560,252)];
|
||||||
[box setTitlePosition:NSNoTitle];
|
[box setTitlePosition:NSNoTitle];
|
||||||
[box setBorderType:NSNoBorder];
|
[box setBorderType:NSNoBorder];
|
||||||
|
@ -90,7 +88,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"Welcome to the GNUstep ProjectCenter!"];
|
[textField setStringValue:@"Welcome to the GNUstep ProjectCenter!"];
|
||||||
[box addSubview:[textField autorelease]];
|
[box addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
textField = [[NSTextField alloc] initWithFrame:NSMakeRect(16,178,500,21)];
|
textField = [[NSTextField alloc] initWithFrame:NSMakeRect(16,178,500,21)];
|
||||||
[textField setAlignment: NSLeftTextAlignment];
|
[textField setAlignment: NSLeftTextAlignment];
|
||||||
|
@ -99,28 +98,32 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"\tPlease report all bugs or other issues you don't like to phr@projectcenter.ch!"];
|
[textField setStringValue:@"\tPlease report all bugs or other issues you don't like to phr@projectcenter.ch!"];
|
||||||
[box addSubview:[textField autorelease]];
|
[box addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
_c_view = [projectWindow contentView];
|
_c_view = [projectWindow contentView];
|
||||||
[_c_view addSubview:browser];
|
[_c_view addSubview:browser];
|
||||||
[_c_view addSubview:box];
|
[_c_view addSubview:box];
|
||||||
|
|
||||||
|
RELEASE(browser);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Left button matrix
|
* Left button matrix
|
||||||
*/
|
*/
|
||||||
|
|
||||||
_w_frame = NSMakeRect(8,388,330,48);
|
_w_frame = NSMakeRect(8,388,330,48);
|
||||||
matrix = [[[NSMatrix alloc] initWithFrame: _w_frame
|
matrix = [[NSMatrix alloc] initWithFrame: _w_frame
|
||||||
mode: NSHighlightModeMatrix
|
mode: NSHighlightModeMatrix
|
||||||
prototype: buttonCell
|
prototype: buttonCell
|
||||||
numberOfRows: 1
|
numberOfRows: 1
|
||||||
numberOfColumns: 7] autorelease];
|
numberOfColumns: 7];
|
||||||
[matrix sizeToCells];
|
[matrix sizeToCells];
|
||||||
[matrix setTarget:self];
|
[matrix setTarget:self];
|
||||||
[matrix setAction:@selector(topButtonsPressed:)];
|
[matrix setAction:@selector(topButtonsPressed:)];
|
||||||
[matrix setSelectionByRect:YES];
|
[matrix setSelectionByRect:YES];
|
||||||
[matrix setAutoresizingMask: (NSViewMaxXMargin | NSViewMinYMargin)];
|
[matrix setAutoresizingMask: (NSViewMaxXMargin | NSViewMinYMargin)];
|
||||||
[_c_view addSubview:matrix];
|
[_c_view addSubview:matrix];
|
||||||
|
RELEASE(matrix);
|
||||||
|
|
||||||
button = [matrix cellAtRow:0 column:0];
|
button = [matrix cellAtRow:0 column:0];
|
||||||
[button setTag:0];
|
[button setTag:0];
|
||||||
|
@ -188,7 +191,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"Host:"];
|
[textField setStringValue:@"Host:"];
|
||||||
[_c_view addSubview:[textField autorelease]];
|
[_c_view addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
// Host message
|
// Host message
|
||||||
buildTargetHostField = [[NSTextField alloc] initWithFrame:NSMakeRect(72,24,184,21)];
|
buildTargetHostField = [[NSTextField alloc] initWithFrame:NSMakeRect(72,24,184,21)];
|
||||||
|
@ -201,7 +205,7 @@
|
||||||
[buildTargetHostField setDelegate:self];
|
[buildTargetHostField setDelegate:self];
|
||||||
[buildTargetHostField setTarget:self];
|
[buildTargetHostField setTarget:self];
|
||||||
[buildTargetHostField setAction:@selector(setHost:)];
|
[buildTargetHostField setAction:@selector(setHost:)];
|
||||||
[_c_view addSubview:[buildTargetHostField autorelease]];
|
[_c_view addSubview:buildTargetHostField];
|
||||||
|
|
||||||
// Args
|
// Args
|
||||||
textField = [[NSTextField alloc] initWithFrame:NSMakeRect(12,44,60,21)];
|
textField = [[NSTextField alloc] initWithFrame:NSMakeRect(12,44,60,21)];
|
||||||
|
@ -211,7 +215,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"Arguments:"];
|
[textField setStringValue:@"Arguments:"];
|
||||||
[_c_view addSubview:[textField autorelease]];
|
[_c_view addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
// Args message
|
// Args message
|
||||||
buildTargetArgsField = [[NSTextField alloc] initWithFrame:NSMakeRect(72,44,184,21)];
|
buildTargetArgsField = [[NSTextField alloc] initWithFrame:NSMakeRect(72,44,184,21)];
|
||||||
|
@ -224,7 +229,7 @@
|
||||||
[buildTargetArgsField setDelegate:self];
|
[buildTargetArgsField setDelegate:self];
|
||||||
[buildTargetArgsField setTarget:self];
|
[buildTargetArgsField setTarget:self];
|
||||||
[buildTargetArgsField setAction:@selector(setArguments:)];
|
[buildTargetArgsField setAction:@selector(setArguments:)];
|
||||||
[_c_view addSubview:[buildTargetArgsField autorelease]];
|
[_c_view addSubview:buildTargetArgsField];
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Model the standard inspector UI
|
* Model the standard inspector UI
|
||||||
|
@ -244,7 +249,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"Install in:"];
|
[textField setStringValue:@"Install in:"];
|
||||||
[projectAttributeInspectorView addSubview:[textField autorelease]];
|
[projectAttributeInspectorView addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
installPathField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,280,176,21)];
|
installPathField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,280,176,21)];
|
||||||
[installPathField setAlignment: NSLeftTextAlignment];
|
[installPathField setAlignment: NSLeftTextAlignment];
|
||||||
|
@ -262,7 +268,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"Build tool:"];
|
[textField setStringValue:@"Build tool:"];
|
||||||
[projectAttributeInspectorView addSubview:[textField autorelease]];
|
[projectAttributeInspectorView addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
toolField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,256,176,21)];
|
toolField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,256,176,21)];
|
||||||
[toolField setAlignment: NSLeftTextAlignment];
|
[toolField setAlignment: NSLeftTextAlignment];
|
||||||
|
@ -280,7 +287,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"CC options:"];
|
[textField setStringValue:@"CC options:"];
|
||||||
[projectAttributeInspectorView addSubview:[textField autorelease]];
|
[projectAttributeInspectorView addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
ccOptField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,232,176,21)];
|
ccOptField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,232,176,21)];
|
||||||
[ccOptField setAlignment: NSLeftTextAlignment];
|
[ccOptField setAlignment: NSLeftTextAlignment];
|
||||||
|
@ -298,7 +306,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"LD options:"];
|
[textField setStringValue:@"LD options:"];
|
||||||
[projectAttributeInspectorView addSubview:[textField autorelease]];
|
[projectAttributeInspectorView addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
ldOptField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,204,176,21)];
|
ldOptField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,204,176,21)];
|
||||||
[ldOptField setAlignment: NSLeftTextAlignment];
|
[ldOptField setAlignment: NSLeftTextAlignment];
|
||||||
|
@ -327,7 +336,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"Type:"];
|
[textField setStringValue:@"Type:"];
|
||||||
[projectProjectInspectorView addSubview:[textField autorelease]];
|
[projectProjectInspectorView addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
projectTypeField = [[NSTextField alloc] initWithFrame:NSMakeRect(84,280,176,21)];
|
projectTypeField = [[NSTextField alloc] initWithFrame:NSMakeRect(84,280,176,21)];
|
||||||
[projectTypeField setAlignment: NSLeftTextAlignment];
|
[projectTypeField setAlignment: NSLeftTextAlignment];
|
||||||
|
@ -351,7 +361,8 @@
|
||||||
[textField setBezeled: NO];
|
[textField setBezeled: NO];
|
||||||
[textField setDrawsBackground: NO];
|
[textField setDrawsBackground: NO];
|
||||||
[textField setStringValue:@"Filename:"];
|
[textField setStringValue:@"Filename:"];
|
||||||
[projectFileInspectorView addSubview:[textField autorelease]];
|
[projectFileInspectorView addSubview:textField];
|
||||||
|
RELEASE(textField);
|
||||||
|
|
||||||
fileNameField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,280,176,21)];
|
fileNameField =[[NSTextField alloc] initWithFrame:NSMakeRect(84,280,176,21)];
|
||||||
[fileNameField setAlignment: NSLeftTextAlignment];
|
[fileNameField setAlignment: NSLeftTextAlignment];
|
||||||
|
@ -415,29 +426,37 @@
|
||||||
|
|
||||||
- (void)dealloc
|
- (void)dealloc
|
||||||
{
|
{
|
||||||
[projectName release];
|
RELEASE(projectName);
|
||||||
[projectPath release];
|
RELEASE(projectPath);
|
||||||
[projectDict release];
|
RELEASE(projectDict);
|
||||||
|
RELEASE(projectManager);
|
||||||
|
|
||||||
[browserController release];
|
RELEASE(projectBuilder);
|
||||||
[projectWindow release];
|
RELEASE(projectDebugger);
|
||||||
[buildTargetPanel release];
|
|
||||||
|
|
||||||
[buildOptions release];
|
RELEASE(browserController);
|
||||||
|
RELEASE(projectWindow);
|
||||||
|
|
||||||
[projectAttributeInspectorView release];
|
RELEASE(buildTargetPanel);
|
||||||
[installPathField release];
|
RELEASE(buildTargetHostField);
|
||||||
[toolField release];
|
RELEASE(buildTargetArgsField);
|
||||||
[ccOptField release];
|
|
||||||
[ldOptField release];
|
|
||||||
[projectTypeField release];
|
|
||||||
|
|
||||||
[projectProjectInspectorView release];
|
RELEASE(buildOptions);
|
||||||
[projectFileInspectorView release];
|
|
||||||
[fileNameField release];
|
|
||||||
[changeFileNameButton release];
|
|
||||||
|
|
||||||
[box release];
|
RELEASE(projectAttributeInspectorView);
|
||||||
|
RELEASE(installPathField);
|
||||||
|
RELEASE(toolField);
|
||||||
|
RELEASE(ccOptField);
|
||||||
|
RELEASE(ldOptField);
|
||||||
|
|
||||||
|
RELEASE(projectProjectInspectorView);
|
||||||
|
RELEASE(projectTypeField);
|
||||||
|
|
||||||
|
RELEASE(projectFileInspectorView);
|
||||||
|
RELEASE(fileNameField);
|
||||||
|
RELEASE(changeFileNameButton);
|
||||||
|
|
||||||
|
RELEASE(box);
|
||||||
|
|
||||||
[super dealloc];
|
[super dealloc];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue