code: protected function remapSorting($arrFiles, $arrSource)
      {
          $files  = array();
          $source = array();
  
          foreach (array_keys($arrFiles) as $k) {
              $files[]  = $arrFiles[$k];
              $source[] = $arrSource[$k];
          }
  
          $this->addClasses($source);
  
          return array
          (
              'files' => $files,
              'source' => $source
          );
      }
docs: Maps the sorting from the files to the source.
  
  All files from $arrFiles are being walked and the corresponding entry from source gets pulled in.
  
  Additionally, the css classes are applied to the returned 'source' array.
  
  This returns an array like: array('files' => array(), 'source' => array())
  
  @param array $arrFiles  The files to sort.
  
  @param array $arrSource The source list.
  
  @return array The mapped result.