Chameleon Applications

Chameleon Applications Commit Details

Date:2011-11-19 19:57:18 (12 years 4 months ago)
Author:Rekursor
Commit:355
Parents: 354
Message:Hidden parts are not selectable in the table view anymore.
Changes:
M/trunk/ChameleonPrefPane/Sources/TableViewsController.mm

File differences

trunk/ChameleonPrefPane/Sources/TableViewsController.mm
122122
123123
124124
125
126
127
128
129
130
131
132
133
125134
126135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
127155
128156
129157
img = [[NSImage alloc] initWithContentsOfFile: sRes];
return img;
}
//--------------------------------------------------------------------------
- (BOOL)tableView:(NSTableView *)tableView shouldSelectRow:(NSInteger)row
{
PartitionInfoElement* partInfo = [PartsInfoMgr objectAtIndex:row];
BOOL ret = (partInfo != nil && [partInfo hidden]== false) ? YES : NO;
[partInfo release];
return ret;
}
//--------------------------------------------------------------------------
#if 0
// TODO: rows of hidden parts should look disable ...
-(NSCell *) tableView:(NSTableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
NSCell *cell = [super tableView: tableView cellForRowAtIndexPath: indexPath];
if (cell == nil)
{
//cell.selectionStyle = UITableViewCellSelectionStyleNone;
//cell.selectionStyle = UITableViewCellSelectionStyleBlue;
// cell.userInteractionEnabled = NO;
}
return cell;
}
#endif
//--------------------------------------------------------------------------
- (void)tableViewSelectionDidChange:(NSNotification *)notification {
NSTableView* tv= [notification object];

Archive Download the corresponding diff file

Revision: 355