Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes
com.github.turtlebot.turtlebot_android.panorama.PanoramaActivity Class Reference
Inheritance diagram for com.github.turtlebot.turtlebot_android.panorama.PanoramaActivity:
Inheritance graph
[legend]

List of all members.

Public Member Functions

GraphName getDefaultNodeName ()
void onConfigurationChanged (Configuration newConfig)
void onCreate (Bundle savedInstanceState)
void onError (Node n, Throwable e)
void onShutdown (Node n)
void onShutdownComplete (Node n)
void onStart (ConnectedNode connectedNode)
 PanoramaActivity ()
void showToast (final String message)

Protected Member Functions

void callService (byte mode)
void init (NodeMainExecutor nodeMainExecutor)
void onPause ()
void onRestart ()
void onResume ()
void onStop ()

Private Member Functions

void buildView (boolean rebuild)

Private Attributes

final OnSeekBarChangeListener angleBarListener
final OnClickListener backButtonListener
final MessageCallable< Bitmap,
sensor_msgs.CompressedImage > 
callable
final OnCheckedChangeListener contCheckListener
ImageView imgView
final OnSeekBarChangeListener intervalBarListener
Toast lastToast
ConnectedNode node
final OnSeekBarChangeListener speedBarListener
final OnClickListener startButtonListener
final OnClickListener stopButtonListener

Detailed Description

Definition at line 38 of file PanoramaActivity.java.


Constructor & Destructor Documentation

Definition at line 47 of file PanoramaActivity.java.


Member Function Documentation

Definition at line 110 of file PanoramaActivity.java.

Definition at line 196 of file PanoramaActivity.java.

Definition at line 296 of file PanoramaActivity.java.

void com.github.turtlebot.turtlebot_android.panorama.PanoramaActivity.init ( NodeMainExecutor  nodeMainExecutor) [inline, protected]

Definition at line 186 of file PanoramaActivity.java.

Definition at line 101 of file PanoramaActivity.java.

Called when the activity is first created.

Definition at line 59 of file PanoramaActivity.java.

Definition at line 278 of file PanoramaActivity.java.

Definition at line 89 of file PanoramaActivity.java.

Definition at line 83 of file PanoramaActivity.java.

Definition at line 95 of file PanoramaActivity.java.

Definition at line 284 of file PanoramaActivity.java.

Definition at line 290 of file PanoramaActivity.java.

void com.github.turtlebot.turtlebot_android.panorama.PanoramaActivity.onStart ( ConnectedNode  connectedNode) [inline]

Definition at line 253 of file PanoramaActivity.java.

Definition at line 77 of file PanoramaActivity.java.

Call Toast on UI thread.

Parameters:
messageMessage to show on toast.

Definition at line 169 of file PanoramaActivity.java.


Member Data Documentation

Initial value:
 new OnSeekBarChangeListener()
  {
    @Override
    public void onProgressChanged(SeekBar seekBar, int progress, boolean fromUser)
    {
      if (lastToast == null)
        lastToast = Toast.makeText(getBaseContext(), progress + " degrees", Toast.LENGTH_SHORT);
      else
        lastToast.setText(progress + " degrees");

      lastToast.show();
    }

    @Override public void onStartTrackingTouch(SeekBar seekBar) { }
    @Override public void onStopTrackingTouch(SeekBar seekBar) { }
  }

Definition at line 376 of file PanoramaActivity.java.

Initial value:
 new OnClickListener()
  {
    @Override
    public void onClick(View v)
    {
      onBackPressed();
    }
  }

Definition at line 306 of file PanoramaActivity.java.

final MessageCallable<Bitmap, sensor_msgs.CompressedImage> com.github.turtlebot.turtlebot_android.panorama.PanoramaActivity.callable [private]
Initial value:
      new ScaledBitmapFromCompressedImage(2)

Definition at line 43 of file PanoramaActivity.java.

Initial value:
 new OnCheckedChangeListener()
  {
    @Override
    public void onCheckedChanged(CompoundButton cb, boolean checked)
    {
      SeekBar snap_interv = (SeekBar)findViewById(R.id.seekBar_interval);
      if (checked == true)
      {
        
        snap_interv.setMax(5000);
        snap_interv.setProgress(Math.round((snap_interv.getProgress()*5000)/90));
      }
      else
      {
        
        snap_interv.setProgress(Math.round((snap_interv.getProgress()*90)/5000));
        snap_interv.setMax(90);
      }
    }
  }

Definition at line 338 of file PanoramaActivity.java.

Definition at line 40 of file PanoramaActivity.java.

Initial value:
 new OnSeekBarChangeListener()
  {
    @Override
    public void onProgressChanged(SeekBar seekBar, int progress, boolean fromUser)
    {
      if (seekBar.getMax() > 360) 
      {
        if (lastToast == null)
          lastToast = Toast.makeText(getBaseContext(), (progress/100)/10.0 + " seconds", Toast.LENGTH_SHORT);
        else
          lastToast.setText((progress/100)/10.0 + " seconds");
      }
      else                        
      {
        if (lastToast == null)
          lastToast = Toast.makeText(getBaseContext(), progress + " degrees", Toast.LENGTH_SHORT);
        else
          lastToast.setText(progress + " degrees");
      }
      lastToast.show();
    }

    @Override public void onStartTrackingTouch(SeekBar seekBar) { }
    @Override public void onStopTrackingTouch(SeekBar seekBar) { }
  }

Definition at line 393 of file PanoramaActivity.java.

Definition at line 41 of file PanoramaActivity.java.

Definition at line 42 of file PanoramaActivity.java.

Initial value:
 new OnSeekBarChangeListener()
  {
    @Override
    public void onProgressChanged(SeekBar seekBar, int progress, boolean fromUser)
    {
      if (lastToast == null)
        lastToast = Toast.makeText(getBaseContext(), progress + " deg/s", Toast.LENGTH_SHORT);
      else
        lastToast.setText(progress + " deg/s");

      lastToast.show();
    }

    @Override public void onStartTrackingTouch(SeekBar seekBar) { }
    @Override public void onStopTrackingTouch(SeekBar seekBar) { }
  }

Definition at line 359 of file PanoramaActivity.java.

Initial value:
 new OnClickListener()
  {
    @Override
    public void onClick(View v)
    {
      CheckBox continuous = (CheckBox)findViewById(R.id.checkBox_continuous);

      if (continuous.isChecked() == true)
        callService(turtlebot_msgs.TakePanoramaRequest.CONTINUOUS);
      else
        callService(turtlebot_msgs.TakePanoramaRequest.SNAPANDROTATE);
    }
  }

Definition at line 315 of file PanoramaActivity.java.

Initial value:
 new OnClickListener()
  {
    @Override
    public void onClick(View v)
    {
      callService(turtlebot_msgs.TakePanoramaRequest.STOP);
    }
  }

Definition at line 329 of file PanoramaActivity.java.


The documentation for this class was generated from the following file:


turtlebot_android
Author(s):
autogenerated on Wed Aug 26 2015 16:32:04