diff --git a/b2g/components/FilePicker.js b/b2g/components/FilePicker.js index 980c72fcea5a..5d401198166f 100644 --- a/b2g/components/FilePicker.js +++ b/b2g/components/FilePicker.js @@ -47,6 +47,7 @@ FilePicker.prototype = { /* members */ mParent: undefined, + mExtraProps: {}, mFilterTypes: [], mFileEnumerator: undefined, mFilePickerShownCallback: undefined, @@ -85,6 +86,8 @@ FilePicker.prototype = { if (filterMask & Ci.nsIFilePicker.filterImages) { this.mFilterTypes = this.mFilterTypes.concat(IMAGE_FILTERS); + // This property is needed for the gallery app pick activity. + this.mExtraProps['nocrop'] = true; } // Ci.nsIFilePicker.filterXML is not supported @@ -117,6 +120,12 @@ FilePicker.prototype = { detail.type = this.mFilterTypes; } + for (let prop in this.mExtraProps) { + if (!(prop in detail)) { + detail[prop] = this.mExtraProps[prop]; + } + } + cpmm.sendAsyncMessage('file-picker', detail); }, diff --git a/b2g/config/gaia.json b/b2g/config/gaia.json index f37aa0dcb7e7..20f5307562fb 100644 --- a/b2g/config/gaia.json +++ b/b2g/config/gaia.json @@ -1,4 +1,4 @@ { - "revision": "c2506884aba22b968d3ab1ad6c28f0782b22a17f", + "revision": "001672effec8835928519312c1075a842af9166c", "repo_path": "/integration/gaia-central" } diff --git a/browser/metro/theme/browser.css b/browser/metro/theme/browser.css index 22f5dd102e9c..b1ea4dabac19 100644 --- a/browser/metro/theme/browser.css +++ b/browser/metro/theme/browser.css @@ -322,10 +322,6 @@ documenttab[selected] .documenttab-selection { min-width: @scroller_minimum@; } -#browsers[input="imprecise"] browser { - overflow: hidden; -} - /* overlay buttons */ .overlay-button { diff --git a/content/media/omx/MediaOmxReader.cpp b/content/media/omx/MediaOmxReader.cpp index 9442e0f93140..fc14561e49e7 100644 --- a/content/media/omx/MediaOmxReader.cpp +++ b/content/media/omx/MediaOmxReader.cpp @@ -37,6 +37,10 @@ MediaOmxReader::MediaOmxReader(AbstractMediaDecoder *aDecoder) : MediaOmxReader::~MediaOmxReader() { ResetDecode(); + VideoFrameContainer* container = mDecoder->GetVideoFrameContainer(); + if (container) { + container->ClearCurrentFrame(); + } mOmxDecoder.clear(); } @@ -64,6 +68,12 @@ bool MediaOmxReader::IsDormantNeeded() void MediaOmxReader::ReleaseMediaResources() { ResetDecode(); + // Before freeing a video codec, all video buffers needed to be released + // even from graphics pipeline. + VideoFrameContainer* container = mDecoder->GetVideoFrameContainer(); + if (container) { + container->ClearCurrentFrame(); + } if (mOmxDecoder.get()) { mOmxDecoder->ReleaseMediaResources(); } @@ -166,18 +176,6 @@ nsresult MediaOmxReader::ReadMetadata(MediaInfo* aInfo, return NS_OK; } -// Resets all state related to decoding, emptying all buffers etc. -nsresult MediaOmxReader::ResetDecode() -{ - MediaDecoderReader::ResetDecode(); - - VideoFrameContainer* container = mDecoder->GetVideoFrameContainer(); - if (container) { - container->ClearCurrentFrame(); - } - return NS_OK; -} - bool MediaOmxReader::DecodeVideoFrame(bool &aKeyframeSkip, int64_t aTimeThreshold) { @@ -347,12 +345,11 @@ nsresult MediaOmxReader::Seek(int64_t aTarget, int64_t aStartTime, int64_t aEndT { NS_ASSERTION(mDecoder->OnDecodeThread(), "Should be on decode thread."); + ResetDecode(); VideoFrameContainer* container = mDecoder->GetVideoFrameContainer(); if (container && container->GetImageContainer()) { container->GetImageContainer()->ClearAllImagesExceptFront(); } - mVideoQueue.Reset(); - mAudioQueue.Reset(); mAudioSeekTimeUs = mVideoSeekTimeUs = aTarget; diff --git a/content/media/omx/MediaOmxReader.h b/content/media/omx/MediaOmxReader.h index 58329da25688..a8c6d714905e 100644 --- a/content/media/omx/MediaOmxReader.h +++ b/content/media/omx/MediaOmxReader.h @@ -48,7 +48,6 @@ public: ~MediaOmxReader(); virtual nsresult Init(MediaDecoderReader* aCloneDonor); - virtual nsresult ResetDecode(); virtual void NotifyDataArrived(const char* aBuffer, uint32_t aLength, int64_t aOffset); diff --git a/dom/ipc/ProcessPriorityManager.cpp b/dom/ipc/ProcessPriorityManager.cpp index 90e630313df6..f4c3ee5b399a 100644 --- a/dom/ipc/ProcessPriorityManager.cpp +++ b/dom/ipc/ProcessPriorityManager.cpp @@ -1045,7 +1045,9 @@ ParticularProcessPriorityManager::ShutDown() mResetPriorityTimer = nullptr; } - ProcessPriorityManager::RemoveFromBackgroundLRUPool(mContentParent); + if (mPriority == PROCESS_PRIORITY_BACKGROUND && !IsPreallocated()) { + ProcessPriorityManager::RemoveFromBackgroundLRUPool(mContentParent); + } mContentParent = nullptr; } diff --git a/dom/speakermanager/SpeakerManager.cpp b/dom/speakermanager/SpeakerManager.cpp index ecfc92e24ce7..d9ba574a0e8d 100644 --- a/dom/speakermanager/SpeakerManager.cpp +++ b/dom/speakermanager/SpeakerManager.cpp @@ -110,10 +110,12 @@ SpeakerManager::DispatchSimpleEvent(const nsAString& aStr) void SpeakerManager::Init(nsPIDOMWindow* aWindow) { - BindToOwner(aWindow->IsOuterWindow() ? - aWindow->GetCurrentInnerWindow() : aWindow); + BindToOwner(aWindow); + + nsCOMPtr docshell = do_GetInterface(GetOwner()); + NS_ENSURE_TRUE_VOID(docshell); + docshell->GetIsActive(&mVisible); - mVisible = !GetOwner()->IsBackground(); nsCOMPtr target = do_QueryInterface(GetOwner()); NS_ENSURE_TRUE_VOID(target); diff --git a/widget/gonk/HwcComposer2D.cpp b/widget/gonk/HwcComposer2D.cpp index 5b21aef7ce90..97556f77f5b0 100644 --- a/widget/gonk/HwcComposer2D.cpp +++ b/widget/gonk/HwcComposer2D.cpp @@ -525,6 +525,8 @@ HwcComposer2D::Render(EGLDisplay dpy, EGLSurface sur) mList->hwLayers[0].compositionType = HWC_BACKGROUND; mList->hwLayers[0].flags = HWC_SKIP_LAYER; mList->hwLayers[0].backgroundColor = {0}; + mList->hwLayers[0].acquireFenceFd = -1; + mList->hwLayers[0].releaseFenceFd = -1; mList->hwLayers[0].displayFrame = {0, 0, mScreenRect.width, mScreenRect.height}; Prepare(fbsurface->lastHandle, fbsurface->lastFenceFD); } diff --git a/widget/gonk/libdisplay/GonkDisplayJB.cpp b/widget/gonk/libdisplay/GonkDisplayJB.cpp index 97612ae44a5d..7ab251af0587 100644 --- a/widget/gonk/libdisplay/GonkDisplayJB.cpp +++ b/widget/gonk/libdisplay/GonkDisplayJB.cpp @@ -234,6 +234,8 @@ GonkDisplayJB::Post(buffer_handle_t buf, int fence) /* Skip this layer so the hwc module doesn't complain about null handles */ mList->hwLayers[0].flags = HWC_SKIP_LAYER; mList->hwLayers[0].backgroundColor = {0}; + mList->hwLayers[0].acquireFenceFd = -1; + mList->hwLayers[0].releaseFenceFd = -1; /* hwc module checks displayFrame even though it shouldn't */ mList->hwLayers[0].displayFrame = r; mList->hwLayers[1].compositionType = HWC_FRAMEBUFFER_TARGET;