This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 230860

Summary: Selected node in navigator incorrectly choosen
Product: web Reporter: Marek Fukala <mfukala>
Component: CSS EditorAssignee: Milutin Kristofic <mkristofic>
Status: NEW ---    
Severity: normal CC: sdedic
Priority: P1    
Version: 7.4   
Hardware: PC   
OS: Mac OS X   
Issue Type: TASK Exception Reporter:

Description Marek Fukala 2013-06-06 13:37:21 UTC
@media screen and (max-height: 200px), printer { 
    h1 {
        alignment-adjust: 20px;
    }
}

1) double-click elements/h1 in the navigator => caret set to proper place => the selected node in navigator is re-set to rules/h1

2) same behaviour for the media at-rule

=> caused by overlapping node ranges in the structure items put to the navigator.
Comment 1 Marek Fukala 2013-08-22 13:14:45 UTC
I'm afraid this can't be made working using the current approach - passing a tree like structure w/ no expectation of overlapping nodes. The generic offset->structure item mechanism then fails from obvious reasons.

Possibly can be fixed by improving the csl.api contract by some custom offset<-> item navigation.
Comment 2 Marek Fukala 2013-08-22 13:16:41 UTC
The nodes are not really overlapping but the order of the source code elements is not equal to the order of the structure items. Some structure items may also represent the same code.