Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 517961

Summary: [Win32][Browser] Case for HTML-Javascript not working in Internal Web Browser
Product: [Eclipse Project] Platform Reporter: David Christensen <davidaca>
Component: SWTAssignee: Niraj Modi <niraj.modi>
Status: RESOLVED NOT_ECLIPSE QA Contact:
Severity: normal    
Priority: P3 CC: arunkumar.thondapu, daniel_megert, kitlo, lshanmug, niraj.modi
Version: 4.6Keywords: triaged
Target Milestone: 4.8   
Hardware: PC   
OS: Windows 10   
Whiteboard:
Attachments:
Description Flags
Import the project, open consoleusersdetailmain.htm with Internal Web Brower and click an option. none

Description David Christensen CLA 2017-06-07 13:19:31 EDT
Created attachment 268796 [details]
Import the project, open consoleusersdetailmain.htm with Internal Web Brower and click an option.

When using HTML Select Option tags, when clicking on the options, the options are not selected or deselected. Javascript is executed with click events.

A workaround 
It works when adding arguments in the eclipse.ini:
-Dorg.eclipse.swt.browser.DefaultType=ie
-Dorg.eclipse.swt.browser.IEVersion=9999

Files to reproduce are attached.
Comment 1 David Christensen CLA 2017-06-07 13:23:17 EDT
I've found errors in the javascript console within Edge Navigator

SCRIPT5009: 'XULElement' is undefined
menu_functions.js (324,1)
Comment 2 Arun Thondapu CLA 2017-06-15 06:29:09 EDT
(In reply to David Christensen from comment #0)
> Created attachment 268796 [details]
> Import the project, open consoleusersdetailmain.htm with Internal Web Brower
> and click an option.
> 
> When using HTML Select Option tags, when clicking on the options, the
> options are not selected or deselected. Javascript is executed with click
> events.
> 
> A workaround 
> It works when adding arguments in the eclipse.ini:
> -Dorg.eclipse.swt.browser.DefaultType=ie
> -Dorg.eclipse.swt.browser.IEVersion=9999
> 
> Files to reproduce are attached.

Are you saying that this works when opened directly in the browser and fails only in the Internal Web Browser? Which version of IE do you have installed?

Niraj, can you please try this out?
Comment 3 David Christensen CLA 2017-06-19 12:55:26 EDT
> Are you saying that this works when opened directly in the browser and fails
> only in the Internal Web Browser? Which version of IE do you have installed?
> 
> Niraj, can you please try this out?


Version 11 of IE. It can also be reproduced on Windows 8 with IE 11.
(11.0.9600.18666)
Comment 4 Kit Lo CLA 2017-08-11 14:11:56 EDT
Any progress?
Comment 5 Dani Megert CLA 2017-08-14 09:17:22 EDT
Niraj, please have a look.
Comment 6 Niraj Modi CLA 2017-11-13 08:16:02 EST
(In reply to David Christensen from comment #1)
> I've found errors in the javascript console within Edge Navigator
> 
> SCRIPT5009: 'XULElement' is undefined
> menu_functions.js (324,1)

Investigation suggested that the issue lies at Java-Script end and not with SWT, summarizing my investigation below:
Tried the 'consoleusersdetailmain.htm' and associated Java-Scripts attached on the public bug 517961

Selection issue not seen on Win7 neither with Stand-alone IE11 nor with embedded IE11.

Could reproduce the selection issue on my Win10 setup:
- Embedded IE11 browser and Edge browser shows up the selection issue.
- Stand-alone IE11 doesn't have any selection issue.

When I open the HTML by removing the associated Java-Scripts, selection works fine even with embedded-IE11 on Win10, which suggests some issue with the JavaScript itself.

After further investigation on lines with (https://bugs.eclipse.org/bugs/show_bug.cgi?id=517961#c1) could narrow down the problem to the 'XULElement' reference call in 'menu_functions.js' line 319, on changing the list-selection error is reported on the Edge console.

Hence marking this issue as NOT_ECLIPSE from SWT side. Thanks!