Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
X
XChart
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Brady James Garvin
XChart
Commits
11017e3c
Commit
11017e3c
authored
12 years ago
by
Tim Molter
Browse files
Options
Downloads
Patches
Plain Diff
allow localization of Save As… String
parent
504956fe
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
pom.xml
+1
-1
1 addition, 1 deletion
pom.xml
xchart/src/main/java/com/xeiam/xchart/XChartPanel.java
+13
-1
13 additions, 1 deletion
xchart/src/main/java/com/xeiam/xchart/XChartPanel.java
with
14 additions
and
2 deletions
pom.xml
+
1
−
1
View file @
11017e3c
...
...
@@ -4,7 +4,7 @@
<groupId>
com.xeiam.xchart
</groupId>
<artifactId>
xchart-parent
</artifactId>
<version>
2.
0.1
-SNAPSHOT
</version>
<version>
2.
1.0
-SNAPSHOT
</version>
<packaging>
pom
</packaging>
<name>
XChart Parent
</name>
<description>
Basic Charts for Java Applications
</description>
...
...
This diff is collapsed.
Click to expand it.
xchart/src/main/java/com/xeiam/xchart/XChartPanel.java
+
13
−
1
View file @
11017e3c
...
...
@@ -46,6 +46,8 @@ public class XChartPanel extends JPanel {
private
final
Chart
chart
;
private
String
saveAsString
=
"Save As..."
;
/**
* Constructor
*
...
...
@@ -64,6 +66,16 @@ public class XChartPanel extends JPanel {
this
.
getActionMap
().
put
(
"save"
,
new
SaveAction
());
}
/**
* Set the "Save As..." String if you want to localize it.
*
* @param saveAsString
*/
public
void
setSaveAsString
(
String
saveAsString
)
{
this
.
saveAsString
=
saveAsString
;
}
@Override
protected
void
paintComponent
(
Graphics
g
)
{
...
...
@@ -194,7 +206,7 @@ public class XChartPanel extends JPanel {
public
XChartPanelPopupMenu
()
{
saveAsMenuItem
=
new
JMenuItem
(
"S
ave
As
..."
);
saveAsMenuItem
=
new
JMenuItem
(
s
aveAs
String
);
saveAsMenuItem
.
addMouseListener
(
new
MouseListener
()
{
@Override
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment