Fixed some issues that were preventing the layout from working on Mac OS.