package se.stolbygge.stolbygge;

import android.app.ActionBar;
import android.app.ListActivity;
import android.content.Intent;
import android.support.v7.app.ActionBarActivity;
import android.os.Bundle;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.*;

import java.util.ArrayList;
import java.util.List;


public class MainActivity extends ActionBarActivity{


    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

    }

    /*
    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        // Inflate the menu; this adds items to the action bar if it is present.
        getMenuInflater().inflate(R.menu.menu_main, menu);
        return true;
    }
    */

    /*
    @Override
    public boolean onOptionsItemSelected(MenuItem item) {
        // Handle action bar item clicks here. The action bar will
        // automatically handle clicks on the Home/Up button, so long
        // as you specify a parent activity in AndroidManifest.xml.
        int id = item.getItemId();

        //noinspection SimplifiableIfStatement
        if (id == R.id.action_settings) {
            return true;
        }

        return super.onOptionsItemSelected(item);
    }
    */

    public void onCreateProductList(View view){

        Intent I = new Intent(this, se.stolbygge.stolbygge.ListActivity.class);
        //Log.d("******", "i metoden onCreateProductList i MainActivity");
        startActivity(I);
    }

    public void onCreateResultList(View view) {
        //Kommentera fram detta för att få funktion till knappen Result List
        //Instead on ListActivitity.class, write in the class for the result page.

        //Intent I = new Intent(this, se.stolbygge.stolbygge.ListActivity.class);
        //startActivity(I);
    }

    public void onCreateAR(View view) {
        //Kommentera fram detta för att få funktion till knappen AR
        //Instead on ListActivitity.class, write in the class for the AR page.

        //Intent I = new Intent(this, se.stolbygge.stolbygge.ListActivity.class);
        //startActivity(I);
    }
}

@@ -1396,24 +1396,326 @@
   %7D%0A    */%0A%0A
+%0A    // Is called when the button %22Product List%22 with id button1 on the homepage is clicked.%0A    // Creates an abstract description called intent I, with an operation to be performed.%0A    // The operation is to call ListActivity.class that shows and handles the product list.%0A    // Starts the intent.%0A
     public v
@@ -1750,17 +1750,16 @@
  view)%7B%0A
-%0A
         
@@ -1930,32 +1930,329 @@
 vity(I);%0A    %7D%0A%0A
+    // Is called when the button %22Result List%22 with id button2 on the homepage is clicked.%0A    // Creates an abstract description called intent I, with an operation to be performed.%0A    // The operation is to call ResultList.class that shows and handles the result list.%0A    // Starts the intent.%0A
     public void 
@@ -2557,24 +2557,312 @@
 (I);%0A    %7D%0A%0A
+    // Is called when the button %22AR%22 with id button3 on the homepage is clicked.%0A    // Creates an abstract description called intent I, with an operation to be performed.%0A    // TODO Implement%0A    // The operation is to call AR. Change ....ListActivity.class.%0A    // Starts the intent.%0A
     public v

Commented the three functions: onCreateProductList, onCreateResultList, onCreateAR