Starting today based on the basics of prior learning Android, combat it to achieve a simple feature of Android phone defenderThis article address: http://www.cnblogs.com/wuyudong/p/5899283.html, reprint please indicate source address.The main functions of mobile phone defender are as follows:The splash page of the mobile page is initially as follows:Splash LayoutThe corresponding code is in the layout file Activity_splash.xml file:Relativelayoutxmlns:
1, the bottom left corner of the desktop to find the Microsoft icon, click the Left button, will pop up the image below, and then select the "Control Panel" option;
2, the bottom left corner of the desktop to find the Microsoft icon, click the left mouse to the Metro interface, there is a "↓" icon, directly click;
The following two scenarios occur:
1, through the above 1 to enter, will appear the next figure, and then find "Windows
Recommended reading: An analysis of Android phone defender turn off automatic Updates
The custom composite control completed in the previous section is not flexible enough to display information about the control, and to customize its own properties, modeled on the system properties
The previous section combines control Settingitemview with three controls, which are textview headings, textview descriptions, checkbox check boxes
Custom Properties Ts
Win7 System 360 security defender will automatically download the installation bug patch in the background what to do? 360 security guards have the Trojan horse, clean up bad comment plug-ins, protect privacy and other functions, Ghost Win7 system installed a prerequisite software. Sometimes 360 guards will be idle in the background automatically download the installation bug patch, resulting in slow speed computer card situation, and the computer hit
of the selected contact, and finally get the data from the activity.①. Set up a Click event for select Contacts; ②. Connect two activity via Intent in the Click event Method (the wizard sets the third step, select the contact); ③. Startactivityforresult Intent, int Requestcode) method starts, the parameter intent is the intention of connecting two activity, int requestcode is the result code returned, here first set to 0.Click event Methodpublic void SelectContact (view view) {Intent Intent = n
This is a copy of the common mobile phone security guard application of the source code, the basic is to achieve the commonly used functions, but some are not perfect, we can study a lot of it.SOURCE Project Download: http://code.662p.com/view/7227.htmlScreenshot_2014-05-11-03-44-01.png (287.72 KB, download number: 0)Screenshot_2014-05-19-21-24-41.png (2.78 MB, download number: 0)Screenshot_2014-05-19-21-38-01.png (603.54 KB, download number: 0)Screenshot_2014-05-24-00-23-56.png (414.44 KB, down
android:background= "@drawable/button"9 android:text= "Next"/ >View CodeThree, the above button background style implementation can refer to the source code.In the Styles.xml file in the Android-19\data\res\values folder, find the View Codebtn_default.xml Code:12 345android:drawable= "@drawable/btn_default_normal"/>67android:drawable= "@drawable/btn_default_normal_disable"/>89android:drawable= "@drawable/btn_default_pressed"/>Ten Oneandroid:drawable= "@drawable/btn_defa
state;
Android:state_checkable:boolean type, only used on the widget can be selected, True indicates optional, false means not selectable;
Android:state_checked:boolean, when True, indicates that the item is in effect when it is selected, and false is not checked when it takes effect;
Android:state_enabled:boolean, when True, the item takes effect when the object is active, such as when the object can accept touch or click events;
The Android:state_window_focused:boolean
(R.id.et_setup3_phonenumber); Bt_select_contact.setonclicklistener (this); bt_next.seTonclicklistener (this); Bt_prev.setonclicklistener (this); } @Override public void OnClick (View v) {switch (V.getid ()) {r.id.bt_select_contact:i Ntent Intent = new Intent (this, selectcontactactivity.class); Activates an interface with a return value Startactivityforresult (intent, 0); Break Case R.id.bt_next:finish ();//users will not see this interface when they click
);} else{ cb_bind.settext ("unbound sim card"); Cb_bind.setchecked (false);}And the boolean Android.content.SharedPreferences.getBoolean (String key, Boolean Defvalue) method,
Retrieve A Boolean value from the preferences.
Parameters:key the name of the preference to retrieve. Defvalue Value to return if this preference does not exist. Returns:returns the preference value if it exists, or defvalue. Throws ClassCastException If there is a preference with the this name, which is
detection device detects the abnormal flow of the object, it pulls the flow to the cleaning device mode.Defense mode: The cleaning device detects the protection mode after abnormal flow.Dynamic blacklist mode: During the defense process, the detected illegal source IP will be added to the dynamic blacklist by the cleaning device.Cleaning bandwidth: Limits the amount of traffic that enters the protection-based defenses before the threshold, and messages that exceed the threshold are discarded di
the broadcastPrivate Screenoffreceiver Offreceiver;Private class Screenoffreceiver extends Broadcastreceiver {@Overridepublic void OnReceive (context context, Intent Intent {offreceiver = null;}}Solution three back to the code that entered the password interface@Overridepublic void onbackpressed () {//back to the desktop. Intent Intent = new Intent () intent.setaction ("Android.intent.action.MAIN"); Intent.addcategory (" Android.intent.category.HOME "), Intent.addcategory (" Android.intent.cate
,2.class);Startactivityforresult (Intent, 0); Where the number 0 is the request code, in a moment will be used-Second Step-In 2.class:Intent Intent = new Intent ();Intent.putextra ("key", value);Setresult (0,intent); Where the number 0 is the return code, in a moment will be used-Step Three-In 1.class:Overriding the parent class method: Onactivityresult/**requestCode 为请求码*resultCode 为返回码*data为2.class传回来的Intent*/protectedvoidonActivityResult(intint resultCode, Intent data) { super.onAct
= Digest.digest (Text.getbytes ());//3. Iterating through an array for(byteB:bytes) {//4. Conducting and computing intNumber = B 0xFF;//5. Converting the result of an operation into a hexadecimal stringString hex = integer.tohexstring (number);//6. Adding a string to buffer if(hex.length () = =1) {Buffer.append ("0"); } buffer.append (hex); } }Catch(NoSuchAlgorithmException e) {E.printstacktrace (); }returnBuffer.tostring (); }U
open the anti-theft protection mechanism: \ n "+"Turn on GPS tracking, send #*location*# \ n"+"Play alarm music please send #*alarm*# \ n"+"remotely delete data please send #*wipedata*# \ n"+"Remote lock screen please send #*lockscreen*#"; arraylistString> texts = manager.dividemessage (MessageText); for(Stringsms:texts) {manager.sendtextmessage (Mobilenumber,NULLSmsNULL,NULL); Toast.maketext (Context,sms,toast.length_short). Show (); }Receive SMSReceiving a message is a way to recei
,latitude)); String longitudetrue = pointdouble.x+""; String latitudetrue = pointdouble.y+"";//Save latitude and longitudeEditor.putstring ("Location","Longitude:"+longitudetrue+"\ n Latitude: Latitude"); Editor.commit (); }Catch(Exception e) {E.printstacktrace (); } }//callback when status is changed Public void onstatuschanged(String provider,intStatus, Bundle extras) {}//Location provider available callback Public void onproviderenabled(String Prov
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.