Fix layout error

Fix error when engine tryed to use main application layout.