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 72805

Summary: I18N: label and mnemonic are not from bundle on debugger attach dialog
Product: debugger Reporter: Masaki Katakai <masaki>
Component: CodeAssignee: Martin Entlicher <mentlicher>
Status: VERIFIED FIXED    
Severity: blocker CC: jf4jbug, mgrummich
Priority: P3 Keywords: I18N
Version: 5.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description Masaki Katakai 2006-02-19 03:44:08 UTC
Bug 23819 is still reproducible on 5.0.

23819: I18N - mnemonic key doesn't work with translated

Also it seems that some labels are not from bundle.

I'm using localized JDK and NB5.0 ml build in Japanese locale.

In ConnectPanel.java under
debuggerjpda/ui/src/org/netbeans/modules/debugger/jpda/ui,
"str" seems to be localized already. Are these from JDK??

    private static String translate (String str)
    private static char getMnemonic (String str) 

so,

        if (str.equalsIgnoreCase ("Host"))
            return NbBundle.getMessage (ConnectPanel.class, "CTL_Host");

str.equalsIgnoreCase(English) always fails. "str" is always returned as it is
from translate(), 0 is always returned from getMnemonic().
Comment 1 Martin Entlicher 2006-02-24 13:31:30 UTC
I have no idea how issue #23819 was fixed, but apparently the problem is there.
We must use "Connector.Argument.name()" instead of "Connector.Argument.label()"
as a key to find the localized label.
Comment 2 Martin Entlicher 2006-02-24 14:21:26 UTC
Fixed for known connectors in trunk, the keys changed to match Argument.name():

/cvs/debuggerjpda/ui/src/org/netbeans/modules/debugger/jpda/ui/Bundle.properties,v
 <--  Bundle.properties
new revision: 1.27; previous revision: 1.26

/cvs/debuggerjpda/ui/src/org/netbeans/modules/debugger/jpda/ui/ConnectPanel.java,v
 <--  ConnectPanel.java
new revision: 1.22; previous revision: 1.21
Comment 3 Pavel Rehak 2006-08-23 13:22:03 UTC
Verified - works fine for latest 5.5