Tk Library Source Code

View Ticket
Login
Ticket UUID: 1344350
Title: Enable browser launch for links in MacOS X
Type: Patch Version: None
Submitter: treincke Created on: 2005-10-31 22:47:10
Subsystem: app: tkchat Assigned To: patthoyts
Priority: 5 Medium Severity:
Status: Closed Last Modified: 2006-03-01 00:11:14
Resolution: Accepted Closed By: wildcard_25
    Closed on: 2006-02-28 17:11:14
Description:
The tkchat.tcl has code to allow clicking on URLs in the chat 
window. The ::tkchat::gotoURL procedure then calls an appropriate 
browser to open the URL. The code differenciates between 
platforms via $tcl_platform(platform) and therefore uses the code 
for $tcl_platform(platform) == "unix" also for MacOS X. This does 
not work, since launching a program in MacOS X is done via the 
"open -a" command and not directly like in other unices.

The attached patch adds another case inside the "unix" branch of 
the switch statement in ::tkchat::gotoURL to handle MacOS X 
(using $tcl_platform(os)). It tries to launch the browser specified in 
the $Options(BROWSER) variable. If this fails, the code tries to 
launch the Safari browser, which should be available at all times. If 
this also fails, an error message is displayed.
User Comments: wildcard_25 added on 2006-03-01 00:11:14:
Logged In: YES 
user_id=596509

patch was applied to v1.316

treincke added on 2005-11-01 05:47:12:

File Added - 154609: tkchat-diff-u.txt

Attachments: