Back to project page ZShaolin.
The source code is released under:
GNU General Public License
If you think the Android project ZShaolin listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
/* * To change this template, choose Tools | Templates * and open the template in the editor.//from w ww . j a v a 2s .c o m */ package com.spartacusrex.spartacuside.util; import android.content.Context; import android.preference.DialogPreference; import android.util.AttributeSet; import android.util.Log; import com.spartacusrex.spartacuside.TermService; /** * The OptionDialogPreference will display a dialog, and will persist the * <code>true</code> when pressing the positive button and <code>false</code> * otherwise. It will persist to the android:key specified in xml-preference. */ public class dialogpref extends DialogPreference { Context mContext; public dialogpref(Context context, AttributeSet attrs) { super(context, attrs); mContext = context; } @Override protected void onDialogClosed(boolean positiveResult) { super.onDialogClosed(positiveResult); // Log.v("DIALOGPREF", "PRESSES "+positiveResult); //Used to reset the Key Mappings.. if(positiveResult){ TermService.resetAllKeyCodes(); } } }