summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-01-23 14:17:16 +0100
committerhut <hut@lavabit.com>2010-01-23 14:17:16 +0100
commitc3cdeb9cbb3a4718d8b0d707e0864c00aca7a580 (patch)
tree9dd35559991c3c896e3e24335cd8e53c9bccf148
parentfb8ee36af09461b09146137c5195c479a7d7fbcd (diff)
downloadranger-c3cdeb9cbb3a4718d8b0d707e0864c00aca7a580.tar.gz
apps: added handler for common webbrowsers
-rw-r--r--ranger/defaults/apps.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/ranger/defaults/apps.py b/ranger/defaults/apps.py
index 49233ce3..10c522fe 100644
--- a/ranger/defaults/apps.py
+++ b/ranger/defaults/apps.py
@@ -29,6 +29,8 @@ class CustomApplications(Applications):
 		if f.extension is not None:
 			if f.extension in ('pdf'):
 				return self.either(c, 'apvlv', 'evince')
+			if f.extension in ('html', 'htm', 'xhtml', 'swf'):
+				return self.either(c, 'firefox', 'opera', 'elinks')
 			if f.extension in ('swc', 'smc'):
 				return self.app_zsnes(c)
 
@@ -125,9 +127,17 @@ class CustomApplications(Applications):
 		if c.mode is 2:
 			return tup("make", "clear")
 	
+	@depends_on('elinks')
+	def app_elinks(self, c):
+		return tup('elinks', *c)
+	
+	@depends_on('opera')
+	def app_elinks(self, c):
+		return tup('opera', *c)
+	
 	@depends_on('firefox')
 	def app_firefox(self, c):
-		return tup("firefox")
+		return tup("firefox", *c)
 
 	@depends_on('javac')
 	def app_javac(self, c):