You are here

function picture_compare_weights in Picture 7.2

Same name and namespace in other branches
  1. 7 picture.admin.inc \picture_compare_weights()

Sort picture groups for the CKEditor image dialog.

1 string reference to 'picture_compare_weights'
picture_admin_settings_submit in ./picture.admin.inc
Submit handler, places chosen picture groups into the variables table.

File

./picture.admin.inc, line 443
Picture - map breakpoints and image styles.

Code

function picture_compare_weights($a, $b) {
  if ($a['weight'] == $b['weight']) {
    return 0;
  }
  return $a['weight'] < $b['weight'] ? -1 : 1;
}