diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/class/catalog.class.php | 20 | ||||
-rw-r--r-- | lib/ui.lib.php | 2 |
2 files changed, 21 insertions, 1 deletions
diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php index 6c93e549..3f854b11 100644 --- a/lib/class/catalog.class.php +++ b/lib/class/catalog.class.php @@ -902,6 +902,26 @@ class Catalog { $file = "$dir/$preferred_filename"; if ($file_handle = fopen($file,"w")) { if (fwrite($file_handle, $image['0']['raw'])) { + + // Also check and see if we should write out some meta data + if ($methods['metadata']) { + switch ($methods['metadata']) { + case 'windows': + $meta_file = $dir . '/desktop.ini'; + $string = "[.ShellClassInfo]\nIconFile=$file\nIconIndex=0\nInfoTip=$album->full_name"; + break; + default: + case 'linux': + $meta_file = $dir . '/.directory'; + $string = "Name=$album->full_name\nIcon=$file"; + break; + } // end switch + + $meta_handle = fopen($meta_file,"w"); + fwrite($meta_handle,$string); + fclose($meta_handle); + + } // end metadata $i++; if (!($i%100)) { echo "Written: $i. . .\n"; diff --git a/lib/ui.lib.php b/lib/ui.lib.php index aa28af36..8898298c 100644 --- a/lib/ui.lib.php +++ b/lib/ui.lib.php @@ -646,7 +646,7 @@ function show_album_select($name='album',$album_id=0,$allow_add=0,$song_id=0) { if ($allow_add) { // Append additional option to the end with value=-1 - echo "\t<option value=\"-1\">Add New...</option>\n"; + echo "\t<option value=\"-1\">" . _('Add New') . "...</option>\n"; } echo "</select>\n"; |