Android mobile guard-SET Password dialog box, android SET Password

Source: Internet
Author: User

Android mobile guard-SET Password dialog box, android SET Password

This article implements the First password verification process, first to achieve the following results

For more information, see http://www.cnblogs.com/wuyudong/p/5939823.html.

The layout is as follows:

<? 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 = "match_parent" android: orientation = "vertical"> <TextView style = "@ style/TitleStyle" android: background = "# f00" android: text = "set password"/> <EditText android: id = "@ + id/et_set_psd" android: layout_width = "match_parent" android: layout_height = "wrap_content" android: hint = "set password"/> <EditText android: id = "@ + id/et_confirm_psd" android: layout_width = "match_parent" android: layout_height = "wrap_content" android: hint = "Confirm Password"/> <LinearLayout android: layout_width = "match_parent" android: layout_height = "wrap_content"> <Button android: id = "@ + id/bt_submit" android: layout_width = "0dp" android: layout_height = "wrap_content" android: layout_weight = "1" android: text = "OK"/> <Button android: id = "@ + id/bt_cancel" android: layout_width = "0dp" android: layout_height = "wrap_content" android: layout_weight = "1" android: text = "cancel"/> </LinearLayout>

The TitleStyle code is as follows:

<Resources> <! -- Base application theme, dependent on API level. this theme is replaced by AppBaseTheme from res/values-vXX/styles. xml on newer devices. --> <style name = "AppBaseTheme" parent = "android: Theme. light "> <! -- Theme customizations available in newer API levels can go in res/values-vXX/styles. xml, while customizations related to backward-compatibility can go here. --> </style> <! -- Application theme. --> <style name = "AppTheme" parent = "AppBaseTheme"> <! -- Keep the style topic of a later version while removing the header --> <! -- All mizmizations that are NOT specific to a special API-level can go here. --> <item name = "android: windowNoTitle"> true </item> </style> <style name = "TitleStyle"> <item name = "android: gravity "> center </item> <item name =" android: textSize "> 20sp </item> <item name =" android: textColor "> #000 </item> <item name =" android: padding "> 10dp </item> <item name =" android: background "> #0f0 </item> <item name =" android: layout_width "> match_parent </item> <item name =" android: layout_height "> wrap_content </item> </style> </resources>

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.