Hirdetés
- Milyen nyomtatót vegyek?
- Kormányok / autós szimulátorok topikja
- Gyárátalakításokkal kaszálna nagyott a memóriapánikból a Samsung
- Vezeték nélküli fülhallgatók
- Hogy is néznek ki a gépeink?
- Vezetékes FEJhallgatók
- Milyen CPU léghűtést vegyek?
- Előkészíti a vörös szőnyeget a neurális leképezéshez a shader modell 6.9
- Milyen asztali (teljes vagy fél-) gépet vegyek?
- OLED monitor topic
Új hozzászólás Aktív témák
-
negyedes
addikt
válasz
WonderCSabo
#893
üzenetére
hat nem, tudom mit masoljak be.

ez a main:
public class MainActivity extends FragmentActivity implements
PatientFrag.OnPatientSelect {
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
AppFolders foldercheck = new AppFolders();
foldercheck.updateExternalStorageState();
foldercheck.updateFolders();
DatabaseHandler db = new DatabaseHandler(this);
db.addPatient(new Patient("Noname1", "10.12.1978", "35", "/sdcard/dicomview/patient/0.dcm" ));
Log.d("Insert: ", "Inserting ..");
setContentView(R.layout.activity_main);
setContentView(R.layout.patient_layout);
// testing if the load is for the first time or a resume
if (findViewById(R.id.patient_list) != null) {
if (savedInstanceState != null) {
return;
}
}
// creating a first instance(pationt)
PatientFrag patientFrag = new PatientFrag();
patientFrag.setArguments(getIntent().getExtras());
// puts the patient_list fragment to the fragmentlayout
getSupportFragmentManager().beginTransaction()
.add(R.id.patient_list, patientFrag).commit();
}
public void patientSelect(int patientPos) {
// find the image fragment
ImageFrag imageFrag = (ImageFrag) getSupportFragmentManager()
.findFragmentById(R.id.image_view);
// verify iff image is opened
if (imageFrag != null) {
// if it is update it
imageFrag.updateImage(patientPos);
} else {
ImageFrag newFrag = new ImageFrag();
Bundle args = new Bundle();
args.putInt(ImageFrag.ARG_POSITION, patientPos);
newFrag.setArguments(args);
FragmentTransaction transaction = getSupportFragmentManager()
.beginTransaction();
transaction.replace(R.id.patient_list, newFrag);
transaction.addToBackStack(null);
transaction.commit();
}
}
@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;
}
Új hozzászólás Aktív témák
- DELL Precision 7550 ntel Core I7-10750H, 64 GB, 1TB SSD MAGYAR VILÁGITÓS BILL
- Lenovo Thinkpad T14 GEN5 Ultra7 165U, 1 tb, 32gb ram, MAGYAR VILÁGÍTÓ BILLENTYŰZET GARIS
- Új MSI 15 Katana FHD IPS 144Hz i7-13620H 10mag 16GB DDR5 1TB SSD Nvidia RTX 4060 8GB Win11 Garancia
- Eladó garanciális Synology DS223j NAS
- Dell Precision 5530 15,6" UHD touch, i7 8850H, 16GB RAM, 4GB VGA, 512GB SSD, jó akku, számla, gar
- LENOVO ThinkBook 13s G2 - i5-1135G7, 16GB RAM, 512GB SSD, jó akku, számla, 6 hó gar
- LG NanoCell 43NANO763QA csere is érdekel (dobozával minden tarozéka meg van)
- HP Probook 6530b,14",Intel Core P8700,4GB RAM,250GB HDD,WIN10
- BESZÁMÍTÁS! ASRock H510M i5 11400F 16GB DDR4 512GB SSD GTX 1660 Super 6GB Kolink Rocket Heavy 450W
- Új! AKRacing Premium Master gamer szék
Állásajánlatok
Cég: Laptopműhely Bt.
Város: Budapest


