Proton transfer in model hydrogen-bonded systems by a density functional approach