From e7b9da61833d88f68187e84e53a67b427db6c98b Mon Sep 17 00:00:00 2001 From: Patrick FELIX-VIMALARATNAM Date: Wed, 2 Apr 2025 09:30:40 +0200 Subject: [PATCH] Add DEV4.5/exo1_controle --- DEV4.5/exo1_controle | 47 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 DEV4.5/exo1_controle diff --git a/DEV4.5/exo1_controle b/DEV4.5/exo1_controle new file mode 100644 index 0000000..e71b8ec --- /dev/null +++ b/DEV4.5/exo1_controle @@ -0,0 +1,47 @@ +package icom.example.q1_amyti; + +import android.app.Activity; +import android.graphics.Color; +import android.os.Bundle; +import android.view.View; + +public class MainActivity extends Activity { + @Override + protected void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + setContentView(R.layout.activity_main); + + // Couleurs RGB explicites + View zoneBleue = findViewById(R.id.zone_bleue); + zoneBleue.setBackgroundColor(Color.rgb(170, 204, 238)); + + View zoneRose = findViewById(R.id.zone_rose); + zoneRose.setBackgroundColor(Color.rgb(255, 170, 204)); + } +} + + + + + + + + + + } +} \ No newline at end of file