Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#11077 closed enhancement (fixed) Heading uses late view resolution

Reported by: foobarfighter Owned by: Jared Jurkiewicz
Priority: high Milestone: 1.5
Component: DojoX Mobile Version: 1.5.0b1
Keywords: Cc:
Blocked By: Blocking:


I'm working on a dojox.phonegap module that uses to render apps in HTML for the iphone (on the net) as well as using phonegap on the iphone (native iphone app).

The code is in a major state of flux right now, but you can see what I have here:

At any rate, here is the enhancement that I would like to see:

Current Behavoir:

When the widget renders it does not resolve it's parent view. When buttons are clicked the parent view widget is resolved and performTransition is called on the parent view.

The widget hierarchy looks like this:

| -- (dijit.byNode(this.domNode.parentNode) resolves to the

Desired Behavoir: This presents some challenges for me when trying to create my module. For my module to correctly render in either the browser or phonegap environment, I have provided a mediator object that decides which rendering engine it needs to require ( or PhoneGap?). An example interface looks like this:

<div id="home" dojoType="" selected="true">

<h1 id="heading" dojoType="dojox.phonegap.widgets.Heading">My Heading</h1> <div dojoType="foo.baz.Bar">...</div>


dojox.phonegap.widgets.Heading calls out to to render the Heading if the phone is executing in a browser environment.

In this case, I do a little fancy dom trickery in order to get around some issues that I was having with the parser. I create a container node, add a cloned heading node, and replace the original heading markup with the new container node.

At this point everything renders correctly but I have changed the normal widget hierarchy which now looks like this:

| -- dojox.phonegap.widgets.Heading

| --

Since dijit.byNode(this.domNode.parentNode) no longer resolves to, I get an error reporting that performTransition is not a method on the dojox.phonegap.widgets.Heading object.

If the widget resolves its view earlier than the onclick event, then I am able to safely set the view property on object post instantiation.

This should be a very minor patch and I can't think of any real use case that this might break. Please keep me posted.

Regards, foobarfighter

Attachments (1)

patch_fix_late_view_resolution.diff (993 bytes) - added by foobarfighter 12 years ago.

Download all attachments as: .zip

Change History (5)

Changed 12 years ago by foobarfighter


comment:1 Changed 12 years ago by Adam Peller

Owner: changed from Adam Peller to Jared Jurkiewicz

comment:2 Changed 12 years ago by Jared Jurkiewicz

Resolution: fixed
Status: newclosed

This should be addressed in [22096].

comment:3 Changed 12 years ago by bill

Component: DojoxDojoX Mobile

comment:4 Changed 12 years ago by bill

Milestone: tbd1.5
Note: See TracTickets for help on using tickets.