diff -Nur IceJ-3.0.0/config/build.properties IceJ-3.0.0-CN/config/build.properties --- IceJ-3.0.0/config/build.properties 2005-11-16 03:52:48.000000000 +0800 +++ IceJ-3.0.0-CN/config/build.properties 2006-04-18 23:33:14.000000000 +0800 @@ -18,7 +18,7 @@ # debug = on - +encoding=gbk # # These properties only need to be set if you want to build the # standalone jar for the IceGrid GUI. diff -Nur IceJ-3.0.0/resources/help.html IceJ-3.0.0-CN/resources/help.html --- IceJ-3.0.0/resources/help.html 1970-01-01 08:00:00.000000000 +0800 +++ IceJ-3.0.0-CN/resources/help.html 2006-04-20 10:30:55.000000000 +0800 @@ -0,0 +1,606 @@ +

Table of Contents

+ + + +
+ + +

Ice Open Source License

+ +

+This copy of Ice is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License version 2 as +published by the Free Software Foundation, and reproduced below.

+ +

+Ice is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS +FOR A PARTICULAR PURPOSE. See the GNU General Public License below for +details.

+ +

+In addition, as a special exception, ZeroC, Inc. gives permission to link +Ice with the OpenSSL library (or with modified versions of OpenSSL +that use the same license as OpenSSL), and distribute linked +combinations including the two. You must obey the GNU General Public +License version 2 in all respects for all of the code used other than +OpenSSL. If you modify this copy of Ice, you may extend this exception +to your version of Ice, but you are not obligated to do so. If you do +not wish to do so, delete this exception statement from your version.

+ +

+

+ +

GNU GENERAL PUBLIC LICENSE

+

+Version 2, June 1991 +

+ +
+Copyright (C) 1989, 1991 Free Software Foundation, Inc.  
+51 Franklin St, Fifth Floor, Boston, MA  02110-1301, USA
+
+Everyone is permitted to copy and distribute verbatim copies
+of this license document, but changing it is not allowed.
+
+ + + +

Preamble

+ +

+ The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + +

+

+ When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + +

+

+ To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + +

+

+ For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + +

+

+ We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + +

+

+ Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + +

+

+ Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + +

+

+ The precise terms and conditions for copying, distribution and +modification follow. + +

+ + +

TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

+ + +

+ +0. + This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". +

+ +

+ +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + +

+ +

+ +1. + You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. +

+ +

+ +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. +

+ +

+ +2. + You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: +

+ +

+ +

+
+
+a) + You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. +
+ + +
+ +

+ +

+

+
+
+b) + You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. +
+ +
+ +

+ +

+

+
+
+c) + If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) +
+ +
+ +

+ +

+ +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +

+ +

+ +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +

+ +

+ +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + +

+ +

+ +3. + + You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + +

+ + + + +

+

+
+
+a) + Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, +
+ + +
+ +

+ +

+

+
+
+b) + Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, +
+ +
+ +

+ +

+

+
+
+c) + Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) +
+ +
+ +

+ +

+ +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +

+ +

+ +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. +

+ +

+ +4. + You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + +

+ +

+ +5. + You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + +

+ +

+ +6. + Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + +

+ +

+ +7. + If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. +

+ +

+ +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. +

+ + +

+ +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. +

+ +

+ +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + +

+ +

+ +8. + If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. +

+ +

+ +9. + + The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. +

+ +

+ +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. +

+ +

+ + +10. + If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. +

+ + +

NO WARRANTY

+ +

+ +11. + BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. +

+ +

+ +12. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. +

+ +

END OF TERMS AND CONDITIONS

+ +

How to Apply These Terms to Your New Programs

+ +

+ If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + +

+

+ To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + +

