activity_main.xml 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. xmlns:tools="http://schemas.android.com/tools"
  4. android:layout_width="match_parent"
  5. android:layout_height="match_parent"
  6. android:background="@android:color/white"
  7. android:orientation="vertical"
  8. tools:context=".MainActivity">
  9. <LinearLayout
  10. android:layout_width="match_parent"
  11. android:layout_height="wrap_content"
  12. android:layout_marginTop="100dp"
  13. android:orientation="vertical">
  14. <TextView
  15. android:layout_width="match_parent"
  16. android:layout_height="wrap_content"
  17. android:paddingTop="20dp"
  18. android:text="@string/label_server_ip"
  19. android:textAppearance="@android:style/TextAppearance" />
  20. <EditText
  21. android:id="@+id/editText_server_host"
  22. android:layout_width="wrap_content"
  23. android:layout_height="wrap_content"
  24. android:maxLength="15"
  25. android:ems="7"
  26. android:inputType="text"
  27. android:minHeight="48dp"
  28. tools:ignore="LabelFor,SpeakableTextPresentCheck"
  29. android:importantForAutofill="no" />
  30. <TextView
  31. android:layout_width="match_parent"
  32. android:layout_height="wrap_content"
  33. android:paddingTop="20dp"
  34. android:text="远程设备端端口:"
  35. android:textAppearance="@android:style/TextAppearance" />
  36. <EditText
  37. android:id="@+id/editText_server_port"
  38. android:layout_width="wrap_content"
  39. android:layout_height="wrap_content"
  40. android:maxLength="7"
  41. android:ems="7"
  42. android:inputType="text"
  43. android:minHeight="48dp"
  44. tools:ignore="LabelFor,SpeakableTextPresentCheck"
  45. android:importantForAutofill="no" />
  46. <TextView
  47. android:layout_width="match_parent"
  48. android:layout_height="wrap_content"
  49. android:layout_marginTop="20dp"
  50. android:text="@string/label_video_resolution"
  51. android:textAppearance="@android:style/TextAppearance" />
  52. <Spinner
  53. android:id="@+id/spinner_video_resolution"
  54. android:layout_width="match_parent"
  55. android:layout_height="wrap_content"
  56. android:entries="@array/options_resolution_keys"
  57. android:minHeight="48dp"
  58. tools:ignore="DuplicateSpeakableTextCheck" />
  59. <TextView
  60. android:layout_width="match_parent"
  61. android:layout_height="wrap_content"
  62. android:layout_marginTop="20dp"
  63. android:text="@string/label_video_bitrate"
  64. android:textAppearance="@android:style/TextAppearance" />
  65. <Spinner
  66. android:id="@+id/spinner_video_bitrate"
  67. android:layout_width="match_parent"
  68. android:layout_height="wrap_content"
  69. android:entries="@array/options_bitrate_keys"
  70. android:minHeight="48dp" />
  71. </LinearLayout>
  72. <LinearLayout
  73. android:layout_width="match_parent"
  74. android:layout_height="wrap_content"
  75. android:layout_marginTop="20dp"
  76. android:orientation="horizontal">
  77. <Switch
  78. android:id="@+id/switch0"
  79. android:layout_width="0dp"
  80. android:layout_height="48dp"
  81. android:layout_weight="1"
  82. android:text="@string/switch0"
  83. android:textSize="15sp" />
  84. </LinearLayout>
  85. <LinearLayout
  86. android:layout_width="match_parent"
  87. android:layout_height="wrap_content"
  88. android:layout_marginTop="20dp"
  89. android:orientation="horizontal">
  90. <Switch
  91. android:id="@+id/switch1"
  92. android:layout_width="0dp"
  93. android:layout_height="48dp"
  94. android:layout_weight="1"
  95. android:text="@string/switch1"
  96. android:textSize="15sp" />
  97. </LinearLayout>
  98. <LinearLayout
  99. android:layout_width="match_parent"
  100. android:layout_height="wrap_content"
  101. android:layout_marginTop="40dp"
  102. android:orientation="horizontal">
  103. <Button
  104. android:id="@+id/button_start"
  105. android:layout_width="0dp"
  106. android:layout_height="wrap_content"
  107. android:layout_weight="1"
  108. android:text="@string/action_start"
  109. android:textSize="30sp" />
  110. </LinearLayout>
  111. </LinearLayout>