- Timestamp:
- 2009-11-29T13:09:43+01:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/tools/BugReportExceptionHandler.java
r2017 r2544 22 22 import org.openstreetmap.josm.actions.ShowStatusReportAction; 23 23 import org.openstreetmap.josm.plugins.PluginHandler; 24 import org.openstreetmap.josm.tools.Base64; 25 26 import java.net.URL; 27 import java.net.URLEncoder; 28 import org.openstreetmap.josm.tools.UrlLabel; 24 29 25 30 /** … … 65 70 + stack.getBuffer().toString(); 66 71 72 URL url = new URL("http://josm.openstreetmap.de/josmticket?" + 73 "data="+ 74 Base64.encode( 75 // To note that it came from this code 76 "keywords=template_report&" + 77 "description=" + java.net.URLEncoder.encode( 78 // Note: This doesn't use tr() intentionally, we want bug reports in English 79 "What steps will reproduce the problem?\n" 80 + " 1. \n" 81 + " 2. \n" 82 + " 3. \n" 83 + "\n" 84 + "What is the expected result?\n\n" 85 + "What happens instead?\n\n" 86 + "Please provide any additional information below. Attach a screenshot if\n" 87 + "possible.\n\n" 88 + "{{{\n" + text + "\n}}}\n", 89 "UTF-8"))); 90 67 91 JPanel p = new JPanel(new GridBagLayout()); 68 p.add(new JLabel("<html>" + tr("Please report a ticket at {0}","http://josm.openstreetmap.de/newticket") + 69 "<br>" + tr("Include your steps to get to the error (as detailed as possible)!") + 70 "<br>" + tr("Try updating to the newest version of JOSM and all plugins before reporting a bug.") + 71 "<br>" + tr("Be sure to include the following information:") + "</html>"), GBC.eol()); 92 p.add(new JLabel(tr("<html>" + 93 "<p>You've encountered an error in JOSM. Before you file a bug<br>" + 94 "make sure you've updated to the latest version of JOSM here:</p></html>")), GBC.eol()); 95 p.add(new UrlLabel("http://josm.openstreetmap.de/#Download"), GBC.eop().insets(8,0,0,0)); 96 p.add(new JLabel(tr("<html>You should also update your plugins. If neither of those help please<br>" + 97 "file a bug in our bugtracker using this link:</p></html>")), GBC.eol()); 98 p.add(new UrlLabel(url.toString(), "http://josm.openstreetmap.de/josmticket?..."), GBC.eop().insets(8,0,0,0)); 99 p.add(new JLabel(tr("<html><p>" + 100 "There the the error information provided below should already be<br>" + 101 "filled out for you. Please include information on how to reproduce<br>" + 102 "the error and try to supply as much detail as possible.</p></html>")), GBC.eop()); 103 p.add(new JLabel(tr("<html><p>" + 104 "Alternatively if that doesn't work you can manually fill in the information<br>" + 105 "below at this URL:</p></html>")), GBC.eol()); 106 p.add(new UrlLabel("http://josm.openstreetmap.de/newticket"), GBC.eop().insets(8,0,0,0)); 72 107 try { 73 108 Toolkit.getDefaultToolkit().getSystemClipboard().setContents(new StringSelection(text), new ClipboardOwner(){ … … 83 118 p.add(new JScrollPane(info), GBC.eop()); 84 119 85 JOptionPane.showMessageDialog(Main.parent, p, tr(" Warning"), JOptionPane.WARNING_MESSAGE);120 JOptionPane.showMessageDialog(Main.parent, p, tr("You've encountered a bug in JOSM"), JOptionPane.ERROR_MESSAGE); 86 121 } catch (Exception e1) { 87 122 e1.printStackTrace();
Note:
See TracChangeset
for help on using the changeset viewer.