【发布时间】:2011-09-23 08:07:45
【问题描述】:
这是我的代码的一部分。
NSLog(@"fr: %@", NSStringFromCGRect(frame_)); NSLog(@"org: %@",
NSStringFromCGPoint(frame_.origin)); // cell.frame = frame_; [cell
setFrame: frame_];
NSLog(@"c: %@", cell); NSLog(@"c frame: %@",
NSStringFromCGRect(cell.frame));
打印输出令人惊讶。有人对此有任何想法吗?帮助和感谢。
[657:707] fr: {{350, 600}, {175, 300}}
[657:707] org: {350, 600}
[657:707] c: <JXUIGridViewCell: 0xf62d3c0; frame = (nan nan; 175 300); tag = 4010; animations = { position=<CABasicAnimation: 0x15b4a0>; bounds=<CABasicAnimation: 0x15b540>; }; layer = <CALayer: 0xf62d400>>
[657:707] c frame: {{nan, nan}, {175, 300}}
【问题讨论】:
-
你没有说你是怎么得到frame_的。你能显示那个代码吗?
-
我不记得如何获得
frame_。但是,NSLog 打印输出可以告诉frame_中的内容。对吗? -
你能解决这个问题吗?我目前也有同样的情况,不知道我的代码有什么问题。