@@ -69,7 +69,7 @@ - (void)awakeFromNib
69
69
70
70
- (void )populateList
71
71
{
72
- NSLog (@" [%@ %s ]" , [self class ], _cmd);
72
+ // NSLog(@"[%@ %s]", [self class], _cmd);
73
73
74
74
PBSourceViewItem *project = [PBSourceViewItem groupItemWithTitle: [repository projectName ]];
75
75
project.isUncollapsible = YES ;
@@ -166,20 +166,20 @@ - (void)populateList
166
166
if (resolvedRev) {
167
167
repository.currentBranch = resolvedRev;
168
168
// repository.currentBranch.isSimpleRef = YES;
169
- NSLog (@" [%@ %s ] currentBranch = %@ " , [self class ], _cmd, repository.currentBranch );
170
- NSLog (@" [%@ %s ] items = %@ " , [self class ], _cmd, [items description ]);
169
+ // NSLog(@"[%@ %s] currentBranch = %@", [self class], _cmd, repository.currentBranch);
170
+ // NSLog(@"[%@ %s] items = %@", [self class], _cmd, [items description]);
171
171
for (PBSourceViewItem * item in items) {
172
172
if (deferredSelectObject = [item findRev: resolvedRev])
173
173
break ;
174
174
}
175
- NSLog (@" [%@ %s ] deferredSelectObject = %@ " , [self class ], _cmd, deferredSelectObject);
175
+ // NSLog(@"[%@ %s] deferredSelectObject = %@", [self class], _cmd, deferredSelectObject);
176
176
}
177
177
}
178
178
}
179
179
180
180
- (void ) observeValueForKeyPath : (NSString *)keyPath ofObject : (id )object change : (NSDictionary *)change context : (void *)context
181
181
{
182
- NSLog (@" [%@ %s ]" , [self class ], _cmd);
182
+ // NSLog(@"[%@ %s]", [self class], _cmd);
183
183
184
184
if ([@" currentBranchChange" isEqualToString: context]) {
185
185
[sourceView reloadData ];
@@ -227,7 +227,7 @@ - (void) selectBranch:(PBSourceViewItem *)branchItem
227
227
{
228
228
[sourceView PBExpandItem: branchItem expandParents: YES ];
229
229
NSInteger row = [sourceView rowForItem: branchItem];
230
- NSLog (@" [%@ %s ] rowForItem (%@ ) = %d " , [self class ], _cmd, branchItem, row);
230
+ // NSLog(@"[%@ %s] rowForItem (%@) = %d", [self class], _cmd, branchItem, row);
231
231
NSIndexSet *index = [NSIndexSet indexSetWithIndex: row];
232
232
[sourceView selectRowIndexes: index byExtendingSelection: NO ];
233
233
}
@@ -236,7 +236,7 @@ - (PBSourceViewItem *) itemForRev:(PBGitRevSpecifier *)rev {
236
236
PBSourceViewItem *foundItem = nil ;
237
237
for (PBSourceViewItem *item in items) {
238
238
if (foundItem = [item findRev: rev]) {
239
- NSLog (@" [%@ %s ]: found item! Item = %@ for rev = %@ " , [self class ], _cmd, item, rev);
239
+ // NSLog(@"[%@ %s]: found item! Item = %@ for rev = %@", [self class], _cmd, item, rev);
240
240
return foundItem;
241
241
}
242
242
}
@@ -245,9 +245,9 @@ - (PBSourceViewItem *) itemForRev:(PBGitRevSpecifier *)rev {
245
245
246
246
- (BOOL ) selectCommitWithSha : (NSString *)refSHA {
247
247
NSArray *revList = repository.revisionList .commits ;
248
- NSLog (@" [%@ %s ] revList = %@ " , [self class ], _cmd, revList);
248
+ // NSLog(@"[%@ %s] revList = %@", [self class], _cmd, revList);
249
249
for (PBGitCommit *commit in revList) {
250
- NSLog (@" [%@ %s ] commit = %@ " , [self class ], _cmd, commit);
250
+ // NSLog(@"[%@ %s] commit = %@", [self class], _cmd, commit);
251
251
if ([[commit realSha ] isEqualToString: refSHA]) {
252
252
[historyViewController selectCommit: refSHA];
253
253
return YES ;
@@ -260,7 +260,7 @@ - (void) selectCurrentBranch
260
260
{
261
261
PBGitRevSpecifier *rev = repository.currentBranch ;
262
262
263
- NSLog (@" [%@ %s ] rev = %@ " , [self class ], _cmd, rev);
263
+ // NSLog(@"[%@ %s] rev = %@", [self class], _cmd, rev);
264
264
265
265
if (deferredSelectObject) {
266
266
NSString * sha = [ApplicationController sharedApplicationController ].deferredSelectSha ;
@@ -270,7 +270,7 @@ - (void) selectCurrentBranch
270
270
}
271
271
272
272
[self selectBranch: deferredSelectObject];
273
- // [historyViewController selectCommit:sha];
273
+
274
274
deferredSelectObject = nil ;
275
275
return ;
276
276
}
@@ -280,24 +280,8 @@ - (void) selectCurrentBranch
280
280
[repository readCurrentBranch ];
281
281
return ;
282
282
}
283
- // else {
284
- // NSString * refSHA = [repository shaForRef:[rev ref]];
285
- // if (![self selectCommitWithSha:refSHA]) {
286
- // [repository reloadRefs];
287
- // [self selectCommitWithSha:refSHA];
288
- // }
289
- // }
290
283
291
284
PBSourceViewItem *item = [self itemForRev: rev];
292
-
293
- // if (!item) {
294
- // // Obviously we havn't found the item so we reset it's isSimpleRef status back to NO
295
- // // so it will get added to the OTHER group.
296
- // //[rev setIsSimpleRef:NO];
297
- // [self addRevSpec:rev];
298
- // // Try to find the just added item again.
299
- // item = [self itemForRev:rev];
300
- // }
301
285
[self selectBranch: item];
302
286
}
303
287
0 commit comments