Fixed point theorems under $w$-distance on a metric space endowed with a graph