Removes a duplicate or implementation in media direction

cusax-fix
Emil Ivov 16 years ago
parent d6f1f54870
commit 0a174c8bb3

@ -412,7 +412,7 @@ private MediaStream initStream(StreamConnector connector,
}
else
{
stream.stop();
//this is a reinit
}
return configureAndStartStream(connector, device, format,
@ -439,7 +439,8 @@ private MediaStream configureAndStartStream(
else
this.videoStream = (VideoMediaStream)stream;
stream.start();
if ( ! stream.isStarted())
stream.start();
return stream;
}

@ -182,42 +182,6 @@ else if( this == RECVONLY)
return direction;
}
/**
* Reverses a direction constraint on this <tt>MediaDirection</tt>
* or in other words performs an <tt>or</tt> operation. This method is
* meant for use in cases like putting a stream off hold or in other words
* reversing the <tt>SENDONLY</tt> constraint.
*
* @param direction the direction that we'd like to enable (i.e. add) to
* this <tt>MediaDirection</tt>
*
* @return the new <tt>MediaDirection</tt> obtained after adding the
* specified <tt>direction</tt> this <tt>MediaDirection</tt>.
*/
public MediaDirection or(MediaDirection direction)
{
if (this == SENDRECV)
{
return this;
}
else if( this == SENDONLY)
{
if( direction.allowsReceiving())
return SENDRECV;
else
return this;
}
else if( this == RECVONLY)
{
if( direction.allowsSending())
return SENDRECV;
else
return this;
}
else // INACTIVE
return direction;
}
/**
* Returns the <tt>MediaDirection</tt> value corresponding to a remote
* party's perspective of this <tt>MediaDirection</tt>. In other words,

Loading…
Cancel
Save