Provides standard layout lookup behavior for method and proc cases

When setting the layout either by referencing a method or supplying a
Proc there is no way to fall back to the default lookup behavior if
desired. This patch allows fallback to the layout lookup behavior when
returning nil from the proc or method.
Merge pull request #8458 from lucisferre/improve-layout-override-fallback-behavior

Provides standard layout lookup behavior for method and proc cases

Conflicts:
	actionpack/CHANGELOG.md