Yes, railways almost invariably put money into crossings as well. The actual relationship really depends on negotiation as to the public benefit and the private benefit to the railways of better safety, but railways put money into these things routinely.
On February 15th, 2011. See this statement in context.