Hide in app billing for astrid lite--it's not set up yet

pull/14/head
Sam Bosley 12 years ago
parent a89a017e10
commit ad8b20f48a

@ -15,6 +15,7 @@ import android.os.Bundle;
import android.preference.Preference; import android.preference.Preference;
import android.preference.Preference.OnPreferenceClickListener; import android.preference.Preference.OnPreferenceClickListener;
import android.preference.PreferenceCategory; import android.preference.PreferenceCategory;
import android.preference.PreferenceScreen;
import android.widget.Toast; import android.widget.Toast;
import com.timsu.astrid.R; import com.timsu.astrid.R;
@ -71,13 +72,18 @@ public class ActFmPreferences extends SyncProviderPreferences {
public void onCreate(Bundle savedInstanceState) { public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
findPreference(getString(R.string.actfm_inapp_billing)).setOnPreferenceClickListener(new OnPreferenceClickListener() { PreferenceScreen screen = getPreferenceScreen();
@Override Preference inAppBilling = findPreference(getString(R.string.actfm_inapp_billing));
public boolean onPreferenceClick(Preference preference) { if (Constants.ASTRID_LITE)
handleInAppBillingClicked(); screen.removePreference(inAppBilling);
return true; else
} inAppBilling.setOnPreferenceClickListener(new OnPreferenceClickListener() {
}); @Override
public boolean onPreferenceClick(Preference preference) {
handleInAppBillingClicked();
return true;
}
});
findPreference(getString(R.string.actfm_account_type)).setOnPreferenceClickListener(new OnPreferenceClickListener() { findPreference(getString(R.string.actfm_account_type)).setOnPreferenceClickListener(new OnPreferenceClickListener() {
@Override @Override

Loading…
Cancel
Save