Blame view

app/src/main/java/tonio/noa/BravoActivity.java 996 Bytes
6b23e70e   aarnaude   first commit
1
2
3
  package tonio.noa;
  
  import android.app.Activity;
d55d5943   aarnaude   resolution Bravo
4
  import android.content.Intent;
6b23e70e   aarnaude   first commit
5
  import android.os.Bundle;
d55d5943   aarnaude   resolution Bravo
6
7
  import android.view.MotionEvent;
  import android.view.View;
e5e6f3ef   aarnaude   intégration noa à...
8
  import android.widget.TextView;
6b23e70e   aarnaude   first commit
9
10
11
12
13
  
  /**
   * Created by tonio on 23/11/17.
   */
  
d55d5943   aarnaude   resolution Bravo
14
  public class BravoActivity extends Activity{
6b23e70e   aarnaude   first commit
15
16
17
18
19
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
  
          super.onCreate(savedInstanceState);
d55d5943   aarnaude   resolution Bravo
20
          final Intent intent = getIntent();
6b23e70e   aarnaude   first commit
21
          setContentView(R.layout.bravo_display);
d55d5943   aarnaude   resolution Bravo
22
23
          View view = findViewById(R.id.bravo_view);
          view.setOnTouchListener(new View.OnTouchListener() {
6b23e70e   aarnaude   first commit
24
  
d55d5943   aarnaude   resolution Bravo
25
26
27
28
29
30
31
32
                                      @Override
                                      public boolean onTouch(View view,MotionEvent event) {
                                          setResult(RESULT_OK,intent);
                                          finish();
                                          return true;
                                      }
                                  });
      }
6b23e70e   aarnaude   first commit
33
  }