Let $G$ be a finite group and $A = \mathbb{C}[G]$ its group algebra with a basis $(u_g)_{g\in G}$. Assume it to be known that $\sum_{g\in G}\gamma(g)u_g$ is in the centre of $A$ iff $\gamma(gh) = \gamma(hg), \forall g, h \in G$. Suppose that $\gamma:G\to \mathbb{C}$ is a class function, i.e. it is constant on all conjugacy classes of $G$, and that $\gamma$ is orthogonal to every irreducible representation of the group $G$. I'd like to show that 1.) $\sum_{g \in G}\gamma(g)\rho(g) \equiv 0$ for every irreducible representation $\rho$ of $G$ and 2.) that the number of irreducible (complex) representations $G$ has is equal to the number of conjugacy classes of $G$. I was wondering whether the following suffices for 1.) and 2.)
For 1.) Let $\rho$ be any irreducible representation of $G$ and $h \in G$. Then $\sum_{g\in G}\gamma(g)\rho(g)\rho(h) = \sum_{g\in G}\gamma(g)\rho(gh) = \sum_{r\in G}\gamma(rh^{-1})\rho(r) = \sum_{r\in G}\gamma(h^{-1}r)\rho(r) = \sum_{r\in G}\gamma(h^{-1}r)\rho(r) = \sum_{u\in G}\gamma(u)\rho(hu)$ which then yields $\sum_{u\in G}\gamma(u)\rho(hu) = \sum_{u\in G}\gamma(u)\rho(h)\rho(u) = \rho(h)\sum_{u\in G}\gamma(u)\rho(u)$, by couple change of variables.
So it follows that $f(\rho) = \sum_{g\in G}\gamma(g)\rho(g):V\to V$ is an intertwining map and therefore by Schur's lemma and linearity of trace $\lambda * \mathrm{dim}(\rho) = \mathrm{tr}(\sum_{g\in G}\gamma(g)\rho(g)) = \sum_{g\in G}\frac{|G|}{|G|}\gamma(g)\mathrm{tr}(\rho(g)) = |G|\frac{1}{|G|}\sum_{g\in G}\gamma(g)\chi_\rho(g) = |G|\left<\overline{\chi_\rho}, \gamma\right> = |G|\cdot 0 = 0$ with the innerproduct $\left<\rho_1, \rho_2\right> = \frac{1}{|G|}\sum_{g\in G}\overline{\rho_1(g)}\rho_2(g)$, as $\gamma$ was assumed to be orthogonal to every irreducible representation. Moreover, if $f$ and $g$ are orthogonal then so are $\overline{f}$ and $g$ (right?). Since $\mathrm{dim}(\rho) > 0$, it follows that $\lambda = 0$ and therefore $f(\rho) = \sum_{g\in G}\gamma(g)\rho(g) \equiv 0$ for every representation $\rho$. In particular, this holds true for the regular representation $\rho(g)u_h = u_{gh}$. But as the basis vector $(u_g)_{g \in G}$ are linearly independent, it follows that $\gamma \equiv 0$.
As for 2.) Since we know from Schur's lemma that the inner product of the characters of two irreducible representations is 0 iff the representations are non-isomorphic and characters are class functions, it follows that the characters of two non-isomorphic representations are linearly independent. Therefore, the number of irreducible representations of $G$ is at most the number of conjugacy classes. But we showed that the only class function $\gamma$ which is orthogonal to all characters of irreducible representations of $G$ is necessarily the zero function, it follows that there are not class functions which are not spanned by the characters of the irreducible representations of $G$. Therefore, the said characters form a basis for the set of class functions of $G$ and it follows that $G$ has as many conjugacy classes as it has irreducible representations.