Skip to content
Snippets Groups Projects
Commit f3c6bf2e authored by Eldar Kurmakaev's avatar Eldar Kurmakaev
Browse files
parents 9ffe3562 2d99e358
No related branches found
No related tags found
No related merge requests found
...@@ -50,6 +50,7 @@ public class ChatScreen { ...@@ -50,6 +50,7 @@ public class ChatScreen {
public ChatScreen(Client client) public ChatScreen(Client client)
{ {
this.client = client; this.client = client;
activeDrawingUserBox = new JTextArea();
yourNameDisplay.setText(client.getUserName()); yourNameDisplay.setText(client.getUserName());
exitThisRoomButton.addActionListener(actionListener); exitThisRoomButton.addActionListener(actionListener);
sendButton.addActionListener(actionListener); sendButton.addActionListener(actionListener);
......
...@@ -142,13 +142,13 @@ public class PaintGUI extends JPanel { ...@@ -142,13 +142,13 @@ public class PaintGUI extends JPanel {
toolbox2.add(textSize); toolbox2.add(textSize);
toolbox2.add(eraserBtn); toolbox2.add(eraserBtn);
toolbox2.add(eraserSizeOptions); toolbox2.add(eraserSizeOptions);
toolbox2.add(clearBtn);
/// File control panel /// /// File control panel ///
fileControl.add(newBtn); fileControl.add(newBtn);
fileControl.add(openBtn); fileControl.add(openBtn);
fileControl.add(saveBtn); fileControl.add(saveBtn);
fileControl.add(saveAsBtn); fileControl.add(saveAsBtn);
fileControl.add(clearBtn);
/// Layout /// /// Layout ///
toolbox.add(toolbox1, BorderLayout.NORTH); toolbox.add(toolbox1, BorderLayout.NORTH);
......
...@@ -20,8 +20,9 @@ public class DrawingUpdate extends UnicastRemoteObject implements IDrawingUpdate ...@@ -20,8 +20,9 @@ public class DrawingUpdate extends UnicastRemoteObject implements IDrawingUpdate
this.client = client; this.client = client;
} }
public void notifyUserIsDrawing(String fromClient){ public boolean notifyUserIsDrawing(String fromClient) throws RemoteException {
client.getApplicationMain().getChatScreen().getActiveDrawingUserBox().append(fromClient); client.getApplicationMain().getChatScreen().getActiveDrawingUserBox().append(fromClient);
return true;
} }
@Override @Override
......
...@@ -11,5 +11,5 @@ public interface IDrawingUpdate extends Remote, Serializable { ...@@ -11,5 +11,5 @@ public interface IDrawingUpdate extends Remote, Serializable {
boolean notifyDraggingDrawing(String fromClient, Shape drawing, String mode, Color color, int strokeSize) throws RemoteException; boolean notifyDraggingDrawing(String fromClient, Shape drawing, String mode, Color color, int strokeSize) throws RemoteException;
boolean notifyCanvasClearance(String fromClient) throws RemoteException; boolean notifyCanvasClearance(String fromClient) throws RemoteException;
boolean receiveImage(byte[] rawImage) throws RemoteException; boolean receiveImage(byte[] rawImage) throws RemoteException;
public void notifyUserIsDrawing(String fromClient) throws RemoteException; boolean notifyUserIsDrawing(String fromClient) throws RemoteException;
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment