X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;ds=sidebyside;f=CRM%2FCore%2FResources.php;h=744e5be721ddd58c5ca1760c8606072f9feb1c06;hb=d09edf64e678a73669cff34014a55a06604de75a;hp=f160634176e937e937b04448cdce72503a988212;hpb=709e574bfc8b047d9e9f9a6ad84595bc3f560b54;p=civicrm-core.git diff --git a/CRM/Core/Resources.php b/CRM/Core/Resources.php index f160634176..744e5be721 100644 --- a/CRM/Core/Resources.php +++ b/CRM/Core/Resources.php @@ -125,7 +125,7 @@ class CRM_Core_Resources { } /** - * Construct a resource manager + * Construct a resource manager. * * @param CRM_Extension_Mapper $extMapper * Map extension names to their base path or URLs. @@ -286,7 +286,7 @@ class CRM_Core_Resources { } /** - * Helper fn for addSettingsFactory + * Helper fn for addSettingsFactory. */ public function getSettings() { $result = $this->settings; @@ -313,7 +313,7 @@ class CRM_Core_Resources { } /** - * Helper fn for addSetting + * Helper fn for addSetting. * Render JavaScript variables for the global CRM object. * * @return string @@ -439,7 +439,7 @@ class CRM_Core_Resources { } /** - * Determine file path of a resource provided by an extension + * Determine file path of a resource provided by an extension. * * @param string $ext * extension name; use 'civicrm' for core. @@ -462,7 +462,7 @@ class CRM_Core_Resources { } /** - * Determine public URL of a resource provided by an extension + * Determine public URL of a resource provided by an extension. * * @param string $ext * extension name; use 'civicrm' for core. @@ -566,7 +566,7 @@ class CRM_Core_Resources { foreach ($this->coreResourceList() as $file) { if (substr($file, -2) == 'js') { // Don't bother looking for ts() calls in packages, there aren't any - $translate = (substr($file, 0, 9) != 'packages/'); + $translate = (substr($file, 0, 3) == 'js/'); $this->addScriptFile('civicrm', $file, $jsWeight++, $region, $translate); } else { @@ -624,7 +624,7 @@ class CRM_Core_Resources { } /** - * Flushes cached translated strings + * Flushes cached translated strings. * @return CRM_Core_Resources */ public function flushStrings() { @@ -659,7 +659,7 @@ class CRM_Core_Resources { } /** - * List of core resources we add to every CiviCRM page + * List of core resources we add to every CiviCRM page. * * @return array */ @@ -672,10 +672,10 @@ class CRM_Core_Resources { // Scripts needed by everyone, everywhere // FIXME: This is too long; list needs finer-grained segmentation $items = array( - "packages/jquery/jquery-1.11.1$min.js", - "packages/jquery/jquery-ui/jquery-ui$min.js", - "packages/jquery/jquery-ui/jquery-ui$min.css", - "packages/backbone/lodash.compat$min.js", + "bower_components/jquery/dist/jquery.min.js", + "bower_components/jquery-ui/jquery-ui.min.js", + "bower_components/jquery-ui/themes/smoothness/jquery-ui$min.css", + "bower_components/lodash-compat/lodash.min.js", "packages/jquery/plugins/jquery.mousewheel$min.js", "packages/jquery/plugins/select2/select2$min.js", "packages/jquery/plugins/select2/select2.css", @@ -715,7 +715,7 @@ class CRM_Core_Resources { if ($config->lcMessages && $config->lcMessages != 'en_US') { // Search for i18n file in order of specificity (try fr-CA, then fr) list($lang) = explode('_', $config->lcMessages); - $path = "packages/jquery/jquery-ui/i18n"; + $path = "bower_components/jquery-ui/ui/i18n"; foreach (array(str_replace('_', '-', $config->lcMessages), $lang) as $language) { $localizationFile = "$path/datepicker-{$language}.js"; if ($this->getPath('civicrm', $localizationFile)) {