Revision c02fa107
Added by Leszek Koltunski over 1 year ago
src/main/java/org/distorted/main/RubikObjectLibInterface.java | ||
---|---|---|
137 | 137 |
} |
138 | 138 |
} |
139 | 139 |
|
140 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
|
141 |
|
|
142 |
private Bundle createDialogBundle() |
|
143 |
{ |
|
144 |
Bundle bundle = new Bundle(); |
|
145 |
String arg = String.valueOf((mNewRecord/10)/100.0f); |
|
146 |
bundle.putString("argument", arg ); |
|
147 |
return bundle; |
|
148 |
} |
|
149 |
|
|
140 | 150 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
141 | 151 |
|
142 | 152 |
private void requestReview(RubikActivity act) |
... | ... | |
442 | 452 |
if( ScreenList.getCurrentScreen()== ScreenList.SOLV ) |
443 | 453 |
{ |
444 | 454 |
RubikActivity act = mAct.get(); |
445 |
Bundle bundle = new Bundle(); |
|
446 |
bundle.putLong("time", mNewRecord ); |
|
447 |
|
|
448 | 455 |
reportRecord(act,startTime,endTime,debug,scrambleNum); |
449 | 456 |
requestReview(act); |
450 | 457 |
|
... | ... | |
465 | 472 |
} |
466 | 473 |
else |
467 | 474 |
{ |
475 |
Bundle bundle = createDialogBundle(); |
|
468 | 476 |
RubikDialogNewRecord d2 = new RubikDialogNewRecord(); |
469 | 477 |
d2.setArguments(bundle); |
470 | 478 |
d2.show( act.getSupportFragmentManager(), RubikDialogNewRecord.getDialogTag() ); |
471 | 479 |
} |
472 | 480 |
break; |
473 |
case RECORD_NEW : RubikDialogNewRecord d2 = new RubikDialogNewRecord(); |
|
474 |
d2.setArguments(bundle); |
|
475 |
d2.show( act.getSupportFragmentManager(), RubikDialogNewRecord.getDialogTag() ); |
|
481 |
case RECORD_NEW : Bundle byes = createDialogBundle(); |
|
482 |
RubikDialogNewRecord dyes = new RubikDialogNewRecord(); |
|
483 |
dyes.setArguments(byes); |
|
484 |
dyes.show( act.getSupportFragmentManager(), RubikDialogNewRecord.getDialogTag() ); |
|
476 | 485 |
break; |
477 |
case RECORD_NOT_NEW: RubikDialogSolved d3 = new RubikDialogSolved(); |
|
478 |
d3.setArguments(bundle); |
|
479 |
d3.show( act.getSupportFragmentManager(), RubikDialogSolved.getDialogTag() ); |
|
486 |
case RECORD_NOT_NEW: Bundle bno = createDialogBundle(); |
|
487 |
RubikDialogSolved dno = new RubikDialogSolved(); |
|
488 |
dno.setArguments(bno); |
|
489 |
dno.show( act.getSupportFragmentManager(), RubikDialogSolved.getDialogTag() ); |
|
480 | 490 |
break; |
481 | 491 |
} |
482 | 492 |
|
... | ... | |
496 | 506 |
public void overlayFinished(long id) |
497 | 507 |
{ |
498 | 508 |
RubikActivity act = mAct.get(); |
499 |
Bundle bundle = new Bundle(); |
|
500 |
bundle.putLong("time", mNewRecord ); |
|
501 |
|
|
502 |
RubikDialogNewRecord d2 = new RubikDialogNewRecord(); |
|
503 |
d2.setArguments(bundle); |
|
504 |
d2.show( act.getSupportFragmentManager(), RubikDialogNewRecord.getDialogTag() ); |
|
509 |
Bundle bundle = createDialogBundle(); |
|
510 |
RubikDialogNewRecord d = new RubikDialogNewRecord(); |
|
511 |
d.setArguments(bundle); |
|
512 |
d.show( act.getSupportFragmentManager(), RubikDialogNewRecord.getDialogTag() ); |
|
505 | 513 |
} |
506 | 514 |
} |
Also available in: Unified diff
Continue unifying all the dialogs under one RubikDialogAbstract.