Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge changes from Sugarizer for env.js #134

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

cheongsiuhong
Copy link

Part of #127
With reference to #133

Merged changes from Sugarizer to env.js, with corresponding changes to activity.js.

Copy link
Collaborator

@llaske llaske left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please update only lines where there is a real change in source code. Too much lines in your PR had just formatting changes.
Did you test the change in an existing Sugar-web activity to ensure it works?

"sugar-web/datastore",
"sugar-web/graphics/icon",
"sugar-web/graphics/activitypalette"], function (
"sugar-web/activity/shortcut",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't change identation style

@@ -21,23 +22,31 @@ define(["webL10n",
function sendPauseEvent() {
var pauseEvent = document.createEvent("CustomEvent");
pauseEvent.initCustomEvent('activityPause', false, false, {
'cancelable': true});
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just indentation change, should not be updated

function sendStopEvent() {
var stopEvent = document.createEvent("CustomEvent");
stopEvent.initCustomEvent('activityStop', false, false, {
'cancelable': true});

'cancelable': true
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still indentation change only

if (!environment.objectId) {
datastoreObject.setMetadata({
"title": environment.activityName + " Activity",
"title": env.isSugarizer() ?
(l10n[environment.user.language] || l10n["en"]).replace("{{name}}", environment.activityName) : environment.activityName + " Activity",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you test in Sugar is the environnement.user.language property exist?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants