* Harden the new `hideAllViewsExcept()` to not do erroneous things if called when
the binding is already gone.
* Generalize things into `hideAllViewsExcept(thisOne)`:
- Clear `_viewShowing` in there and do the descriptionHeightWorkaround thing
in there too,
- For Photon panels, do all the 'current' attribute setting in there. To show
a panel during transition, I introduced the 'in-transition' attribute.
* I had to make sure not to over-eagerly dispatch 'ViewShowing' events, because
that confuses some,
* Move the temporary panel handling, which contains an ephemeral panelmultiview
instance, internally. This cleans up the hacky, duplicate PanelUI.js code nicely.
* Keep a local copy of `_transitionDetails` to ensure it's still there after transition,
* Harden `_cleanupTransitionPhase()` to only clear the phase that belongs to a
specific transition, _if_ that's passed in as an argument. This resolves any
potential raciness that might occur when `showSubView()` is called again mid-transition.
* Skip the UITour element visibility check when it's inside a panelview, because
too many things need to happen and that check is too simple to be useful in
that case.
MozReview-Commit-ID: 5HpJKs1Ny5j
--HG--
extra : rebase_source : b810e1de2dbd75932a42d68e751fdaecd9fee69a
We weren't removing the 'open' attribute from the anchor if the transition didn't complete.
This patch fixes this by moving the addition of 'open' into _transitionViews, and its removal into
_cleanupTransitionPhase.
MozReview-Commit-ID: TS0CcwsHVN
--HG--
extra : rebase_source : 1bdace324f22ee95002024fe68b572a16dd25aac
Prior to this change, showMainView set the 'current' attribute on a main view, but then _cleanupTransitionPhase() would remove it again.
This patch fixes that by calling showMainView *after* _cleanupTransitionPhase.
Separately, we weren't removing the 'open' attribute from the anchor if the transition didn't complete.
This patch fixes this by moving the addition of 'open' into _transitionViews, and its removal into
_cleanupTransitionPhase.
MozReview-Commit-ID: 24FYaxDVlga
--HG--
extra : rebase_source : 41bb5ffe29ca8e0ec9acc1793ae87d63d28e1f43
While this creates several methods with just 1 callsite, given the previous length of the
showSubView method (230 lines), it seems wise to split this up and to try to reduce the
nesting, as well as making it easier to reason about what happens if we hide the panel
mid-transition.
MozReview-Commit-ID: 9Vf4p4fVBSs
--HG--
extra : rebase_source : f21ca55eaeb4bda49ba51f2694ecb5620f47e941
Prior to this patch, both CustomizableUI itself and the PanelMultiView module
tried to ensure that onViewShowing/Shown/Hiding/Hidden listeners were invoked
when the relevant DOM events fired.
PanelMultiView was doing this manually because CUI was only adding listeners
once the corresponding widget was created. Now that the relevant views can be
accessed without the corresponding widgets (via the fixed appMenu), there was
no guarantee that the listeners would be attached, and this caused empty
subviews.
Unfortunately, if the widget *was* present, it caused events to fire more than
once, which understandably broke consumers like the sync remote tabs widget,
which broke the test we're fixing up here. For other views, even if they were
not completely broken it at least did busy-work.
This patch removes the manual event invocation, and delegates the event
listener work to CUI from the PanelMultiView side. This ensures events fire,
and fire only once.
MozReview-Commit-ID: 94GhcrdcBuB
--HG--
extra : rebase_source : 4df42939aa06ec10b7f86c3c2e4fe75160c7e7bd
This patch changes the history-panelmenu widget with the following:
- Move the Recently Closed Tabs and Recently Closed Windows lists into their own
respective (nested) subview,
- Add a Recent History header to list of history items,
- Extend the list of Recent History items to be max 42 items long,
- Share more code with Bookmarks panel,
- Generalizes panelview event dispatching to always support customizable widgets.
MozReview-Commit-ID: 4sBR6llIvxG
--HG--
extra : rebase_source : 2758dd643cd504448ee1f19296670a588bf56069
This is a follow-up to the previous patch, required because on Windows we cannot measure the full height of the main view until it is visible.
MozReview-Commit-ID: 2pfYwMLPYIb
--HG--
extra : rebase_source : 0391a619f551b5e100688ea231d12ac26e0868c8
These rules are set explicitly to allow the two views to be displayed next to
each other briefly when the slide-in transition starts.
This patch also applies the last remaining photon styles to the temporary panel,
which is used by the new Library widget as well.
MozReview-Commit-ID: 45aYzVHwRYv
--HG--
extra : rebase_source : 0bf4fc4effc9de9e431ee50dfcf5fc7206e252cf
These rules are set explicitly to allow the two views to be displayed next to
each other briefly when the slide-in transition starts.
This patch also applies the last remaining photon styles to the temporary panel,
which is used by the new Library widget as well.
MozReview-Commit-ID: 45aYzVHwRYv
--HG--
extra : rebase_source : 0bf4fc4effc9de9e431ee50dfcf5fc7206e252cf
These rules are set explicitly to allow the two views to be displayed next to
each other briefly when the slide-in transition starts.
This patch also applies the last remaining photon styles to the temporary panel,
which is used by the new Library widget as well.
MozReview-Commit-ID: 45aYzVHwRYv
--HG--
extra : rebase_source : f142e3dbba0d70effe129dad43f139e494070d82