Revision: 27860
http://sourceforge.net/p/bibdesk/svn/27860
Author: hofman
Date: 2022-09-06 23:15:14 +0000 (Tue, 06 Sep 2022)
Log Message:
-----------
notify changed clients from number of connections setter
Modified Paths:
--------------
trunk/bibdesk/BDSKSharingServer.m
Modified: trunk/bibdesk/BDSKSharingServer.m
===================================================================
--- trunk/bibdesk/BDSKSharingServer.m 2022-09-06 23:08:52 UTC (rev 27859)
+++ trunk/bibdesk/BDSKSharingServer.m 2022-09-06 23:15:14 UTC (rev 27860)
@@ -618,6 +618,9 @@
[rwLock lockForWriting];
numberOfConnections = count;
[rwLock unlock];
+ dispatch_async(dispatch_get_main_queue(), ^{
+ [[NSNotificationCenter defaultCenter]
postNotificationName:BDSKClientConnectionsChangedNotification object:nil];
+ });
}
#pragma mark Main Thread
@@ -678,9 +681,6 @@
[registeredClients removeAllObjects];
if ([self numberOfConnections] > 0){
[self setNumberOfConnections:0];
- dispatch_async(dispatch_get_main_queue(), ^{
- [[NSNotificationCenter defaultCenter]
postNotificationName:BDSKClientConnectionsChangedNotification object:nil];
- });
}
if (connection) {
@@ -753,9 +753,6 @@
[client setProxy:clientObject];
[registeredClients setObject:client forKey:identifier];
[self setNumberOfConnections:[registeredClients count]];
- dispatch_async(dispatch_get_main_queue(), ^{
- [[NSNotificationCenter defaultCenter]
postNotificationName:BDSKClientConnectionsChangedNotification object:nil];
- });
}
}
@@ -781,9 +778,6 @@
[client release];
}
[self setNumberOfConnections:[registeredClients count]];
- dispatch_async(dispatch_get_main_queue(), ^{
- [[NSNotificationCenter defaultCenter]
postNotificationName:BDSKClientConnectionsChangedNotification object:nil];
- });
}
- (void)notifyClientsOfChange;
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit