Fix error when using wxWidgets >= 3.0.