Temperance is necessary, a person who spends too much time on the computer loses his willpower to resist stimuli because he is used to receiving his emotional life from the content on the computer rather than actively producing, suppressing, and controlling his emotional life.
Therefor you should change your lifestyle and spend much less time on the computer, to none at all if it is a near occasion of sin.
Go out, exercise, join a gym or Y, do various activities that do not make your emotional life one determined by passive reception to immediate stimuli and gratification such as TV, computers, etc.
Also, when one does use a computer, as a man, one should normally turn off images for all websites and then only allow them on trusted websites so as to avoid near occasions of sin.
Also do not forget to say 3 Aves morning and evening.
I will say them for you now.