Gallery order specified by shortcodes is ignored in gallery function

Since 3.5, the gallery shortcode works a bit differently, the order is embedded within the shortcode itself, in the form of the ids= attribute. In your call to get_posts, change orderby to post__in, and pass the ids as include argument.

For more specifics, look inside wp-includes/media.php at the gallery_shortcode function to see how core does it.