Skip to content
This repository
Browse code

tree icon for net-mounted roots

  • Loading branch information...
commit 4f70b095e46cf1c7300ab24e87ffca5365cf28b7 1 parent 91fb19f
Josh Schmidt authored
5 css/navbar.css
@@ -104,6 +104,11 @@
104 104 .finder-tree .finder-navbar-root .finder-navbar-icon { background-position:0 0; }
105 105 .finder-places .finder-navbar-root .finder-navbar-icon { background-position:0 -48px; }
106 106
  107 +/* netmount */
  108 +.finder-tree .finder-navbar-net .finder-navbar-icon { background-position: 0 -656px; }
  109 +
  110 +
  111 +
107 112 /* icon in active/hove/dropactive state */
108 113 .ui-state-active .finder-navbar-icon,
109 114 .finder-droppable-active .finder-navbar-icon,
4 js/ui/tree.js
@@ -173,7 +173,9 @@ $.fn.findertree = function(fm, opts) {
173 173 */
174 174 replace = {
175 175 id : function(dir) { return fm.navHash2Id(dir.hash) },
176   - cssclass : function(dir) { return (dir.phash ? '' : root)+' '+navdir+' '+fm.perms2class(dir)+' '+(dir.dirs && !dir.link ? collapsed : ''); },
  176 + cssclass : function(dir) {
  177 + return (dir.phash ? '' : root)+' '+(dir.net ? 'finder-navbar-net' : '' )+' '+navdir+' '+fm.perms2class(dir)+' '+(dir.dirs && !dir.link ? collapsed : '');
  178 + },
177 179 permissions : function(dir) { return !dir.read || !dir.write ? ptpl : ''; },
178 180 symlink : function(dir) { return dir.alias ? stpl : ''; }
179 181 },
1  php/Finder.class.php
@@ -652,6 +652,7 @@ protected function netmount($args) {
652 652
653 653 $netVolumes = $this->getNetVolumes();
654 654 $options['driver'] = $driver;
  655 + $options['netmount'] = true;
655 656 $netVolumes[] = $options;
656 657 $netVolumes = array_unique($netVolumes);
657 658 $this->saveNetVolumes($netVolumes);
4 php/FinderVolumeDriver.class.php
@@ -1117,6 +1117,10 @@ public function tree($hash='', $deep=0, $exclude='') {
1117 1117 }
1118 1118 $dir = $this->HasSubdirs($path,$dir);
1119 1119
  1120 + if( $this->options['netmount'] ){
  1121 + $dir['net'] = 1;
  1122 + }
  1123 +
1120 1124 $this->options['treeDeep'] = $this->options['treeDeep'] > 0 ? (int)$this->options['treeDeep'] : 1;
1121 1125
1122 1126 $dirs = $this->gettree($path, $deep > 0 ? $deep -1 : $this->options['treeDeep']-1, $exclude ? $this->decode($exclude) : null);

0 comments on commit 4f70b09

Please sign in to comment.
Something went wrong with that request. Please try again.