Project

General

Profile

« Previous | Next » 

Revision 18174881

Added by Leszek Koltunski over 7 years ago

Improve Projection.

View differences:

src/main/java/org/distorted/examples/projection/ProjectionActivity.java
38 38
///////////////////////////////////////////////////////////////////////////////////////////////////
39 39
    
40 40
    @Override
41
    protected void onCreate(Bundle icicle) 
41
    protected void onCreate(Bundle savedState)
42 42
      {
43
      super.onCreate(icicle);
43
      super.onCreate(savedState);
44 44
      setContentView(R.layout.projectionlayout);
45 45

  
46 46
      textF = (TextView)findViewById(R.id.projectionTextFOV);
47 47
      textN = (TextView)findViewById(R.id.projectionTextNear);
48 48

  
49
      SeekBar bar;
49
      SeekBar bar1 = (SeekBar)findViewById(R.id.projectionSeekFOV);
50
      SeekBar bar2 = (SeekBar)findViewById(R.id.projectionSeekNear);
50 51

  
51
      bar = (SeekBar)findViewById(R.id.projectionSeekFOV);
52
      bar.setOnSeekBarChangeListener(this);
53
      bar.setProgress(50);
54
      bar = (SeekBar)findViewById(R.id.projectionSeekNear);
55
      bar.setOnSeekBarChangeListener(this);
56
      bar.setProgress(50);
52
      bar1.setOnSeekBarChangeListener(this);
53
      bar2.setOnSeekBarChangeListener(this);
54

  
55
      if(savedState==null )
56
        {
57
        bar1.setProgress(50);
58
        bar2.setProgress(50);
59
        }
60
      else
61
        {
62
        textF.setText(getString(R.string.fov_placeholder ,0));
63
        textN.setText(getString(R.string.near_placeholder,0.0f));
64
        }
57 65
      }
58 66

  
59 67
///////////////////////////////////////////////////////////////////////////////////////////////////

Also available in: Unified diff