问题
While i finished developing an in-app-purchase application, and after several testing on iPad/Iphone, every thing was fine, the images of table view's cells and its hight was exactly as wrote in code, so i upload the application, when it was processed to the app Store, i download it, the table view cells in both IPhone/IPad were in different sizes much bigger size then that was set while testing,so the image in cells was like stretched!!!!and not clear, i tried to test it then directly via xcode to my device, it was almost fine as before, but the problem is only when downloading from store,
I really appreciate any help,


Regards,
回答1:
This is quite likely to be do with floating-point calculation optimization.
When building for release, by default, Xcode will try to fully optimize your code, including making your floating-point calculations more efficient. However, sometimes they can be incorrectly optimized, and this can cause major issues especially with positioning / sizing of views etc.
For me, this happens when building for release + armv6 architecture, and I've had exactly the same problem (only realized when released) before.
Thankfully, there is a way to disable the floating-point optimizations. Here's how:
Using LLVM GCC 4.2
- Click on your project in the files pane on the left
- Click the project name under
Targets
(as seen below), then click "Build Settings". - Search for "thumb" in the search box on the right hand side
- You should see a setting called "Compile for Thumb" under "LLVM GCC 4.2 - Code Generation". If you don't, it's because you're using the Apple LLVM compiler 3.0 (instructions for that are below).
- Hover over Release, and click the plus icon.
- A new option should appear, with a drop-down, select "ARMv6" from the dropdown.
- Then select "No" for that option. It should now look like below:

Using Apple LLVM 3.0 Compiler
- Follow steps 1 and 2 above.
- Search for "other c flags" in the search box
- Follow the same steps above to add a specific configuration for ARMv6 + release.
- Double-click the box with the flags in, and add the flag
-mno-thumb
. It should now look like below

If it still has issues under the release build after that, you may want to try disabling compile for thumb globally.
Hope that helps.
回答2:
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
return 120; // also custom uitableviewcell should have same height
}
来源:https://stackoverflow.com/questions/9328122/images-of-uitableview-cells-change