Copying Intent Data

There is some confusion from an earlier tutorial I wrote about using urban airships push notifications. On one of the steps I have a function call to copyIntentData. This is a method I wrote. I glossed over it because I was focusing on urban airship configuration and felt that this topic fell outside the scope of tutorial. I have had …

Custom Button States

I wanted to make a ImageButton to appear differently depending on a variable. The ImageButton would behave more like a checkbox. I know that there are other options such as subclassing the CheckBox or ToggleButton. This was more of a curiosity. My use case was I had a loop button that I wanted to display a different image when it …

Hide filter popup

Filtering a ListView is easy. However, there is popup text that comes with it: I couldn’t find reference to getting rid of this popup text. I had to do some exploring to come up with the following: The code for that is: Filter lFilter = mDataAdapter.getFilter(); lFilter.filter(“Item to filter for”); Also to clear the filter: Filter lFilter = mDataAdapter.getFilter(); lFilter.filter(“”); …

Up, up, and away with Urban Airship

Update I have gotten a lot of feedback from this post. I am a freelance Android developer. If you get stuck or simply don’t want the headache of configuring push notifications. I can be hired. Forward This tutorial is for using Urban Airship’s Android push notifications service. They offer two different methods for enabling push notifications. One via their in …

Sample Code For Sending an Android Push Notification from PHP via Urban Airship

Update: Sorry there is some confusion about what variables need to be changed in order for this script to work. The only values that need to be changed are: $dictionary[‘apids’] = array(…) $username $password Obtaining an apid is explained on step 9 of this page. The $username is the application key from the details page for the urban airship apps …

Put a clamp on it

I wanted to have a background that is horizontally centered, and clamp the pixels on the left and right side. It seems as though clamping is only for pixels to the right and bottom of an image. This called for some image handling to get the missing clamp.

Alpha Compositing Tutorial with Britney Spears and Guillermo Diaz

I was attempting to use PorterDuff.Mode.DST_IN to apply a rounded rectangle to images. The mask was successful in removing the parts of the image I did not want. However it was leaving behind solid black instead of transparent. This is not what I wanted. After researching the problem for a while I discovered that I needed create an additional layer …

Prevent animation on activity start or stop

I was looking for a way to prevent the animation into and out of Activities. Here is what I found: To prevent the default slide animation on Activity.finish() I found the following to work on 1.6. I am not sure what other versions it works on. getWindow().setWindowAnimations(0); For animation into a new activity for 1.6 is done the following: int …