Use scoped_nsobject to ensure our intermediate objects get cleaned up.

This commit is contained in:
Charlie Hess 2016-05-04 11:28:49 -07:00
parent 7b207aa1b6
commit b2fb95f857
4 changed files with 10 additions and 9 deletions

View file

@ -29,11 +29,11 @@
}
- (void)setCurrentActivity:(NSUserActivity*)userActivity {
currentActivity_ = userActivity;
currentActivity_ = base::scoped_nsobject<NSUserActivity>(userActivity);
}
- (NSUserActivity*)getCurrentActivity {
return currentActivity_;
return currentActivity_.get();
}
- (void)awakeFromNib {