mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-30 03:23:16 +00:00
リスナー作成 いろいろ
This commit is contained in:
parent
78c36df105
commit
07042f4e91
|
@ -29,7 +29,10 @@ import java.util.ArrayList;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
|
|
||||||
|
import javax.inject.Inject;
|
||||||
|
|
||||||
import one.nem.lacerta.processor.DocumentProcessor;
|
import one.nem.lacerta.processor.DocumentProcessor;
|
||||||
|
import one.nem.lacerta.processor.factory.DocumentProcessorFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A simple {@link Fragment} subclass.
|
* A simple {@link Fragment} subclass.
|
||||||
|
@ -45,6 +48,9 @@ public class ScannerDataManagerStubFragment extends Fragment {
|
||||||
|
|
||||||
private Uri photoURI;
|
private Uri photoURI;
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
DocumentProcessorFactory documentProcessorFactory;
|
||||||
|
|
||||||
private final ActivityResultLauncher<Intent> cameraLauncher = registerForActivityResult(
|
private final ActivityResultLauncher<Intent> cameraLauncher = registerForActivityResult(
|
||||||
new ActivityResultContracts.StartActivityForResult(),
|
new ActivityResultContracts.StartActivityForResult(),
|
||||||
result -> {
|
result -> {
|
||||||
|
@ -123,10 +129,17 @@ public class ScannerDataManagerStubFragment extends Fragment {
|
||||||
updateResults();
|
updateResults();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
view.findViewById(R.id.button_create_documnent).setOnClickListener(v -> {
|
||||||
|
Log.d("ScannerDataManagerStubFragment", "button_create_documnent clicked");
|
||||||
|
Toast.makeText(getActivity(), "button_create_documnent clicked", Toast.LENGTH_LONG).show();
|
||||||
|
// TODO-rca: ここでDocumentを作成する
|
||||||
|
});
|
||||||
|
|
||||||
view.findViewById(R.id.button_init_document_processor).setOnClickListener(v -> {
|
view.findViewById(R.id.button_init_document_processor).setOnClickListener(v -> {
|
||||||
Log.d("ScannerDataManagerStubFragment", "button_init_document_processor clicked");
|
Log.d("ScannerDataManagerStubFragment", "button_init_document_processor clicked");
|
||||||
Toast.makeText(getActivity(), "button_init_document_processor clicked", Toast.LENGTH_LONG).show();
|
Toast.makeText(getActivity(), "button_init_document_processor clicked", Toast.LENGTH_LONG).show();
|
||||||
// TODO-rca: ここでDocumentProcessorを初期化する
|
// TODO-rca: ここでDocumentProcessorを初期化する
|
||||||
|
DocumentProcessor documentProcessor = documentProcessorFactory.create();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user