Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Bug 827288 - Pressing home to exit activity picker gets device into b…

…usted state
  • Loading branch information...
commit 1e8ecd4ac47321e397132d4d81a5258a5110d7d0 1 parent 66221e0
@vingtetun vingtetun authored
View
24 apps/system/js/list_menu.js
@@ -124,12 +124,15 @@ var ListMenu = {
return;
var self = this;
- this.container.addEventListener('transitionend',
- function onTransitionEnd() {
- self.element.classList.remove('visible');
- self.container.removeEventListener('transitionend', onTransitionEnd);
- });
- this.container.classList.add('slidedown');
+ var container = this.container;
+ container.addEventListener('transitionend', function list_hide() {
+ container.removeEventListener('transitionend', list_hide);
+ self.element.classList.remove('visible');
+ });
+
+ setTimeout(function() {
+ container.classList.add('slidedown');
+ });
},
handleEvent: function lm_handleEvent(evt) {
@@ -162,10 +165,11 @@ var ListMenu = {
break;
case 'home':
- if (this.visible) {
- this.hide();
- this.oncancel();
- }
+ if (!this.visible)
+ return;
+
+ this.hide();
+ this.oncancel();
break;
}
}
View
7 apps/system/style/list_menu/list_menu.css
@@ -6,7 +6,8 @@
visibility: visible;
}
-#listmenu menu {
+#listmenu menu,
+#listmenu.visible menu.slidedown {
transition: transform 0.3s ease;
transform: translateY(100%);
}
@@ -15,10 +16,6 @@
transform: translateY(0);
}
-#listmenu menu.slidedown {
- transform: translateY(100%);
-}
-
#listmenu menu button.icon,
#listmenu menu a[role="button"].icon {
background-repeat: no-repeat;
Please sign in to comment.
Something went wrong with that request. Please try again.