mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-29 17:52:06 +01:00
[SMACK-223] - More Fixes
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@8217 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
parent
904379fd52
commit
ac958c9971
2 changed files with 38 additions and 25 deletions
|
@ -142,14 +142,18 @@ public class ScreenShareSession extends JingleMediaSession {
|
|||
* Stops transmission and for NAT Traversal reasons stop receiving also.
|
||||
*/
|
||||
public void stopTrasmit() {
|
||||
|
||||
if(transmitter!=null){
|
||||
transmitter.stop();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* For NAT Reasons this method does nothing. Use startTransmit() to start transmit and receive jmf
|
||||
*/
|
||||
public void stopReceive() {
|
||||
// Do nothing
|
||||
if(receiver!=null){
|
||||
receiver.stop();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -100,6 +100,8 @@ public class ImageTransmitter implements Runnable {
|
|||
|
||||
if (baos != null) {
|
||||
|
||||
try {
|
||||
|
||||
Thread.sleep(1);
|
||||
|
||||
baos.write(i);
|
||||
|
@ -124,6 +126,10 @@ public class ImageTransmitter implements Runnable {
|
|||
tiles[i][j] = pixels;
|
||||
|
||||
}
|
||||
catch (Exception e) {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -156,6 +162,7 @@ public class ImageTransmitter implements Runnable {
|
|||
|
||||
/**
|
||||
* Set Transmit Enabled/Disabled
|
||||
*
|
||||
* @param transmit boolean Enabled/Disabled
|
||||
*/
|
||||
public void setTransmit(boolean transmit) {
|
||||
|
@ -164,6 +171,7 @@ public class ImageTransmitter implements Runnable {
|
|||
|
||||
/**
|
||||
* Get the encoder used to encode Images Tiles
|
||||
*
|
||||
* @return encoder
|
||||
*/
|
||||
public ImageEncoder getEncoder() {
|
||||
|
@ -172,6 +180,7 @@ public class ImageTransmitter implements Runnable {
|
|||
|
||||
/**
|
||||
* Set the encoder used to encode Image Tiles
|
||||
*
|
||||
* @param encoder encoder
|
||||
*/
|
||||
public void setEncoder(ImageEncoder encoder) {
|
||||
|
@ -181,9 +190,9 @@ public class ImageTransmitter implements Runnable {
|
|||
/**
|
||||
* Stops Transmitter
|
||||
*/
|
||||
public void stop(){
|
||||
this.transmit=false;
|
||||
this.on=false;
|
||||
public void stop() {
|
||||
this.transmit = false;
|
||||
this.on = false;
|
||||
socket.close();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue