Android Open Source - SensorModelDataCollector Main Menu






From Project

Back to project page SensorModelDataCollector.

License

The source code is released under:

This is free and unencumbered software released into the public domain. Anyone is free to copy, modify, publish, use, compile, sell, or distribute this software, either in source code form or as a co...

If you think the Android project SensorModelDataCollector listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.clarkson.sensormodeldatacollector;
//  w  w w  . j  a v a 2 s  .  c om
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
//import android.widget.Button;
import android.widget.CheckBox;
import android.widget.EditText;

/**
 * An example full-screen activity 
 */
public class MainMenu extends Activity {
    

    /**
     * If set, will toggle the system UI visibility upon interaction. Otherwise,
     * will show the system UI visibility upon interaction.
     */
    //private static final boolean TOGGLE_ON_CLICK = true;

    /**
     * The flags to pass to {@link SystemUiHider#getInstance}.
     */
    //private static final int HIDER_FLAGS = SystemUiHider.FLAG_HIDE_NAVIGATION;

    /**
     * The instance of the {@link com.clarkson.sensormodeldatacollector.util.SystemUiHider} for this activity.
     */
    //private SystemUiHider mSystemUiHider;
  private CheckBox mConnectToServerCheckBox;
  private EditText mWifiScanIntervalTextField;
    private CheckBox mSSIDFilterEnableCheckbox;
    private EditText mSSIDFilterTextField;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        setContentView(R.layout.activity_main_menu);
        mConnectToServerCheckBox = (CheckBox) findViewById(R.id.connectToServerCheckBox);
        mWifiScanIntervalTextField = (EditText)findViewById(R.id.timer_seconds);
        mSSIDFilterEnableCheckbox = (CheckBox)findViewById(R.id.ssidFilterEnabled);
        mSSIDFilterTextField = (EditText)findViewById(R.id.ssidFilter);
        
Log.d(getLocalClassName(), "Step 1");
        
        
    }

    
    public void wifiScan(View view)
    {
      Log.d(getLocalClassName(), "Step 2");
      //Intent intent = new Intent(getApplicationContext(), apc.examples.AboutActivity.class); 
      Intent intent = new Intent(getApplicationContext(), com.clarkson.sensormodeldatacollector.WiFiScanActivity.class);
      intent.putExtra("mConnectToServer", mConnectToServerCheckBox.isChecked());
      intent.putExtra("mWifiScanIntervalSeconds", Long.getLong(mWifiScanIntervalTextField.getText().toString()));
        intent.putExtra("mSSIDFilterEnabled", mSSIDFilterEnableCheckbox.isChecked());
        intent.putExtra("mSSIDFilter", mSSIDFilterTextField.getText().toString());
      startActivity(intent);
    }
}




Java Source Code List

com.clarkson.sensormodeldatacollector.MainMenu.java
com.clarkson.sensormodeldatacollector.TimestampedRSS.java
com.clarkson.sensormodeldatacollector.WiFiScanActivity.java
com.clarkson.sensormodeldatacollector.WiFiScanResultAdapter.java
com.clarkson.sensormodeldatacollector.WiFiScanResultHashMap.java
com.clarkson.sensormodeldatacollector.WiFiScanResult.java
com.clarkson.sensormodeldatacollector.util.SystemUiHiderBase.java
com.clarkson.sensormodeldatacollector.util.SystemUiHiderHoneycomb.java
com.clarkson.sensormodeldatacollector.util.SystemUiHider.java