]> source.dussan.org Git - nextcloud-server.git/commitdiff
always show home breadcrumb in files view
authorBjoern Schiessle <schiessle@owncloud.com>
Fri, 13 Dec 2013 13:34:26 +0000 (14:34 +0100)
committerBjoern Schiessle <schiessle@owncloud.com>
Mon, 16 Dec 2013 16:40:35 +0000 (17:40 +0100)
apps/files/templates/part.breadcrumb.php
core/js/js.js

index 9db27eb9b2935a8282b87efbb75a4f7c6f25cc90..90d07d4336cd233149971d762c808fb62e87335e 100644 (file)
@@ -1,10 +1,8 @@
-<?php if(count($_["breadcrumb"])):?>
-       <div class="crumb" data-dir=''>
-               <a href="<?php print_unescaped($_['baseURL']); ?>">
-                       <img src="<?php print_unescaped(OCP\image_path('core', 'places/home.svg'));?>" class="svg" />
-               </a>
-       </div>
-<?php endif;?>
+<div class="crumb <?php if(!count($_["breadcrumb"])) p('last');?>" data-dir=''>
+       <a href="<?php print_unescaped($_['baseURL']); ?>">
+               <img src="<?php print_unescaped(OCP\image_path('core', 'places/home.svg'));?>" class="svg" />
+       </a>
+</div>
 <?php for($i=0; $i<count($_["breadcrumb"]); $i++):
        $crumb = $_["breadcrumb"][$i];
        $dir = \OCP\Util::encodePath($crumb["dir"]); ?>
index d9b3b54e0a1628104a0396d22d261f0e261d38ab..66faa48f85f97aaf650b24d1bc4183ace611cb82 100644 (file)
@@ -471,11 +471,11 @@ OC.Breadcrumb={
        },
        _show:function(container, dir, leafname, leaflink){
                var self = this;
-               
+
                this._clear(container);
-               
+
                // show home + path in subdirectories
-               if (dir && dir !== '/') {
+               if (dir) {
                        //add home
                        var link = OC.linkTo('files','index.php');
 
@@ -502,7 +502,7 @@ OC.Breadcrumb={
                                }
                        });
                }
-               
+
                //add leafname
                if (leafname && leaflink) {
                        this._push(container, leafname, leaflink);