Calculation of long-distance effects in exclusive weak radiative decays of B-mesons