Bug 22549 - Add WML <do> element support.
Summary: Add WML <do> element support.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: XML (show other bugs)
Version: 528+ (Nightly build)
Hardware: Mac OS X 10.5
: P2 Normal
Assignee: Nikolas Zimmermann
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-11-28 18:07 PST by Nikolas Zimmermann
Modified: 2008-11-28 18:52 PST (History)
0 users

See Also:


Attachments
Initial patch (17.58 KB, patch)
2008-11-28 18:10 PST, Nikolas Zimmermann
no flags Details | Formatted Diff | Diff
Updated patch (17.62 KB, patch)
2008-11-28 18:34 PST, Nikolas Zimmermann
zecke: review+
Details | Formatted Diff | Diff
Layout test results (14.59 KB, patch)
2008-11-28 18:34 PST, Nikolas Zimmermann
zecke: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Nikolas Zimmermann 2008-11-28 18:07:59 PST
Add <do> element support, a general task element container element. Until now only <anchor> supported <go>/<prev>/<refresh> task child elements, <do> provides a way to register a task to a <template>/<card> element.
Comment 1 Nikolas Zimmermann 2008-11-28 18:10:43 PST
Created attachment 25578 [details]
Initial patch
Comment 2 Nikolas Zimmermann 2008-11-28 18:34:11 PST
Created attachment 25579 [details]
Updated patch

Incorporate comments from Holger.
Comment 3 Nikolas Zimmermann 2008-11-28 18:34:36 PST
Created attachment 25580 [details]
Layout test results
Comment 4 Holger Freyther 2008-11-28 18:41:36 PST
Comment on attachment 25580 [details]
Layout test results

Okay.
Comment 5 Holger Freyther 2008-11-28 18:46:10 PST
Comment on attachment 25579 [details]
Updated patch


> +2008-11-28  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
> +
> +        Reviewed by Holger Freyther

^^ haha ;)

> +void WMLDoElement::defaultEventHandler(Event* event)

I assume that you look at the right events?! But if you don't I'm pretty sure you will find that out sooner than later.

> +
> +    Node* parent = parentNode();
> +    ASSERT(parent);
> +
> +    if (!parent || !parent->isWMLElement())
> +        return;

Before landing decide if the parentNode might be zero or not and then remove the assert or the !parent from the if?

> +    bool m_isOption;

maybe call it m_isOptional? but that is optional...


from a grep in the source tree it looks like you uncommented all doTag users...
Comment 6 Nikolas Zimmermann 2008-11-28 18:50:29 PST
> > +
> > +        Reviewed by Holger Freyther
> 
> ^^ haha ;)
Psst :-)

> 
> > +void WMLDoElement::defaultEventHandler(Event* event)
> 
> I assume that you look at the right events?! But if you don't I'm pretty sure
> you will find that out sooner than later.
Yes, we'll find out soon - it worked this way in the internal codebase, so maybe it's correct as is already :-)

> 
> > +
> > +    Node* parent = parentNode();
> > +    ASSERT(parent);
> > +
> > +    if (!parent || !parent->isWMLElement())
> > +        return;
> 
> Before landing decide if the parentNode might be zero or not and then remove
> the assert or the !parent from the if?
Ok, as we discussed on IRC, there are 6 other places with exactly the same snippet. Will clean that up in another patch for all of them.
 
> > +    bool m_isOption;
> 
> maybe call it m_isOptional? but that is optional...
Done.

> from a grep in the source tree it looks like you uncommented all doTag users...
Yes.

Thanks for the review, landing soon.
Comment 7 Nikolas Zimmermann 2008-11-28 18:52:25 PST
Landed in r38837.