<commit_before>package de.ecotastic.android.camerautil.example;

import android.graphics.Bitmap;
import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import de.ecotastic.android.camerautil.R;
import de.ecotastic.android.camerautil.lib.CameraIntentHelperActivity;
import de.ecotastic.android.camerautil.util.BitmapHelper;

/**
 * Example Activity of how to use the CameraIntentHelperActivity
 * 
 * @author <NAME> <<EMAIL>>
 */
public class TakePhotoActivity extends CameraIntentHelperActivity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_take_photo);
	}
	
	public void onStartCamera(View view) {
		startCameraIntent();
	}
	
	@Override
	protected void onPhotoUriFound() {
		TextView uirView = (TextView) findViewById(R.id.acitvity_take_photo_image_uri);
		uirView.setText("photo uri: " + photoUri.toString());
		
		Bitmap photo = BitmapHelper.readBitmap(this, photoUri);
        if (photo != null) {
            photo = BitmapHelper.shrinkBitmap(photo, 300, rotateXDegrees);
            ImageView imageView = (ImageView) findViewById(R.id.acitvity_take_photo_image_view);
 			imageView.setImageBitmap(photo); 
        }
		
        //Delete photo in second location (if applicable)
        if (preDefinedCameraUri != null && !preDefinedCameraUri.equals(photoUri)) {
        	BitmapHelper.deleteImageWithUriIfExists(preDefinedCameraUri, this);
        }
        //Delete photo in thid location (if applicable)<commit_msg>Update TakePhotoActivity.java<commit_after>package de.ecotastic.android.camerautil.example;

import android.graphics.Bitmap;
import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import de.ecotastic.android.camerautil.R;
import de.ecotastic.android.camerautil.lib.CameraIntentHelperActivity;
import de.ecotastic.android.camerautil.util.BitmapHelper;

/**
 * Example Activity of how to use the CameraIntentHelperActivity
 * 
 * @author <NAME> <<EMAIL>>
 */
public class TakePhotoActivity extends CameraIntentHelperActivity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_take_photo);
	}
	
	public void onStartCamera(View view) {
		startCameraIntent();
	}
	
	@Override
	protected void onPhotoUriFound() {
		TextView uirView = (TextView) findViewById(R.id.acitvity_take_photo_image_uri);
		uirView.setText("photo uri: " + photoUri.toString());
		
		Bitmap photo = BitmapHelper.readBitmap(this, photoUri);
        if (photo != null) {
            photo = BitmapHelper.shrinkBitmap(photo, 300, rotateXDegrees);
            ImageView imageView = (ImageView) findViewById(R.id.acitvity_take_photo_image_view);
 			imageView.setImageBitmap(photo); 
        }
		
        //Delete photo in second location (if applicable)
        if (preDefinedCameraUri != null && !preDefinedCameraUri.equals(photoUri)) {
        	BitmapHelper.deleteImageWithUriIfExists(preDefinedCameraUri, this);
        }
        //Delete photo in third location (if applicable)
{'fraction_non_alphanumeric': 0.0986448156318941, 'fraction_numerical': 0.0018909549322407816, 'mean_word_length': 4.500866551126516, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1792675', 'n_tokens_mistral': 989, 'n_tokens_neox': 911, 'n_words': 186}