• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Buggy WO Doc with performParentAction
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Buggy WO Doc with performParentAction


  • Subject: Buggy WO Doc with performParentAction
  • From: Wolfram Stebel <email@hidden>
  • Date: Wed, 8 Sep 2004 08:32:33 +0200

Hello all,

the following block is the doc for performParentAction:

---

An example best illustrates this mechanism. Let's say there is a Palette subcomponent, and this WOComponent is nested in a parent component with a displaySelection action method. When the user selects an item in the palette (perhaps a color), you want to invoke displaySelection to show the result of the new selection (perhaps a car in the new color). The declaration in the parent's .wod file would look like this:

 PALETTE: Palette {
   selection = number;
   callBack = "displaySelection";
 };


The "callBack" item is an arbitrary attribute of the child component bound in this declaration to the parent component's displaySelection method. The performParentAction method is used to activate this binding. Assuming the child component has an action method called click, the implementation would look like this:


 public WOActionResults click() {  // this is the child's action
   selection = "xxxx"; // some value
   // now invoke the parent's action
   return performParentAction(callBack);
 }

---

This does not work as expected. Instead i have to get the binding myself.


callBack = ( String ) valueForBinding ( "callBack" ); WOActionResults war = performParentAction ( callBack );

Is that true, or am i missing some essential information?

Thanks

Wolfram Stebel
Mailto: email@hidden
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.


  • Prev by Date: IE 6 SP2 problem
  • Next by Date: Problem with dynamic downloads on IE on windows
  • Previous by thread: IE 6 SP2 problem
  • Next by thread: RE: Buggy WO Doc with performParentAction
  • Index(es):
    • Date
    • Thread