The father has the primary right to the child. When mother died, the child should automatically be in father's custody. Mother does not have the power to grant custody to anyone. Step-father can sue for custody but must show father is essentially unfit.
I agree with Mr. Krusch, but would add that if the child has lived for a long period of time with the step father, and the biological father has been absent, the step father may be able to show the biological father has acted inconsistent with his paramount right to custody. If that is the case, then the court can award custody based upon what is in the best interest of the child.