[virtualcommons-svn] commit/foraging: alllee: transition to waiting screen after survey submission
Status: Beta
Brought to you by:
alllee
From: Bitbucket <com...@bi...> - 2012-01-30 06:06:58
|
1 new commit in foraging: https://bitbucket.org/virtualcommons/foraging/changeset/e076a4ba6648/ changeset: e076a4ba6648 user: alllee date: 2012-01-30 07:06:36 summary: transition to waiting screen after survey submission affected #: 3 files diff -r c3edd5171f5d267af8e18e6451e94fdc36c9e88f -r e076a4ba66489cfcbf30f8a9f5b3e78e947494f9 src/main/java/edu/asu/commons/foraging/client/ForagingClient.java --- a/src/main/java/edu/asu/commons/foraging/client/ForagingClient.java +++ b/src/main/java/edu/asu/commons/foraging/client/ForagingClient.java @@ -176,7 +176,7 @@ }); addEventProcessor(new EventTypeProcessor<ShowVoteScreenRequest>(ShowVoteScreenRequest.class) { public void handle(ShowVoteScreenRequest request) { - getGameWindow2D().showVoteScreen(); + getGameWindow2D().showVotingScreen(); } }); addEventProcessor(new EventTypeProcessor<ShowSurveyInstructionsRequest>(ShowSurveyInstructionsRequest.class) { diff -r c3edd5171f5d267af8e18e6451e94fdc36c9e88f -r e076a4ba66489cfcbf30f8a9f5b3e78e947494f9 src/main/java/edu/asu/commons/foraging/conf/ServerConfiguration.java --- a/src/main/java/edu/asu/commons/foraging/conf/ServerConfiguration.java +++ b/src/main/java/edu/asu/commons/foraging/conf/ServerConfiguration.java @@ -156,7 +156,7 @@ } public String getWaitingRoomInstructions() { - return assistant.getProperty("waiting-room-instructions"); + return assistant.getProperty("waiting-room-instructions", "<h1>Please wait</h1><hr><p>Please wait while the rest of the participants complete the task.</p>"); } } diff -r c3edd5171f5d267af8e18e6451e94fdc36c9e88f -r e076a4ba66489cfcbf30f8a9f5b3e78e947494f9 src/main/java/edu/asu/commons/foraging/ui/GameWindow2D.java --- a/src/main/java/edu/asu/commons/foraging/ui/GameWindow2D.java +++ b/src/main/java/edu/asu/commons/foraging/ui/GameWindow2D.java @@ -739,9 +739,8 @@ } }); } - - - private JPanel getVotingPanel() { + + public void showVotingScreen() { if (votingPanel == null) { votingPanel = new JPanel(); votingPanel.setLayout(new BoxLayout(votingPanel, BoxLayout.Y_AXIS)); @@ -752,10 +751,10 @@ votingForm = new VotingForm(client); votingPanel.add(votingForm); votingPanel.setName(VotingForm.NAME); + add(votingPanel); } - return votingPanel; + showPanel(VotingForm.NAME); } - public void showVotingResults(final List<ForagingStrategy> selectedRules, final Map<ForagingStrategy, Integer> votingResults) { SwingUtilities.invokeLater(new Runnable() { @@ -770,14 +769,6 @@ }); } - - public void showVoteScreen() { - if (votingPanel == null) { - add(getVotingPanel()); - } - showPanel(VotingForm.NAME); - } - public void showSurveyInstructions() { SwingUtilities.invokeLater(new Runnable() { public void run() { Repository URL: https://bitbucket.org/virtualcommons/foraging/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email. |