Fix #324 do not process actions if not in layout