Retrofit is a framework developed by the Square company for the Android network, RETROFIT2 based on Okhttp, Okhttp is now officially recognized by Google, and a large number of apps are using okhttp to make network requests, Its source details see
On the internet to find a lot of questions about dialog custom style, there are a lot of people write more complex, need to change style or something, or custom dialog make very complex, I finally found a way to achieve.Here is my dialog layout XML
About WebViewWe know that some of the apps in the Android Market are developed in roughly three ways: Native app, Web app, Hybrid app. This paper is mainly implemented in hybrid app, the main technology native component and JS data interaction
Some of the demand is that the video automatically full-screen playback, which is the default on the iphone. But on the Android system you need to manually click the Full-screen button. Now the full screen API for the video label has been in the
The use of Android fragment
1. Use Support Library
If your application needs to run in versions 3.0 and above, you can ignore this part of the content.
If your application uses a version below 3.0, 1.6, or more, you need to use a support library to
For example: To add a button, view to a linearlayout is a button and the parent view is linearlayout. The properties of the child view are set by Layoutparams. Note that the linearlayout.layoutparams, because the height of the child view, the width
sharedpreferences IntroductionSharedpreferences is a lightweight storage class on the Android platform that holds some common configurations for applications, such as activity status, when activity pauses, Saves the state of this activity to
The code is as follows
Copy Code
If you have an upload file, you receive if ($_files) { $target _path = $target _path. basename ($_files[' file1 '] [' name ']); try{if (move_uploaded_file ($_files[' file1 '] [' tmp_name '],
1. For a common project, first add the ant build function to it.
The code is as follows
Copy Code
Android Update Project--name project_name-t 3-p d:/temp/project_name
An ant script named Build.xml is
In this article we share a simple chat room instance source under Android based on socket clientEstablish an Android client: package Com.example.mysocketclient;import Java.io.BufferedReader;Import Java.io.BufferedWriter;Import
Method One, enter the phone set restore
1, open the mobile phone "function table-Settings-security privacy-Restore factory settings" as shown in the following figure.
Method two, Recovery mode
1, close the Android phone, and then boot, as
Typically, after you have installed and configured the environment variables for the Android SDK, you will not see your device immediately after you successfully enter the ADB devices on the command line (Terminal). This eliminates the problem of
1, the picture into a thumbnail and then load:
The code is as follows
Copy Code
1 bitmapfactory.options Options = new Bitmapfactory.options ();2 options.insamplesize = 2;3 Bitmap img = bitmapfactory.decodefile ("/sdcard/1
1. Because Android is a smartphone we can sometimes reboot to solve this problem, we restart the phone to try.
2, if the restart is not valid we can try to download a dedicated photo software to try
3, if still not, we can try to reset the
Hotfix-Tinker, fix-tinker
Open source is a great surprise. You have to check it out. It is much better than nuwa. In addition, there are dedicated official documentation on github, and there are still a lot of data queries.
Reference:
Genymotion solution: genymotion Solution
Genymotion claims to be the fastest running Android simulator, but the server is abroad and Android images can be downloaded at that speed.
The download speed after adding new device is too slow and is easy
Android SQLite database, androidsqlite
I. Introduction to SQLite
Google provides SQLite,He is outstanding in data storage, management, maintenance, and other aspects,The function is also very powerful.
Ii. Features of SQLite
1. lightweightTo use
Example 2 of AlertDialog in Android (normal option dialog box) and androidalertdialog
In Android development, we often need to pop up some dialogs on the Android interface, such as asking users or asking users to choose. These functions are called
To implement automatic text message reply, the APP we want to use is called Tasker. It is a powerful system configuration APP that allows you to set a wide range of automatic tasks, the automatic reply of short messages is one of them. To set the
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