示例#1
0
文件: FoodEditor.java 项目: kba/neon
 protected void save() {
   data.name = nameField.getText();
   try {
     costField.commitEdit();
     data.cost = ((Long) costField.getValue()).intValue();
   } catch (ParseException e) {
     data.cost = 0;
   }
   data.color = colorBox.getSelectedItem().toString();
   data.text = charField.getText();
   data.weight = Float.parseFloat(weightField.getText());
   if (spellBox.getSelectedItem() != null) {
     data.spell = spellBox.getSelectedItem().toString();
   }
   data.setPath(Editor.getStore().getActive().get("id"));
 }
示例#2
0
文件: HelpLabels.java 项目: kba/neon
 public static JLabel getCraftingCostHelpLabel() {
   return getLabel(
       "The cost to craft this item (in " + Editor.getStore().getActive().get("small") + ").");
 }
示例#3
0
文件: HelpLabels.java 项目: kba/neon
 public static JLabel getCostHelpLabel() {
   return getLabel("The cost of this item in " + Editor.getStore().getActive().get("small") + ".");
 }