Fix order of window buttons in xfce panel
Do this: right-click on the panel, navigate to Panel > Panel Preferences..., then change to the Items tab, and select the Window Buttons item. Click the settings button, and in the dialog that opens, change the Sorting order dropdown menu to "Timestamp". That should fix it.