mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-12-03 03:24:22 +00:00
Fixed: crash when having a CPTableViewHeader without a CPTableView
Previously, when having a CPTableViewHeader without a CPTableView, cappuccino just crashed. We now check if _tableView is set before iterating on the tableview's columns.
This commit is contained in:
1 parent
42d7e4312b
commit
185ad5e747
1 file changed
+5
-2
@@ -466,9 +466,12 @@ var CPTableHeaderViewResizeZone = 3.0,
|
||||
- (void)updateTrackingAreas
|
||||
{
|
||||
[self removeAllTrackingAreas];
|
||||
|
||||
|
||||
var options = CPTrackingCursorUpdate | CPTrackingActiveInKeyWindow;
|
||||
|
||||
|
||||
if (!_tableView)
|
||||
return;
|
||||
|
||||
for (var i = 0; i < _tableView._tableColumns.length; i++)
|
||||
[self addTrackingArea:[[CPTrackingArea alloc] initWithRect:[self _cursorRectForColumn:i]
|
||||
options:options
|
||||
|
||||
Reference in new issue
Block a user