Details
Description
Noticed by Wei Jen thread start here: (http://www.jalview.org/pipermail/jalview-discuss/2011-October/000696.html).
On 19/10/2011 19:36, Wei Jen wrote:
> Yes, we are using the setFeatureGroupState to control which feature to highlight. And we are setting the hidefeaturegroups parameter with all the features to hide them. However, some users reported that they saw the alignments got highlighted then disapeared. I am assuming either the network or the user machine was slow, so when jalviewLite read the feature file, processed and highlighted the features, and then hide them one after another.
This is happening because the jalview.bin.JalviewLite code does the following:
1. load features from feature file parameter
2. set feature display state.
3. does more stuff.
4. processes the hide/show feature groups parameter, and passes them to the AlignFrame.setFeatureGroupState method.
The problem lies in the fact that the AlignFrame.setFeatureGroupState uses a SwingWorker.invokeLater call to ensure that the javascript execution thread is not deadlocked (previous versions of JalviewLite didn't do this, but the introduction of callbacks have lead to this possibility).
On 19/10/2011 19:36, Wei Jen wrote:
> Yes, we are using the setFeatureGroupState to control which feature to highlight. And we are setting the hidefeaturegroups parameter with all the features to hide them. However, some users reported that they saw the alignments got highlighted then disapeared. I am assuming either the network or the user machine was slow, so when jalviewLite read the feature file, processed and highlighted the features, and then hide them one after another.
This is happening because the jalview.bin.JalviewLite code does the following:
1. load features from feature file parameter
2. set feature display state.
3. does more stuff.
4. processes the hide/show feature groups parameter, and passes them to the AlignFrame.setFeatureGroupState method.
The problem lies in the fact that the AlignFrame.setFeatureGroupState uses a SwingWorker.invokeLater call to ensure that the javascript execution thread is not deadlocked (previous versions of JalviewLite didn't do this, but the introduction of callbacks have lead to this possibility).