One of the main problem of the optical imaging systems is limited depth of field which prevent from obtaining an all-in-focus image of the environment. This paper proposes a novel pixel-based multi-focus image fusion method making use of a series of multi-focus images to obtain an all-in-focus image. The proposed method, firstly, generate a focus map over the edges. Then, a full focus map is obtained by propagating the focus values at edge locations to the entire image. The proposed method and the state-of-the-art methods are compared in terms of both quantitative and visual evaluation. Based on the results, the proposed method outperforms the other ones.