mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-17 11:50:56 +00:00
[docs] Tweak README code snippet.
This commit is contained in:
parent
5558e870f6
commit
74d9bb6c8f
@ -50,7 +50,7 @@ dispatch_async(_backgroundQueue, ^{
|
|||||||
node.frame = (CGRect){ CGPointZero, node.calculatedSize };
|
node.frame = (CGRect){ CGPointZero, node.calculatedSize };
|
||||||
|
|
||||||
// self.view isn't a node, so we can only use it on the main thread
|
// self.view isn't a node, so we can only use it on the main thread
|
||||||
dispatch_sync(dispatch_get_main_queue(), ^{
|
dispatch_async(dispatch_get_main_queue(), ^{
|
||||||
[self.view addSubview:node.view];
|
[self.view addSubview:node.view];
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@ -52,7 +52,7 @@ dispatch_async(_backgroundQueue, ^{
|
|||||||
node.frame = (CGRect){ CGPointZero, node.calculatedSize };
|
node.frame = (CGRect){ CGPointZero, node.calculatedSize };
|
||||||
|
|
||||||
// self.view isn't a node, so we can only use it on the main thread
|
// self.view isn't a node, so we can only use it on the main thread
|
||||||
dispatch_sync(dispatch_get_main_queue(), ^{
|
dispatch_async(dispatch_get_main_queue(), ^{
|
||||||
[self.view addSubview:node.view];
|
[self.view addSubview:node.view];
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user