Skip to content

Commit

Permalink
add SMSLogPanel Chinese translation
Browse files Browse the repository at this point in the history
  • Loading branch information
wszf committed Aug 10, 2014
1 parent 4e05104 commit 4c1e4cc
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 15 deletions.
28 changes: 15 additions & 13 deletions src/AndroratServer/src/gui/panel/SMSLogPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,10 @@
import javax.swing.text.MaskFormatter;

import Packet.SMSPacket;
import java.util.ResourceBundle;

public class SMSLogPanel extends JPanel {
private static final ResourceBundle BUNDLE = ResourceBundle.getBundle("gui.panel.messages"); //$NON-NLS-1$

public static Color IN_SMS = new Color(14,92,7);
public static Color OUT_SMS = Color.blue;
Expand All @@ -51,12 +53,12 @@ public class SMSLogPanel extends JPanel {
public SMSLogPanel(UserGUI gui) {
this.gui = gui;

JLabel lblTypes = new JLabel("Types :");
JLabel lblTypes = new JLabel(BUNDLE.getString("Types;")); //$NON-NLS-1$

JLabel lblIncoming = new JLabel("received SMS");
JLabel lblIncoming = new JLabel(BUNDLE.getString("received-SMS")); //$NON-NLS-1$
lblIncoming.setForeground(IN_SMS);

JLabel lblSent = new JLabel("sent SMS");
JLabel lblSent = new JLabel(BUNDLE.getString("sent-SMS")); //$NON-NLS-1$
lblSent.setForeground(OUT_SMS);

JSplitPane splitPane = new JSplitPane();
Expand Down Expand Up @@ -98,39 +100,39 @@ public SMSLogPanel(UserGUI gui) {

JPanel panel = new JPanel();
splitPane.setRightComponent(panel);
panel.setBorder(new TitledBorder(UIManager.getBorder("TitledBorder.border"), "Optionnal filters", TitledBorder.LEADING, TitledBorder.TOP, null, null));
panel.setBorder(new TitledBorder(UIManager.getBorder("TitledBorder.border"), BUNDLE.getString("sms-filters"), TitledBorder.LEADING, TitledBorder.TOP, null, null));

JLabel lblTypeOfCall = new JLabel("Source SMS :");
JLabel lblTypeOfCall = new JLabel(BUNDLE.getString("Source-SMS")); //$NON-NLS-1$

sourceBox = new JComboBox();
sourceBox.setModel(new DefaultComboBoxModel(new String[] {"All", "Received", "Sent"}));
sourceBox.setModel(new DefaultComboBoxModel(new String[] {BUNDLE.getString("All-sms"), BUNDLE.getString("received-SMS"), BUNDLE.getString("sent-SMS")}));

JLabel lblPhoneNumber = new JLabel("Phone number :");
JLabel lblPhoneNumber = new JLabel(BUNDLE.getString("Phone-number")); //$NON-NLS-1$

phoneNumberField = new JTextField();
phoneNumberField.setColumns(10);

JLabel lblMinDate = new JLabel("Not before (dd/mm/yyyy) :");
JLabel lblMinDate = new JLabel(BUNDLE.getString("Not-before")); //$NON-NLS-1$

formattedMinDate = new JFormattedTextField(createFormatter("**/**/****"));

JLabel lblNotAfter = new JLabel("Not after");
JLabel lblNotAfter = new JLabel(BUNDLE.getString("Not-after")); //$NON-NLS-1$

formattedMaxDate = new JFormattedTextField(createFormatter("**/**/****"));

JButton btnGetSMSLogs = new JButton("Get SMS");
JButton btnGetSMSLogs = new JButton(BUNDLE.getString("Get-SMS")); //$NON-NLS-1$
btnGetSMSLogs.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
fireGetSMS();
}
});

JLabel lblTypeOfSms = new JLabel("Type of SMS :");
JLabel lblTypeOfSms = new JLabel(BUNDLE.getString("Type-of-SMS")); //$NON-NLS-1$

typeBox = new JComboBox();
typeBox.setModel(new DefaultComboBoxModel(new String[] {"All", "Unread", "Read"}));
typeBox.setModel(new DefaultComboBoxModel(new String[] {BUNDLE.getString("All"), BUNDLE.getString("Unread"),BUNDLE.getString("Read")}));

JLabel lblBodyKeyword = new JLabel("Body keyword :");
JLabel lblBodyKeyword = new JLabel(BUNDLE.getString("Body-keyword")); //$NON-NLS-1$

JScrollPane scrollPane_1 = new JScrollPane();
GroupLayout gl_panel = new GroupLayout(panel);
Expand Down
17 changes: 16 additions & 1 deletion src/AndroratServer/src/gui/panel/messages.properties
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,19 @@ Signed=Signed :
Microphone=Microphone
Voice-call=Voice call (up & down)
Up-voice-call=Up voice call
Down-voice-call=Down voice call
Down-voice-call=Down voice call
#smsPanel
received-SMS=received SMS
sent-SMS=sent SMS
Source-SMS=Source SMS :
Phone-number=Phone number :
All-sms=All SMS
Not-before=Not before (dd/mm/yyyy) :
Not-after=Not after
Type-of-SMS=Type of SMS :
All=All
Unread=Unread
Read=Read
Body-keyword=Body keyword :
Get-SMS=Get SMS
sms-filters=Optionnal filters
17 changes: 16 additions & 1 deletion src/AndroratServer/src/gui/panel/messages_zh.properties
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,19 @@ Signed=\u7B7E\u540D:
Microphone=\u9EA6\u514B\u98CE
Voice-call=\u8BED\u97F3\u901A\u8BDD(\u547C\u51FA&\u547C\u5165)
Up-voice-call=\u8BED\u97F3\u7535\u8BDD(\u547C\u51FA)
Down-voice-call=\u8BED\u97F3\u7535\u8BDD(\u547C\u5165)
Down-voice-call=\u8BED\u97F3\u7535\u8BDD(\u547C\u5165)
#SmsPanel
received-SMS=\u63A5\u6536
Phone-number=\u7535\u8BDD\u53F7\u7801:
sent-SMS=\u53D1\u9001
Source-SMS=\u77ED\u4FE1\u6765\u6E90:
All-sms=\u5168\u90E8\u77ED\u4FE1
Not-before=\u4E4B\u540E (dd/mm/yyyy) :
Not-after=\u4E4B\u524D
Type-of-SMS=\u77ED\u4FE1\u7C7B\u578B:
All=\u5168\u90E8
Unread=\u672A\u8BFB
Read=\u5DF2\u8BFB
Body-keyword=\u5185\u5BB9\u5173\u952E\u5B57:
Get-SMS=\u83B7\u53D6\u77ED\u4FE1
sms-filters=\u8FC7\u6EE4\u9009\u9879

0 comments on commit 4c1e4cc

Please sign in to comment.