defaultValue on sharedPreference key is always 0
<p>The defaultValue is always being returned as 0, despite my attempt to return a different value when the pref key does not exist. I wonder why. Here's my piece of code -</p>

<pre><code>public static final String PREFS_NAME = "MyPrefsFile";
public static final String PREFS_OLD_TRIM = "trimName";
SharedPreferences settings = getSharedPreferences(PREFS_NAME, 0);
int trim_val = settings.getInt(PREFS_OLD_TRIM, 7);
</code></pre>

<p>I know for sure, in the initial run, that there is no pref key - PREFS_OLD_TRIM. So, i was expecting trim_val to get a value of 7. But it's getting 0.</p>

<p>Am i missing anything? Thanks. I am targeting API Level 8 device set.</p>
