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 149024 - I18N - Web Browser option is not saved in the localized product
Summary: I18N - Web Browser option is not saved in the localized product
Status: VERIFIED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Options&Settings (show other bugs)
Version: 6.x
Hardware: Sun All
: P2 blocker (vote)
Assignee: Jiri Skrivanek
URL:
Keywords: I18N, SIMPLEFIX
Depends on:
Blocks:
 
Reported: 2008-10-03 07:52 UTC by Keiichi Oono
Modified: 2008-12-22 13:51 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Keiichi Oono 2008-10-03 07:52:25 UTC
IDE: trunk Build 200810010201
JDK: 1.6.0_05
OS: Windows XP, Solaris 10

to reproduce:
 - Run localized version (install ML, and run it in Japanese or Chinese locale)
 - Select main menu [Tools] > [Options]
 - Click [Edit] button in the displayed General panel
 - Modify any values in the displayed Web Browsers dialog, and click [OK]

The modification is discarded. It can be confirmed by re-opening Web Browsers dialog.

In my investigation, dialog works fine if the following message is translated back into English.

core.windows/src/org/netbeans/core/windows/services/Bundle.properties
   OK_OPTION_CAPTION=OK

I checked the source files a little and I'm guessing the following hardcoded "OK" causes this problem
(OK_OPTION_CAPTION=OK must not be translated). Line #335 in GeneralOptionsPanel.java

core.ui/src/org/netbeans/core/ui/options/general/GeneralOptionsPanel.java

330  private void editBrowserButtonActionPerformed(java.awt.event.ActionEvent evt) {
...
334              public void actionPerformed(ActionEvent e) {
335                  if( "OK".equals(e.getActionCommand()) ) {
336                      wbModel.applyChanges();
337                  } else {
338                      wbModel.discardChanges();
339                  }

The workaround is to translate OK_OPTION_CAPTION back into English, but the caption "OK" is back to English in other
customizer dialogs.
Comment 1 Lukas Hasik 2008-10-03 09:55:04 UTC
Probably easily fixable. Jirko, can we fix it for 6.5?
Comment 2 Jiri Skrivanek 2008-10-03 10:42:20 UTC
Fixed. Keiichio, thank you for evaluation. It was very helpful.

http://hg.netbeans.org/core-main/rev/4b3d1b72d98e
Comment 3 Quality Engineering 2008-10-04 09:23:39 UTC
Integrated into 'main-golden', will be available in build *200810040600* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/4b3d1b72d98e
User: Jiri Skrivanek <jskrivanek@netbeans.org>
Log: #149024 - Cannot compare action command because it is internationalized.
Comment 4 Rebecca Liu 2008-10-06 04:11:08 UTC
Verified in build 200810041417. It is fixed in ja and zh_CN locale.
Comment 5 Keiichi Oono 2008-10-06 11:02:14 UTC
Thank you very much for your very quick fixing!