+ +
+one line to give the program's name and an idea of what it does.
+Copyright (C) yyyy  name of author
+
+This program is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License
+as published by the Free Software Foundation; either version 2
+of the License, or (at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
+
+ +

+Also add information on how to contact you by electronic and paper mail. + +

+ +

+If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + +

+ +
+Gnomovision version 69, Copyright (C) year name of author
+Gnomovision comes with ABSOLUTELY NO WARRANTY; for details
+type `show w'.  This is free software, and you are welcome
+to redistribute it under certain conditions; type `show c' 
+for details.
+
+ +

+The hypothetical commands `show w' and `show c' should show +the appropriate parts of the General Public License. Of course, the +commands you use may be called something other than `show w' and + +`show c'; they could even be mouse-clicks or menu items--whatever +suits your program. + +

+

+You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + +

+ +
+Yoyodyne, Inc., hereby disclaims all copyright
+interest in the program `Gnomovision'
+(which makes passes at compilers) written 
+by James Hacker.
+
+signature of Ty Coon, 1 April 1989
+Ty Coon, President of Vice
+
+ +

+This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General Public License +instead of this License. +

diff -Nur IceJ-3.0.0/src/IceGrid/AdminGUI.java IceJ-3.0.0-CN/src/IceGrid/AdminGUI.java --- IceJ-3.0.0/src/IceGrid/AdminGUI.java 2005-11-14 23:10:32.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/AdminGUI.java 2006-04-20 10:46:23.000000000 +0800 @@ -12,6 +12,7 @@ import java.awt.FlowLayout; import java.awt.event.WindowAdapter; import java.awt.event.WindowEvent; +import java.awt.Font; import javax.swing.Icon; import javax.swing.JFrame; @@ -39,7 +40,7 @@ _text.setHorizontalAlignment(SwingConstants.LEFT); add(_text, BorderLayout.LINE_START); - _connectedLabel = new JLabel("Working Offline"); + _connectedLabel = new JLabel("离线"); _connectedLabel.setHorizontalAlignment(SwingConstants.RIGHT); add(_connectedLabel, BorderLayout.LINE_END); } @@ -53,11 +54,11 @@ { if(connected) { - _connectedLabel.setText("Working Online"); + _connectedLabel.setText("在线"); } else { - _connectedLabel.setText("Working Offline"); + _connectedLabel.setText("离线"); } } @@ -78,7 +79,7 @@ AdminGUI(String[] args) { - super("IceGrid Admin"); + super("IceGrid管理器中文版 (3.0.0)"); setIconImage(Utils.getIcon("/icons/16x16/grid.png").getImage()); setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); @@ -134,7 +135,32 @@ else // JGoodies L&F { UIManager.setLookAndFeel("com.jgoodies.looks.plastic.PlasticXPLookAndFeel"); - } + } + Font font = new Font("SimSun", Font.PLAIN,12); + UIManager.put("MenuBar.font", font); + UIManager.put("MenuItem.font", font); + UIManager.put("CheckBoxMenuItem.font", font); + UIManager.put("Menu.font", font); + UIManager.put("PopupMenu.font", font); + UIManager.put("ToolBar.font", font); + UIManager.put("ToolTip.font", font); + UIManager.put("TabbedPane.font", font); + UIManager.put("Label.font", font); + UIManager.put("List.font", font); + UIManager.put("ComboBox.font", font); + UIManager.put("Button.font", font); + UIManager.put("Table.font", font); + UIManager.put("TableHeader.font", font); + UIManager.put("Tree.font", font); + UIManager.put("TextField.font", font); + UIManager.put("TextArea.font", font); + UIManager.put("TitledBorder.font", font); + UIManager.put("OptionPane.font", font); + UIManager.put("RadioButton.font", font); + UIManager.put("CheckBox.font", font); + UIManager.put("ToggleButton.font", font); + UIManager.put("Dialog.font", font); + UIManager.put("Panel.font", font); } catch(Exception e) { diff -Nur IceJ-3.0.0/src/IceGrid/HelpDialog.java IceJ-3.0.0-CN/src/IceGrid/HelpDialog.java --- IceJ-3.0.0/src/IceGrid/HelpDialog.java 1970-01-01 08:00:00.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/HelpDialog.java 2006-04-20 10:30:05.000000000 +0800 @@ -0,0 +1,82 @@ +// ********************************************************************** +// +// Copyright (c) 2003-2005 ZeroC, Inc. All rights reserved. +// +// This copy of Ice is licensed to you under the terms described in the +// ICE_LICENSE file included in this distribution. +// +// ********************************************************************** +package IceGrid; + +import java.awt.BorderLayout; +import java.awt.Dimension; +import java.awt.Frame; + +import java.awt.event.ActionEvent; + +import javax.swing.JDialog; +import javax.swing.JEditorPane; +import javax.swing.JPanel; +import javax.swing.JScrollPane; + +import javax.swing.text.html.HTMLDocument; +import javax.swing.text.html.HTMLFrameHyperlinkEvent; + +import javax.swing.event.HyperlinkEvent; +import javax.swing.event.HyperlinkListener; + +import com.jgoodies.forms.factories.Borders; + +// +// Shows Ice license and warranty +// +public class HelpDialog extends JDialog +{ + public HelpDialog(Frame parentFrame) + { + super(parentFrame, "帮助-IceGrid 管理器", false); + setDefaultCloseOperation(JDialog.HIDE_ON_CLOSE); + + try + { + _pane = new JEditorPane(Utils.class.getResource("/help.html")); + } + catch(java.io.IOException e) + { + _pane = new JEditorPane(); + _pane.setText("找不到 help.html 文件"); + } + _pane.setEditable(false); + + _pane.addHyperlinkListener(new HyperlinkListener() + { + public void hyperlinkUpdate(HyperlinkEvent e) + { + if (e.getEventType() == HyperlinkEvent.EventType.ACTIVATED) + { + _pane.scrollToReference(e.getURL().getRef()); + } + } + }); + Dimension prefSize = new Dimension(700, 500); + _pane.setPreferredSize(prefSize); + + JScrollPane scrollPane = new JScrollPane(_pane); + scrollPane.setBorder(Borders.DIALOG_BORDER); + getContentPane().add(scrollPane, BorderLayout.CENTER); + pack(); + } + + + public void show(String ref) + { + setLocationRelativeTo(null); + setVisible(true); + _pane.scrollToReference(ref); + } + + JEditorPane _pane; +} + + + diff -Nur IceJ-3.0.0/src/IceGrid/LicenseDialog.java IceJ-3.0.0-CN/src/IceGrid/LicenseDialog.java --- IceJ-3.0.0/src/IceGrid/LicenseDialog.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/LicenseDialog.java 2006-04-19 21:53:40.000000000 +0800 @@ -34,7 +34,7 @@ { public LicenseDialog(Frame parentFrame) { - super(parentFrame, "License - IceGrid Admin", false); + super(parentFrame, "许可证 - IceGrid 管理器", false); setDefaultCloseOperation(JDialog.HIDE_ON_CLOSE); try @@ -44,7 +44,7 @@ catch(java.io.IOException e) { _pane = new JEditorPane(); - _pane.setText("Cannot find license.html"); + _pane.setText("找不到 license.html 文件"); } _pane.setEditable(false); diff -Nur IceJ-3.0.0/src/IceGrid/ListDialog.java IceJ-3.0.0-CN/src/IceGrid/ListDialog.java --- IceJ-3.0.0/src/IceGrid/ListDialog.java 2005-10-29 02:30:55.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/ListDialog.java 2006-04-21 07:54:29.000000000 +0800 @@ -38,7 +38,7 @@ { public ListDialog(Frame parentFrame, String title, boolean trim) { - super(parentFrame, title + " - IceGrid Admin", true); + super(parentFrame, title + " - IceGrid 管理器", true); setDefaultCloseOperation(JDialog.HIDE_ON_CLOSE); _trim = trim; @@ -49,7 +49,7 @@ _list = new JTable(); _list.setTableHeader(null); - Action ok = new AbstractAction("OK") + Action ok = new AbstractAction("确定") { public void actionPerformed(ActionEvent e) { @@ -59,7 +59,7 @@ }; JButton okButton = new JButton(ok); - Action cancel = new AbstractAction("Cancel") + Action cancel = new AbstractAction("取消") { public void actionPerformed(ActionEvent e) { @@ -68,7 +68,7 @@ }; JButton cancelButton = new JButton(cancel); - Action deleteRow = new AbstractAction("Delete selected element(s)") + Action deleteRow = new AbstractAction("删除选定的元素") { public void actionPerformed(ActionEvent e) { diff -Nur IceJ-3.0.0/src/IceGrid/MainPane.java IceJ-3.0.0-CN/src/IceGrid/MainPane.java --- IceJ-3.0.0/src/IceGrid/MainPane.java 2005-10-28 04:50:06.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/MainPane.java 2006-04-20 23:05:35.000000000 +0800 @@ -16,6 +16,9 @@ import javax.swing.event.ChangeEvent; import javax.swing.tree.TreeCellRenderer; +import javax.swing.DefaultCellEditor; +import javax.swing.JTextField; +import javax.swing.tree.DefaultTreeCellEditor; import javax.swing.tree.TreeSelectionModel; import javax.swing.tree.TreePath; import java.awt.*; @@ -151,6 +154,14 @@ tree.setBorder(new EmptyBorder(5, 5, 5, 5)); tree.setCellRenderer(renderer); + + //TreeCellEditor begin + //tree.setEditable(true); + + //tree.setCellEditor(new DefaultTreeCellEditor(tree, + // renderer, + // new DefaultCellEditor(new JTextField()))); + //TreeCellEditor end ToolTipManager.sharedInstance().registerComponent(tree); tree.addMouseListener(popupListener); @@ -166,7 +177,7 @@ JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED); appScroll.setBorder(Borders.EMPTY_BORDER); - SimpleInternalFrame leftPane = new SimpleInternalFrame("Applications"); + SimpleInternalFrame leftPane = new SimpleInternalFrame("应用列表"); leftPane.setContent(appScroll); leftPane.setPreferredSize(new Dimension(280, 350)); diff -Nur IceJ-3.0.0/src/IceGrid/Model.java IceJ-3.0.0-CN/src/IceGrid/Model.java --- IceJ-3.0.0/src/IceGrid/Model.java 2005-11-15 04:31:18.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/Model.java 2006-04-20 10:39:56.000000000 +0800 @@ -121,14 +121,14 @@ // // File menu // - JMenu fileMenu = new JMenu("File"); + JMenu fileMenu = new JMenu("文件"); fileMenu.setMnemonic(java.awt.event.KeyEvent.VK_F); add(fileMenu); // // New sub-menu // - _newMenu = new JMenu("New"); + _newMenu = new JMenu("新建"); _newMenu.setEnabled(false); fileMenu.add(_newMenu); _newMenu.add(_newApplicationWithDefaultTemplates); @@ -142,7 +142,7 @@ // // New server sub-sub-menu // - _newServerMenu = new JMenu("Server"); + _newServerMenu = new JMenu("服务器"); _newServerMenu.setEnabled(false); _newMenu.add(_newServerMenu); _newServerMenu.add(_actions[CommonBase.NEW_SERVER]); @@ -152,7 +152,7 @@ // // New service sub-sub-menu // - _newServiceMenu = new JMenu("Service"); + _newServiceMenu = new JMenu("服务"); _newServiceMenu.setEnabled(false); _newMenu.add(_newServiceMenu); _newServiceMenu.add(_actions[CommonBase.NEW_SERVICE]); @@ -161,7 +161,7 @@ // // New template sub-sub-menu // - _newTemplateMenu = new JMenu("Template"); + _newTemplateMenu = new JMenu("模板"); _newTemplateMenu.setEnabled(false); _newMenu.add(_newTemplateMenu); _newTemplateMenu.add(_actions[CommonBase.NEW_TEMPLATE_SERVER]); @@ -180,7 +180,7 @@ // // Edit menu // - JMenu editMenu = new JMenu("Edit"); + JMenu editMenu = new JMenu("编辑"); editMenu.setMnemonic(java.awt.event.KeyEvent.VK_E); add(editMenu); editMenu.add(_actions[CommonBase.COPY]); @@ -191,7 +191,7 @@ // // View menu // - JMenu viewMenu = new JMenu("View"); + JMenu viewMenu = new JMenu("视图"); viewMenu.setMnemonic(java.awt.event.KeyEvent.VK_V); add(viewMenu); viewMenu.add(_showVarsMenuItem); @@ -203,14 +203,14 @@ // // Tools menu // - JMenu toolsMenu = new JMenu("Tools"); + JMenu toolsMenu = new JMenu("工具"); toolsMenu.setMnemonic(java.awt.event.KeyEvent.VK_T); add(toolsMenu); // // Application sub-menu // - _appMenu = new JMenu("Application"); + _appMenu = new JMenu("应用"); _appMenu.setEnabled(false); toolsMenu.add(_appMenu); _appMenu.add(_actions[CommonBase.APPLICATION_INSTALL_DISTRIBUTION]); @@ -218,7 +218,7 @@ // // Node sub-menu // - _nodeMenu = new JMenu("Node"); + _nodeMenu = new JMenu("节点"); _nodeMenu.setEnabled(false); toolsMenu.add(_nodeMenu); _nodeMenu.add(_actions[CommonBase.SHUTDOWN_NODE]); @@ -226,7 +226,7 @@ // // Server sub-menu // - _serverMenu = new JMenu("Server"); + _serverMenu = new JMenu("服务器"); _serverMenu.setEnabled(false); toolsMenu.add(_serverMenu); _serverMenu.add(_actions[CommonBase.START]); @@ -240,7 +240,7 @@ // // Service sub-menu // - _serviceMenu = new JMenu("Service"); + _serviceMenu = new JMenu("服务"); _serviceMenu.setEnabled(false); toolsMenu.add(_serviceMenu); _serviceMenu.add(_actions[CommonBase.MOVE_UP]); @@ -249,11 +249,12 @@ // // Help menu // - JMenu helpMenu = new JMenu("Help"); + JMenu helpMenu = new JMenu("帮助"); helpMenu.setMnemonic(java.awt.event.KeyEvent.VK_H); add(helpMenu); helpMenu.add(_helpContents); + helpMenu.add(_onlineHelpContents); if(GPL_BUILD) { helpMenu.addSeparator(); @@ -361,7 +362,7 @@ { _root.applicationAdded(desc); _statusBar.setText( - "Last update: new application '" + desc.name + "'"); + "最近更新: 新建应用 '" + desc.name + "'"); checkWriteSerial(); } } @@ -372,7 +373,7 @@ { _root.applicationRemoved(name); _statusBar.setText( - "Last update: application '" + name + "' was removed"); + "最近更新: 应用 '" + name + "'被删除"); checkWriteSerial(); } } @@ -388,7 +389,7 @@ path = currentNode.getPath(); } _root.applicationUpdated(desc); - _statusBar.setText("Last update: application '" + desc.name + "' was updated"); + _statusBar.setText("最近更新: 应用 '" + desc.name + "' 被更新"); checkWriteSerial(); restore(path); } @@ -418,7 +419,7 @@ else { _sessionKeeper.sessionLost( - "Received message from IceGrid Registry out of order"); + "从IceGrid注册表接受消息次序混乱"); return false; } } @@ -497,8 +498,8 @@ { JOptionPane.showMessageDialog( _mainFrame, - "Updates are not allowed while working offline", - "Working Offline", + "离线状态不允许进行更新", + "离线", JOptionPane.ERROR_MESSAGE); return false; } @@ -532,10 +533,10 @@ // JOptionPane.showMessageDialog( _mainFrame, - "Your view was not up-to-date;" - + " you now have exclusive write-access to the" + - " IceGrid Registry, however your previous changes were lost.", - "Concurrent update", + "您现在查看的视图不是最新的;" + + " 你对IceGrid注册表的写操作是独占的" + + " 您的上一次变更已经丢失.", + "并发更新", JOptionPane.WARNING_MESSAGE); // @@ -566,7 +567,7 @@ } private void setUpdateInProgress() { - _statusBar.setText("Update in progress"); + _statusBar.setText("正在进行更新"); _save.setEnabled(true); _discard.setEnabled(true); } @@ -575,8 +576,8 @@ { JOptionPane.showMessageDialog( _mainFrame, - "Another session (username = " + e.lockUserId + ") has exclusive write access to the registry", - "Access Denied", + "其他会话 (用户名 : " + e.lockUserId + ") 正在对IceGrid注册表进行排他写操作", + "禁止访问", JOptionPane.ERROR_MESSAGE); } @@ -604,8 +605,8 @@ // JOptionPane.showMessageDialog( _mainFrame, - "Can't remove Application '" + e.name + "': it does not exist!", - "Application does not exist", + "不能删除应用 '" + e.name + "': 因为它根本不存在!", + "应用不存在", JOptionPane.ERROR_MESSAGE); return true; } @@ -676,8 +677,8 @@ { JOptionPane.showMessageDialog( _mainFrame, - "Application '" + application.getId() + "': "+ e.reason, - "Deployment Exception", + "应用部署 '" + application.getId() + "': "+ e.reason, + "部署异常", JOptionPane.ERROR_MESSAGE); return false; } @@ -719,8 +720,8 @@ int reallyDiscard = JOptionPane.showConfirmDialog( _mainFrame, - "Do you want to discard all your updates?", - "Discard Confirmation", + "你真的要放弃所有更新吗?", + "放弃确认", JOptionPane.YES_NO_OPTION); if(reallyDiscard == JOptionPane.YES_OPTION) @@ -834,27 +835,27 @@ catch(Glacier2.PermissionDeniedException e) { JOptionPane.showMessageDialog(parent, - "Permission denied: " + "权限不足: " + e.reason, - "Login failed", + "登录失败", JOptionPane.ERROR_MESSAGE); return null; } catch(Glacier2.CannotCreateSessionException e) { JOptionPane.showMessageDialog(parent, - "Could not create session: " + "创建会话失败: " + e.reason, - "Login failed", + "登录失败", JOptionPane.ERROR_MESSAGE); return null; } catch(Ice.LocalException e) { JOptionPane.showMessageDialog(parent, - "Could not create session: " + "创建会话失败: " + e.toString(), - "Login failed", + "登录失败", JOptionPane.ERROR_MESSAGE); return null; } @@ -880,8 +881,8 @@ { JOptionPane.showMessageDialog( parent, - "Could not contact '" + str + "': " + e.toString(), - "Login failed", + "无法联系 '" + str + "': " + e.toString(), + "登录失败", JOptionPane.ERROR_MESSAGE); return null; } @@ -901,9 +902,9 @@ catch(Ice.LocalException e) { JOptionPane.showMessageDialog(parent, - "Could not create session: " + "创建会话失败: " + e.toString(), - "Login failed", + "登录失败", JOptionPane.ERROR_MESSAGE); return null; } @@ -920,8 +921,8 @@ { JOptionPane.showMessageDialog( parent, - "Could not retrieve Admin proxy: " + e.toString(), - "Login failed", + "不能取得IceGrid管理代理: " + e.toString(), + "登录失败", JOptionPane.ERROR_MESSAGE); destroySession(session); return null; @@ -1133,6 +1134,7 @@ _treeModel = new TreeModelI(_root); _licenseDialog = new LicenseDialog(_mainFrame); + _helpDialog = new HelpDialog(_mainFrame); _shutdownHook = new Thread("Shutdown hook") { @@ -1159,7 +1161,7 @@ // // Common actions (nodes not involved) // - _newApplication = new AbstractAction("Application without default templates") + _newApplication = new AbstractAction("应用(无模板)") { public void actionPerformed(ActionEvent e) { @@ -1169,7 +1171,7 @@ _newApplication.setEnabled(false); _newApplicationWithDefaultTemplates = - new AbstractAction("Application") + new AbstractAction("应用") { public void actionPerformed(ActionEvent e) { @@ -1178,7 +1180,7 @@ }; _newApplicationWithDefaultTemplates.setEnabled(false); - _login = new AbstractAction("Login...") + _login = new AbstractAction("登录...") { public void actionPerformed(ActionEvent e) { @@ -1186,19 +1188,19 @@ } }; _login.putValue(Action.SHORT_DESCRIPTION, - "Log into an IceGrid Registry"); + "登录到IceGrid 注册表"); - _logout = new AbstractAction("Logout") + _logout = new AbstractAction("注销") { public void actionPerformed(ActionEvent e) { logout(); } }; - _logout.putValue(Action.SHORT_DESCRIPTION, "Logout"); + _logout.putValue(Action.SHORT_DESCRIPTION, "退出登录"); _logout.setEnabled(false); - _save = new AbstractAction("Save") + _save = new AbstractAction("保存") { public void actionPerformed(ActionEvent e) { @@ -1208,9 +1210,9 @@ _save.setEnabled(false); _save.putValue(Action.ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_S, MENU_MASK)); - _save.putValue(Action.SHORT_DESCRIPTION, "Save to IceGrid Registry"); + _save.putValue(Action.SHORT_DESCRIPTION, "保存到IceGrid注册表"); - _discard = new AbstractAction("Discard all updates...") + _discard = new AbstractAction("放弃所有更新...") { public void actionPerformed(ActionEvent e) { @@ -1218,9 +1220,9 @@ } }; _discard.setEnabled(false); - _discard.putValue(Action.SHORT_DESCRIPTION, "Discard all updates"); + _discard.putValue(Action.SHORT_DESCRIPTION, "放弃所有更新"); - _exit = new AbstractAction("Exit") + _exit = new AbstractAction("退出") { public void actionPerformed(ActionEvent e) { @@ -1230,7 +1232,7 @@ _exit.putValue(Action.ACCELERATOR_KEY, KeyStroke.getKeyStroke("alt F4")); - _back = new AbstractAction("Go back to the previous node") + _back = new AbstractAction("返回上一节点") { public void actionPerformed(ActionEvent e) { @@ -1238,9 +1240,9 @@ } }; _back.setEnabled(false); - _back.putValue(Action.SHORT_DESCRIPTION, "Go back to the previous node"); + _back.putValue(Action.SHORT_DESCRIPTION, "返回上一节点"); - _forward = new AbstractAction("Go to the next node") + _forward = new AbstractAction("到下一节点") { public void actionPerformed(ActionEvent e) { @@ -1248,17 +1250,25 @@ } }; _forward.setEnabled(false); - _forward.putValue(Action.SHORT_DESCRIPTION, "Go to the next node"); + _forward.putValue(Action.SHORT_DESCRIPTION, "到下一节点"); - _helpContents = new AbstractAction("Contents") + _helpContents = new AbstractAction("帮助") { public void actionPerformed(ActionEvent e) { - helpContents(); + _helpDialog.show("TOP"); } }; - _copying = new AbstractAction("Copying conditions") + _onlineHelpContents = new AbstractAction("在线帮助") + { + public void actionPerformed(ActionEvent e) + { + onlineHelpContents(); + } + }; + + _copying = new AbstractAction("版权许可") { public void actionPerformed(ActionEvent e) { @@ -1266,7 +1276,7 @@ } }; - _warranty = new AbstractAction("(Non)Warranty") + _warranty = new AbstractAction("免责声明") { public void actionPerformed(ActionEvent e) { @@ -1274,7 +1284,7 @@ } }; - _about = new AbstractAction("About") + _about = new AbstractAction("关于") { public void actionPerformed(ActionEvent e) { @@ -1288,7 +1298,7 @@ // _actions = new Action[CommonBase.ACTION_COUNT]; - _actions[CommonBase.NEW_ADAPTER] = new AbstractAction("Adapter") + _actions[CommonBase.NEW_ADAPTER] = new AbstractAction("适配器") { public void actionPerformed(ActionEvent e) { @@ -1296,7 +1306,7 @@ } }; - _actions[CommonBase.NEW_DBENV] = new AbstractAction("Database environment") + _actions[CommonBase.NEW_DBENV] = new AbstractAction("数据库环境") { public void actionPerformed(ActionEvent e) { @@ -1304,7 +1314,7 @@ } }; - _actions[CommonBase.NEW_NODE] = new AbstractAction("Node") + _actions[CommonBase.NEW_NODE] = new AbstractAction("节点") { public void actionPerformed(ActionEvent e) { @@ -1312,7 +1322,7 @@ } }; - _actions[CommonBase.NEW_REPLICA_GROUP] = new AbstractAction("Replica group") + _actions[CommonBase.NEW_REPLICA_GROUP] = new AbstractAction("复制组") { public void actionPerformed(ActionEvent e) { @@ -1320,7 +1330,7 @@ } }; - _actions[CommonBase.NEW_SERVER] = new AbstractAction("Server") + _actions[CommonBase.NEW_SERVER] = new AbstractAction("服务器") { public void actionPerformed(ActionEvent e) { @@ -1328,7 +1338,7 @@ } }; - _actions[CommonBase.NEW_SERVER_ICEBOX] = new AbstractAction("IceBox server") + _actions[CommonBase.NEW_SERVER_ICEBOX] = new AbstractAction("IceBox服务器") { public void actionPerformed(ActionEvent e) { @@ -1336,7 +1346,7 @@ } }; - _actions[CommonBase.NEW_SERVER_FROM_TEMPLATE] = new AbstractAction("Server from template") + _actions[CommonBase.NEW_SERVER_FROM_TEMPLATE] = new AbstractAction("从模板创建服务器") { public void actionPerformed(ActionEvent e) { @@ -1345,7 +1355,7 @@ }; - _actions[CommonBase.NEW_SERVICE] = new AbstractAction("Service") + _actions[CommonBase.NEW_SERVICE] = new AbstractAction("服务") { public void actionPerformed(ActionEvent e) { @@ -1353,7 +1363,7 @@ } }; - _actions[CommonBase.NEW_SERVICE_FROM_TEMPLATE] = new AbstractAction("Service from template") + _actions[CommonBase.NEW_SERVICE_FROM_TEMPLATE] = new AbstractAction("从模板创建服务") { public void actionPerformed(ActionEvent e) { @@ -1361,7 +1371,7 @@ } }; - _actions[CommonBase.NEW_TEMPLATE_SERVER] = new AbstractAction("Server template") + _actions[CommonBase.NEW_TEMPLATE_SERVER] = new AbstractAction("服务器模板") { public void actionPerformed(ActionEvent e) { @@ -1369,7 +1379,7 @@ } }; - _actions[CommonBase.NEW_TEMPLATE_SERVER_ICEBOX] = new AbstractAction("IceBox server template") + _actions[CommonBase.NEW_TEMPLATE_SERVER_ICEBOX] = new AbstractAction("IceBox服务器模板") { public void actionPerformed(ActionEvent e) { @@ -1378,7 +1388,7 @@ }; - _actions[CommonBase.NEW_TEMPLATE_SERVICE] = new AbstractAction("Service template") + _actions[CommonBase.NEW_TEMPLATE_SERVICE] = new AbstractAction("服务模板") { public void actionPerformed(ActionEvent e) { @@ -1387,7 +1397,7 @@ }; - _actions[CommonBase.COPY] = new AbstractAction("Copy") + _actions[CommonBase.COPY] = new AbstractAction("复制") { public void actionPerformed(ActionEvent e) { @@ -1396,9 +1406,9 @@ }; _actions[CommonBase.COPY].putValue(Action.ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_C, MENU_MASK)); - _actions[CommonBase.COPY].putValue(Action.SHORT_DESCRIPTION, "Copy"); + _actions[CommonBase.COPY].putValue(Action.SHORT_DESCRIPTION, "复制"); - _actions[CommonBase.PASTE] = new AbstractAction("Paste") + _actions[CommonBase.PASTE] = new AbstractAction("粘贴") { public void actionPerformed(ActionEvent e) { @@ -1407,9 +1417,9 @@ }; _actions[CommonBase.PASTE].putValue(Action.ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_V, MENU_MASK)); - _actions[CommonBase.PASTE].putValue(Action.SHORT_DESCRIPTION, "Paste"); + _actions[CommonBase.PASTE].putValue(Action.SHORT_DESCRIPTION, "粘贴"); - _actions[CommonBase.DELETE] = new AbstractAction("Delete") + _actions[CommonBase.DELETE] = new AbstractAction("删除") { public void actionPerformed(ActionEvent e) { @@ -1417,10 +1427,10 @@ } }; _actions[CommonBase.DELETE].putValue(Action.ACCELERATOR_KEY, KeyStroke.getKeyStroke("DELETE")); - _actions[CommonBase.DELETE].putValue(Action.SHORT_DESCRIPTION, "Delete"); + _actions[CommonBase.DELETE].putValue(Action.SHORT_DESCRIPTION, "删除"); _actions[CommonBase.SHOW_VARS] = new - AbstractAction("Show variables") + AbstractAction("变量") { public void actionPerformed(ActionEvent e) { @@ -1429,11 +1439,11 @@ }; _actions[CommonBase.SHOW_VARS].putValue( Action.SHORT_DESCRIPTION, - "Show variables and parameters in the Properties pane"); + "在属性栏显示变量和参数"); _actions[CommonBase.SUBSTITUTE_VARS] = new - AbstractAction("Substitute variables") + AbstractAction("实际值") { public void actionPerformed(ActionEvent e) { @@ -1443,7 +1453,7 @@ _actions[CommonBase.SUBSTITUTE_VARS].putValue( Action.SHORT_DESCRIPTION, - "Substitute variables and parameters with their values in the Properties pane"); + "使用属性栏中定义的值替换掉变量和参数"); _showVarsMenuItem = new @@ -1471,7 +1481,7 @@ _showVarsMenuItem.setSelected(true); _showVarsTool.setSelected(true); - _actions[CommonBase.MOVE_UP] = new AbstractAction("Move up") + _actions[CommonBase.MOVE_UP] = new AbstractAction("上移") { public void actionPerformed(ActionEvent e) { @@ -1479,7 +1489,7 @@ } }; - _actions[CommonBase.MOVE_DOWN] = new AbstractAction("Move down") + _actions[CommonBase.MOVE_DOWN] = new AbstractAction("下移") { public void actionPerformed(ActionEvent e) { @@ -1496,7 +1506,7 @@ } }; _actions[CommonBase.START].putValue(Action.SHORT_DESCRIPTION, - "Start this server"); + "起动服务器"); _actions[CommonBase.STOP] = new AbstractAction( @@ -1508,7 +1518,7 @@ } }; _actions[CommonBase.STOP].putValue(Action.SHORT_DESCRIPTION, - "Stop this server"); + "停止服务器"); _actions[CommonBase.ENABLE] = new AbstractAction( @@ -1520,7 +1530,7 @@ } }; _actions[CommonBase.ENABLE].putValue(Action.SHORT_DESCRIPTION, - "Enable this server"); + "启用此服务器"); _actions[CommonBase.DISABLE] = new AbstractAction( "Disable", Utils.getIcon("/icons/16x16/disable.png")) @@ -1531,9 +1541,9 @@ } }; _actions[CommonBase.DISABLE].putValue(Action.SHORT_DESCRIPTION, - "Disable this server"); + "禁用此服务器"); - _actions[CommonBase.SHUTDOWN_NODE] = new AbstractAction("Shutdown") + _actions[CommonBase.SHUTDOWN_NODE] = new AbstractAction("关闭") { public void actionPerformed(ActionEvent e) { @@ -1541,7 +1551,7 @@ } }; _actions[CommonBase.APPLICATION_INSTALL_DISTRIBUTION] = - new AbstractAction("Patch") + new AbstractAction("补丁") { public void actionPerformed(ActionEvent e) { @@ -1549,7 +1559,7 @@ } }; _actions[CommonBase.SERVER_INSTALL_DISTRIBUTION] = - new AbstractAction("Patch") + new AbstractAction("补丁") { public void actionPerformed(ActionEvent e) { @@ -1570,7 +1580,7 @@ Component currentStatus = _currentEditor.getCurrentStatus(title); if(title.value == null) { - title.value = "Current status"; + title.value = "当前状态"; } _currentStatusFrame.setTitle(title.value); @@ -1643,18 +1653,18 @@ { JOptionPane.showMessageDialog( _mainFrame, - "The default application descriptor from the IceGrid Registry is invalid:\n" + "IceGrid注册表中的默认应用描述符是无效的:\n" + e.reason, - "Deployment Exception", + "部署异常", JOptionPane.ERROR_MESSAGE); } catch(Ice.LocalException e) { JOptionPane.showMessageDialog( _mainFrame, - "Could not retrieve the default application descriptor from the IceGrid Registry: \n" + "不能取得IceGrid注册表中的默认应用描述符: \n" + e.toString(), - "Trouble with IceGrid Registry", + " 导致IceGrid注册表产生严重问题", JOptionPane.ERROR_MESSAGE); } finally @@ -1672,8 +1682,8 @@ { int saveFirst = JOptionPane.showConfirmDialog( _mainFrame, - "Do you want to save your updates?", - "Save Confirmation", + "要保存所有更新吗?", + "保存确认", JOptionPane.YES_NO_CANCEL_OPTION); switch(saveFirst) @@ -1705,8 +1715,8 @@ { int saveFirst = JOptionPane.showConfirmDialog( _mainFrame, - "Do you want to save your updates?", - "Save Confirmation", + "要保存所有更新吗?", + "保存确认", JOptionPane.YES_NO_CANCEL_OPTION); switch(saveFirst) @@ -1827,7 +1837,7 @@ } } - private void helpContents() + private void onlineHelpContents() { BareBonesBrowserLaunch.openURL( "http://www.zeroc.com/help/IceGridAdmin/"); @@ -1835,14 +1845,16 @@ private void about() { - String text = "IceGrid Admin version " + String text = "IceGrid管理器版本 " + IceUtil.Version.ICE_STRING_VERSION + "\n" - + "Copyright \u00A9 2005 ZeroC, Inc. All rights reserved.\n"; + + "版权(R) 2005 ZeroC公司保留所有权利.\n" + + "翻译:殷允桥\n" + + "2006年04月19日"; JOptionPane.showMessageDialog( _mainFrame, text, - "About - IceGrid Admin", + "关于 - IceGrid 管理器中文版", JOptionPane.INFORMATION_MESSAGE); } @@ -2040,9 +2052,9 @@ private boolean _displayEnabled = true; private SimpleInternalFrame _currentStatusFrame - = new SimpleInternalFrame("Current status"); + = new SimpleInternalFrame("当前状态"); private SimpleInternalFrame _propertiesFrame - = new SimpleInternalFrame("Properties"); + = new SimpleInternalFrame("属性"); private JFrame _mainFrame; private SessionKeeper _sessionKeeper; @@ -2052,6 +2064,7 @@ private Object _clipboard; private LicenseDialog _licenseDialog; + private HelpDialog _helpDialog; // // back/forward navigation @@ -2073,6 +2086,7 @@ private Action _exit; private Action _back; private Action _forward; + private Action _onlineHelpContents; private Action _helpContents; private Action _copying; private Action _warranty; diff -Nur IceJ-3.0.0/src/IceGrid/ParametersDialog.java IceJ-3.0.0-CN/src/IceGrid/ParametersDialog.java --- IceJ-3.0.0/src/IceGrid/ParametersDialog.java 2005-10-29 02:30:55.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/ParametersDialog.java 2006-04-19 23:15:04.000000000 +0800 @@ -47,7 +47,7 @@ String valHeading, boolean editNames, final String nullLabel) { - super(parentFrame, title + " - IceGrid Admin", true); + super(parentFrame, title + " - IceGrid管理器", true); _editNames = editNames; _nullObject = new Object() { @@ -70,7 +70,7 @@ comboBox.addItem(_nullObject); _cellEditor = new DefaultCellEditor(comboBox); - Action ok = new AbstractAction("OK") + Action ok = new AbstractAction("确定") { public void actionPerformed(ActionEvent e) { @@ -80,7 +80,7 @@ }; JButton okButton = new JButton(ok); - Action cancel = new AbstractAction("Cancel") + Action cancel = new AbstractAction("取消") { public void actionPerformed(ActionEvent e) { @@ -91,7 +91,7 @@ if(_editNames) { - Action deleteRow = new AbstractAction("Delete selected parameter(s)") + Action deleteRow = new AbstractAction("删除选定参数") { public void actionPerformed(ActionEvent e) { diff -Nur IceJ-3.0.0/src/IceGrid/SessionKeeper.java IceJ-3.0.0-CN/src/IceGrid/SessionKeeper.java --- IceJ-3.0.0/src/IceGrid/SessionKeeper.java 2005-10-28 04:50:06.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/SessionKeeper.java 2006-04-19 23:20:34.000000000 +0800 @@ -176,11 +176,11 @@ { LoginDialog() { - super(_model.getMainFrame(), "Login - IceGrid Admin", true); + super(_model.getMainFrame(), "登录 - IceGrid管理器", true); setDefaultCloseOperation(JDialog.HIDE_ON_CLOSE); - JButton okButton = new JButton("OK"); + JButton okButton = new JButton("确定"); ActionListener okListener = new ActionListener() { public void actionPerformed(ActionEvent e) @@ -199,7 +199,7 @@ okButton.addActionListener(okListener); getRootPane().setDefaultButton(okButton); - JButton cancelButton = new JButton("Cancel"); + JButton cancelButton = new JButton("取消"); ActionListener cancelListener = new ActionListener() { public void actionPerformed(ActionEvent e) @@ -218,13 +218,13 @@ builder.setRowGroupingEnabled(true); builder.setLineGapSize(LayoutStyle.getCurrent().getLinePad()); - builder.append("Username", _registryUsername); + builder.append("用户名", _registryUsername); builder.nextLine(); builder.append("", _registryAutoconnect); builder.nextLine(); - builder.append("IceGrid Instance Name", _registryInstanceName); + builder.append("IceGrid 实例名", _registryInstanceName); builder.nextLine(); - builder.append("IceGrid Registry Endpoint(s)", _registryEndpoints); + builder.append("IceGrid 注册表端口", _registryEndpoints); builder.nextLine(); directPanel = builder.getPanel(); @@ -240,20 +240,20 @@ builder.setRowGroupingEnabled(true); builder.setLineGapSize(LayoutStyle.getCurrent().getLinePad()); - builder.append("Username", _routerUsername); + builder.append("用户名", _routerUsername); builder.nextLine(); - builder.append("Password", _routerPassword); + builder.append("密码", _routerPassword); builder.nextLine(); - builder.append("Glacier2 Instance Name", _routerInstanceName); + builder.append("Glacier2实例名", _routerInstanceName); builder.nextLine(); - builder.append("Glacier2 Router Endpoint(s)", _routerEndpoints); + builder.append("Glacier2路由器端口", _routerEndpoints); builder.nextLine(); routedPanel = builder.getPanel(); } - _tabbedPane.addTab("Direct", directPanel); - _tabbedPane.addTab("Routed", routedPanel); + _tabbedPane.addTab("直连", directPanel); + _tabbedPane.addTab("路由", routedPanel); _tabbedPane.setBorder(Borders.DIALOG_BORDER); JComponent buttonBar = @@ -312,7 +312,7 @@ private JTabbedPane _tabbedPane = new JTabbedPane(); private JTextField _registryUsername = new JTextField(30); private JCheckBox _registryAutoconnect - = new JCheckBox("Automatically log in at startup"); + = new JCheckBox("启动时自动登录"); private JTextField _registryInstanceName = new JTextField(30); private JTextField _registryEndpoints = new JTextField(30); @@ -350,7 +350,7 @@ { public void run() { - sessionLost("Failed to contact the IceGrid registry: " + sessionLost("连接IceGrid注册表失败: " + e.toString()); } }); @@ -476,9 +476,9 @@ { logout(true); JOptionPane.showMessageDialog(parent, - "Could not register observers: " + "不能注册观察者: " + e.toString(), - "Login failed", + "登录失败", JOptionPane.ERROR_MESSAGE); return false; } @@ -497,7 +497,7 @@ JOptionPane.showMessageDialog( _model.getMainFrame(), message, - "Session lost", + "会话丢失", JOptionPane.ERROR_MESSAGE); logout(false); diff -Nur IceJ-3.0.0/src/IceGrid/TableDialog.java IceJ-3.0.0-CN/src/IceGrid/TableDialog.java --- IceJ-3.0.0/src/IceGrid/TableDialog.java 2005-10-29 02:30:55.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TableDialog.java 2006-04-19 23:22:06.000000000 +0800 @@ -40,7 +40,7 @@ public TableDialog(Frame parentFrame, String title, String heading0, String heading1, boolean editKeys) { - super(parentFrame, title + " - IceGrid Admin", true); + super(parentFrame, title + " - IceGrid管理器", true); _editKeys = editKeys; setDefaultCloseOperation(JDialog.HIDE_ON_CLOSE); @@ -50,7 +50,7 @@ _table = new JTable(); - Action ok = new AbstractAction("OK") + Action ok = new AbstractAction("确定") { public void actionPerformed(ActionEvent e) { @@ -60,7 +60,7 @@ }; JButton okButton = new JButton(ok); - Action cancel = new AbstractAction("Cancel") + Action cancel = new AbstractAction("取消") { public void actionPerformed(ActionEvent e) { @@ -71,7 +71,7 @@ if(_editKeys) { - Action deleteRow = new AbstractAction("Delete selected row(s)") + Action deleteRow = new AbstractAction("删除选定行") { public void actionPerformed(ActionEvent e) { diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/AbstractServerEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/AbstractServerEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/AbstractServerEditor.java 2005-10-19 07:11:29.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/AbstractServerEditor.java 2006-04-19 23:23:41.000000000 +0800 @@ -239,11 +239,11 @@ void appendCurrentStatus(DefaultFormBuilder builder) { - builder.append("State"); + builder.append("状态"); builder.append(_currentState, 3); builder.nextLine(); - builder.append("Process ID"); + builder.append("进程ID"); builder.append(_currentPid, 3); builder.nextLine(); } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/AdapterEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/AdapterEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/AdapterEditor.java 2005-11-12 07:43:53.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/AdapterEditor.java 2006-04-20 10:09:06.000000000 +0800 @@ -61,7 +61,7 @@ _currentStatus.setEditable(false); _currentEndpoints.setEditable(false); _currentEndpoints.setToolTipText( - "Endpoints registered with the IceGrid Registry during the activation of this adapter"); + "适配器激活时向IceGrid注册表注册端口"); // // Create buttons @@ -102,16 +102,16 @@ } }; gotoReplicaGroup.putValue(Action.SHORT_DESCRIPTION, - "Goto the definition of this replica group"); + "查看复制组的定义"); _replicaGroupButton = new JButton(gotoReplicaGroup); // // _objectsButton // _objectsDialog = new TableDialog(parentFrame, - "Registered Objects", - "Object Identity", - "Type", true); + "已注册对象", + "对象标示", + "类型", true); Action openObjectsDialog = new AbstractAction("...") { @@ -128,11 +128,11 @@ } }; openObjectsDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit registered objects"); + "编辑已注册对象"); _objectsButton = new JButton(openObjectsDialog); - Action checkRegisterProcess = new AbstractAction("Register Process") + Action checkRegisterProcess = new AbstractAction("注册进程") { public void actionPerformed(ActionEvent e) { @@ -141,13 +141,13 @@ }; _registerProcess = new JCheckBox(checkRegisterProcess); _registerProcess.setToolTipText( - "During activation, create a Process object
" - + "in this adapter and register it with IceGrid
" - + "to enable clean shutdown; you should register
" - + "exactly one Process object per server."); + "当激活时在此适配器中创建一个进程对象
" + + "并向IceGrid注册,IceGrid就可以使用此对象
" + + "进行干净的进程关闭操作;你应该确保每个服
" + + "务器只注册一个进程对象!"); Action checkWaitForActivation = - new AbstractAction("Wait for Activation") + new AbstractAction("等待激活") { public void actionPerformed(ActionEvent e) { @@ -156,8 +156,8 @@ }; _waitForActivation = new JCheckBox(checkWaitForActivation); _waitForActivation.setToolTipText( - "When starting the enclosing server, " - + "does IceGrid
wait for this adapter to become active?"); + "当启动服务器时,IceGrid是否需要等待此适配器的激活?"); + // // Associate updateListener with various fields // @@ -191,38 +191,38 @@ }); _name.setToolTipText( - "Identifies this object adapter within an Ice communicator"); + "在一个Ice通信器内部标识此对象适配器"); _endpoints.getDocument().addDocumentListener(_updateListener); _endpoints.setToolTipText( - "The network interfaces on which this adapter receives requests;
" - + "for example:
" - + " tcp (listen on all local interfaces using a random port)
" - + " tcp -h venus.foo.com (listen on just one interface)
" - + " tcp -t 10000 (sets a timeout of 10,000 milliseconds)
" - + " ssl -h venus.foo.com (accepts SSL connections instead of plain TCP)" + "对象适配器接受请求的网络接口:
" + + "例如:
" + + " tcp (使用随机的端口号侦听所有本地网络接口)
" + + " tcp -h hotmill.baosteel.com (只在此地址侦听)
" + + " tcp -t 10000 (设置 10,000毫秒的超时)
" + + " ssl -h hotmill.baosteel.com (使用加密的SSL协议连接代替TCP协议)" + ""); _description.getDocument().addDocumentListener(_updateListener); _description.setToolTipText( - "An optional description for this object adapter"); + "对此对象适配器的可选描述信息"); JTextField idTextField = (JTextField) _id.getEditor().getEditorComponent(); idTextField.getDocument().addDocumentListener(_updateListener); - _id.setToolTipText("If set, must be unique within this IceGrid deployment"); + _id.setToolTipText("如果设置,则在整个IceGrid环境中必须保持唯一"); JTextField replicaGroupIdTextField = (JTextField) _replicaGroupId.getEditor().getEditorComponent(); replicaGroupIdTextField.getDocument().addDocumentListener(_updateListener); - _replicaGroupId.setToolTipText("Select a replica group"); + _replicaGroupId.setToolTipText("选择一个复制组"); JTextField publishedEndpointsTextField = (JTextField) _publishedEndpoints.getEditor().getEditorComponent(); publishedEndpointsTextField.getDocument().addDocumentListener(_updateListener); _publishedEndpoints.setToolTipText( - "Direct adapter: endpoints included in proxies created using this adapter.
" - + "Indirect adapter: endpoints registered with the IceGrid Registry during the activation of this adapter." + "直接对象适配器:使用此适配器的对象代理内部直接包含此适配器的端口信息。
" + + "间接对象适配器:当此适配器被激活时,端口信息自动注册在IceGrid注册表中。" + ""); } @@ -258,22 +258,22 @@ void appendCurrentStatus(DefaultFormBuilder builder) { - builder.append("Status" ); + builder.append("状态" ); builder.append(_currentStatus, 3); builder.nextLine(); - builder.append("Published Endpoints" ); + builder.append("发布的端口" ); builder.append(_currentEndpoints, 3); builder.nextLine(); } void appendProperties(DefaultFormBuilder builder) { - builder.append("Adapter Name" ); + builder.append("对象适配器名" ); builder.append(_name, 3); builder.nextLine(); - builder.append("Description"); + builder.append("描述"); builder.nextLine(); builder.append(""); builder.nextRow(-2); @@ -284,15 +284,15 @@ builder.nextRow(2); builder.nextLine(); - builder.append("Adapter ID"); + builder.append("对象适配器ID"); builder.append(_id, 3); builder.nextLine(); - builder.append("Replica Group", _replicaGroupId); + builder.append("对象复制组", _replicaGroupId); builder.append(_replicaGroupButton); builder.nextLine(); - builder.append("Registered Objects"); + builder.append("注册的对象"); builder.append(_objects, _objectsButton); builder.nextLine(); @@ -301,11 +301,11 @@ builder.append("", _waitForActivation); builder.nextLine(); - builder.append("Endpoints" ); + builder.append("端口" ); builder.append(_endpoints, 3); builder.nextLine(); - builder.append("Published Endpoints" ); + builder.append("发布的端口" ); builder.append(_publishedEndpoints, 3); builder.nextLine(); } @@ -567,12 +567,12 @@ if(currentEndpoints == null) { - _currentStatus.setText("Inactive"); + _currentStatus.setText("停止"); _currentEndpoints.setText(""); } else { - _currentStatus.setText("Active"); + _currentStatus.setText("活动"); _currentEndpoints.setText(currentEndpoints); } } @@ -649,7 +649,7 @@ { public String toString() { - return "Actual endpoints"; + return "实际端口"; } }; @@ -657,7 +657,7 @@ { public String toString() { - return "No ID (a direct adapter)"; + return "没有ID (直接对象适配器)"; } }; @@ -665,7 +665,7 @@ { public String toString() { - return "Does not belong to a replica group"; + return "不属于任何对象复制组"; } }; } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Adapter.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Adapter.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Adapter.java 2005-10-27 07:28:50.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Adapter.java 2006-04-19 23:59:08.000000000 +0800 @@ -273,7 +273,7 @@ if(proxy == null) { _currentEndpoints = null; - _toolTip = "Inactive"; + _toolTip = "停止"; } else { @@ -287,7 +287,7 @@ { _currentEndpoints = str.substring(index + 1); } - _toolTip = "Published endpoints: " + _currentEndpoints; + _toolTip = "已发布端口: " + _currentEndpoints; } } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Adapters.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Adapters.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Adapters.java 2005-10-13 08:06:05.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Adapters.java 2006-04-20 09:56:14.000000000 +0800 @@ -54,7 +54,7 @@ { _popup = new PopupMenu(_model); JMenuItem item = new JMenuItem(_model.getActions()[NEW_ADAPTER]); - item.setText("New adapter"); + item.setText("新适配器"); _popup.add(item); } if(canHaveNewChild()) @@ -100,7 +100,7 @@ Model model) throws UpdateFailedException { - super("Adapters", model); + super("适配器", model); _descriptors = descriptors; _isEditable = isEditable; _inIceBox = inIceBox; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ApplicationEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ApplicationEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ApplicationEditor.java 2005-11-09 00:07:53.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ApplicationEditor.java 2006-04-20 00:06:56.000000000 +0800 @@ -152,7 +152,7 @@ // Variables // _variablesDialog = new TableDialog(parentFrame, - "Variables", "Name", "Value", true); + "自定义变量", "变量名", "值", true); Action openVariablesDialog = new AbstractAction("...") { @@ -169,7 +169,7 @@ } }; openVariablesDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit variables"); + "编辑变量"); _variablesButton = new JButton(openVariablesDialog); // @@ -177,7 +177,7 @@ // _distrib = new JComboBox(new Object[]{NO_DISTRIB, DEFAULT_DISTRIB}); _distrib.setEditable(true); - _distrib.setToolTipText("The proxy to the IcePatch2 server holding your files"); + _distrib.setToolTipText("IcePatch2服务器的代理持有你的文件"); JTextField distribTextField = (JTextField) _distrib.getEditor().getEditorComponent(); @@ -186,7 +186,7 @@ _distribDirs.setEditable(false); _distribDirsDialog = new ListDialog(parentFrame, - "Directories", true); + "目录", true); Action openDistribDirsDialog = new AbstractAction("...") { @@ -203,17 +203,17 @@ } }; openDistribDirsDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit directory list"); + "编辑目录列表"); _distribDirsButton = new JButton(openDistribDirsDialog); } void appendProperties(DefaultFormBuilder builder) { - builder.append("Name"); + builder.append("名字"); builder.append(_name, 3); - builder.append("Description"); + builder.append("描述"); builder.nextLine(); builder.append(""); builder.nextRow(-2); @@ -224,16 +224,16 @@ builder.nextRow(2); builder.nextLine(); - builder.append("Variables", _variables); + builder.append("变量", _variables); builder.append(_variablesButton); builder.nextLine(); - JComponent c = builder.appendSeparator("Distribution"); - c.setToolTipText("Files shared by all servers in your application"); + JComponent c = builder.appendSeparator("分布"); + c.setToolTipText("被应用中所有服务器共享的文件"); builder.append("IcePatch2 Proxy"); builder.append(_distrib, 3); builder.nextLine(); - builder.append("Directories"); + builder.append("目录"); builder.append(_distribDirs, _distribDirsButton); builder.nextLine(); } @@ -281,7 +281,7 @@ Utils.substitute(descriptor.description, resolver)); _description.setEditable(isEditable); _description.setOpaque(isEditable); - _description.setToolTipText("An optional description for this application"); + _description.setToolTipText("对应用的可选描述"); _variablesMap = descriptor.variables; setVariablesField(); @@ -328,7 +328,7 @@ Utils.stringify(_distribDirsList, stringifier, ", ", toolTipHolder)); - String toolTip = "Include only these directories"; + String toolTip = "仅包含这些目录"; if(toolTipHolder.value != null) { @@ -364,7 +364,7 @@ { public String toString() { - return "None selected"; + return "未选择"; } }; static private final String DEFAULT_DISTRIB = "${application}.IcePatch2/server"; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Application.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Application.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Application.java 2005-11-09 03:51:53.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Application.java 2006-04-20 10:08:01.000000000 +0800 @@ -118,25 +118,25 @@ _popup = new PopupMenu(_model); JMenuItem newNodeItem = new JMenuItem(_model.getActions()[NEW_NODE]); - newNodeItem.setText("New node"); + newNodeItem.setText("新节点"); _popup.add(newNodeItem); JMenuItem newReplicaGroupItem = new JMenuItem(_model.getActions()[NEW_REPLICA_GROUP]); - newReplicaGroupItem.setText("New replica group"); + newReplicaGroupItem.setText("新复制组"); _popup.add(newReplicaGroupItem); _popup.addSeparator(); JMenuItem newServerItem = new JMenuItem(_model.getActions()[NEW_TEMPLATE_SERVER]); - newServerItem.setText("New server template"); + newServerItem.setText("新服务器模板"); _popup.add(newServerItem); JMenuItem newIceBoxItem = new JMenuItem(_model.getActions()[NEW_TEMPLATE_SERVER_ICEBOX]); - newIceBoxItem.setText("New IceBox server template"); + newIceBoxItem.setText("新IceBox服务器模板"); _popup.add(newIceBoxItem); _popup.addSeparator(); JMenuItem newServiceItem = new JMenuItem(_model.getActions()[NEW_TEMPLATE_SERVICE]); - newServiceItem.setText("New service template"); + newServiceItem.setText("新服务模板"); _popup.add(newServiceItem); _popup.addSeparator(); @@ -178,10 +178,8 @@ { int shutdown = JOptionPane.showConfirmDialog( _model.getMainFrame(), - "You are about to install or refresh" - + " the distribution of your application onto this node.\n" - + " Do you want shut down all servers affected by this update?", - "Patch Confirmation", + "你正要安装或更新你的应用分布信息到这个节点上。你希望关闭受此更新影响的所有服务器吗?" + ,"补丁安装确认", JOptionPane.YES_NO_CANCEL_OPTION); if(shutdown == JOptionPane.CANCEL_OPTION) @@ -194,7 +192,7 @@ return; } - final String prefix = "Patching application '" + _id + "'..."; + final String prefix = "正在修补应用 '" + _id + "'..."; _model.getStatusBar().setText(prefix); AMI_Admin_patchApplication cb = new AMI_Admin_patchApplication() @@ -209,12 +207,12 @@ public void ice_exception(Ice.UserException e) { - amiFailure(prefix, "Failed to patch " + _id, e); + amiFailure(prefix, "修补失败 " + _id, e); } public void ice_exception(Ice.LocalException e) { - amiFailure(prefix, "Failed to patch " + _id, e.toString()); + amiFailure(prefix, "修补失败 " + _id, e.toString()); } }; @@ -228,7 +226,7 @@ } catch(Ice.LocalException e) { - failure(prefix, "Failed to patch " + _id, e.toString()); + failure(prefix, "修补失败 " + _id, e.toString()); } finally { @@ -408,9 +406,8 @@ { int confirm = JOptionPane.showConfirmDialog( _model.getMainFrame(), - "This will immediately remove this application from " - + "the IceGrid Registry. Do you want to proceed?", - "Remove Confirmation", + "将立即从IceGrid注册表中删除此应用。你确定继续吗? 真的确定吗?不是闹着完的吧?可别后悔哦!" + ,"删除确认", JOptionPane.YES_NO_OPTION); // diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/CommonBaseI.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/CommonBaseI.java --- IceJ-3.0.0/src/IceGrid/TreeNode/CommonBaseI.java 2005-10-27 07:54:03.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/CommonBaseI.java 2006-04-20 23:06:30.000000000 +0800 @@ -380,7 +380,7 @@ { public void run() { - _model.getStatusBar().setText(prefix + "done."); + _model.getStatusBar().setText(prefix + "完成."); } }); } @@ -393,19 +393,19 @@ (IceGrid.ServerNotExistException)e; amiFailure(prefix, title, - "Server '" + sne.id + - "' was not registered with the IceGrid Registry"); + "服务器 '" + sne.id + + "' 没有注册到此IceGrid注册表"); } else if(e instanceof IceGrid.ServerStartException) { IceGrid.ServerStartException ste = (IceGrid.ServerStartException)e; - amiFailure(prefix, title, "Server '" + - ste.id + "' did not start: " + ste.reason); + amiFailure(prefix, title, "服务器 '" + + ste.id + "' 没有启动: " + ste.reason); } else if(e instanceof IceGrid.ApplicationNotExistException) { amiFailure(prefix, title, - "This application was not registered with the IceGrid Registry"); + "此应用没有注册到IceGrid注册表"); } else if(e instanceof IceGrid.PatchException) { @@ -418,15 +418,15 @@ (IceGrid.NodeNotExistException)e; amiFailure(prefix, title, - "Node '" + nnee.name + - " 'was not registered with the IceGrid Registry."); + "节点 '" + nnee.name + + " '没有注册到IceGrid注册表."); } else if(e instanceof IceGrid.NodeUnreachableException) { IceGrid.NodeUnreachableException nue = (IceGrid.NodeUnreachableException)e; - amiFailure(prefix, title, "Node '" + - nue.name + "' is unreachable: " + nue.reason); + amiFailure(prefix, title, "节点 '" + + nue.name + "' 不可达: " + nue.reason); } else { @@ -448,7 +448,7 @@ protected void failure(String prefix, String title, String message) { - _model.getStatusBar().setText(prefix + "failed!"); + _model.getStatusBar().setText(prefix + "失败!"); JOptionPane.showMessageDialog( _model.getMainFrame(), diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/CommunicatorSubEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/CommunicatorSubEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/CommunicatorSubEditor.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/CommunicatorSubEditor.java 2006-04-20 08:08:29.000000000 +0800 @@ -38,9 +38,9 @@ // _propertiesButton // _propertiesDialog = new TableDialog(parentFrame, - "Properties", - "Name", - "Value", true); + "属性", + "名字", + "值", true); Action openPropertiesDialog = new AbstractAction("...") { @@ -58,18 +58,18 @@ } }; openPropertiesDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit properties"); + "编辑属性"); _propertiesButton = new JButton(openPropertiesDialog); _description.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); - _description.setToolTipText("An optional description"); + _description.setToolTipText("可选的描述"); } void appendProperties(DefaultFormBuilder builder) { - builder.append("Description"); + builder.append("描述"); builder.nextLine(); builder.append(""); builder.nextRow(-2); @@ -80,7 +80,7 @@ builder.nextRow(2); builder.nextLine(); - builder.append("Properties"); + builder.append("属性"); builder.append(_properties, _propertiesButton); builder.nextLine(); } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/DbEnvEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/DbEnvEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/DbEnvEditor.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/DbEnvEditor.java 2006-04-20 08:18:39.000000000 +0800 @@ -35,17 +35,17 @@ super(false); _name.getDocument().addDocumentListener(_updateListener); _name.setToolTipText( - "Identifies this Freeze database environment within an Ice communicator"); + "标识Ice通信器中的Freeze数据库环境"); _description.getDocument().addDocumentListener(_updateListener); _description.setToolTipText( - "An optional description for this database environment"); + "对此数据库环境的可选描述"); JTextField dbHomeTextField = (JTextField) _dbHome.getEditor().getEditorComponent(); dbHomeTextField.getDocument().addDocumentListener(_updateListener); - _dbHome.setToolTipText("node data dir/servers/server id" - + "/dbs/db env name if created by the IceGrid Node;
" - + "otherwise, IceGrid does not create this directory" + _dbHome.setToolTipText("节点数据目录/servers/服务器ID" + + "/dbs/DB环境名 由IceGrid节点创建;
" + + "否则IceGrid不会创建此目录" + ""); @@ -55,9 +55,9 @@ // _propertiesButton // _propertiesDialog = new TableDialog(parentFrame, - "Berkeley DB Configuration Properties", - "Name", - "Value", true); + "Berkeley DB 配置属性", + "名字", + "值", true); Action openPropertiesDialog = new AbstractAction("...") { @@ -75,7 +75,7 @@ } }; openPropertiesDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit properties"); + "编辑属性"); _propertiesButton = new JButton(openPropertiesDialog); } @@ -98,11 +98,11 @@ void appendProperties(DefaultFormBuilder builder) { - builder.append("Name" ); + builder.append("名字" ); builder.append(_name, 3); builder.nextLine(); - builder.append("Description"); + builder.append("描述"); builder.nextLine(); builder.append(""); builder.nextRow(-2); @@ -113,11 +113,11 @@ builder.nextRow(2); builder.nextLine(); - builder.append("DB Home" ); + builder.append("DB HOME目录" ); builder.append(_dbHome, 3); builder.nextLine(); - builder.append("Properties"); + builder.append("属性"); builder.append(_properties, _propertiesButton); builder.nextLine(); } @@ -212,8 +212,7 @@ Utils.stringify(_propertiesMap.entrySet(), stringifier, ", ", toolTipHolder)); - String toolTip = "Properties used to generate a" - + " DB_CONFIG file in the DB home directory"; + String toolTip = "这些属性将在DB HOME目录产生一个DB_CONFIG文件"; if(toolTipHolder.value != null) { toolTip += ":
" + toolTipHolder.value; @@ -237,7 +236,7 @@ { public String toString() { - return "Created by the IceGrid Node"; + return "由IceGrid节点创建"; } }; } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/DbEnvs.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/DbEnvs.java --- IceJ-3.0.0/src/IceGrid/TreeNode/DbEnvs.java 2005-11-15 00:24:11.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/DbEnvs.java 2006-04-20 09:57:24.000000000 +0800 @@ -111,7 +111,7 @@ Model model) throws UpdateFailedException { - super("DbEnvs", model); + super("数据库环境", model); _isEditable = isEditable; _descriptors = descriptors; _resolver = resolver; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/DuplicateIdException.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/DuplicateIdException.java --- IceJ-3.0.0/src/IceGrid/TreeNode/DuplicateIdException.java 2005-09-01 02:03:10.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/DuplicateIdException.java 2006-04-20 08:19:52.000000000 +0800 @@ -18,8 +18,8 @@ public String toString() { - return _parent.getId() + " cannot have two children with '" - + _id + "' as id"; + return _parent.getId() + " 标识号 '" + + _id + "' 不能有两个成员"; } private Parent _parent; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Editor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Editor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Editor.java 2005-11-03 01:21:49.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Editor.java 2006-04-20 13:13:11.000000000 +0800 @@ -158,7 +158,7 @@ // // _applyButton // - AbstractAction apply = new AbstractAction("Apply") + AbstractAction apply = new AbstractAction("确定") { public void actionPerformed(ActionEvent e) { @@ -170,7 +170,7 @@ // // _discardButton // - AbstractAction discard = new AbstractAction("Discard") + AbstractAction discard = new AbstractAction("放弃") { public void actionPerformed(ActionEvent e) { diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/NodeEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/NodeEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/NodeEditor.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/NodeEditor.java 2006-04-20 08:49:25.000000000 +0800 @@ -165,9 +165,9 @@ super(true, true); _name.getDocument().addDocumentListener(_updateListener); - _name.setToolTipText("Must match the IceGrid.Node.Name property of the desired icegridnode process"); + _name.setToolTipText("对应的icegridnode进程必须有一个IceGrid.Node.Name属性"); _description.getDocument().addDocumentListener(_updateListener); - _description.setToolTipText("An optional description for this node"); + _description.setToolTipText("可选的描述"); _variables.setEditable(false); _hostname.setEditable(false); @@ -175,7 +175,7 @@ _machineType.setEditable(false); _loadAverage.setEditable(false); - Action refresh = new AbstractAction("Refresh") + Action refresh = new AbstractAction("刷新") { public void actionPerformed(ActionEvent e) { @@ -184,7 +184,7 @@ } }; refresh.putValue(Action.SHORT_DESCRIPTION, - "Fetch the latest values from this IceGrid Node"); + "从IceGrid节点获取最新的值"); _refreshButton = new JButton(refresh); @@ -192,7 +192,7 @@ // Variables // _variablesDialog = new TableDialog(parentFrame, - "Variables", "Name", "Value", true); + "变量", "名", "值", true); Action openVariablesDialog = new AbstractAction("...") { @@ -209,18 +209,18 @@ } }; openVariablesDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit variables"); + "编辑变量"); _variablesButton = new JButton(openVariablesDialog); _loadFactor.getDocument().addDocumentListener(_updateListener); - _loadFactor.setToolTipText("A floating point value.
" - + "When not specified, IceGrid uses 1.0 on all platforms
" - + "except Windows where it uses 1.0 divided by number of processors."); + _loadFactor.setToolTipText("浮点值.
" + + "如果不设置, IceGrid在大部分平台上使用1.0做为默认值
" + + "在Windows平台上使用1.0除以处理器个数."); } public JComponent getCurrentStatus(Ice.StringHolder title) { - title.value = "System information"; + title.value = "系统信息"; return super.getCurrentStatus(title); } @@ -231,34 +231,34 @@ if(info == null) { - _hostname.setText("Unknown"); - _os.setText("Unknown"); - _machineType.setText("Unknown"); - _loadAverageLabel.setText("Load Average"); - _loadAverage.setText("Unknown"); + _hostname.setText("未知"); + _os.setText("未知"); + _machineType.setText("未知"); + _loadAverageLabel.setText("平均负载"); + _loadAverage.setText("未知"); } else { _hostname.setText(info.hostname); _os.setText(info.os + " " + info.release + " " + info.version); - _machineType.setText(info.machine + " with " + + _machineType.setText(info.machine + " 处理器个数 " + info.nProcessors + " CPU" + (info.nProcessors >= 2 ? "s" : "")); if(node.isRunningWindows()) { - _loadAverageLabel.setText("CPU Usage"); + _loadAverageLabel.setText("CPU 运行信息"); _loadAverage.setToolTipText( - "CPU usage in the past 1 min, 5 min and 15 min period"); + "在过去1分钟,5分钟,15分钟期间的CPU使用情况"); } else { - _loadAverageLabel.setText("Load Average"); + _loadAverageLabel.setText("平均负载"); _loadAverage.setToolTipText( - "Load average in the past 1 min, 5 min and 15 min period"); + "在过去1分钟,5分钟,15分钟期间的平均负载情况"); } - _loadAverage.setText("Refreshing..."); + _loadAverage.setText("刷新..."); node.getLoad(); } } @@ -277,13 +277,13 @@ void appendCurrentStatus(DefaultFormBuilder builder) { - builder.append("Hostname"); + builder.append("主机"); builder.append(_hostname, 3); builder.nextLine(); - builder.append("Operating System"); + builder.append("操作系统"); builder.append(_os, 3); builder.nextLine(); - builder.append("Machine Type"); + builder.append("机器类型"); builder.append(_machineType, 3); builder.append(_loadAverageLabel, _loadAverage); builder.append(_refreshButton); @@ -292,11 +292,11 @@ void appendProperties(DefaultFormBuilder builder) { - builder.append("Name"); + builder.append("名字"); builder.append(_name, 3); builder.nextLine(); - builder.append("Description"); + builder.append("描述"); builder.nextLine(); builder.append(""); builder.nextRow(-2); @@ -307,10 +307,10 @@ builder.nextRow(2); builder.nextLine(); - builder.append("Variables", _variables); + builder.append("变量", _variables); builder.append(_variablesButton); builder.nextLine(); - builder.append("Load Factor"); + builder.append("负载加权因子"); builder.append(_loadFactor, 3); builder.nextLine(); } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Node.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Node.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Node.java 2005-11-09 03:51:53.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Node.java 2006-04-20 08:58:23.000000000 +0800 @@ -103,16 +103,16 @@ _popup = new PopupMenu(_model); JMenuItem newServerItem = new JMenuItem(_model.getActions()[NEW_SERVER]); - newServerItem.setText("New server"); + newServerItem.setText("新服务器"); _popup.add(newServerItem); JMenuItem newIceBoxItem = new JMenuItem(_model.getActions()[NEW_SERVER_ICEBOX]); - newIceBoxItem.setText("New IceBox server"); + newIceBoxItem.setText("新IceBox服务器"); _popup.add(newIceBoxItem); JMenuItem newServerFromTemplateItem = new JMenuItem(_model.getActions()[NEW_SERVER_FROM_TEMPLATE]); - newServerFromTemplateItem.setText("New server from template"); + newServerFromTemplateItem.setText("基于模板的新服务器"); _popup.add(newServerFromTemplateItem); _popup.addSeparator(); @@ -159,7 +159,7 @@ } public void shutdownNode() { - final String prefix = "Shutting down node '" + _id + "'..."; + final String prefix = "正在关闭节点 '" + _id + "'..."; _model.getStatusBar().setText(prefix); AMI_Admin_shutdownNode cb = new AMI_Admin_shutdownNode() @@ -174,12 +174,12 @@ public void ice_exception(Ice.UserException e) { - amiFailure(prefix, "Failed to shutdown " + _id, e); + amiFailure(prefix, _id + " 关闭失败", e); } public void ice_exception(Ice.LocalException e) { - amiFailure(prefix, "Failed to shutdown " + _id, + amiFailure(prefix, _id + "关闭失败", e.toString()); } }; @@ -193,7 +193,7 @@ } catch(Ice.LocalException e) { - failure(prefix, "Failed to shutdown " + _id, e.toString()); + failure(prefix, _id + "关闭失败", e.toString()); } finally { @@ -226,10 +226,10 @@ { JOptionPane.showMessageDialog( _model.getMainFrame(), - "There is no definition for this node in application '" + "应用中没有关于此节点的定义 '" + getApplication().getId() - + "'; this node only appears here because it's up and running.", - "Nothing to destroy", + + "'; 只有节点处于启动和运行状态时才能在这里看到.", + "不需要销毁任何信息", JOptionPane.INFORMATION_MESSAGE); return false; } @@ -278,7 +278,7 @@ if(_up) { - _cellRenderer.setToolTipText("Up and running"); + _cellRenderer.setToolTipText("运行中"); if(expanded) { _cellRenderer.setOpenIcon(_nodeUp); @@ -290,7 +290,7 @@ } else { - _cellRenderer.setToolTipText("Not running"); + _cellRenderer.setToolTipText("没有运行"); if(expanded) { _cellRenderer.setOpenIcon(_nodeDown); @@ -636,16 +636,16 @@ if(e instanceof IceGrid.NodeNotExistException) { _editor.setLoad( - "Error: this node is not known to the IceGrid Registry", + "错误:IceGrid注册表不知道此节点", Node.this); } else if(e instanceof IceGrid.NodeUnreachableException) { - _editor.setLoad("Error: cannot reach this node", Node.this); + _editor.setLoad("错误:节点不能到达", Node.this); } else { - _editor.setLoad("Error: " + e.toString(), Node.this); + _editor.setLoad("错误: " + e.toString(), Node.this); } } }); @@ -671,7 +671,7 @@ IceGrid.AdminPrx admin = _model.getAdmin(); if(admin == null) { - _editor.setLoad("Unknown", this); + _editor.setLoad("未知", this); } else { @@ -1320,8 +1320,8 @@ { JOptionPane.showMessageDialog( _model.getMainFrame(), - "You need to create a server template before you can create a server from a template.", - "No Server Template", + "从模板创建服务器前必须先建立服务器模板.", + "无服务器模板", JOptionPane.INFORMATION_MESSAGE); return; } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Nodes.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Nodes.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Nodes.java 2005-11-09 03:51:53.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Nodes.java 2006-04-20 09:54:10.000000000 +0800 @@ -62,7 +62,7 @@ JMenuItem newNodeItem = new JMenuItem(_model.getActions()[NEW_NODE]); - newNodeItem.setText("New node"); + newNodeItem.setText("新节点"); _popup.add(newNodeItem); } return _popup; @@ -87,7 +87,7 @@ public Nodes(java.util.Map nodeMap, Application application) throws UpdateFailedException { - super(false, "Nodes", application.getModel()); + super(false, "节点", application.getModel()); _descriptors = nodeMap; java.util.Iterator p = nodeMap.entrySet().iterator(); diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ReplicaGroupEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ReplicaGroupEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ReplicaGroupEditor.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ReplicaGroupEditor.java 2006-04-20 10:08:25.000000000 +0800 @@ -179,9 +179,9 @@ // _objectsButton // _objectsDialog = new TableDialog(parentFrame, - "Registered Objects", - "Object Identity", - "Type", true); + "已注册对象", + "对象标识", + "类型", true); Action openObjectsDialog = new AbstractAction("...") { @@ -198,7 +198,7 @@ } }; openObjectsDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit registered objects"); + "编辑已注册对象"); _objectsButton = new JButton(openObjectsDialog); // @@ -222,29 +222,27 @@ } }); _loadBalancing.setToolTipText( - "Specifies how IceGrid selects adapters when resolving a replica group ID"); + "规定IceGrid解析复制组ID时如何选择适配器"); // // Associate updateListener with various fields // _id.getDocument().addDocumentListener(_updateListener); - _id.setToolTipText("Must be unique within this IceGrid deployment"); + _id.setToolTipText("在IceGrid部署环境中必须唯一"); _description.getDocument().addDocumentListener(_updateListener); _description.setToolTipText( - "An optional description for this replica group"); + "对复制组的可选描述"); _nReplicas.getDocument().addDocumentListener(_updateListener); - _nReplicas.setToolTipText("IceGrid returns the endpoints of " - + "up to number adapters
" - + "when resolving a replica group ID"); + _nReplicas.setToolTipText("IceGrid解析复制组ID时返回的适配器端口的最多个数"); _loadSample.setEditable(true); JTextField loadSampleTextField = (JTextField) _loadSample.getEditor().getEditorComponent(); loadSampleTextField.getDocument().addDocumentListener(_updateListener); _loadSample.setToolTipText( - "Use the load average or CPU usage over the last 1, 5 or 15 minutes?"); + "参考过去1分钟,5分钟以及15分钟的CPU平均负载信息吗?"); } @@ -293,11 +291,11 @@ void appendProperties(DefaultFormBuilder builder) { - builder.append("Replica Group ID" ); + builder.append("复制组ID" ); builder.append(_id, 3); builder.nextLine(); - builder.append("Description"); + builder.append("描述"); builder.nextLine(); builder.append(""); builder.nextRow(-2); @@ -308,17 +306,17 @@ builder.nextRow(2); builder.nextLine(); - builder.append("Registered Objects"); + builder.append("已注册的对象"); builder.append(_objects, _objectsButton); builder.nextLine(); - builder.append("Load Balancing Policy"); + builder.append("负载平衡策略"); builder.append(_loadBalancing, 3); builder.nextLine(); - _nReplicasLabel = builder.append("How many Adapters?"); + _nReplicasLabel = builder.append("多少个对象适配器?"); builder.append(_nReplicas, 3); builder.nextLine(); - _loadSampleLabel = builder.append("Load Sample"); + _loadSampleLabel = builder.append("负载采样"); builder.append(_loadSample, 3); builder.nextLine(); } @@ -428,10 +426,10 @@ return (ReplicaGroup)_target; } - static private String RETURN_ALL = "Return all"; - static private String RANDOM = "Random"; - static private String ROUND_ROBIN = "Round-robin"; - static private String ADAPTIVE = "Adaptive"; + static private String RETURN_ALL = "返回所有"; + static private String RANDOM = "随机"; + static private String ROUND_ROBIN = "循环"; + static private String ADAPTIVE = "自适应"; private JTextField _id = new JTextField(20); private JTextArea _description = new JTextArea(3, 20); diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ReplicaGroups.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ReplicaGroups.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ReplicaGroups.java 2005-10-14 02:59:08.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ReplicaGroups.java 2006-04-20 09:55:41.000000000 +0800 @@ -54,7 +54,7 @@ { _popup = new PopupMenu(_model); JMenuItem item = new JMenuItem(_model.getActions()[NEW_REPLICA_GROUP]); - item.setText("New replica group"); + item.setText("新复制组"); _popup.add(item); } return _popup; @@ -85,7 +85,7 @@ ReplicaGroups(java.util.List descriptors, Model model) throws UpdateFailedException { - super(false, "Replica Groups", model); + super(false, "复制组", model); _descriptors = descriptors; java.util.Iterator p = _descriptors.iterator(); diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Root.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Root.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Root.java 2005-10-21 23:16:06.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Root.java 2006-04-20 09:59:43.000000000 +0800 @@ -76,7 +76,7 @@ public Root(Model model) { - super("Applications", model, true); + super("应用", model, true); } public void init(java.util.List descriptors) @@ -97,7 +97,7 @@ // // Bug in the IceGrid registry // - System.err.println("Failed to create application " + System.err.println("创建应用失败 " + descriptor.name + ": " + e.toString()); assert false; @@ -129,7 +129,7 @@ // // Bug in the IceGrid registry // - System.err.println("Failed to create application " + System.err.println("创建应用失败 " + desc.name + ": " + e.toString()); assert false; @@ -155,7 +155,7 @@ // // Bug in the IceGrid registry // - System.err.println("Failed to update application " + System.err.println("更新应用失败 " + desc.name + ": " + e.toString()); assert false; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServerInstanceEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerInstanceEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServerInstanceEditor.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerInstanceEditor.java 2006-04-20 09:11:36.000000000 +0800 @@ -52,7 +52,7 @@ super(model); _subEditor = new ServerSubEditor(this, parentFrame); - _template.setToolTipText("Server template"); + _template.setToolTipText("服务器模板"); _parameterValues.setEditable(false); // @@ -71,15 +71,15 @@ } }; gotoTemplate.putValue(Action.SHORT_DESCRIPTION, - "Goto this server template"); + "前往该服务器模板"); _templateButton = new JButton(gotoTemplate); // // Parameter values // _parametersDialog = new ParametersDialog(parentFrame, - "Parameter values", - "Value", false, "Use default"); + "参数值", + "值", false, "默认值"); Action openParametersDialog = new AbstractAction("...") { @@ -98,7 +98,7 @@ } }; openParametersDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit parameters"); + "参数编辑"); _parametersButton = new JButton(openParametersDialog); } @@ -127,11 +127,11 @@ void appendProperties(DefaultFormBuilder builder) { - builder.append("Template", _template); + builder.append("模板", _template); builder.append(_templateButton); builder.nextLine(); - builder.append("Parameter values", _parameterValues); + builder.append("参数值", _parameterValues); builder.append(_parametersButton); builder.nextLine(); diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Server.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Server.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Server.java 2005-11-09 04:49:36.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Server.java 2006-04-20 09:46:52.000000000 +0800 @@ -210,15 +210,15 @@ _popup = new PopupMenu(_model); JMenuItem item = new JMenuItem(_model.getActions()[NEW_ADAPTER]); - item.setText("New adapter"); + item.setText("新适配器"); _popup.add(item); item = new JMenuItem(_model.getActions()[NEW_DBENV]); - item.setText("New DbEnv"); + item.setText("新数据库环境"); _popup.add(item); item = new JMenuItem(_model.getActions()[NEW_SERVICE]); - item.setText("New service"); + item.setText("新服务"); _popup.add(item); _popup.addSeparator(); @@ -263,7 +263,7 @@ public void start() { - final String prefix = "Starting server '" + _id + "'..."; + final String prefix = "正在启动服务器 '" + _id + "'..."; _model.getStatusBar().setText(prefix); AMI_Admin_startServer cb = new AMI_Admin_startServer() @@ -278,12 +278,12 @@ public void ice_exception(Ice.UserException e) { - amiFailure(prefix, "Failed to start " + _id, e); + amiFailure(prefix, "启动失败 " + _id, e); } public void ice_exception(Ice.LocalException e) { - amiFailure(prefix, "Failed to start " + _id, e.toString()); + amiFailure(prefix, "启动失败 " + _id, e.toString()); } }; @@ -295,7 +295,7 @@ } catch(Ice.LocalException e) { - failure(prefix, "Failed to start " + _id, e.toString()); + failure(prefix, "启动失败 " + _id, e.toString()); } finally { @@ -311,7 +311,7 @@ public void stop() { - final String prefix = "Stopping server '" + _id + "'..."; + final String prefix = "停止服务器 '" + _id + "'..."; _model.getStatusBar().setText(prefix); AMI_Admin_stopServer cb = new AMI_Admin_stopServer() @@ -326,12 +326,12 @@ public void ice_exception(Ice.UserException e) { - amiFailure(prefix, "Failed to stop " + _id, e); + amiFailure(prefix, "停止失败 " + _id, e); } public void ice_exception(Ice.LocalException e) { - amiFailure(prefix, "Failed to stop " + _id, e.toString()); + amiFailure(prefix, "停止失败 " + _id, e.toString()); } }; @@ -343,7 +343,7 @@ } catch(Ice.LocalException e) { - failure(prefix, "Failed to stop " + _id, e.toString()); + failure(prefix, "停止失败 " + _id, e.toString()); } finally { @@ -370,10 +370,8 @@ { int shutdown = JOptionPane.showConfirmDialog( _model.getMainFrame(), - "You are about to install or refresh your" - + " server distribution and your application distribution onto this node.\n" - + " Do you want shut down all servers affected by this update?", - "Patch Confirmation", + "即将安装或更新此节点上你的应用和服务器分布信息,要关闭所有受此影响的服务器吗?\n" + ,"更新确认", JOptionPane.YES_NO_CANCEL_OPTION); if(shutdown == JOptionPane.CANCEL_OPTION) @@ -386,7 +384,7 @@ return; } - final String prefix = "Patching server '" + _id + "'..."; + final String prefix = "正在更新服务器 '" + _id + "'..."; _model.getStatusBar().setText(prefix); AMI_Admin_patchServer cb = new AMI_Admin_patchServer() @@ -401,12 +399,12 @@ public void ice_exception(Ice.UserException e) { - amiFailure(prefix, "Failed to patch " + _id, e); + amiFailure(prefix, _id + "更新失败", e); } public void ice_exception(Ice.LocalException e) { - amiFailure(prefix, "Failed to patch " + _id, e.toString()); + amiFailure(prefix, _id + "更新失败", e.toString()); } }; @@ -419,7 +417,7 @@ } catch(Ice.LocalException e) { - failure(prefix, "Failed to patch " + _id, e.toString()); + failure(prefix, _id +"更新失败", e.toString()); } finally { @@ -436,9 +434,9 @@ private void enableServer(boolean enable) { final String prefix = (enable ? - "Enabling" : "Disabling") + " server '" + _id + "'..."; + "启用" : "禁用") + " 服务器: '" + _id + "'..."; - final String action = enable ? "enable" : "disable"; + final String action = enable ? "启用" : "禁用"; _model.getStatusBar().setText(prefix); @@ -454,12 +452,12 @@ public void ice_exception(Ice.UserException e) { - amiFailure(prefix, "Failed to " + action + " " + _id, e); + amiFailure(prefix, "任务失败: " + action + " " + _id, e); } public void ice_exception(Ice.LocalException e) { - amiFailure(prefix, "Failed to " + action + " " + _id, e.toString()); + amiFailure(prefix, "任务失败 " + action + " " + _id, e.toString()); } }; @@ -471,7 +469,7 @@ } catch(Ice.LocalException e) { - failure(prefix, "Failed to " + action + " " + _id, e.toString()); + failure(prefix, "任务失败 " + action + " " + _id, e.toString()); } finally { @@ -933,11 +931,11 @@ static private String toolTip(ServerState state, int pid, boolean enabled) { - String result = (state == null ? "Unknown" : state.toString()); + String result = (state == null ? "未知" : state.toString()); if(!enabled) { - result += ", disabled"; + result += ", 禁用"; } if(pid != 0) diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServerSubEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerSubEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServerSubEditor.java 2005-11-09 04:49:36.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerSubEditor.java 2006-04-20 09:51:11.000000000 +0800 @@ -36,11 +36,11 @@ _id.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); - _id.setToolTipText("Must be unique within this IceGrid deployment"); + _id.setToolTipText("在IceGrid部署中必须保持唯一"); _exe.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); - _exe.setToolTipText("Path to this server's executable, e.g.:
" + _exe.setToolTipText("服务器的可执行路径,如:
" + "icebox
" + "java
" + "myHelloServer
" @@ -49,16 +49,15 @@ _pwd.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); _pwd.setToolTipText( - "If not set, the server will start in " + "如果未设置,服务器将在下列路径启动: " + "node data dir/servers/server-id;
" - + "relative directories are relative to the current directory" - + " of the icegridnode process."); + + "相对目录指相对于icegridnode进程的当前目录"); _options.setEditable(false); _envs.setEditable(false); _activation = new JComboBox(new Object[]{ON_DEMAND, MANUAL}); - _activation.setToolTipText("Select 'on-demand' to have IceGrid start your server on-demand"); + _activation.setToolTipText("选择`自动`使得IceGrid按需自动启动你的服务器"); JTextField activationTextField = (JTextField) _activation.getEditor().getEditorComponent(); @@ -67,18 +66,18 @@ _activationTimeout.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); - _activationTimeout.setToolTipText("Number of seconds; if not set or set to 0, " - + "the IceGrid Node
uses the value of its " - + "IceGrid.Node.WaitTime property"); + _activationTimeout.setToolTipText( + "秒数; 如果未设置,值为0, " + + "IceGrid节点使用
" + + "IceGrid.Node.WaitTime属性的定义"); _deactivationTimeout.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); - _deactivationTimeout.setToolTipText("Number of seconds; if not set or set to 0, " - + "the IceGrid Node
uses the value of its " - + "IceGrid.Node.WaitTime property"); - + _deactivationTimeout.setToolTipText("秒数; 如果未设置,值为0, " + + "IceGrid节点使用
" + + "IceGrid.Node.WaitTime属性的定义"); - _envDialog = new TableDialog(parentFrame, "Environment Variables", - "Name", "Value", true); + _envDialog = new TableDialog(parentFrame, "环境变量", + "名字", "值", true); Action openEnvDialog = new AbstractAction("...") { public void actionPerformed(ActionEvent e) @@ -94,11 +93,11 @@ } }; openEnvDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit environment variables"); + "编辑环境变量"); _envButton = new JButton(openEnvDialog); _optionDialog = new ListDialog(parentFrame, - "Command Arguments", false); + "命令行参数", false); Action openOptionDialog = new AbstractAction("...") { public void actionPerformed(ActionEvent e) @@ -114,11 +113,11 @@ } }; openOptionDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit command-line arguments"); + "编辑命令行参数"); _optionButton = new JButton(openOptionDialog); - Action appDistrib = new AbstractAction("Depends on the application distribution") + Action appDistrib = new AbstractAction("依赖应用的分布设置") { public void actionPerformed(ActionEvent e) { @@ -126,14 +125,13 @@ } }; appDistrib.putValue(Action.SHORT_DESCRIPTION, - "Check this box if this server needs to be restarted
" - + "each time the distribution for your application is refreshed."); + "当应用更新时此服务器需要重新启动请选定此项"); _applicationDistrib = new JCheckBox(appDistrib); _distrib = new JComboBox(new Object[]{NO_DISTRIB, DEFAULT_DISTRIB}); _distrib.setToolTipText( - "The proxy to the IcePatch2 server holding your files"); + "IcePatch2服务器的代理持有你的文件"); JTextField distribTextField = (JTextField) _distrib.getEditor().getEditorComponent(); @@ -142,7 +140,7 @@ _distribDirs.setEditable(false); _distribDirsDialog = new ListDialog(parentFrame, - "Directories", true); + "目录", true); Action openDistribDirsDialog = new AbstractAction("...") { @@ -159,7 +157,7 @@ } }; openDistribDirsDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit directory list"); + "编辑目录列表"); _distribDirsButton = new JButton(openDistribDirsDialog); } @@ -181,38 +179,38 @@ super.appendProperties(builder); - builder.appendSeparator("Activation"); - builder.append("Path to Executable"); + builder.appendSeparator("激活"); + builder.append("执行路径"); builder.append(_exe, 3); builder.nextLine(); - builder.append("Working Directory"); + builder.append("工作目录"); builder.append(_pwd, 3); builder.nextLine(); - builder.append("Command Arguments"); + builder.append("命令行参数"); builder.append(_options, _optionButton); builder.nextLine(); - builder.append("Environment Variables"); + builder.append("环境变量"); builder.append(_envs, _envButton); builder.nextLine(); - builder.append("Activation Mode"); + builder.append("激活模式"); builder.append(_activation, 3); builder.nextLine(); - builder.append("Activation Timeout"); + builder.append("激活超时"); builder.append(_activationTimeout, 3); builder.nextLine(); - builder.append("Deactivation Timeout"); + builder.append("停止超时"); builder.append(_deactivationTimeout, 3); builder.nextLine(); - JComponent c = builder.appendSeparator("Distribution"); - c.setToolTipText("Files specific to this server"); + JComponent c = builder.appendSeparator("分布"); + c.setToolTipText("于此服务器相关的文件"); builder.append("", _applicationDistrib); builder.nextLine(); - builder.append("IcePatch2 Proxy"); + builder.append("IcePatch2代理"); builder.append(_distrib, 3); builder.nextLine(); - builder.append("Directories"); + builder.append("目录"); builder.append(_distribDirs, _distribDirsButton); builder.nextLine(); } @@ -417,7 +415,7 @@ Utils.stringify(_distribDirsList, stringifier, ", ", toolTipHolder)); - String toolTip = "Include only these directories"; + String toolTip = "只包含这些目录"; if(toolTipHolder.value != null) { @@ -433,11 +431,11 @@ { public String toString() { - return "None selected"; + return "未选择"; } }; - static private final String DEFAULT_DISTRIB = "${application}.IcePatch2/server"; + static private final String DEFAULT_DISTRIB = "${application.IcePatch2/server"; private JTextField _id = new JTextField(20); private JTextField _exe = new JTextField(20); diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServerTemplate.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerTemplate.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServerTemplate.java 2005-11-12 07:43:53.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerTemplate.java 2006-04-20 09:35:19.000000000 +0800 @@ -147,19 +147,19 @@ _popup = new PopupMenu(_model); JMenuItem item = new JMenuItem(_model.getActions()[NEW_ADAPTER]); - item.setText("New adapter"); + item.setText("新适配器"); _popup.add(item); item = new JMenuItem(_model.getActions()[NEW_DBENV]); - item.setText("New DbEnv"); + item.setText("新数据库环境"); _popup.add(item); item = new JMenuItem(_model.getActions()[NEW_SERVICE]); - item.setText("New service"); + item.setText("新服务"); _popup.add(item); item = new JMenuItem(_model.getActions()[NEW_SERVICE_FROM_TEMPLATE]); - item.setText("New service from template"); + item.setText("基于模板的新服务"); _popup.add(item); } return _popup; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServerTemplates.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerTemplates.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServerTemplates.java 2005-11-09 03:51:53.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServerTemplates.java 2006-04-20 09:57:51.000000000 +0800 @@ -57,11 +57,11 @@ { _popup = new PopupMenu(_model); JMenuItem newServerItem = new JMenuItem(_model.getActions()[NEW_TEMPLATE_SERVER]); - newServerItem.setText("New server template"); + newServerItem.setText("新服务器模板"); _popup.add(newServerItem); JMenuItem newIceBoxItem = new JMenuItem(_model.getActions()[NEW_TEMPLATE_SERVER_ICEBOX]); - newIceBoxItem.setText("New IceBox server template"); + newIceBoxItem.setText("新IceBox服务器模板"); _popup.add(newIceBoxItem); } return _popup; @@ -92,7 +92,7 @@ ServerTemplates(java.util.Map descriptors, Application application) throws UpdateFailedException { - super("Server templates", application.getModel()); + super("服务器模板", application.getModel()); _descriptors = descriptors; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServiceInstanceEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceInstanceEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServiceInstanceEditor.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceInstanceEditor.java 2006-04-20 09:37:25.000000000 +0800 @@ -53,15 +53,15 @@ } }; gotoTemplate.putValue(Action.SHORT_DESCRIPTION, - "Goto this service template"); + "前往此服务模板"); _templateButton = new JButton(gotoTemplate); // // Parameter values // _parametersDialog = new ParametersDialog(parentFrame, - "Parameter values", - "Value", false, "Use default"); + "参数值", + "值", false, "默认值"); Action openParametersDialog = new AbstractAction("...") { @@ -80,7 +80,7 @@ } }; openParametersDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit parameter values"); + "编辑参数值"); _parametersButton = new JButton(openParametersDialog); } @@ -119,11 +119,11 @@ void appendProperties(DefaultFormBuilder builder) { - builder.append("Template", _template); + builder.append("模板", _template); builder.append(_templateButton); builder.nextLine(); - builder.append("Parameter values", _parameterValues); + builder.append("参数值", _parameterValues); builder.append(_parametersButton); builder.nextLine(); diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Service.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Service.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Service.java 2005-10-27 07:28:50.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Service.java 2006-04-20 09:37:58.000000000 +0800 @@ -117,11 +117,11 @@ { _popup = new PopupMenu(_model); JMenuItem item = new JMenuItem(_model.getActions()[NEW_ADAPTER]); - item.setText("New adapter"); + item.setText("新适配器"); _popup.add(item); item = new JMenuItem(_model.getActions()[NEW_DBENV]); - item.setText("New DbEnv"); + item.setText("新数据库环境"); _popup.add(item); _popup.addSeparator(); diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/Services.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/Services.java --- IceJ-3.0.0/src/IceGrid/TreeNode/Services.java 2005-10-13 02:10:42.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/Services.java 2006-04-20 09:56:57.000000000 +0800 @@ -58,11 +58,11 @@ { _popup = new PopupMenu(_model); JMenuItem newServiceItem = new JMenuItem(_model.getActions()[NEW_SERVICE]); - newServiceItem.setText("New service"); + newServiceItem.setText("新服务"); _popup.add(newServiceItem); JMenuItem newServiceFromTemplateItem = new JMenuItem(_model.getActions()[NEW_SERVICE_FROM_TEMPLATE]); - newServiceFromTemplateItem.setText("New service from template"); + newServiceFromTemplateItem.setText("基于模板的新服务"); _popup.add(newServiceFromTemplateItem); } return _popup; @@ -173,7 +173,7 @@ Application application) throws UpdateFailedException { - super("Services", application.getModel()); + super("服务", application.getModel()); _descriptors = descriptors; _isEditable = isEditable; _resolver = resolver; @@ -223,8 +223,8 @@ { JOptionPane.showMessageDialog( _model.getMainFrame(), - "You need to create a service template before you can create a service from a template.", - "No Service Template", + "创建基于模板的服务前需要先检录服务模板.", + "没有服务模板", JOptionPane.INFORMATION_MESSAGE); return; } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServiceSubEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceSubEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServiceSubEditor.java 2005-11-03 12:34:56.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceSubEditor.java 2006-04-20 09:42:10.000000000 +0800 @@ -29,15 +29,15 @@ _name.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); - _name.setToolTipText("Identifies this service within an IceBox server"); + _name.setToolTipText("在IceBox服务器中标识此服务"); _entry.getDocument().addDocumentListener( _mainEditor.getUpdateListener()); _entry.setToolTipText( - "The service entry point and optional arguments.
" - + "C++: shared object:function-name arg1 arg2 ...
" - + "Java: class-name arg1 arg2 ...
" - + "C#, Visual Basic: assembly:class-name arg1 arg2 ..." + "服务入口点是可选参数.
" + + "C++: 共享库对象:函数名 参数1 参数2...
" + + "Java: 类名 参数1 参数2 ...
" + + "C#, Visual Basic: 汇编对象:类名 参数1 参数2 ..." + ""); } @@ -49,7 +49,7 @@ void appendProperties(DefaultFormBuilder builder) { - builder.append("Service Name"); + builder.append("服务名"); builder.append(_name, 3); builder.nextLine(); @@ -58,7 +58,7 @@ // super.appendProperties(builder); - builder.append("Entry Point"); + builder.append("入口点"); builder.append(_entry, 3); builder.nextLine(); } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServiceTemplate.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceTemplate.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServiceTemplate.java 2005-10-27 07:28:50.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceTemplate.java 2006-04-20 09:42:43.000000000 +0800 @@ -99,11 +99,11 @@ { _popup = new PopupMenu(_model); JMenuItem item = new JMenuItem(_model.getActions()[NEW_ADAPTER]); - item.setText("New adapter"); + item.setText("新适配器"); _popup.add(item); item = new JMenuItem(_model.getActions()[NEW_DBENV]); - item.setText("New DbEnv"); + item.setText("新数据库环境"); _popup.add(item); } return _popup; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/ServiceTemplates.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceTemplates.java --- IceJ-3.0.0/src/IceGrid/TreeNode/ServiceTemplates.java 2005-10-13 02:10:42.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/ServiceTemplates.java 2006-04-20 09:58:06.000000000 +0800 @@ -60,7 +60,7 @@ { _popup = new PopupMenu(_model); JMenuItem item = new JMenuItem(_model.getActions()[NEW_TEMPLATE_SERVICE]); - item.setText("New service template"); + item.setText("新服务模板"); _popup.add(item); } return _popup; @@ -90,7 +90,7 @@ ServiceTemplates(java.util.Map descriptors, Model model) throws UpdateFailedException { - super("Service templates", model); + super("服务模板", model); _descriptors = descriptors; diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/TemplateEditor.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/TemplateEditor.java --- IceJ-3.0.0/src/IceGrid/TreeNode/TemplateEditor.java 2005-11-15 00:24:11.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/TemplateEditor.java 2006-04-20 09:45:03.000000000 +0800 @@ -30,15 +30,15 @@ { super(false, true); _template.getDocument().addDocumentListener(_updateListener); - _template.setToolTipText("Must be unique within the enclosing application"); + _template.setToolTipText("在所包含的应用里必须唯一"); _parameters.setEditable(false); // // Parameters // _parametersDialog = new ParametersDialog(parentFrame, - "Parameters", - "Default value", true, "No default"); + "参数", + "默认值", true, "无默认值"); Action openParametersDialog = new AbstractAction("...") { @@ -57,7 +57,7 @@ } }; openParametersDialog.putValue(Action.SHORT_DESCRIPTION, - "Edit parameters"); + "编辑参数"); _parametersButton = new JButton(openParametersDialog); } @@ -87,11 +87,11 @@ void appendProperties(DefaultFormBuilder builder) { - builder.append("Template ID"); + builder.append("模板ID"); builder.append(_template, 3); builder.nextLine(); - builder.append("Parameters", _parameters); + builder.append("参数", _parameters); builder.append(_parametersButton); builder.nextLine(); } diff -Nur IceJ-3.0.0/src/IceGrid/TreeNode/UpdateFailedException.java IceJ-3.0.0-CN/src/IceGrid/TreeNode/UpdateFailedException.java --- IceJ-3.0.0/src/IceGrid/TreeNode/UpdateFailedException.java 2005-10-07 01:34:18.000000000 +0800 +++ IceJ-3.0.0-CN/src/IceGrid/TreeNode/UpdateFailedException.java 2006-04-20 09:45:33.000000000 +0800 @@ -76,7 +76,7 @@ { _message = "???"; } - _message += " cannot have two children named " + _duplicateName; + _message += " 名字重复 " + _duplicateName; } return _message; }