1. Using SmartGWT 4.0 (patched 20140401) and SmartClient Version: v9.0p_2014-04-01/LGPL Development Only (built 2014-04-01)
2. IE10 (neither FF nor Chrome appear to be affected).
3. No logged errors either client or server side.
4. Sample code attached.
I've tried to boil my attached code down to the most basic situation I could get the issue to be reproducible. Unfortunately, I wasn't able to isolate the issue in such a way that it would present when running in Native Mode. That means the code will only show the issue in Hosted Mode. However, my main application where I discovered this issue was reproducing in Native Mode.
The basic issue is that: when I click on a ComboBoxItem's arrow to open the results my "window.location.hash" value clears out. This only seems to happen when I have a click handler attached to the document. I noticed in my test case it was also dependent on the event handler function being wrapped in the $entry() method (which I do need because in practice I will be calling back into GWT). The handler doesn't have to do anything, it just has to be attached. I can fix the issue without any side-effects by calling jQuery's preventDefault() method on the event, but I'm not sure yet if there will be no further issue or not so I wanted to at least document the issue.
To reproduce with the attached code:
1. Make sure your app includes jQuery (1.7.2 was the version we tested with)
2. Load the page
3. Change the url to something that has a hash value (e.g. #temp)
4. Click on the ComboBoxItem's down arrow
5. Notice only the "#" remains but not "temp"
2. IE10 (neither FF nor Chrome appear to be affected).
3. No logged errors either client or server side.
4. Sample code attached.
I've tried to boil my attached code down to the most basic situation I could get the issue to be reproducible. Unfortunately, I wasn't able to isolate the issue in such a way that it would present when running in Native Mode. That means the code will only show the issue in Hosted Mode. However, my main application where I discovered this issue was reproducing in Native Mode.
The basic issue is that: when I click on a ComboBoxItem's arrow to open the results my "window.location.hash" value clears out. This only seems to happen when I have a click handler attached to the document. I noticed in my test case it was also dependent on the event handler function being wrapped in the $entry() method (which I do need because in practice I will be calling back into GWT). The handler doesn't have to do anything, it just has to be attached. I can fix the issue without any side-effects by calling jQuery's preventDefault() method on the event, but I'm not sure yet if there will be no further issue or not so I wanted to at least document the issue.
To reproduce with the attached code:
1. Make sure your app includes jQuery (1.7.2 was the version we tested with)
2. Load the page
3. Change the url to something that has a hash value (e.g. #temp)
4. Click on the ComboBoxItem's down arrow
5. Notice only the "#" remains but not "temp"
Comment