First-principles study of electronic properties of hydrogenated graphite