Tuesday, February 23, 2010

» Dark Glass theme with DroidMod v1.0 - White Clock +

The DroidMod Team (formerly of sholes.info) relased a new ROM (--one of the best availible, I might add). The only "problem" with the ROM is that it does not include the ability to select the Smoked Glass theme when applying it. This is not so much a problem as a design decision.

The Metamorph application, available on the Market, lets you apply all manner of themes to your device, uncluding the "Dark Glass" theme previously included in the SholesMod ROM. Thus, the new ROM opts to exclude theme support directly, and just let users apply whatever theme they like via Metamorph.

That's fine, and Metamorph is an awesome application. However, there is a minor hang-up. AdamZ's Smoked Glass metamorph themes do not include a hacked services.jar, so you have a black statusbar clock, and the XML files in framework-res don't change all of the foreground text colors to white for notifications.

So, here is a simple Metamorph theme that adds a services.jar and framework-res.apk with white clock and notifications (just used colorChangev3.jar on them). Should work with any theme on any 2.0 or 2.0.1 ROM. :)

  1. Install the Smoked Glass theme located here (the "Glass Theme Only - No Blue" is the closest to the one previously included in SholesMod).
  2. Install the "White Clock Notifications" theme from here
  3. ???
  4. PROFIT!

Happy droiding. :)

Labels: , , , ,

Monday, February 15, 2010

» Clear Android Market Search History +

So, I wanted to clear the search history that displays in the Market app when you open the search bar. It seems that from a quick googling many people would like to do the same thing. I found a way that seems to work, but it requires root access.

I figured the Market app probably stores the search history in some type of standard database, rather than in a compressed or encrypted container, so I just grep'd /data for a unique history item (foobarbazbozbiz) that I searched for in the Market for specifically this purpose:

grep -r foobarbazbozbiz *

It looks like /data/data/com.android.vending/databases/suggestions.db is where the history is stored. And yes, this is just an SQLite3 database. I tried removing the file, but the Market app still shows the same history. Hmmm. Maybe the Market app is still running in the background and holds an open handle to the database? (In Linux, the kernel Android runs on, when a reference to a file is held in memory, the file can be deleted from disk, but it is not actually removed until all the references to it are released--see here).

So I tried killing the Market app:

Menu -> Settings -> Applications -> Manage Applications -> Menu -> Filter -> All -> Market -> Force Stop

That worked. :)

I haven't found any other apps that use the database, but there may be some that do. So far, my phone hasn't exploded, but YMMV.

Ps. Maybe my first Android app will be a "Clear Market Search History" app (looks like the SearchRecentSuggestions class might be helpful; or I'll just do it quick and dirty with the File I/O APIs ;)).

Labels: , ,