Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4478364

Solaris: some widgets being added by awt_addWidget several time into widget list

XMLWordPrintable

    • beta2
    • sparc
    • solaris_2.6

      In Solaris native code we have widget list to map widgets and their siblings(if it is a complex widget) to WidgetInfo structure. We add entries to this list by call to awt_addWidget which accepts several parameters and creates appropriate WidgetInfo structure and list entry. It was found that for some widgets this function is being called with different parameters several times and therefore it creates different WidgetInfo structures for one widget. This by itself is the error which should be fixed. The map was designed to be one-to-one and is being used keeping this in mind.

      When we do the lookup it returns the first found structure for the desired widget. The problem arises when the actual structure we want to get as the result(and correct one in this case) is the second structure.

      Until this time the need for this never arised but while fixing bug 4470922 I found that this problem prevents me from fixing this bug.

      The root of the problem is that for every component MComponentPeer_pInitialize method calls awt_addWiget with parameters which for some widgets are incorrect. These special widgets do call awt_addWidget by themselves. Therefore the fix is just to check if there is already some entry for the specified widget and do nothing if there is.

            dmikhalksunw Denis Mikhalkin (Inactive)
            domsunw Dom Dom (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: