support html browser under unix
authorca
Fri, 28 Jul 2006 14:06:24 +0200
changeset 2141 8decb5cd7766
parent 2140 f6da72fe0e4b
child 2142 d9537c2a5c64
support html browser under unix
MIMETypes.st
--- a/MIMETypes.st	Mon Jul 24 14:31:43 2006 +0200
+++ b/MIMETypes.st	Fri Jul 28 14:06:24 2006 +0200
@@ -195,6 +195,17 @@
     unixCommands at:'application/x-tar-compressed' put:'gunzip < %1 | tar tvf -'.
     unixCommands at:'application/pdf'              put:'acroread -display %2 %1'.
 
+    OperatingSystem isMSWINDOWSlike ifFalse:[ |cmd|
+        cmd := #( firefox mozilla netscape opera )
+                detect:[:aCmd| (OperatingSystem pathOfCommand:aCmd) notEmptyOrNil ]
+                ifNone:nil.
+
+        cmd notNil ifTrue:[
+            unixCommands at:'text/html' put:(cmd, ' %1')       
+        ].
+    ].
+
+
     DefaultPrintCommandPerMIMEPerOS := Dictionary new.
     DefaultPrintCommandPerMIMEPerOS at:#unix  put:(unixPrintCommands := Dictionary new).
     DefaultPrintCommandPerMIMEPerOS at:#win32 put:(win32PrintCommands := Dictionary new).
@@ -1051,7 +1062,7 @@
 !MIMETypes class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview2/MIMETypes.st,v 1.85 2006-03-03 13:41:29 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview2/MIMETypes.st,v 1.86 2006-07-28 12:06:24 ca Exp $'
 ! !
 
 MIMETypes initialize!