summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHofi <[email protected]>2017-11-23 00:02:41 +0100
committerDamiano Galassi <[email protected]>2017-11-23 07:48:12 +0100
commit47d7b716b2c1f99c9d6a0ba6d2e834012d0a4d68 (patch)
treebcc6c2581b5a7e410a77dad02711efb3d3c3a1a5
parent653020c9e7ce01155d46810138482d2187cdd3b0 (diff)
D&D opening file could cause crash
- remove observers ASAP
-rw-r--r--macosx/HBSummaryViewController.m5
1 files changed, 3 insertions, 2 deletions
diff --git a/macosx/HBSummaryViewController.m b/macosx/HBSummaryViewController.m
index 5778a39e1..63fb45957 100644
--- a/macosx/HBSummaryViewController.m
+++ b/macosx/HBSummaryViewController.m
@@ -45,16 +45,17 @@
- (void)setJob:(HBJob *)job
{
- _job = job;
if (job)
{
+ _job = job;
[self addJobObservers];
[self updateLabels];
}
else
{
- [self resetLabels];
[self removeJobObservers];
+ [self resetLabels];
+ _job = job;
}
}