summaryrefslogtreecommitdiffstats
path: root/apps/files/js/breadcrumb.js
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2014-04-04 11:32:07 +0200
committerVincent Petry <pvince81@owncloud.com>2014-04-04 11:34:26 +0200
commita4eafca77f86ab2630bec698c3302c93daddb991 (patch)
treed19954cea3761efe945e1cee0816c69fc555e94b /apps/files/js/breadcrumb.js
parent8a10c44eb33d45e2deba7d72b30e509fa332fb24 (diff)
downloadnextcloud-server-a4eafca77f86ab2630bec698c3302c93daddb991.tar.gz
nextcloud-server-a4eafca77f86ab2630bec698c3302c93daddb991.zip
Moved code to replace svg with png to OC.Util
- Moved code that replaces the "svg" extension for the given file to core as OC.Util.replaceSVGIcon. - Added unit test for OC.Util.replaceSVGIcon - Moved "replaceSVG" to OC.Util.replaceSVG and deprecated the global "replaceSVG" function. - Added alias for SVGSupport() as OC.Util.hasSVGSupport() (for now)
Diffstat (limited to 'apps/files/js/breadcrumb.js')
-rw-r--r--apps/files/js/breadcrumb.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/apps/files/js/breadcrumb.js b/apps/files/js/breadcrumb.js
index ff017a22bb5..5bc2fac1369 100644
--- a/apps/files/js/breadcrumb.js
+++ b/apps/files/js/breadcrumb.js
@@ -20,7 +20,6 @@
*/
/* global OC */
-/* global SVGSupport, replaceSVG */
(function() {
/**
* Creates an breadcrumb element in the given container
@@ -104,8 +103,8 @@
$crumb.addClass('last');
// in case svg is not supported by the browser we need to execute the fallback mechanism
- if (!SVGSupport()) {
- replaceSVG();
+ if (!OC.Util.hasSVGSupport()) {
+ OC.Util.replaceSVG(this.$el);
}
// setup drag and drop