about summary refs log tree commit diff stats
path: root/code/entry.rb
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2009-07-03 17:19:52 +0200
committerhut <hut@lavabit.com>2009-07-03 17:19:52 +0200
commitf8634dd6d2477d1871764982fe8d55f2003ab938 (patch)
tree5d278f4fd3538a2d990cd78450d0e883d0fbce1d /code/entry.rb
parent27ebfe639466906a9bdaeb3a8ade280e07921122 (diff)
downloadranger-f8634dd6d2477d1871764982fe8d55f2003ab938.tar.gz
option to show ascii only and replace non-ascii with *
Diffstat (limited to 'code/entry.rb')
-rw-r--r--code/entry.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/code/entry.rb b/code/entry.rb
index 9f0cb7b9..af1faa83 100644
--- a/code/entry.rb
+++ b/code/entry.rb
@@ -70,6 +70,10 @@ class Directory::Entry
 	alias movie? video?
 	alias sound? audio?
 
+	def displayname()
+		@displayname ||= @basename.ascii_only_if(Option.ascii_only)
+	end
+
 	def handler()
 		## get_handler has to be defined in another file
 		@handler ||= catch(:use) do