[vlc-commits] macosx: work-around a racing condition (close #6412)
Felix Paul Kühne
git at videolan.org
Fri Apr 6 15:10:25 CEST 2012
vlc/vlc-2.0 | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Fri Apr 6 13:32:39 2012 +0200| [b3127daf8deafa19bb69daceebf591eb67d4adeb] | committer: Felix Paul Kühne
macosx: work-around a racing condition (close #6412)
(cherry picked from commit 6cbf48f1f9c38c1a0ed91fb6699f977b3b7f97ea)
> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.0.git/?a=commit;h=b3127daf8deafa19bb69daceebf591eb67d4adeb
---
modules/gui/macosx/playlistinfo.h | 2 ++
modules/gui/macosx/playlistinfo.m | 5 +++++
2 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/modules/gui/macosx/playlistinfo.h b/modules/gui/macosx/playlistinfo.h
index 3ae9664..7c5a4cd 100644
--- a/modules/gui/macosx/playlistinfo.h
+++ b/modules/gui/macosx/playlistinfo.h
@@ -98,6 +98,8 @@
VLCInfoTreeItem * rootItem;
input_item_t * p_item;
+
+ BOOL b_awakeFromNib;
}
- (void)initPanel;
diff --git a/modules/gui/macosx/playlistinfo.m b/modules/gui/macosx/playlistinfo.m
index 00612e3..be2a201 100644
--- a/modules/gui/macosx/playlistinfo.m
+++ b/modules/gui/macosx/playlistinfo.m
@@ -121,6 +121,8 @@ static VLCInfo *_o_sharedInstance = nil;
[o_info_window setInitialFirstResponder: o_uri_txt];
[o_info_window setDelegate: self];
+ b_awakeFromNib = YES;
+
/* We may be awoken from nib way after initialisation
* Update ourselves */
[self updatePanelWithItem:p_item];
@@ -278,6 +280,9 @@ static VLCInfo *_o_sharedInstance = nil;
- (void)updateStatistics
{
+ if (!b_awakeFromNib)
+ return;
+
if ([o_info_window isVisible])
{
if( !p_item || !p_item->p_stats )
More information about the vlc-commits
mailing list