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

[TIMOB-13697] Added jet rockets to Mobile Web #4229

Merged
merged 11 commits into from Jul 24, 2013
Merged

[TIMOB-13697] Added jet rockets to Mobile Web #4229

merged 11 commits into from Jul 24, 2013

Conversation

cb1kenobi
Copy link
Contributor

This PR contains major performance improvements for Mobile Web. We're seeing significantly faster object instantiation times, much faster load times, and significantly less memory usage. In addition, a few bugs were fixed:

  • Removed JSON.parse() and JSON.stringify() shims
  • Removed Object.defineProperty() shim
  • Only listen for device orientation when the 'orientationchange' event is being listened for
  • Removed Promise implementation (was never used)
  • Fixed bug with invalid layout not defaulting to 'composite'
  • Fixed conflict between TableViewRow.layout and View.layout properties

There were some internal changes that may break Mobile Web modules and platforms such as Tizen:

  • You can no longer reference an class's properties and constants via this.properties and this.constants (you must use this.values.properties or this.values.constants)
  • Dropped support for multiple inheritance in declare()
  • All 3rd party Filesystem back-ends must extend Ti/_/Evented

Also, after this PR, Mobile Web will no longer support:

  • IE7 and below
  • Firefox 3.x and below
  • iOS 3 and below
  • Opera 9.x and below
  • Android 2.1 and below
  • Safari 4.x and below

…mizations. Some internal changes including this.constants.something is now this.__values__.constants.something and this.constants.__values__.something is now this.__values__.constants.something.
@ingo
Copy link
Contributor

ingo commented May 5, 2013

Please do not merge this PR until I understand the context.

dest['get' + capitalizedName] = desc.get;
writable && (dest['set' + capitalizedName] = desc.set);
}
}(prop, name, propObj[name], name.substring(0, 1).toUpperCase() + name.substring(1), special[prop]));
Copy link
Contributor

Choose a reason for hiding this comment

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

FYI string.slice() takes the same arguments as string.substring() as long as the arguments are not negative and saves 4 bytes.

@nebrius
Copy link
Contributor

nebrius commented Jul 24, 2013

Code reviewed and tested. Request accepted

nebrius added a commit that referenced this pull request Jul 24, 2013
[TIMOB-13697] Added jet rockets to Mobile Web
@nebrius nebrius merged commit 7229461 into tidev:master Jul 24, 2013
@@ -99,7 +99,7 @@ define(["Ti/_", "Ti/_/declare", "Ti/_/has", "Ti/_/lang", "Ti/_/Evented", "Ti/Fil

open: function(method, url, async) {
var httpURLFormatter = Ti.Network.httpURLFormatter,
c = this.constants,
c = this.__values__.constants,
Copy link
Contributor

Choose a reason for hiding this comment

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

This change breaks HttpClient as this.values is undefined at this point. I can change my local copy of this file but is there a fix that can be pushed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hi Brenton, this pull request swapped the internal location where constants and properties are stored. This is correct. It should be this.values.constants. I'm not sure why HttpClient wouldn't be working.

Can you do me a favor and create a new ticket (http://jira.appcelerator.org/), then set the component to "MobileWeb" and assign it to me (Chris Barber)? Please include an error message and if possible, a small test case that reproduces the problem. This would help out a ton. I will take a look at it asap.

Copy link
Contributor

Choose a reason for hiding this comment

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

@cb1kenobi Sorry, I already created a ticket and I am not sure if I can reassign it now. The ticket is here: https://jira.appcelerator.org/browse/TC-2738. It will try to create a sample project to recreate but I wasn't doing anything fancy... I did notice that this.constants was populated with the values I wanted so my next step was going to be to try a previous version of that file with the rest of the RC2 code and see how that works.

Do you happen know where the values property is supposed to get set so I can put a breakpoint in and see what happens?

@brentonhouse
Copy link
Contributor

I made a comment by the line, but this pull request breaks HttpClient at the open function: values is undefined at this point. I can fix my local copy but is there a fix that can be pushed?

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.

None yet

4 participants