예제 #1
0
  public Settings() {
    settingsGroup = new UIPreferencesTableCell();
    settingsGroup.setTitle("Settings");

    ipAddressCell = new UIPreferencesTextTableCell();
    ipAddressCell.setTitle("IP Address");
    ipAddressCell.setEnabled(true);

    useAccelerometerCell = new UIPreferencesTableCell();
    useAccelerometerCell.setTitle("Accelerometer");
    useAccelerometerCell.setEnabled(true);
    useAccelerometerControl = new UISwitchControl(new CGRect(170, 5, 120, 30));
    useAccelerometerControl.setValue(0.0f);
    useAccelerometerCell.addSubview(useAccelerometerControl);
  }
예제 #2
0
 public float getAccelerometerSetting() {
   return useAccelerometerControl.getValue();
 }