blob: ff62d14407406767eb1441da2cdf1e0e92f947fd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
package jrummikub.control.network;
import java.util.UUID;
import jrummikub.control.SettingsControl;
import jrummikub.model.GameSettings;
import jrummikub.view.IGameListPanel.GameData;
import jrummikub.view.IView;
public class NetworkSettingsControl extends SettingsControl {
private GameData gameData = new GameData(UUID.randomUUID(), settings);
private ConnectionControl connectionControl;
public NetworkSettingsControl(ConnectionControl connectionControl, IView view, GameSettings settings) {
super(view, settings);
this.connectionControl = connectionControl;
}
@Override
public void startSettings() {
super.startSettings();
}
@Override
protected void update() {
super.update();
connectionControl.offerGame(gameData);
}
@Override
public void abort() {
super.abort();
connectionControl.withdrawGame(gameData.getGameID());
}
}
|