[Buri][3rd party app][Game Pack]Can't pause game pack after click home key, game keeps running at background

RESOLVED DUPLICATE of bug 872177

Status

Firefox OS
Gaia
P2
normal
RESOLVED DUPLICATE of bug 872177
5 years ago
5 years ago

People

(Reporter: sync-1, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [apps watch list])

(Reporter)

Description

5 years ago
+++ This bug was initially created as a clone of Bug #452063 +++
 
 AU_LINUX_GECKO_ICS_STRAWBERRY_V1.01.00.01.019.099
 Firefox os  v1.0.1
 Mozilla build ID:20130506230205
 
 +++ This bug was initially created as a clone of Bug #451811 +++
 
 *DEFECT DESCRIPTION:
 1. Enter Game Pack->magic stone.
 2. Press home button to go to homescreen.
 3. You can here the game music.
 4. Enter the game again, you'll find the game is running when minimize.
 
 *REPRODUCING PROCEDURES:
 
 *EXPECTED BEHAVIOR:
 The game should pause when minimize.
 *USER IMPACT:
 
 *REPRODUCING RATE:
 5/5
 ++++++++++ end of initial bug #451811 description ++++++++++
 
 
 
 
  DEFECT DESCRIPTION:
 
  REPRODUCING PROCEDURES:
 
  EXPECTED BEHAVIOUR:
 
  ASSOCIATE SPECIFICATION:
 
  TEST PLAN REFERENCE:
 
  TOOLS AND PLATFORMS USED:
 
  USER IMPACT:
 
  REPRODUCING RATE:
 
  For FT PR, Please list reference mobile's behavior:
 
 ++++++++++ end of initial bug #452063 description ++++++++++
 
 
 
 CONTACT INFO (Name,Phone number):
 
  DEFECT DESCRIPTION:
 
  REPRODUCING PROCEDURES:
 
  EXPECTED BEHAVIOUR:
 
  ASSOCIATE SPECIFICATION:
 
  TEST PLAN REFERENCE:
 
  TOOLS AND PLATFORMS USED:
 
  USER IMPACT:
 
  REPRODUCING RATE:
 
  For FT PR, Please list reference mobile's behavior:
Hmm...isn't this by design?

Josh?
Flags: needinfo?(jcarpenter)

Updated

5 years ago
blocking-b2g: --- → tef?

Comment 2

5 years ago
Similar question to Vivien - is it up to the app to react properly?
Flags: needinfo?(21)

Updated

5 years ago
Whiteboard: [apps watch list1]

Updated

5 years ago
Whiteboard: [apps watch list1] → [apps watch list]

Comment 3

