account_setup.xml 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!--
  3. ownCloud Android client application
  4. Copyright (C) 2012 Bartek Przybylski
  5. Copyright (C) 2012-2013 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. <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  17. android:layout_width="match_parent"
  18. android:layout_height="match_parent"
  19. android:background="@color/login_background_color"
  20. android:padding="8dip"
  21. >
  22. <LinearLayout
  23. android:layout_width="match_parent"
  24. android:layout_height="wrap_content"
  25. android:layout_above="@+id/bottom_block"
  26. android:layout_alignParentTop="true"
  27. android:orientation="horizontal" >
  28. <ImageView
  29. android:id="@+id/imageView1"
  30. android:layout_width="0dp"
  31. android:layout_height="wrap_content"
  32. android:layout_weight="1"
  33. android:layout_gravity="center"
  34. android:background="@color/login_logo_background_color"
  35. android:src="@drawable/logo"
  36. />
  37. <ScrollView
  38. android:layout_width="0dp"
  39. android:layout_height="match_parent"
  40. android:layout_weight="1"
  41. android:id="@+id/scroll"
  42. android:fillViewport="true"
  43. android:orientation="vertical" >
  44. <LinearLayout
  45. android:id="@+id/LinearLayout1"
  46. android:layout_width="match_parent"
  47. android:layout_height="wrap_content"
  48. android:gravity="center"
  49. android:orientation="vertical"
  50. android:padding="8dp" >
  51. <Button
  52. android:id="@+id/centeredRefreshButton"
  53. android:layout_width="wrap_content"
  54. android:layout_height="wrap_content"
  55. android:layout_gravity="center_horizontal"
  56. android:layout_marginBottom="10dp"
  57. android:onClick="onRefreshClick"
  58. android:text="@string/auth_check_server"
  59. android:visibility="gone" />
  60. <TextView
  61. android:id="@+id/auth_message"
  62. android:layout_width="wrap_content"
  63. android:layout_height="wrap_content"
  64. android:layout_gravity="fill_horizontal"
  65. android:text="@string/auth_expired_basic_auth_toast"
  66. android:visibility="gone"
  67. android:layout_marginBottom="10dp"/>
  68. <FrameLayout
  69. android:id="@+id/hostUrlFrame"
  70. android:layout_width="match_parent"
  71. android:layout_height="wrap_content"
  72. android:layout_marginBottom="10dp"
  73. >
  74. <EditText
  75. android:id="@+id/hostUrlInput"
  76. android:layout_width="match_parent"
  77. android:layout_height="wrap_content"
  78. android:layout_gravity="bottom"
  79. android:hint="@string/auth_host_url"
  80. android:inputType="textUri"
  81. android:drawablePadding="5dp"
  82. android:paddingRight="55dp"
  83. >
  84. <requestFocus />
  85. </EditText>
  86. <ImageButton
  87. android:id="@+id/embeddedRefreshButton"
  88. android:layout_width="48dp"
  89. android:layout_height="48dp"
  90. android:layout_gravity="center_vertical|right"
  91. android:layout_marginRight="5dp"
  92. android:padding="0dp"
  93. android:scaleType="fitCenter"
  94. android:src="@drawable/ic_action_refresh_black"
  95. android:onClick="onRefreshClick"
  96. android:visibility="gone"
  97. android:background="@android:color/transparent"
  98. />
  99. </FrameLayout>
  100. <TextView
  101. android:id="@+id/server_status_text"
  102. android:layout_width="match_parent"
  103. android:layout_height="wrap_content"
  104. android:layout_marginBottom="10dp"
  105. android:drawableLeft="@android:drawable/stat_notify_sync"
  106. android:drawablePadding="5dp"
  107. android:gravity="center_vertical"
  108. android:text="@string/auth_testing_connection" />
  109. <CheckBox
  110. android:id="@+id/oauth_onOff_check"
  111. android:layout_width="wrap_content"
  112. android:layout_height="wrap_content"
  113. android:checked="false"
  114. android:onClick="onCheckClick"
  115. android:text="@string/oauth_check_onoff"
  116. android:textAppearance="?android:attr/textAppearanceSmall"
  117. />
  118. <EditText
  119. android:id="@+id/oAuthEntryPoint_1"
  120. android:layout_width="match_parent"
  121. android:layout_height="wrap_content"
  122. android:ems="10"
  123. android:enabled="false"
  124. android:text="@string/oauth2_url_endpoint_auth"
  125. android:singleLine="true"
  126. android:inputType="textUri"
  127. android:visibility="gone" >
  128. </EditText>
  129. <EditText
  130. android:id="@+id/oAuthEntryPoint_2"
  131. android:layout_width="match_parent"
  132. android:layout_height="wrap_content"
  133. android:ems="10"
  134. android:enabled="false"
  135. android:text="@string/oauth2_url_endpoint_access"
  136. android:singleLine="true"
  137. android:inputType="textUri"
  138. android:visibility="gone" >
  139. <requestFocus />
  140. </EditText>
  141. <EditText
  142. android:id="@+id/account_username"
  143. android:layout_width="match_parent"
  144. android:layout_height="wrap_content"
  145. android:ems="10"
  146. android:hint="@string/auth_username"
  147. android:inputType="textNoSuggestions" />
  148. <EditText
  149. android:id="@+id/account_password"
  150. android:layout_width="match_parent"
  151. android:layout_height="wrap_content"
  152. android:ems="10"
  153. android:hint="@string/auth_password"
  154. android:inputType="textPassword"
  155. android:drawablePadding="5dp"
  156. />
  157. <TextView
  158. android:id="@+id/auth_status_text"
  159. android:layout_width="match_parent"
  160. android:layout_height="wrap_content"
  161. android:gravity="center_vertical"
  162. android:text="@string/auth_unauthorized"
  163. android:drawableLeft="@android:drawable/stat_notify_sync"
  164. android:drawablePadding="5dip"
  165. />
  166. </LinearLayout>
  167. </ScrollView>
  168. </LinearLayout>
  169. <LinearLayout
  170. android:id="@id/bottom_block"
  171. android:layout_width="match_parent"
  172. android:layout_height="wrap_content"
  173. android:layout_alignParentBottom="true"
  174. android:orientation="vertical" >
  175. <Button
  176. android:id="@+id/buttonOK"
  177. android:layout_width="match_parent"
  178. android:layout_height="wrap_content"
  179. android:layout_gravity="center_horizontal"
  180. android:enabled="false"
  181. android:onClick="onOkClick"
  182. android:text="@string/setup_btn_connect" />
  183. <Button
  184. android:id="@+id/welcome_link"
  185. android:layout_width="wrap_content"
  186. android:layout_height="wrap_content"
  187. android:layout_gravity="center_horizontal"
  188. android:background="@android:color/transparent"
  189. android:onClick="onRegisterClick"
  190. android:paddingBottom="5dp"
  191. android:paddingTop="5dp"
  192. android:text="@string/auth_register"
  193. android:textColor="#0000FF"/>
  194. </LinearLayout>
  195. </RelativeLayout>