Search in sources :

Example 1 with IgnitedHttp

use of com.github.ignition.support.http.IgnitedHttp in project ignition by mttkay.

the class IgnitedHttpSampleActivity method onCreate.

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.ignited_http_sample);
    statusText = (TextView) findViewById(R.id.ignitedhttp_status);
    useCache = (CheckBox) findViewById(R.id.ignitedhttp_chk_use_cache);
    useCache.setOnCheckedChangeListener(new OnCheckedChangeListener() {

        @Override
        public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
            enableCache(isChecked);
            updateCacheStatus();
        }
    });
    http = new IgnitedHttp(this);
    enableCache(useCache.isChecked());
}
Also used : OnCheckedChangeListener(android.widget.CompoundButton.OnCheckedChangeListener) IgnitedHttp(com.github.ignition.support.http.IgnitedHttp) CompoundButton(android.widget.CompoundButton)

Aggregations

CompoundButton (android.widget.CompoundButton)1 OnCheckedChangeListener (android.widget.CompoundButton.OnCheckedChangeListener)1 IgnitedHttp (com.github.ignition.support.http.IgnitedHttp)1