Adds several modifications in the glwidget and some tests