Revision: 29333
http://sourceforge.net/p/bibdesk/svn/29333
Author: hofman
Date: 2025-07-22 16:30:21 +0000 (Tue, 22 Jul 2025)
Log Message:
-----------
rename methods
Modified Paths:
--------------
trunk/bibdesk/BDSKFormatParser.m
trunk/bibdesk/BDSKPublicationsArray.h
trunk/bibdesk/BDSKPublicationsArray.m
trunk/bibdesk/BDSKStaticGroup.m
trunk/bibdesk/BibDocument.m
trunk/bibdesk/BibDocument_DataSource.m
trunk/bibdesk/BibDocument_UI.m
trunk/bibdesk/BibItem.m
Modified: trunk/bibdesk/BDSKFormatParser.m
===================================================================
--- trunk/bibdesk/BDSKFormatParser.m 2025-07-22 16:06:42 UTC (rev 29332)
+++ trunk/bibdesk/BDSKFormatParser.m 2025-07-22 16:30:21 UTC (rev 29333)
@@ -1291,7 +1291,7 @@
static NSString *validCiteKey(NSString *key, id <BDSKParseableItem> pub) {
if ([NSString isEmptyString:key])
return nil;
- NSArray *items = [[[pub owner] publications] allItemsForCiteKey:key];
+ NSArray *items = [[[pub owner] publications] itemsForCiteKey:key];
if ([items count] == 0)
return key;
if ([items count] == 1 && [items firstObject] == pub)
Modified: trunk/bibdesk/BDSKPublicationsArray.h
===================================================================
--- trunk/bibdesk/BDSKPublicationsArray.h 2025-07-22 16:06:42 UTC (rev
29332)
+++ trunk/bibdesk/BDSKPublicationsArray.h 2025-07-22 16:30:21 UTC (rev
29333)
@@ -57,10 +57,10 @@
- (void)setReorderedArray:(NSArray *)otherArray;
- (nullable BibItem *)itemForCiteKey:(NSString *)key;
-- (nullable NSArray *)allItemsForCiteKey:(NSString *)key;
+- (nullable NSArray *)itemsForCiteKey:(NSString *)key;
- (void)changeCiteKey:(NSString *)oldKey forItem:(BibItem *)anItem;
-- (nullable NSArray *)allItemsForCrossref:(NSString *)key;
+- (nullable NSArray *)itemsForCrossref:(NSString *)key;
- (void)changeCrossref:(nullable NSString *)oldKey forItem:(BibItem *)anItem;
- (nullable BibItem *)itemForIdentifierURL:(NSURL *)aURL;
Modified: trunk/bibdesk/BDSKPublicationsArray.m
===================================================================
--- trunk/bibdesk/BDSKPublicationsArray.m 2025-07-22 16:06:42 UTC (rev
29332)
+++ trunk/bibdesk/BDSKPublicationsArray.m 2025-07-22 16:30:21 UTC (rev
29333)
@@ -271,7 +271,7 @@
return [[itemsForCiteKeys objectForKey:key] firstObject];
}
-- (NSArray *)allItemsForCiteKey:(NSString *)key;
+- (NSArray *)itemsForCiteKey:(NSString *)key;
{
if ([NSString isEmptyString:key] == NO)
return [itemsForCiteKeys objectForKey:key];
@@ -288,7 +288,7 @@
[self addItem:anItem forCrossref:newKey];
}
-- (NSArray *)allItemsForCrossref:(NSString *)key {
+- (NSArray *)itemsForCrossref:(NSString *)key {
if ([NSString isEmptyString:key] == NO)
return [itemsForCrossrefs objectForKey:key];
return nil;
Modified: trunk/bibdesk/BDSKStaticGroup.m
===================================================================
--- trunk/bibdesk/BDSKStaticGroup.m 2025-07-22 16:06:42 UTC (rev 29332)
+++ trunk/bibdesk/BDSKStaticGroup.m 2025-07-22 16:30:21 UTC (rev 29333)
@@ -195,7 +195,7 @@
[super setDocument:newDocument];
if (document && tmpKeys) {
for (NSString *key in tmpKeys)
- [publications addObjectsFromArray:[[document publications]
allItemsForCiteKey:key]];
+ [publications addObjectsFromArray:[[document publications]
itemsForCiteKey:key]];
[self setCount:[publications count]];
tmpKeys = nil;
}
Modified: trunk/bibdesk/BibDocument.m
===================================================================
--- trunk/bibdesk/BibDocument.m 2025-07-22 16:06:42 UTC (rev 29332)
+++ trunk/bibdesk/BibDocument.m 2025-07-22 16:30:21 UTC (rev 29333)
@@ -1980,7 +1980,7 @@
- (void)generateForTemporaryCiteKey:(NSString *)tmpKey {
NSArray *selItems = [self selectedPublications];
- [self selectPublications:[[self publications] allItemsForCiteKey:tmpKey]];
+ [self selectPublications:[[self publications] itemsForCiteKey:tmpKey]];
[self generateCiteKeysForPublications:[self selectedPublications]];
[self selectPublications:selItems];
}
@@ -1990,7 +1990,7 @@
return;
NSString *tmpKey = [BibItem placeholderCiteKey];
- NSArray *tmpKeyItems = [[self publications] allItemsForCiteKey:tmpKey];
+ NSArray *tmpKeyItems = [[self publications] itemsForCiteKey:tmpKey];
if([tmpKeyItems count] == 0)
return;
Modified: trunk/bibdesk/BibDocument_DataSource.m
===================================================================
--- trunk/bibdesk/BibDocument_DataSource.m 2025-07-22 16:06:42 UTC (rev
29332)
+++ trunk/bibdesk/BibDocument_DataSource.m 2025-07-22 16:30:21 UTC (rev
29333)
@@ -710,8 +710,8 @@
(isBiblatex == NO || (([scanner scanUpToString:@"}"
intoString:NULL] || YES) && [scanner scanString:@"}{" intoString:NULL])) &&
[scanner scanUpToString:@"}" intoString:&keys]) {
for (NSString *key in [keys componentsSeparatedByString:@","]) {
- if ((items = [publications allItemsForCiteKey:key]))
- [selItems addObjectsFromArray:[publications
allItemsForCiteKey:key]];
+ if ((items = [publications itemsForCiteKey:key]))
+ [selItems addObjectsFromArray:[publications
itemsForCiteKey:key]];
}
}
[scanner scanUpToCharactersFromSet:[NSCharacterSet
newlineCharacterSet] intoString:NULL];
Modified: trunk/bibdesk/BibDocument_UI.m
===================================================================
--- trunk/bibdesk/BibDocument_UI.m 2025-07-22 16:06:42 UTC (rev 29332)
+++ trunk/bibdesk/BibDocument_UI.m 2025-07-22 16:30:21 UTC (rev 29333)
@@ -1449,7 +1449,7 @@
}
if ([changedKey isNoteField] == NO && [changedKey isGeneralURLField] == NO
&& [changedKey isIntegerField] == NO && [changedKey
isEqualToString:BDSKPubTypeString] == NO) {
- NSArray *crossreffedItems = [publications allItemsForCrossref:key];
+ NSArray *crossreffedItems = [publications itemsForCrossref:key];
if ([crossreffedItems count]) {
// invalidate groups that depend on inherited values
[crossreffedItems
makeObjectsPerformSelector:@selector(resetGroups)];
@@ -1462,7 +1462,7 @@
}
if (oldKey) {
// change the crossrefs if we change the parent cite key
- crossreffedItems = [publications allItemsForCrossref:oldKey];
+ crossreffedItems = [publications itemsForCrossref:oldKey];
if ([crossreffedItems count]) {
for (BibItem *aPub in [crossreffedItems copy])
[aPub setField:BDSKCrossrefString toValue:key];
Modified: trunk/bibdesk/BibItem.m
===================================================================
--- trunk/bibdesk/BibItem.m 2025-07-22 16:06:42 UTC (rev 29332)
+++ trunk/bibdesk/BibItem.m 2025-07-22 16:30:21 UTC (rev 29333)
@@ -1040,7 +1040,7 @@
- (BOOL)isValidCiteKey:(NSString *)proposedCiteKey{
if ([NSString isEmptyString:proposedCiteKey])
return NO;
- NSArray *items = [[owner publications] allItemsForCiteKey:proposedCiteKey];
+ NSArray *items = [[owner publications] itemsForCiteKey:proposedCiteKey];
return [items count] == 0 || ([items count] == 1 && [items firstObject] ==
self);
}
@@ -1048,7 +1048,7 @@
if ([NSString isEmptyString:key])
return NO;
- NSArray *crossreffedItems = [[owner publications] allItemsForCrossref:key];
+ NSArray *crossreffedItems = [[owner publications] itemsForCrossref:key];
return [crossreffedItems count] > 0 && ([crossreffedItems count] > 1 ||
[crossreffedItems firstObject] != self);
}
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