Skip to content

Comment on Show HN: iOS Table View that automatically adjusts with keyboard show/hideparent

Comments

When using CGFloat you want to make sure to use 0.0 and 50.0.

Actually, on iOS, CGFloat is 32 bits, so you should use '0.0f' and '50.0f'.

On the Mac, in, 64-bit, it's a 64-bit value, so your advice would be correct there.

It is slightly annoying there's no easy way to write a CGFloat literal in a cross-platform way apart from the overly verbose '((CGFloat)50.0)'.

You are - of course - correct. Did too much Mac development lately. :)

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.