Bug 1523969 part 15 - Move method definition inline comments to new line in 'media/'. r=jya

Differential Revision: https://phabricator.services.mozilla.com/D21116

--HG--
extra : rebase_source : bf7d4b2a09768420f8da04d82d34afed374d7961
This commit is contained in:
Ryan Hunt 2019-02-25 16:09:55 -06:00
parent b936c00a65
commit d5e3e54658
8 changed files with 48 additions and 36 deletions

View File

@ -50,10 +50,11 @@ class ClearKeyDecryptor : public RefCounted {
Key mKey;
};
/* static */ ClearKeyDecryptionManager* ClearKeyDecryptionManager::sInstance =
nullptr;
/* static */
ClearKeyDecryptionManager* ClearKeyDecryptionManager::sInstance = nullptr;
/* static */ ClearKeyDecryptionManager* ClearKeyDecryptionManager::Get() {
/* static */
ClearKeyDecryptionManager* ClearKeyDecryptionManager::Get() {
if (!sInstance) {
sInstance = new ClearKeyDecryptionManager();
}

View File

@ -86,9 +86,9 @@ static void IncrementIV(vector<uint8_t>& aIV) {
BigEndian::writeUint64(&aIV[8], BigEndian::readUint64(&aIV[8]) + 1);
}
/* static */ void ClearKeyUtils::DecryptAES(const vector<uint8_t>& aKey,
vector<uint8_t>& aData,
vector<uint8_t>& aIV) {
/* static */
void ClearKeyUtils::DecryptAES(const vector<uint8_t>& aKey,
vector<uint8_t>& aData, vector<uint8_t>& aIV) {
assert(aIV.size() == CENC_KEY_LEN);
assert(aKey.size() == CENC_KEY_LEN);
@ -156,9 +156,10 @@ static bool EncodeBase64Web(vector<uint8_t> aBinary, string& aEncoded) {
return true;
}
/* static */ void ClearKeyUtils::MakeKeyRequest(const vector<KeyId>& aKeyIDs,
string& aOutRequest,
SessionType aSessionType) {
/* static */
void ClearKeyUtils::MakeKeyRequest(const vector<KeyId>& aKeyIDs,
string& aOutRequest,
SessionType aSessionType) {
assert(aKeyIDs.size() && aOutRequest.empty());
aOutRequest.append("{\"kids\":[");
@ -400,10 +401,10 @@ static bool ParseKeys(ParserContext& aCtx, vector<KeyIdPair>& aOutKeys) {
return GetNextSymbol(aCtx) == ']';
}
/* static */ bool ClearKeyUtils::ParseJWK(const uint8_t* aKeyData,
uint32_t aKeyDataSize,
vector<KeyIdPair>& aOutKeys,
SessionType aSessionType) {
/* static */
bool ClearKeyUtils::ParseJWK(const uint8_t* aKeyData, uint32_t aKeyDataSize,
vector<KeyIdPair>& aOutKeys,
SessionType aSessionType) {
ParserContext ctx;
ctx.mIter = aKeyData;
ctx.mEnd = aKeyData + aKeyDataSize;
@ -471,9 +472,10 @@ static bool ParseKeyIds(ParserContext& aCtx, vector<KeyId>& aOutKeyIds) {
return GetNextSymbol(aCtx) == ']';
}
/* static */ bool ClearKeyUtils::ParseKeyIdsInitData(
const uint8_t* aInitData, uint32_t aInitDataSize,
vector<KeyId>& aOutKeyIds) {
/* static */
bool ClearKeyUtils::ParseKeyIdsInitData(const uint8_t* aInitData,
uint32_t aInitDataSize,
vector<KeyId>& aOutKeyIds) {
ParserContext ctx;
ctx.mIter = aInitData;
ctx.mEnd = aInitData + aInitDataSize;
@ -526,8 +528,8 @@ static bool ParseKeyIds(ParserContext& aCtx, vector<KeyId>& aOutKeyIds) {
}
}
/* static */ bool ClearKeyUtils::IsValidSessionId(const char* aBuff,
uint32_t aLength) {
/* static */
bool ClearKeyUtils::IsValidSessionId(const char* aBuff, uint32_t aLength) {
if (aLength > 10) {
// 10 is the max number of characters in UINT32_MAX when
// represented as a string; ClearKey session ids are integers.

View File

@ -1167,9 +1167,11 @@ static SSLHandshakeType SrtpXtnServerMessage(PRFileDesc *fd) {
: ssl_hs_server_hello;
}
/* static */ PRBool TransportLayerDtls::WriteSrtpXtn(
PRFileDesc *fd, SSLHandshakeType message, uint8_t *data, unsigned int *len,
unsigned int max_len, void *arg) {
/* static */
PRBool TransportLayerDtls::WriteSrtpXtn(PRFileDesc *fd,
SSLHandshakeType message, uint8_t *data,
unsigned int *len, unsigned int max_len,
void *arg) {
auto self = reinterpret_cast<TransportLayerDtls *>(arg);
// ClientHello: send all supported versions.
@ -1282,7 +1284,8 @@ class TlsParser {
bool error_ = false;
};
/* static */ SECStatus TransportLayerDtls::HandleSrtpXtn(
/* static */
SECStatus TransportLayerDtls::HandleSrtpXtn(
PRFileDesc *fd, SSLHandshakeType message, const uint8_t *data,
unsigned int len, SSLAlertDescription *alert, void *arg) {
static const uint8_t kTlsAlertHandshakeFailure = 40;

View File

@ -8,12 +8,14 @@
namespace mozilla {
/* static */ WebrtcVideoEncoder* MediaDataDecoderCodec::CreateEncoder(
/* static */
WebrtcVideoEncoder* MediaDataDecoderCodec::CreateEncoder(
webrtc::VideoCodecType aCodecType) {
return nullptr;
}
/* static */ WebrtcVideoDecoder* MediaDataDecoderCodec::CreateDecoder(
/* static */
WebrtcVideoDecoder* MediaDataDecoderCodec::CreateDecoder(
webrtc::VideoCodecType aCodecType) {
switch (aCodecType) {
case webrtc::VideoCodecType::kVideoCodecVP8:

View File

@ -431,7 +431,8 @@ int32_t WebrtcGmpVideoEncoder::RegisterEncodeCompleteCallback(
return WEBRTC_VIDEO_CODEC_OK;
}
/* static */ void WebrtcGmpVideoEncoder::ReleaseGmp_g(
/* static */
void WebrtcGmpVideoEncoder::ReleaseGmp_g(
RefPtr<WebrtcGmpVideoEncoder>& aEncoder) {
aEncoder->Close_g();
}
@ -465,9 +466,10 @@ int32_t WebrtcGmpVideoEncoder::SetRates(uint32_t aNewBitRate,
return WEBRTC_VIDEO_CODEC_OK;
}
/* static */ int32_t WebrtcGmpVideoEncoder::SetRates_g(
RefPtr<WebrtcGmpVideoEncoder> aThis, uint32_t aNewBitRate,
uint32_t aFrameRate) {
/* static */
int32_t WebrtcGmpVideoEncoder::SetRates_g(RefPtr<WebrtcGmpVideoEncoder> aThis,
uint32_t aNewBitRate,
uint32_t aFrameRate) {
if (!aThis->mGMP) {
// destroyed via Terminate()
return WEBRTC_VIDEO_CODEC_ERROR;
@ -663,7 +665,8 @@ int32_t WebrtcGmpVideoDecoder::InitDecode(
return WEBRTC_VIDEO_CODEC_OK;
}
/* static */ void WebrtcGmpVideoDecoder::InitDecode_g(
/* static */
void WebrtcGmpVideoDecoder::InitDecode_g(
const RefPtr<WebrtcGmpVideoDecoder>& aThis,
const webrtc::VideoCodec* aCodecSettings, int32_t aNumberOfCores,
const RefPtr<GmpInitDoneRunnable>& aInitDone) {
@ -893,7 +896,8 @@ int32_t WebrtcGmpVideoDecoder::RegisterDecodeCompleteCallback(
return WEBRTC_VIDEO_CODEC_OK;
}
/* static */ void WebrtcGmpVideoDecoder::ReleaseGmp_g(
/* static */
void WebrtcGmpVideoDecoder::ReleaseGmp_g(
RefPtr<WebrtcGmpVideoDecoder>& aDecoder) {
aDecoder->Close_g();
}

View File

@ -594,8 +594,8 @@ void SdpHelper::appendSdpParseErrors(
*aErrorString += os.str();
}
/* static */ bool SdpHelper::GetPtAsInt(const std::string& ptString,
uint16_t* ptOutparam) {
/* static */
bool SdpHelper::GetPtAsInt(const std::string& ptString, uint16_t* ptOutparam) {
char* end;
unsigned long pt = strtoul(ptString.c_str(), &end, 10);
size_t length = static_cast<size_t>(end - ptString.c_str());

View File

@ -16,7 +16,8 @@ extern "C" {
namespace mozilla {
/* static */ const std::string SipccSdpAttributeList::kEmptyString = "";
/* static */
const std::string SipccSdpAttributeList::kEmptyString = "";
SipccSdpAttributeList::SipccSdpAttributeList(
const SipccSdpAttributeList* sessionLevel)

View File

@ -12,9 +12,8 @@
// The implementations can't be in the .h file for some annoying reason
/* static */ void
PlatformThread:: YieldCurrentThread()
{
/* static */
void PlatformThread::YieldCurrentThread() {
#ifdef WEBRTC_WIN
Sleep(1);
#else