Skip to content

Instantly share code, notes, and snippets.

View bilijo's full-sized avatar
🏠
Working from home

damir bilijo

🏠
Working from home
View GitHub Profile
@bilijo
bilijo / gist:842f085fbaefe0902086f6bf8207bfd7
Created June 29, 2017 17:11
click listener on the ListView, to earthquakeApp
// Set an item click listener on the ListView, which sends an intent to a web browser
// to open a website with more information about the selected earthquake.
earthquakeListView.setOnItemClickListener(new AdapterView.OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> adapterView, View view, int position, long l) {
// Find the current earthquake that was clicked on
EarthQuakeData currentEarthQuakeData = mAdapter.getItem(position);
// Convert the String URL into a URI object (to pass into the Intent constructor)
Uri earthquakeUri = Uri.parse(currentEarthQuakeData.getUrl());
//*************************** Question 3 *************************************
//define an instance of checkboxes linked to question 3
Button btn3 = (Button) findViewById(R.id.button_check_Q3);
final CheckBox checkBox1 = (CheckBox) findViewById(checkbox3_1);
final CheckBox checkBox2 = (CheckBox) findViewById(checkbox3_2);
final CheckBox checkBox3 = (CheckBox) findViewById(checkbox3_3);
final CheckBox checkBox4 = (CheckBox) findViewById(checkbox3_4);
@bilijo
bilijo / MainActivity.java
Last active June 16, 2017 19:16
cheesequiz
package com.example.android.cheesequiz;
import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.RadioButton;
@bilijo
bilijo / gist:1d798400630e35ad8f5acad2c1355875
Last active June 8, 2017 19:13
report card class - v1
/**
* This Class is indented to manage some grades informations about a student.
* A teacher is able to set and get, grade notes relative to some courses the student follows
*
* @author (damir Males)
* @version (v1 02 juin 2017)
*/
public class ReportCard
{
@bilijo
bilijo / ClassicMusic.java
Created May 26, 2017 17:38
intent caller - damir
package com.example.android.mymusicapp;
import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import android.widget.AdapterView;
import android.widget.ListView;
@bilijo
bilijo / ClassicArtist.java
Created May 26, 2017 17:36
intent target- damir
package com.example.android.mymusicapp;
import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.AdapterView;
import android.widget.ListView;
import android.widget.TextView;