account_setup.xml 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!--
  3. ownCloud Android client application
  4. Copyright (C) 2012 Bartek Przybylski
  5. Copyright (C) 2015 ownCloud Inc.
  6. This program is free software: you can redistribute it and/or modify
  7. it under the terms of the GNU General Public License version 2,
  8. as published by the Free Software Foundation.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. -->
  16. <ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
  17. android:layout_width="match_parent"
  18. android:layout_height="match_parent"
  19. android:layout_gravity="center"
  20. android:fillViewport="true"
  21. android:orientation="vertical"
  22. android:id="@+id/scroll"
  23. >
  24. <LinearLayout
  25. android:layout_width="match_parent"
  26. android:layout_height="wrap_content"
  27. android:background="@color/login_background_color"
  28. android:gravity="center"
  29. android:orientation="vertical"
  30. android:padding="8dp" >
  31. <ImageView
  32. android:id="@+id/thumbnail"
  33. android:layout_width="match_parent"
  34. android:layout_height="wrap_content"
  35. android:layout_marginBottom="10dp"
  36. android:layout_marginTop="10dp"
  37. android:background="@color/login_logo_background_color"
  38. android:src="@drawable/logo"
  39. android:contentDescription="@string/app_name"/>
  40. <Button
  41. android:id="@+id/centeredRefreshButton"
  42. android:layout_width="wrap_content"
  43. android:layout_height="wrap_content"
  44. android:layout_gravity="center_horizontal"
  45. android:layout_marginBottom="10dp"
  46. android:onClick="onRefreshClick"
  47. android:text="@string/auth_check_server"
  48. android:visibility="gone"
  49. android:contentDescription="@string/auth_check_server"/>
  50. <TextView
  51. android:id="@+id/instructions_message"
  52. android:layout_width="wrap_content"
  53. android:layout_height="wrap_content"
  54. android:layout_gravity="fill_horizontal"
  55. android:text="@string/auth_expired_basic_auth_toast"
  56. android:visibility="gone"
  57. android:layout_marginBottom="10dp"
  58. android:contentDescription="@string/auth_expired_basic_auth_toast"/>
  59. <FrameLayout
  60. android:id="@+id/hostUrlFrame"
  61. android:layout_width="match_parent"
  62. android:layout_height="wrap_content"
  63. android:layout_marginBottom="10dp"
  64. >
  65. <EditText
  66. android:id="@+id/hostUrlInput"
  67. android:layout_width="match_parent"
  68. android:layout_height="wrap_content"
  69. android:layout_gravity="bottom"
  70. android:hint="@string/auth_host_url"
  71. android:inputType="textUri"
  72. android:drawablePadding="5dp"
  73. android:paddingRight="55dp"
  74. android:contentDescription="@string/auth_host_address"
  75. android:textColor="@color/textColor">
  76. <requestFocus />
  77. </EditText>
  78. <ImageButton
  79. android:id="@+id/embeddedRefreshButton"
  80. android:layout_width="48dp"
  81. android:layout_height="48dp"
  82. android:layout_gravity="center_vertical|right"
  83. android:layout_marginRight="5dp"
  84. android:padding="0dp"
  85. android:scaleType="fitCenter"
  86. android:src="@drawable/ic_action_refresh_black"
  87. android:onClick="onRefreshClick"
  88. android:visibility="gone"
  89. android:background="@android:color/transparent"
  90. android:contentDescription="@string/auth_refresh_button"
  91. />
  92. </FrameLayout>
  93. <TextView
  94. android:id="@+id/server_status_text"
  95. android:layout_width="match_parent"
  96. android:layout_height="wrap_content"
  97. android:layout_marginBottom="10dp"
  98. android:drawableLeft="@android:drawable/stat_notify_sync"
  99. android:drawablePadding="5dp"
  100. android:gravity="center_vertical"
  101. android:text="@string/auth_testing_connection"
  102. android:contentDescription="@string/auth_testing_connection"/>
  103. <CheckBox
  104. android:id="@+id/oauth_onOff_check"
  105. android:layout_width="wrap_content"
  106. android:layout_height="wrap_content"
  107. android:checked="false"
  108. android:onClick="onCheckClick"
  109. android:text="@string/oauth_check_onoff"
  110. android:textAppearance="?android:attr/textAppearanceSmall"
  111. android:contentDescription="@string/oauth_check_onoff"
  112. />
  113. <EditText
  114. android:id="@+id/oAuthEntryPoint_1"
  115. android:layout_width="match_parent"
  116. android:layout_height="wrap_content"
  117. android:ems="10"
  118. android:enabled="false"
  119. android:text="@string/oauth2_url_endpoint_auth"
  120. android:singleLine="true"
  121. android:inputType="textUri"
  122. android:visibility="gone">
  123. </EditText>
  124. <EditText
  125. android:id="@+id/oAuthEntryPoint_2"
  126. android:layout_width="match_parent"
  127. android:layout_height="wrap_content"
  128. android:ems="10"
  129. android:enabled="false"
  130. android:text="@string/oauth2_url_endpoint_access"
  131. android:singleLine="true"
  132. android:inputType="textUri"
  133. android:visibility="gone"/>
  134. <EditText
  135. android:id="@+id/account_username"
  136. android:layout_width="match_parent"
  137. android:layout_height="wrap_content"
  138. android:ems="10"
  139. android:hint="@string/auth_username"
  140. android:inputType="textNoSuggestions"
  141. android:contentDescription="@string/auth_username"
  142. android:textColor="@color/textColor" />
  143. <EditText
  144. android:id="@+id/account_password"
  145. android:layout_width="match_parent"
  146. android:layout_height="wrap_content"
  147. android:drawablePadding="5dp"
  148. android:ems="10"
  149. android:hint="@string/auth_password"
  150. android:inputType="textPassword"
  151. android:contentDescription="@string/auth_password"
  152. android:textColor="@color/textColor" />
  153. <TextView
  154. android:id="@+id/auth_status_text"
  155. android:layout_width="match_parent"
  156. android:layout_height="wrap_content"
  157. android:layout_marginBottom="10dp"
  158. android:drawableLeft="@android:drawable/stat_notify_sync"
  159. android:drawablePadding="5dp"
  160. android:gravity="center_vertical"
  161. android:text="@string/auth_unauthorized"
  162. android:contentDescription="@string/auth_unauthorized"/>
  163. <Button
  164. android:id="@+id/buttonOK"
  165. android:layout_width="match_parent"
  166. android:layout_height="wrap_content"
  167. android:layout_gravity="center_horizontal"
  168. android:enabled="false"
  169. android:onClick="onOkClick"
  170. android:text="@string/setup_btn_connect"
  171. android:contentDescription="@string/setup_btn_connect"/>
  172. <Button
  173. android:id="@+id/welcome_link"
  174. android:layout_width="wrap_content"
  175. android:layout_height="wrap_content"
  176. android:background="@android:color/transparent"
  177. android:onClick="onRegisterClick"
  178. android:paddingBottom="5dp"
  179. android:paddingTop="5dp"
  180. android:text="@string/auth_register"
  181. android:textColor="#0000FF"
  182. android:contentDescription="@string/auth_register"/>
  183. </LinearLayout>
  184. </ScrollView>