What does it mean that every open set in the weak* topology is open in the metric space? Let $(X, d)$ be a metric space and $\mathcal{M}(X)$ the collection of all probability measures defined on the measurable space $(X, \mathcal{B}(X))$.

Theorem: If $X$ is a compact metrisable space, then the space $\mathcal{M}(X)$ is metrisable in the weak* topology. If $\{f_n\}_{n \ge 1}$ is a dense subset oc $C(X)$, then 
  $$D(m, \mu) = \sum_{n=1}^\infty \frac{| \int f_n dm - \int f_n d\mu |}{2^n \| f_n \|}$$
  is a metric on $\mathcal{M}(X)$ giving the weak* topology.

In the proof of this theorem it is shown that for each $f \in C(X)$ the map $\mu \mapsto \int f d\mu$ is continuous on $(\mathcal{M}(X), D)$ and therefore every open set in the weak* topology is open in the metric space $(\mathcal{M}(X), D)$.
I don't understand why it results that every open set in the weak* topology is open in the metric space $(\mathcal{M}(X), D)$. What does it mean open set in the weak* topology?
 A: Topological definition of weak topology
Let $X$ be a set, $(X_i)_{i\in I}$ be a family of topological spaces, and $(f_i)_{i\in I}$ be a family of functions such that $f_i:X \to X_i$. The weak topology on $X$ induced by the set of functions $\{f_i \mid i \in I\}$ is the smallest topology such that each $f_i$ is continuous. This means that the weak topology is the topology generated by the the sets of the form
$$
f_i^{-1}(U),\ \text{where $i\in I$ and $U\subseteq X_i$ is open}.
$$
This means that every open set in the weak topology on $X$ is a union of sets of the form
$$
f_{i_1}^{-1}(U_1)\cap \cdots\cap f_{i_n}^{-1}(U_n),
\ \text{where $i_1,\ldots,i_n\in I$ and $U_k\subseteq X_{i_k}$ is open for each $k$}.
$$
Definition of weak* topology of a normed space
Given a normed space $X$, we can define a mapping $J:X\to X^{**}$ by $J(x)(x^*)=x^*(x)$, for all $x\in X$ and $x^*\in X^*$. The weak* topology on $X^*$ is weak topology on $X^*$ induced by the set of functions $\{J(x):X^*\to\mathbb{K} \mid x\in X\}$. Since each $J(x)$ is continuous in norm topology on $X^*$, we infer that the weak* topology is smaller (contains less open sets) than the norm topology. A basic open set of $0\in X^*$ in the weak* topology is a set of the form
$$
J(x_1)^{-1}(-\varepsilon,\varepsilon)\cap \cdots\cap J(x_n)^{-1}(-\varepsilon,\varepsilon),
\ \text{where $x_1,\ldots,x_n\in X$ and $\varepsilon>0$}.
$$
Application to your situation
If $X$ is a compact metrizable space, then $C(X)^*$ is isometrically isomorphic to $\mathcal{M}(X)$. Thus we consider $\mathcal{M}(X)$ to be the dual space of $C(X)^*$. Using the definition of $J$ and the particular isometry identifying  $C(X)^*=\mathcal{M}(X)$, we have that $J(f)(\mu) = \int f\,d\mu$. You now need to show that every set of the form
$$
J(f)^{-1}(-\varepsilon,\varepsilon),\ \text{where $f\in C(X)$ and $\varepsilon>0$},
$$
is open with respect to the metric $D$ on $\mathcal{M}(X)$.
A: $\mathcal{M}(X)$ is the dual of $C(X)$ as you should know, certainly for compact metrisable spaces. This is the Riesz representation theorem, where it is shown that a continuous functional $\phi$ on $C(X)$ (can be identified with a (signed) measure $\mu$ such that $\phi(f) = \int f d\mu$ in an isometric way (so that $\|\mu\| = \|\phi\|$), see e.g. here
Now $\mathcal{M}(X)$ has two weak topologies that are natural: the weak topology w.r.t. its own dual $\mathcal{M}^\ast$ (which is quite large), and the weak topology w.r.t. all images of canonical embedding $J: C(X) \to \mathcal{M}(X)^\ast$, (which is what the weak$^\ast$ is defined as) defined by $J(f)(\mu)  = \int f d\mu$, for $f \in C(X)$. The weak topology w.r.t. a family of functions is given (by definition) by (topology generated by) the inverse images of open sets under the functions in that family. So a typical subbasic open set in the weak$^\ast$ looks like $J(f)^{-1}[(a,b)] = \{ \mu \in \mathcal{M}(X): a < \int f d\mu < b\}$, for $f \in (X)$, and basic elements are finite intersections of such sets. 
