<commit_before>package com.jaselogic.adamsonelearn;

import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;

public class Main extends Activity {

	@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.main, menu);
		return true;
	}

}<commit_msg>Set proper visibility attributes upon login button click<commit_after>package com.jaselogic.adamsonelearn;

import java.io.IOException;
import java.util.Map;

import org.jsoup.Jsoup;
import org.jsoup.Connection.Method;
import org.jsoup.Connection.Response;
import org.jsoup.nodes.Document;

import android.os.AsyncTask;
import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ProgressBar;

public class Main extends Activity {

	private Button btnLogin;
	private EditText txtStudNo;
	private EditText txtPassword;
	private ProgressBar pb1;
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		
		//get views
		btnLogin = (Button) findViewById(R.id.btn_login);
		txtStudNo = (EditText) findViewById(R.id.txt_studno);
		txtPassword = (EditText) findViewById(R.id.txt_password);
		pb1 = (ProgressBar) findViewById(R.id.progressBar1);
		
		btnLogin.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				// TODO Auto-generated method stub
				btnLogin.setVisibility(View.INVISIBLE);
				txtStudNo.setVisibility(View.INVISIBLE);
				txtPassword.setVisibility(View.INVISIBLE);
				
				pb1.setVisibility(View.VISIBLE);
			}
		});
	}

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

	private class DownloadDocumentTask extends AsyncTask<String, Void, Document> {

		@Override
		protected Document doInBackground(String... arg0) {
			// TODO Auto-generated method stub
	        Document doc = null;
	        Response res = null;
	        try {                                              
	            res = Jsoup.connect("http://learn.adamson.edu.ph/V4/")
	            		.data("TXTusername", "<PASSWORD>", "TXTpassword", "<PASSWORD>", "BTNlogin", "Login")
	            		.method(Method.POST)
	            		.execute();
	            Map<String, String> loginCookies = res.cookies();
	            
	            doc = Jsoup.connect("http://learn.adamson.edu.ph/V4/?page=welcome")
	            		.cookies(loginCookies)
	            		.get();
	        } catch (IOException e) {                          
	            e.printStackTrace();                           
	        }
	        
	        return doc;
		}
		
		protected void onPostExecute(Document result) {

		}
		
	}
	
}
{'fraction_non_alphanumeric': 0.10305704380712259, 'fraction_numerical': 0.002206114087614245, 'mean_word_length': 2.9774436090225564, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 3, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6601580', 'n_tokens_mistral': 1033, 'n_tokens_neox': 913, 'n_words': 209}