document-panel: group row wrong name and position

When adding tab group before the last one, group row
name and position are wrong.

https://bugzilla.gnome.org/show_bug.cgi?id=725923