This android tutorial is about adding a refresh item in the action bar. When refreshing is disabled, a simple image is shown. When refreshing is running, a circular progressbar is shown. Let’s see the screenshots below to show the results.
AsyncTask in Android allows you to execute some code in background threads so that it does not block the user interface. They are mostly used to query webservices and to download data like pictures. But AsyncTask are not so easy to use if you want them to behave correctly, especially when a configuration change happens (like rotations). This article presents my conclusion of how to correctly use the AsyncTask. If you don’t know the basics about them, i invite you to read first the Android documentation.
Integrating Admob into your android application is quite easy, and this is what i am going to show you in this tutorial. Admob allows you to add advertizing banners in your app so you can make some money and become rich. Here’s some screenshots of the result :
In this android tutorial, i will show you how to highlight the selected item of a ListView, so that it keeps being highlighted. By default, the highlight disppears so in a list-detail page, you don’t see which item has been selected. Other people use a radio to do that, but i prefer to change the background color to lighten the UI. Let’s see a little demo:
This android tutorial shows how to swap two fragments. The goal was to re-use the fragment instances when rotating, no new fragment instances are re-created when rotating. There is also two layouts : one for portrait mode and one for landscape mode. In portrait mode, the second panel is below the first panel. In landscape mode, the second panel is on the right of the first panel. The support android library has been used.
Hi, i explain in this post the way i use to manage the sqlite database creation and upgrades in my android applications. As you may have already seen, this is done using the class SQLiteOpenHelper : you have to write your own sub class and fill the method onCreate and onUpgrade. So, from that point, there can be a lot of strategies like deleting/recreating the database for upgrades. Let’s talk about mine :
Hi, here’s the way i found to make a splash screen for my android application. First thing to note is that rotation works. I use a FragmentActivity so you need the android support compatibility jar. I didnot used a dialog : the splash screen is an activity that launches the main activity after application initialization which is done in a handler. Last thing about my code: i use the library RoboGuice for IOC.
Here’s the result:
When you want to connect a remote service using flex and the swiz framework, you have to use the class ChannelSetHelper. Most of time, you will find in the documentation, articles that kind of example :
The problem is that the parameters (server,port,context) are hard coded and you have to compile a swf for each of yours environnements (dev, testing, production). These parameters need to be externalized.
Here is the solution using flashvars :
Generating graphs from dstat log files is now possible using Vmstax. At the origin, Vmstax was created to build graphics from vmstat log files. It is very convenient to monitor the server load during a load test. All you had to do is to capture the log with a command like “vmstat -n 5 > output.log“, then upload the log file into vmstax and finally, export the graphs as images to include them into reports.
Actually, it is not a so good solution to analyze your servers : a lot of things is missing like network traffics, load per cpu, io per disk and others. Mpstat, iostat, ifstat can be used together but this is inconvenient because you have to manage several log ouputs.
Dstat is a versatile replacement for vmstat, iostat, netstat and ifstat. You can configure it with a bunch of options and you can even developp your own plugins for your specific needs. So, you have only one command to monitor what ever you want.
To draw charts from dstat output with Vmstax :
Learning Flex 3, i wanted to test the chart functionnalities. As a case study, i took the problematic of drawing charts from a vmstat log. At the end of your load tests, you have to build the charts. It may take some times to do that with Word or OpenOffice and it is not one of my favorite task. So, i decided to make a littleapplication in Flex : you upload your vmstat log, the chars appears and you can export them as images.
Click here to test: vmstax