And mine heart walked after mine eyes— The expression is strong and beautiful. The meaning of this latter clause is, "If my eyes have seduced my heart, or any corruption have defiled my hands."
Related Commentaries of Job 31:7
Job 31:7
7 If my step hath turned out of the way, and mine heart walked after mine eyes, and if any blot hath cleaved to mine hands;