Revision: 27692
http://sourceforge.net/p/bibdesk/svn/27692
Author: hofman
Date: 2022-07-05 13:55:04 +0000 (Tue, 05 Jul 2022)
Log Message:
-----------
only reload updated smart and field groups rather than whole groups table
Modified Paths:
--------------
trunk/bibdesk/BibDocument_Groups.m
Modified: trunk/bibdesk/BibDocument_Groups.m
===================================================================
--- trunk/bibdesk/BibDocument_Groups.m 2022-07-05 09:34:36 UTC (rev 27691)
+++ trunk/bibdesk/BibDocument_Groups.m 2022-07-05 13:55:04 UTC (rev 27692)
@@ -415,7 +415,7 @@
// reload (a section of) the outlineview and preserve the selection
- (void)reloadParentGroup:(BDSKParentGroup *)parentGroup {
- if (parentGroup && [groupOutlineView isItemExpanded:parentGroup] == NO)
+ if ([parentGroup isKindOfClass:[BDSKParentGroup class]] &&
[groupOutlineView isItemExpanded:parentGroup] == NO)
return;
// this is a hack to keep us from getting selection change notifications
while sorting (which updates the TeX and attributed text previews)
@@ -426,10 +426,14 @@
NSArray *selectedGroups = [self selectedGroups];
- if (parentGroup)
+ if (parentGroup == nil) {
+ [groupOutlineView reloadData];
+ } else if ([parentGroup isKindOfClass:[BDSKParentGroup class]]) {
[groupOutlineView reloadItem:parentGroup reloadChildren:YES];
- else
- [groupOutlineView reloadData];
+ } else {
+ for (BDSKParentGroup *parent in (NSArray *)parentGroup)
+ [groupOutlineView reloadItem:parent reloadChildren:YES];
+ }
// select the current groups, if still around. Otherwise select Library
BOOL didSelect = [self selectGroups:selectedGroups];
@@ -602,7 +606,7 @@
if ([parentsToReload count] == 1)
[self reloadParentGroup:[parentsToReload firstObject]];
else if ([parentsToReload count])
- [self reloadParentGroup:nil];
+ [self reloadParentGroup:(id)parentsToReload];
else if (isSelected)
[self displaySelectedGroups];
else
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