Compare commits
No commits in common. 'master' and 'guoziyang_branch' have entirely different histories.
master
...
guoziyang_
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,43 @@
|
||||
package net.micode.notes.translation;
|
||||
|
||||
|
||||
public class TranslationResponse {
|
||||
private String error_code;
|
||||
private String error_msg;
|
||||
private String from;
|
||||
private String to;
|
||||
private TransResult[] trans_result;
|
||||
|
||||
public String getError_code() {
|
||||
return error_code;
|
||||
}
|
||||
|
||||
public String getError_msg() {
|
||||
return error_msg;
|
||||
}
|
||||
|
||||
public String getFrom() {
|
||||
return from;
|
||||
}
|
||||
|
||||
public String getTo() {
|
||||
return to;
|
||||
}
|
||||
|
||||
public TransResult[] getTrans_result() {
|
||||
return trans_result;
|
||||
}
|
||||
|
||||
public static class TransResult {
|
||||
private String src;
|
||||
private String dst;
|
||||
|
||||
public String getSrc() {
|
||||
return src;
|
||||
}
|
||||
|
||||
public String getDst() {
|
||||
return dst;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
</selector>
|
||||
@ -0,0 +1,30 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="源语言:"
|
||||
android:paddingBottom="8dp"/>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatSpinner
|
||||
android:id="@+id/spinner_from"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="16dp"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="目标语言:"
|
||||
android:paddingBottom="8dp"/>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatSpinner
|
||||
android:id="@+id/spinner_to"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"/>
|
||||
</LinearLayout>
|
||||
@ -0,0 +1,42 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="原文:"
|
||||
android:textStyle="bold"
|
||||
android:paddingBottom="4dp"/>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/original_text"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:minHeight="100dp"
|
||||
android:maxLines="5"
|
||||
android:scrollbars="vertical"
|
||||
android:editable="false"
|
||||
android:background="@android:color/transparent"
|
||||
android:paddingBottom="16dp"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="译文:"
|
||||
android:textStyle="bold"
|
||||
android:paddingBottom="4dp"/>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/translated_text"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:minHeight="100dp"
|
||||
android:maxLines="5"
|
||||
android:scrollbars="vertical"
|
||||
android:editable="false"
|
||||
android:background="@android:color/transparent"/>
|
||||
</LinearLayout>
|
||||
Loading…
Reference in new issue