Generify in MediaElement the gstreamer element management

Change-Id: Iffd0a2a0bc4d86af0c7bb7ecd22c4186cb680857