I think there is a little bug in column header with gridview when sorting a grouped column and ShowGroupedColumns = true.
Changing sorting direction only works first time, then you need to click on grouped tag to change sorting direction. See attached gif
I have attached the example project used in the gif to test this.