mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-31 18:40:47 +00:00
Changes to make inheriting decoding simpler
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@7294 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
57b68f1931
commit
4e6790ebf6
1 changed files with 21 additions and 9 deletions
|
@ -100,15 +100,7 @@ static Class defaultCellClass = nil;
|
||||||
|
|
||||||
[self insertRow:index];
|
[self insertRow:index];
|
||||||
[self putCell:new_cell atRow:index column:0];
|
[self putCell:new_cell atRow:index column:0];
|
||||||
[new_cell release];
|
RELEASE (new_cell);
|
||||||
|
|
||||||
[self setValidateSize: YES];
|
|
||||||
|
|
||||||
[[NSNotificationCenter defaultCenter]
|
|
||||||
addObserver: self
|
|
||||||
selector: @selector(_setTitleWidthNeedsUpdate:)
|
|
||||||
name: _NSFormCellDidChangeTitleWidthNotification
|
|
||||||
object: new_cell];
|
|
||||||
|
|
||||||
return new_cell;
|
return new_cell;
|
||||||
}
|
}
|
||||||
|
@ -123,6 +115,26 @@ static Class defaultCellClass = nil;
|
||||||
[self removeRow:index];
|
[self removeRow:index];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Overriding this method allows decoding stuff to be inherited
|
||||||
|
simpler by NSForm */
|
||||||
|
- (void) putCell: (NSCell*)newCell atRow: (int)row column: (int)column
|
||||||
|
{
|
||||||
|
if (column > 0)
|
||||||
|
{
|
||||||
|
NSLog (@"Warning: NSForm: tried to add a cell in a column > 0");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
[super putCell: newCell atRow: row column: column];
|
||||||
|
|
||||||
|
[self setValidateSize: YES];
|
||||||
|
|
||||||
|
[[NSNotificationCenter defaultCenter]
|
||||||
|
addObserver: self
|
||||||
|
selector: @selector(_setTitleWidthNeedsUpdate:)
|
||||||
|
name: _NSFormCellDidChangeTitleWidthNotification
|
||||||
|
object: newCell];
|
||||||
|
}
|
||||||
|
|
||||||
- (void)dealloc
|
- (void)dealloc
|
||||||
{
|
{
|
||||||
[[NSNotificationCenter defaultCenter]
|
[[NSNotificationCenter defaultCenter]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue