Add SliderGUI::getIndex() method.

It allows to know the index of the slide we're in.

It's only meaningful with SliderBlockGUI, but since some compilation
problems with the rest of the project, it was better to simply create
it as a virtual method in the base class (SliderGUI).