5 years ago
(In reply to Alex Keybl [:akeybl] from comment #2)
> Similar question to Vivien - is it up to the app to react properly?

mchen/rlin - do you know correct behavior?
Flags: needinfo?(rlin)
Flags: needinfo?(mchen)
Flags: needinfo?(21)

Updated

5 years ago
Whiteboard: [apps watch list] → [apps watch list][target:05/15]

Updated

5 years ago
Whiteboard: [apps watch list][target:05/15] → [apps watch list]

Comment 4

5 years ago
Hi all,

As I knew that Web APP should listen to event of visibility change then do the corresponding work. In this case, I think game should pause itself when visibility is false.

From the view of AudioChannelService, when game fall into background, the audio in normal channel will be paused but AudioChannelService doesn't ask game to pause itself.
Flags: needinfo?(mchen)
This was a decision we made really long ago and has always been the case. I'm not particularly a fan of this design, but there is no way that we can change that for v1.0.1.

I filed bug 872177 on changing this behavior, but it's a big change which will take both a long time to fix (likely weeks), and will likely need a lot of followup work (definitely weeks).

We could *maybe* toss together some form of quick hacky solution, but there's no telling what that would break. So not something that I feel comfortable doing.

I'm sorry, but if we wanted different behavior here, that's something that needs to have been brought up a long time ago.

That said, the audio from the game should pause when the game is put in the background. Are we sure that's not happening?

Updated

5 years ago
Flags: needinfo?(rlin)
Flags: needinfo?(jcarpenter)
(In reply to Jonas Sicking (:sicking) from comment #5)
> That said, the audio from the game should pause when the game is put in the
> background. Are we sure that's not happening?

Really? I thought the expected behavior was that we should allow audio in an app should continue to play when it's in the background. I thought that was intentionally setup that way to handle use cases such as a music app wanting to music in the background.
We do allow audio from apps to play in the background. But only if the app has said that it wants the audio to keep playing in the background. The default behavior is that the audio is paused.

Technically the game here could be opting in to letting the audio play even when the app is in the background, by using <audio mozaudiochannel="content">. But I suspect it does not.
(In reply to Jonas Sicking (:sicking) from comment #7)
> We do allow audio from apps to play in the background. But only if the app
> has said that it wants the audio to keep playing in the background. The
> default behavior is that the audio is paused.
> 
> Technically the game here could be opting in to letting the audio play even
> when the app is in the background, by using <audio
> mozaudiochannel="content">. But I suspect it does not.

Doesn't look like it - I don't see the app permission specified to allow for audio-channel-content in the Poppit app manifest.
Anyways - the audio issue we are seeing here is technically a different bug - let me reproduce this and I'll file it.

As for this bug, I think technically this is a dupe of what bug 872177 is talking about. This bug is talking about freezing the game when the app goes into the background, which is exactly what bug 872177 is talking about.

If you disagree with the resolution, please explain.
Status: NEW → RESOLVED
blocking-b2g: tef? → ---
Last Resolved: 5 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 872177
(In reply to Jason Smith [:jsmith] from comment #8)
> (In reply to Jonas Sicking (:sicking) from comment #7)
> > We do allow audio from apps to play in the background. But only if the app
> > has said that it wants the audio to keep playing in the background. The
> > default behavior is that the audio is paused.
> > 
> > Technically the game here could be opting in to letting the audio play even
> > when the app is in the background, by using <audio
> > mozaudiochannel="content">. But I suspect it does not.
> 
> Doesn't look like it - I don't see the app permission specified to allow for
> audio-channel-content in the Poppit app manifest.

Ack. Wrong app. Let me try again by looking at the right app this time.
Okay, this time I looked at the right app. And yes, the permission isn't specified.

{
	"version": "1.1.0",
	"name": "Game Pack",
	"description": "The ultimate game pack with 5 cool games in one package. Addictive Tower game. Brain game with magic stones. Fun flipping tile game. Cute matching farm game. Swap colorful zombies.",
	"icons": {
		"60": "/icon-60.png",
		"128": "/icon-128.png"
	},
	"launch_path": "/index.html",
	"developer": {
		"name": "TweenSoft Inc.",
		"url": "http://www.tweensoft.com"
	},
	"default_locale": "en",
	"fullscreen": "true",
	"locales": {
		"es": {
			"launch_path": "/index-es.html",
			"description": "El paquete completo de 5 juegos fantásticos en uno. Juego Tower enganchando. Juego listo con piedras mágicas. Divertirse volteando casillas. Juego de granja mono. Intercambiar zombis colorados."
		},
		"pl": {
			"launch_path": "/index-pl.html",
			"description": "Pakiet gier zawierający 5 fajnych gier w jednej paczce. Uzależniająca gra Wieża. Magiczne kamienie - gra wymagająca myślenia. Zabawna gra z obracanymi płytkami, dopasowywanie farm oraz obracanie kolorowymi zombie."
		},
		"pt": {
			"launch_path": "/index-pt.html",
			"description": "O pacote ultimate com 5 jogos legais em um único pacote. Jogo de Torre viciante. Jogos inteligentes com pedras mágicas. Jogo divertido de lançamento de peças. Jogo de combinação de fazendas bonito. Troque zumbis coloridos."
		}
	}
}
Yup, I can reproduce the music issue. Bug coming.

Comment 13

5 years ago
This bug is for the special app Game Pack->magic stone,
I enter game and press home key to homescreen,
wait a few minutes and back to game, you'll find the game is over.

According to your discussion, I wonder if a game (app) should pause itself when visibility change or the system will do the job?
the system will not pause the game in the v1.0.1 release.

But the game can certainty pause itself using the visibility events.

I don't know who developed that game but someone would need to reach out to those developers.

Comment 15

5 years ago
Since bug 872177 won't fix for v1.0.1,
for this bug, the "game pack" app should pause itself when visibility change.
blocking-b2g: --- → tef?
(Reporter)

Comment 16

5 years ago
Comment from Mozilla:Since bug 872177 won't fix for v1.0.1,
 for this bug, the "game pack" app should pause itself when visibility change.
(In reply to buri.blff from comment #15)
> Since bug 872177 won't fix for v1.0.1,
> for this bug, the "game pack" app should pause itself when visibility change.

Please file a different bug for this in tech evangelism :: preinstalled b2g apps. This is already a closed bug.
blocking-b2g: tef? → ---
(Reporter)

Comment 18

5 years ago
Comment from Mozilla:(In reply to buri.blff from comment #15)
 > Since bug 872177 won't fix for v1.0.1,
 > for this bug, the "game pack" app should pause itself when visibility change.
 
 Please file a different bug for this in tech evangelism :: preinstalled b2g apps. This is already a closed bug.
You need to log in before you can comment on or make changes to this bug.