Modify

Opened 10 years ago

Closed 10 years ago

#1915 closed defect (fixed)

Context sensitive help for JMenu uses translated string

Reported by: stoecker Owned by: framm
Priority: major Milestone:
Component: unspecified Version:
Keywords: Cc:

Description

The context sensitive help for JMenu's uses the translated string instead of the unstranslated one.
http://josm.openstreetmap.de/wiki/Help/Menu/Datei is used instead of
http://josm.openstreetmap.de/wiki/Help/Menu/File and
http://josm.openstreetmap.de/wiki/Help/Menu/De:File

Attachments (1)

context_help_menu.diff (1.4 KB) - added by sanna 10 years ago.
silly diff of how I got context sensitive menu help working

Download all attachments as: .zip

Change History (3)

Changed 10 years ago by sanna

Attachment: context_help_menu.diff added

silly diff of how I got context sensitive menu help working

comment:1 Changed 10 years ago by sanna

I made an extremely silly patch that solved this for me (I am NOT a java programmer) that imho is too stupid to use, but it might show those more adept at java than me how to do it properly...

Basically in MainMenu.java I chop up the shortName that is sent in to add to register the shortcut into initial and rest, do a uppercase conversion on the initial character and mash them together again and store with putClientProperty as "help", then I remove the "if (c instanceof JMenu)" part from HelpAction.java, and let the (c instanceof AbstractButton) handle the JMenu as well.

Note: this breaks the WMS-plugin, since the help pages are stored at WMS, not Wms while the menu shortcut seems to be registered as wms.

comment:2 Changed 10 years ago by stoecker

Resolution: fixed
Status: newclosed

In r1498.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain framm.
as The resolution will be set.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.