Yes. Even though the pitcher did not throw a pitch he was the
pitcher of record when the winning runs scored. So he would get
credit for the win. Let's say this happened in the 6th inning: A
pitcher comes in with the bases loaded, two out, and his team is
trailing 6-4. He picks the runner off of first base before he
throws a pitch. In the bottom of the 6th the pitcher is pinch hit
for and his team scores 4 runs to put his team ahead 8-6. The game
ends with a score of 8-7. The pitcher would be credited with the
win in this case because, as before, he was the pitcher of record
when the go-ahead runs scored. I cannot recall this ever happening
but, by rule, a pitcher can be credited with a win without throwing
a single pitch.