[maccode] r284 commited - We have an 'item' local variable; use it consistently to make this cod...

0 views
Skip to first unread message

codesite...@google.com

unread,
Jul 27, 2009, 5:34:44 PM7/27/09
to mac...@googlegroups.com
Revision: 284
Author: tekjew
Date: Mon Jul 27 14:33:40 2009
Log: We have an 'item' local variable; use it consistently to make this
code clearer
http://code.google.com/p/maccode/source/detail?r=284

Modified:
/trunk/Utilities/PSMTabBarControl/source/PSMTabBarControl.m

=======================================
--- /trunk/Utilities/PSMTabBarControl/source/PSMTabBarControl.m Sat Apr 4
12:52:16 2009
+++ /trunk/Utilities/PSMTabBarControl/source/PSMTabBarControl.m Mon Jul 27
14:33:40 2009
@@ -636,37 +636,37 @@
[cell unbind:@"isEdited"];

if ([item identifier] != nil) {
- if ([[[cell representedObject] identifier]
respondsToSelector:@selector(isProcessing)]) {
- [[[cell representedObject] identifier] removeObserver:cell
forKeyPath:@"isProcessing"];
+ if ([[item identifier] respondsToSelector:@selector(isProcessing)]) {
+ [[item identifier] removeObserver:cell forKeyPath:@"isProcessing"];
}
}

if ([item identifier] != nil) {
- if ([[[cell representedObject] identifier]
respondsToSelector:@selector(icon)]) {
+ if ([[item identifier] respondsToSelector:@selector(icon)]) {
[[item identifier] removeObserver:cell forKeyPath:@"icon"];
}
}

if ([item identifier] != nil) {
- if ([[[cell representedObject] identifier]
respondsToSelector:@selector(objectCount)]) {
+ if ([[item identifier] respondsToSelector:@selector(objectCount)]) {
[[item identifier] removeObserver:cell forKeyPath:@"objectCount"];
}
}

if ([item identifier] != nil) {
- if ([[[cell representedObject] identifier]
respondsToSelector:@selector(countColor)]) {
+ if ([[item identifier] respondsToSelector:@selector(countColor)]) {
[[item identifier] removeObserver:cell forKeyPath:@"countColor"];
}
}

if ([item identifier] != nil) {
- if ([[[cell representedObject] identifier]
respondsToSelector:@selector(largeImage)]) {
+ if ([[item identifier] respondsToSelector:@selector(largeImage)]) {
[[item identifier] removeObserver:cell forKeyPath:@"largeImage"];
}
}

if ([item identifier] != nil) {
- if ([[[cell representedObject] identifier]
respondsToSelector:@selector(isEdited)]) {
+ if ([[item identifier] respondsToSelector:@selector(isEdited)]) {
[[item identifier] removeObserver:cell forKeyPath:@"isEdited"];
}
}

Reply all
Reply to author
Forward
0 new messages