get the URL of a new window event in SWT Browser

youpunkx

New Member
I am creating a Browser using SWT and would like to handle newWindow events using code I have already written that creates a new window (or tab depending on user preferences). After looking at the pop-up window snippet on the SWT page I'm a bit confused. Why is it so complicated to open a new window? Why does event.location return null? Why did the creators of SWT not handle new window events like so - create a new shell, new browser, add desired listeners, set the url of the browser to the url of the new window event, and open the shell.Most importantly, what is the best way to get the URL of the new window being opened so I can handle the event myself. Thanks for the help!
 
Back
Top