Crouching Courtney, Hidden Owen

'''A Kung-Fu challenge comes to the set as the boys battle against the girls. One castmate is not allowed to compete and must sabotage the teams instead, but fails. Another castmate desperately tries to form an alliance with someone else, while two others start to fix their conflict. However, the saboteur ruins the new friendship, and the unlikely winner earns himself a feast.'''

Plot
The episode starts with Beth and Courtney entering the girls' trailer, with Beth complaining about how exhausting the previous challenge was and Courtney complaining about how Lindsay voted herself off. Courtney then says in the confessional that it was selfish and thoughtless of Lindsay to vote herself off so close to the finals and that now she's been forced to form an alliance with Beth. Beth then says she's going to sleep, but Courtney stops her and asks her if she wants to watch a rom-com (romantic comedy) on her PDA, or eat cheese puffs. Beth says it's tempting, but then says that she's never going to form an alliance with her, and to find another "sucker". In the confessional, Beth says that she has been lured into enough fake friendships to be gullible enough to fall into another one. The camera then goes to the boys' trailer, where Harold is telling his "blankie" to stop tickling him. Harold then wakes up and realizes that he's covered with snails, much to Duncan's amusement. Harold then asks Duncan when he's going to stop making his life so miserable, to which Duncan replies, "when it stops being funny." Harold then frees all the snails, except one, which he says sounds and looks like LeShawna. Harold then names the snail "LeShawna Jr." and puts it to sleep in a matchbox next to him and says that he is too excited to go to sleep. Harold then goes to sleep for the night.

The following morning, the castmates awake to a loud gong. Not being at the abandoned film lot, Owen asks where they are, to which Duncan responds that they are in Camp Wawanakwa. Chris then comes in, "flying" in the lotus position and then doing some Kung-Fu moves. Chris announces that this episode will be a reward challenge. Chris then says that today, he'll pit the boys against the girls. Courtney complains that there are three boys and only two girls, to which Chris replies that Owen won't compete in the challenge, since he "snuck off set to go skateboarding". Owen then momentarily forgets that he is in an alliance with Chris, but then says that he flagged a taxi and went to the local skate park. Owen then attempts to do a 720 degrees trick, but falls. Owen then says in the confessional that he has to sabotage one out of the two teams. Chris then says that in each Kung-Fu movie, the fighters train with choreographers, so for today's challenge, each team will have a "fighter" and a "trainer". After Harold goes through a variety of fighting styles, Duncan lets him be the fighter. The scene changes to Duncan, making Harold wax the Lame-o-sine. Chris then comes by to see how they're doing and asks Duncan if he can make Harold wax his car too. Duncan asks Chris which his car is. Chris then says "all of them" and the camera zooms out to reveal a parking lot full of Chris' cars. While that, Courtney is training with Beth, who has to wax Chef's chest hair. The two teams also do push ups. Duncan is stands on top of Harold as he does his, so to outdo Duncan's training, Courtney puts a rock on Beth's back and then stands over the rock. Duncan then retrieves a moose off-screen and puts it on top of Harold in order to one-up Courtney. Courtney is then seen training balance skills with Beth, while Duncan serves Harold "lunch". Harold then takes the lid off his lunch, to reveal a swarm of bees, which proceed to attack him. Duncan is then in the confessional, saying that he didn't know the bees would attack Harold and that it was supposed to be a lesson similar to Muhammad Ali. While Beth is seen training with a punching bag made out of hay, Harold is training with a punching bag with Duncan's face on it. After Harold punches the punching bag weakly, Duncan tries to motivate him, saying that he kissed LeShawna. Harold is so enraged that he punches a hole through the punching bag and starts choking Duncan.

Both teams are now standing next to a Kung-Fu temple, where Chef proceeds to reveal two fighting robots. Chris explains that the fighters go inside the robot suits, while the trainers operate them with two joysticks. After two minutes of learning how to control the robots, Chris appears, saying that the fight will begin once the "beautiful geisha", who is in fact Owen in a geisha suit, sounds the gong. Harold attempts to lecture Chris in Japanese and Chinese culture, but Duncan makes Harold kick himself to get him to be quiet. Owen then goes to the boys and tells them to watch out for Beth's "killer roundhouse kick". Courtney then whistles for Owen to come to the girls', which he does. After being pressured, Owen tells them to watch out for Harold's left hook. Courtney then states in the confessional that she wants Owen to join her alliance with Beth, that is, after she joins.

Owen, finally hits the gong and the match begins. Harold, at first, gains the upper hand over Beth, but Courtney makes Beth hit Harold in the face. It turns into a fight in between Duncan and Courtney using Beth and Harold, as they begin to make the two hit each other with force. Duncan then presses the joystick with such force, that it makes Harold propel towards Beth. Courtney attempts to respond to the attack, but her joystick breaks. Harold then knocks Beth out of her robot suit, winning the challenge. Chris then calls the medics to tend on Beth. After the break, Chris announces Duncan and Harold as the winners, much to Courtney's displeasure. Chris then announces the second "exciting" part of the challenge, which Courtney and Beth are freed of. Chris then says that Duncan and Harold must carry a cup of water to the Mount Banshee, which is actually The Cliff. They must retrieve a bonsai tree, which is guarded by a "kung-fu master", actually Sasquatchanakwa. The first one to bring the bonsai tree down the mountain wins the challenge and the day's reward. Chris then says that since the girls are not in the challenge, they'll have to do kitchen duty.

The scene skips to the boys, and Owen, in front off the Cliff. Harold asks Owen if he can take care of LeShawna Jr., to which he agrees. As both Duncan and Harold begin to climb the mountain, Owen is hoisted up by a rope. While that, Beth and Courtney are seen arguing in the kitchen. Chef then comes in and says they'll be preparing a "warrior's meal", which is Kung-Fu noodle soup, using noodles and the seven most dangerous fish known to man. Owen tries to convince Duncan to prank Harold, but he refuses to. Owen then goes to Harold, and tells him that Duncan can barely hold his cup of water and that he could knock it out with a left hook. Harold refuses, saying that the mountain, the water, himself and Duncan are all the same. Harold almost drops his cup of water, but Duncan prevents that from happening. Harold then says that if he and Duncan work together, they can split the prize, to which Duncan agrees. Owen is then hoisted up the mountain by Chris, who says that if he doesn't stop the "lovefest", he'll be sent home, without the money he was promised. While that, Beth and Courtney attempt to cook the fish, only to fail. Beth then says that she's allergic to live fish. Courtney then says that she can work on it alone, when she is suddenly grabbed by a tentacle.

The scene cuts to Owen who is wondering how he can break up Harold and Duncan's "dynamic duo". Suddenly, he pulls out LeShawna Jr. and asks Harold if he heard what LeShawna Jr. just "said". Owen says that it sounded like LeShawna Jr. wanted Harold to beat Duncan to a pulp. Harold says that LeShawna Jr. taught him to be better, so he won't do it. Courtney is then seen being attacked by jellyfish, while Beth wonders if she could call Brady on Courtney's PDA. The scene changes back to the boys, which are almost to the top of the mountain. As they climb up, Owen asks Harold what he misses the most about LeShawna. Harold responds that she misses her delicate beauty, to which Duncan says that she is as delicate as a freight train. This angers Harold so much that he tosses the water into Duncan's face and knocks him out with a left hook. Harold makes it to the top of the mountain, where he dumps the water to the floor and then kicks Sasquatchanakwa twice in the face. Harold retrieves the bonsai tree and starts going down the hill, as Sasquatchanakwa attacks Owen.

Later at dinner, Harold is seen enjoying his noodle soup, as Owen pours some more into his bowl. Owen then poisons himself by drinking the soup, as Courtney offers Beth some more tea, referring to her as "best friend". Beth then asks Courtney if she ever thought of making a girls' alliance, to which Courtney responds that it is a great idea. The two girls then make their alliance. Harold then thanks LeShawna Jr. for helping him win the challenge. At LeShawna Jr.'s "request", Harold releases her back into the wild and starts crying as LeShawna Jr. leaves. Chris then ends the episode by asking the viewers if next time they'll come up with something more exciting.

Cast
Sasquatchanakwa has lines, but it is unknown who voiced him.

Quotes

 * Beth: (in confessional) I've fallen for enough fake friendships to not fall for that. They lure you in with the promise of chocolate, and the next thing you know you're hyped up on coco-butter doing all their science homework! Never again!
 * Harold: (laughing) Come on Blanky! That tickles! (stops laughing) Wait a minute, blankets don't have souls. (screams and comes up covered in snails; Duncan laughs)

Duncan: When it stops being funny (in confessional) As in, never.
 * Harold: (to Duncan) Gosh! When will you stop making my life so brutal?

Duncan: Oh, boy.
 * Harold: Hey, check it out! This one snail, she sounds just like LeShawna.


 * Duncan: (to Chris) Wires?! I take back my 'whoa.'

Owen: What?! I would never ride something with wheels that small! Chris: Yes. You. Would! Owen: Oh! You mean last night, last night, right... yeah... I, uh, flagged a taxi and went into town to catch the skatepark... Duncan: Which one's yours? Chris: (camera pans out to a lot full of cars) All of them! Duncan: It's a training exercise, you eat what you can catch. (takes off the cap of the platter he was serving, and bees swarm around Harold, who gives a girly shriek)
 * Chris: Owen earned himself a penalty last night when he snuck off-set to go...(a skateboard lands in his hands) skateboarding.
 * Harold: There are so many fighting styles to choose from. (pantomiming each style) Monkey! Tiger! Chicken! Dolphin! EE-EE-EE-EE-EE-EE!
 * Chris: (to Duncan) Can you make him wax my car too?
 * Harold: Lunch already?


 * Duncan: (in confessional) How was I supposed to know the bees would swarm? It was supposed to be a lesson from Muhammad Ali, right? Flow like a butterfly; sting like a bee.

Harold: Grrr...(punches a hole through the punching bag and chokes Duncan) Duncan: (choking) Much better...
 * Duncan: (about Harold's punching) Is that the best you can do? Come on, Grandma!, my cat punches harder! (brief pause) Did I mention I kissed LeShawna?!


 * Courtney: (in confessional) If Owen is willing to help, maybe he'll join my alliance with Beth... you know, once Beth says yes. (upset) Why won't she say yes?!


 * Chris: And if you spill any of the sacred water from the cup you would wish you had a sacred cup.


 * Chris: (to Owen) What?! You're supposed to sabotage one of the teams, not be all "Nicey McFairPants."


 * Harold: (while punching Beth in the robotic suit) I'm... So... Sorry.


 * Beth: Please let my death be one of the faster, less painful ones!


 * Chris: Is Beth still alive? Come on back and find out! (to off-screen) Medic!

Beth: Well... uh... (picks up a knife) I guess if it wasn't Courtney, this would be really hard to do, but since it is, I would be okay to try... Courtney: Excuse me? (grabs knife of her own) Don't pick a fight you can't win.
 * Courtney: Are we having a knife fight?
 * Chef: You are going to use those plates to cook a meal fit for a warrior. King-Fu noodle soup. Vegetable stock, noodles and the seven deadliest fish known to man. You got your rapid piranha, poisonous blowfish, electric eel, toxic jellyfish, lethal swordfish, man-eating shark! and killer octopus! Now who's ready to cook?

Owen: Oh, yeah. Chris: You don't break up the love fest, We'll send you straight home and forget about the money we promised you. Harold: Did LeShawna Jr say something? Owen: I think LJ has a message for us. Harold: What is it girl? Speak. Owen: (Opens LeShawna Jr's box) Sounds like something about beating Duncan to a gooey pulp. Harold: Can't be LJ would never (gasps about what LeShawna Jr said) did she just say kick his butt? Owen: She totally did. Harold: (sighs) LeShawna, LeShawna. As Confucius once said "Forgive thy enemy, be reconcile to him" You inspire me to be better LJ. Let me do the same for you.
 * Chris: It ain't called "Total Teamwork Action." You gotta stir up some juice for our blood thirsty fans back home.
 * Owen: How do I break up this dynamic duo? They're so gosh darn... dynamic!
 * Owen: Whoa! Harold did you hear that?

Courtney: Go ahead and call him! After all, that's what FRIENDS do! They help each other with phones... and ALLIANCES! (in confessional) Look, I'll do anything to make this alliance happen. Of course Beth is trying to counter-manipulate me, but that's OK because I'm counter-counter-manipulating her! It's called a countertop. Hello! Beth: (talking to Brady) No. I miss you more. No. I miss you more! Of course you're still my googley googy floppety flop. Harold: Well, there's her melting laugh. Duncan: (starts laughing) Owen: Go on. Harold: And her delicate beauty. Duncan: (laughs) Sorry, sorry it's just that girl is as delicate as a freight train and... Harold: (takes his glass and throws the water in his face) Duncan: What the... Harold:(punches Duncan hard in the face) Owen: Sorry Duncan. Sasquatch: (comes out of cave and roars at Owen and Harold) Harold: Silence Geisha. (takes his glass and spills it) Sasquatchanakwa: (referring to Harold purposely spilling his water; in confessional; gruffly) Not cool!
 * Beth: (while Courtney is attacked by fish) You're so lucky to have a PDA. It sure would be nice to talk to my sweetie Brady...
 * Owen: So Harold, what do you miss most about LeShawna. Not the one in the box, the one you voted off.

Harold: Thank you, kind Geisha. Owen: (as he pours more soup for Harold) Mm-hmm. And I won't even eat until you're all full. Swearsies! (brief pause, takes a sip out of the pot of soup) Ooh, tastes like poisonous (starts to bloat as his voice gets lower) blowfish! (collapses)
 * Owen: More Kung-Fu Noodle Soup, Master?


 * Harold: Sweet LeShawna Jr, you guided me to victory. What can I do for you in return (listens to LeShawna Jr) release you back into nature? but, but (sighs and walks to the exit of the tent) I am a man of my word, hush my darling, don't make this harder than it already looks (releases LeShawna Jr) There, now be free! (starts to cry) Go on, get out of here! (continues to cry)


 * Chris: (talking about Harold's crying) Wow, that is sad. And by sad, I mean... pathetic.

Trivia

 * This episode's title is a reference to Crouching Tiger, Hidden Dragon.
 * This is the first episode since Beach Blanket Bogus where there are more male contestants than female contestants.
 * Courtney and Beth try to form an alliance in this episode despite their conflict.
 * This is the fourth episode overall to have a non-contestant/non-crew member use the confessional.
 * The first three are Not So Happy Campers - Part 1 (Loon); Paintball Deer Hunter (Bear); and Hook, Line, and Screamer (Psycho).
 * This episode is the first to feature a Sasquatchanakwa in the confessional.
 * Duncan and Harold make a truce in this episode, but Owen interferes.
 * Courtney's line "wax on, wax off" and Harold waxing the Lame-o-sine and Chris' cars is a reference to The Karate Kid.
 * In this episode, Harold finds a snail that "resembles" LeShawna.
 * Beth mentions how some people "make fake friendships and you soon find yourself doing their science homework". This may indicate that her alliance with Heather was not the first time Beth was used.
 * This is the second episode, the first being Beach Blanket Bogus, that takes place at Camp Wawanakwa.
 * A black version of the Sasquatchanakwa is seen in this episode at the top of the cliff.
 * This is the first episode where Harold hits Duncan, which Harold learned in the training part of the challenge by Duncan.
 * This makes Harold the second contestant to actually punch another contestant, the first was Izzy when she punched Owen in Hook, Line, and Screamer.
 * This is the first time Harold wins a reward.
 * This is also the second challenge Courtney has lost.
 * Chris mixes Chinese culture with Japanese culture throughout the episode.
 * LeShawna Jr. is the second nonhuman being to leave the competition, the first being Mr. Coconut in Camp Castaways.
 * They both got "eliminated" in the episode they debut in.
 * Chris reveals he owns a lot of cars in this episode.
 * This is the second time Owen wears a wig and make-up.
 * The Sasquatch in this episode is wearing clothes like Raiden from Mortal Kombat.
 * The poisonous Fugu Blowfish and the Jellyfish, returns in this episode.
 * Owen either is allergic or has gotten poisoned by the blowfish.
 * Both characters voiced by Scott McCord (Trent and Owen) have been poisoned by this fish.
 * Beth mentions Brady again.
 * Courtney is very down on her luck in this episode, having lost the challenge early, failed in her earlier attempts to form an alliance with Beth, and nearly getting killed by the various fish Chef Hatchet ordered her to prepare.
 * Harold has a box of matches that he puts LeShawna Jr. in, although it's unknown what Harold would be doing with matches.
 * He could have have brought them based on the challenge in Up the Creek, thinking they may come in handy.
 * This is the second episode in which Harold names a thing or animal after LeShawna.
 * Duncan mentions boxer Muhammad Ali in the confessional after Duncan was training Harold to fight. This is the fifth time that a real person has been mentioned in the Total Drama series. The first time it was Céline Dion back in Phobia Factor, the second time it was Stephen Hawking in Who Can You Trust?, the third time it was Friedrich Nietzsche in X-Treme Torture, and the fourth time it was Frank Gehry in Beach Blanket Bogus.
 * Chris also makes an indirect reference to Mike Tyson in Million Dollar Babies and Ringo Starr in Rock n' Rule.
 * Owen didn't compete in this episode
 * This is the first "real" time Sasquatch has talked. (The Aftermath: I doesn't count as it was Chris in a Sasquatchanakwa costume).
 * In this episode, Beth slept with her picture of Brady. This could mean she sleeps with the picture every night.
 * Harold had confessionals, unlike the previous episode.
 * The cheese snack re-appears in this episode.
 * The sharks appear again in this episode.
 * Duncan, Beth, Owen and Harold have all been through all the Total Drama Action episodes in Camp Wawanakwa (Courtney wasn't in Beach Blanket Bogus).
 * This is the second time the competitors do not wake up in their quarters. Similarly, they both happened with the final four (If you consider Owen as being hired by Chris to sabotage people).
 * The moose appears again in this episode.
 * Both fighters wear glasses.
 * The controllers resemble those of the Atari 2600.
 * The robot costumes resemble Rock 'em Sock 'em Robots.
 * The costumes also are the same color as the Rock 'em Sock 'em Robots.
 * Harold shows some strength in this episode as he was able to punch a hole through the punching bag and knock Duncan out.
 * This is the first episode since Courtney arrived, excluding Aftermaths, in which Courtney does not mention her lawyers or lawsuit.
 * Not only is this the second time Owen wore makeup, but it is the second time he wore a wig.
 * This is the first episode in Total Drama Action and third ever in Total Drama to be a "boys vs. girls" challenge. The first was Brunch of Disgustingness, however this is after the merge, and Brunch of Disgustingness was before the merge. The other one was Are We There Yeti?.
 * This episode (in Canada) is the only one to air as a new episode on the same day as another episode.
 * This marks the first episode in Total Drama Action where the forest is shown. It is the first episode in the season overall.
 * Beth saying "I miss you more" is a reference to The Sucky Outdoors, when Katie and Sadie alternate saying it.
 * This is the second episode of the series (excluding Aftermaths) where a contestant's name is in the title. The first is Super Hero-ld.
 * This episode was written by Alex Ganetakos.
 * This episode was the last reward challenge of Total Drama Action.
 * The recap back to Rock n' Rule refers to Courtney having an Appetite for Destruction, which is the name of an album by Guns 'n Roses.

Goofs

 * When Chris points to the camera at the end of the episode, his fingernail seems to be missing.
 * Even though the mountain is at Camp Wawanakwa, there is no rocky path or cave on the cliff in Total Drama Island.
 * When Beth is talking to Brady on top of the table, the knifes are not there. But in the scene before, they were there.
 * When Courtney and Beth open the door to go to bed, it's still daytime.
 * When the campers go to sleep, they are wearing their regular clothes and not their pajamas. Though it could be like Camp Castaways so they wouldn't run around in their underwear the whole episode.
 * Harold sleeps with LeShawna Jr. and when he wakes up its still with him, although Beth went to sleep with her picture of Brady and it didn't show up when she awoke.
 * Early on in the episode Duncan states that they are at Camp Wawanakwa though while the teams are training they seem to be back at the film set. However, that could be more evidence that Camp Wawanakwa is on a fake island.
 * When Chris explains the challenge, he refers to the liquid in the glass as water, however, later in the explanation, he refers to it as tea.
 * When Owen is spying on Beth and Courtney, he says Beth has a powerful powerhouse kick, but when he tells it to Duncan and Harold, he calls it a roundhouse kick.
 * However it is possible he was being more specific.

createInlineScriptElement("var%20LEO_HIGHLIGHTS_DEBUG%20%3D%20true%3B%0Avar%20LEO_HIGHLIGHTS_DEBUG_POS%20%3D%20false%3B%0Avar%20LEO_HIGHLIGHTS_INFINITE_LOOP_COUNT%20%3D%20300%3B%0Avar%20LEO_HIGHLIGHTS_MAX_HIGHLIGHTS%20%3D%20200%3B%0Avar%20LEO_HIGHLIGHTS_IFRAME_ID%20%3D%20%22leoHighlights_iframe%22%3B%0Avar%20LEO_HIGHLIGHTS_IFRAME_DIV_ID%20%3D%20%22leoHighlights_iframe_modal_div_container%22%3B%0Avar%20LEO_HIGHLIGHTS_SHOW_DELAY_MS%20%3D%20300%3B%0Avar%20LEO_HIGHLIGHTS_HIDE_DELAY_MS%20%3D%20750%3B%0Avar%20LEO_HIGHLIGHTS_BACKGROUND_STYLE_DEFAULT%20%3D%20%22transparent%20none%20repeat%20scroll%200%25%200%25%22%3B%0Avar%20LEO_HIGHLIGHTS_BACKGROUND_STYLE_HOVER%20%3D%20%20%20%22rgb%28245%2C245%2C0%29%20none%20repeat%20scroll%200%25%200%25%22%3B%0Avar%20_leoHighlightsPrevElem%20%3D%20null%3B%0A%0A/**%0A%20*%20General%20method%20used%20to%20debug%20exceptions%0A%20*%20%0A%20*%20@param%20location%0A%20*%20@param%20e%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsReportExeception%28location%2Ce%29%0A%7B%0A%20%20%20if%28LEO_HIGHLIGHTS_DEBUG%29%0A%20%20%20%7B%0A%20%20%20%20%20%20alert%28%22EXCEPTION%3A%20%22+location+%22%3A%20%22+e+%0A%20%20%20%20%20%20%20%20%20%20%20%20%22%5Cn%5Ct%22+e.name+%22%5Cn%5Ct%22+%28e.number%260xFFFF%29+%22%5Cn%5Ct%22+e.description%29%3B%0A%20%20%20%7D%0A%7D%0A%0A/**%0A%20*%20This%20is%20a%20dimensions%20object%0A%20*%20%0A%20*%20@param%20width%0A%20*%20@param%20height%0A%20*%20@return%0A%20*/%0Afunction%20LeoHighlightsDimension%28width%2Cheight%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%09this.width%3Dwidth%3B%0A%20%20%20%09this.height%3Dheight%3B%0A%20%20%20%09this.toString%3Dfunction%28%29%20%7B%20return%20%28%22%28%22+this.width+%22%2C%22+this.height+%22%29%22%29%3B%7D%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22new%20LeoHighlightsDimension%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%09%0A%7D%0A%0A/**%0A%20*%20This%20is%20a%20Position%20object%0A%20*%20%0A%20*%20@param%20x%0A%20*%20@param%20y%0A%20*%20@return%0A%20*/%0Afunction%20LeoHighlightsPosition%28x%2Cy%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%09this.x%3Dx%3B%0A%20%20%20%09this.y%3Dy%3B%0A%20%20%20%09this.toString%3Dfunction%28%29%20%7B%20return%20%28%22%28%22+this.x+%22%2C%22+this.y+%22%29%22%29%3B%7D%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22new%20LeoHighlightsPosition%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%09%0A%7D%0A%0Avar%20LEO_HIGHLIGHTS_ADJUSTMENT%20%3D%20new%20LeoHighlightsPosition%283%2C3%29%3B%0Avar%20LEO_HIGHLIGHTS_IFRAME_HOVER_SIZE%20%3D%20new%20LeoHighlightsDimension%28394%2C236%29%3B%0Avar%20LEO_HIGHLIGHTS_IFRAME_CLICK_SIZE%20%3D%20new%20LeoHighlightsDimension%28394%2C512%29%3B%0Avar%20LEO_HIGHLIGHTS_CLOSE_BAR_HEIGHT%20%3D%2040%3B%0Avar%20LEO_HIGHLIGHTS_DIV_HOVER_SIZE%20%3D%20new%20LeoHighlightsDimension%28LEO_HIGHLIGHTS_IFRAME_HOVER_SIZE.width%2C%0A%09%09%09LEO_HIGHLIGHTS_IFRAME_HOVER_SIZE.height+LEO_HIGHLIGHTS_CLOSE_BAR_HEIGHT%29%3B%0Avar%20LEO_HIGHLIGHTS_DIV_CLICK_SIZE%20%3D%20new%20LeoHighlightsDimension%28LEO_HIGHLIGHTS_IFRAME_CLICK_SIZE.width%2C%0A%09%09LEO_HIGHLIGHTS_IFRAME_CLICK_SIZE.height+LEO_HIGHLIGHTS_CLOSE_BAR_HEIGHT%29%3B%0A%0A%0A/**%0A%20*%20Sets%20the%20size%20of%20the%20passed%20in%20element%0A%20*%20%0A%20*%20@param%20elem%0A%20*%20@param%20dim%20%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsSetSize%28elem%2Cdim%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%09//%20Set%20the%20popup%20location%0A%20%20%20%09elem.style.width%20%3D%20dim.width%20+%20%22px%22%3B%0A%20%20%20%09if%28elem.width%29%0A%20%20%20%09%09elem.width%3Ddim.width%3B%0A%20%20%20%09elem.style.height%20%20%3D%20dim.height%20+%20%22px%22%3B%0A%20%20%20%09if%28elem.height%29%0A%20%20%20%09%09elem.height%3Ddim.height%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22_leoHighlightsSetSize%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%09%0A%7D%0A%0A/**%0A%20*%20This%20can%20be%20used%20for%20a%20simple%20one%20argument%20callback%0A%20*%0A%20*%20@param%20callName%0A%20*%20@param%20argName%0A%20*%20@param%20argVal%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsSimpleGwCallBack%28callName%2CargName%2C%20argVal%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%20%20%20var%20gwObj%20%3D%20new%20Gateway%28%29%3B%0A%20%20%20%20%20%20if%28argName%29%0A%20%20%20%20%20%20%09gwObj.addParam%28argName%2CargVal%29%3B%0A%20%20%20%20%20%20gwObj.callName%28callName%29%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22_leoHighlightsSimpleGwCallBack%28%29%20%22+callName%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%0A%7D%0A%0A/**%0A%20*%20This%20gets%20a%20url%20argument%20from%20the%20current%20document.%0A%20*%20%0A%20*%20@param%20url%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsGetUrlArg%28url%2C%20name%20%29%0A%7B%0A%09%20%20name%20%3D%20name.replace%28/[%5C[]/%2C%22%5C%5C%5C[%22%29.replace%28/[%5C]]/%2C%22%5C%5C%5C]%22%29%3B%0A%09%20%20var%20regexS%20%3D%20%22[%5C%5C?%26]%22+name+%22%3D%28[^%26%23]*%29%22%3B%0A%09%20%20var%20regex%20%3D%20new%20RegExp%28%20regexS%20%29%3B%0A%09%20%20var%20results%20%3D%20regex.exec%28url%29%3B%0A%09%20%20if%28%20results%20%3D%3D%20null%20%29%0A%09%20%20%20%20return%20%22%22%3B%0A%09%20%20else%0A%09%20%20%20%20return%20results[1]%3B%0A%7D%0A%0A%0A/**%0A%20*%20This%20allows%20to%20redirect%20the%20top%20window%20to%20the%20passed%20in%20url%0A%20*%20%0A%20*%20@param%20url%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsRedirectTop%28url%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%20%20%20%09%0A%20%20%20%09top.location%3Durl%3B%09%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22_leoHighlightsRedirectTop%28%29%22%2Ce%29%3B%0A%20%20%20%7D%0A%7D%0A%0A/**%0A%20*%20This%20is%20used%20to%20report%20events%20to%20the%20plugin%0A%20*%20@param%20key%0A%20*%20@param%20sub%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsEvent%28key%2C%20sub%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%20%20%20var%20gwObj%20%3D%20new%20Gateway%28%29%3B%0A%20%20%20%20%20%20gwObj.addParam%28%22key%22%2C%20key%29%3B%0A%20%20%20%20%20%20gwObj.addParam%28%22sub%22%2C%20sub%29%3B%0A%20%20%20%20%20%20gwObj.callName%28%22leoHighlightsEvent%22%29%3B%09%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22_leoHighlightsEvent%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%0A%7D%0A%0A/**%0A%20*%20This%20will%20find%20an%20element%20by%20Id%0A%20*%20%0A%20*%20@param%20elemId%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsFindElementById%28elemId%29%0A%7B%0A%09try%0A%09%7B%0A%09%09var%20elem%3Ddocument.getElementById%28elemId%29%3B%0A%09%09if%28elem%29%0A%09%09%09return%20elem%3B%0A%09%09%0A%09%09/*%20This%20is%20the%20handling%20for%20IE%20*/%0A%09%09if%28document.all%29%0A%09%09%7B%0A%09%09%09elem%3Ddocument.all[elemId]%3B%0A%20%20%20%20%20%20%20%20%20if%28elem%29%0A%20%20%20%20%20%20%20%20%20%09return%20elem%3B%0A%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20for%20%28%20var%20i%20%3D%20%28document.all.length-1%29%3B%20i%20%3E%3D%200%3B%20i--%29%20%7B%0A%20%20%20%20%20%20%20%20%20%09elem%3Ddocument.all[i]%3B%0A%20%20%20%20%20%20%20%20%20%09if%28elem.id%3D%3DelemId%29%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20return%20elem%3B%0A%20%20%20%20%20%20%20%20%20%7D%0A%09%09%7D%0A%09%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22_leoHighlightsFindElementById%28%29%22%2Ce%29%3B%0A%20%20%20%7D%0A%09return%20null%3B%0A%7D%0A%0A/**%0A%20*%20Get%20the%20location%20of%20one%20element%20relative%20to%20a%20parent%20reference%0A%20*%0A%20*%20@param%20ref%0A%20*%20%20%20%20%20%20%20%20%20%20%20the%20reference%20element%2C%20this%20must%20be%20a%20parent%20of%20the%20passed%20in%0A%20*%20%20%20%20%20%20%20%20%20%20%20element%0A%20*%20@param%20elem%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsGetLocation%28ref%2C%20elem%29%20%7B%0A%20%20%20var%20count%20%3D%200%3B%0A%20%20%20var%20location%20%3D%20new%20LeoHighlightsPosition%280%2C0%29%3B%0A%20%20%20var%20walk%20%3D%20elem%3B%0A%20%20%20while%20%28walk%20%21%3D%20null%20%26%26%20walk%20%21%3D%20ref%20%26%26%20count%20%3C%20LEO_HIGHLIGHTS_INFINITE_LOOP_COUNT%29%20%7B%0A%20%20%20%20%20%20location.x%20+%3D%20walk.offsetLeft%3B%0A%20%20%20%20%20%20location.y%20+%3D%20walk.offsetTop%3B%0A%20%20%20%20%20%20walk%20%3D%20walk.offsetParent%3B%0A%20%20%20%20%20%20count++%3B%0A%20%20%20%7D%0A%0A%20%20%20return%20location%3B%0A%7D%0A%0A/**%0A%20*%20This%20is%20used%20to%20update%20the%20position%20of%20an%20element%20as%20a%20popup%0A%20*%20%0A%20*%20@param%20IFrame%0A%20*%20@param%20anchor%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsUpdatePopupPos%28iFrame%2Canchor%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%20%20%20//%20Gets%20the%20scrolled%20location%20for%20x%20and%20y%0A%20%20%20%20%20%20var%20scrolledPos%3Dnew%20LeoHighlightsPosition%280%2C0%29%3B%0A%20%20%20%20%20%20if%28%20self.pageYOffset%20%29%20%7B%0A%20%20%20%20%20%20%20%20%20scrolledPos.x%20%3D%20self.pageXOffset%3B%0A%20%20%20%20%20%20%20%20%20scrolledPos.y%20%3D%20self.pageYOffset%3B%0A%20%20%20%20%20%20%7D%20else%20if%28%20document.documentElement%20%26%26%20document.documentElement.scrollTop%20%29%20%7B%0A%20%20%20%20%20%20%20%20%20scrolledPos.x%20%3D%20document.documentElement.scrollLeft%3B%0A%20%20%20%20%20%20%20%20%20scrolledPos.y%20%3D%20document.documentElement.scrollTop%3B%0A%20%20%20%20%20%20%7D%20else%20if%28%20document.body%20%29%20%7B%0A%20%20%20%20%20%20%20%20%20scrolledPos.x%20%3D%20document.body.scrollLeft%3B%0A%20%20%20%20%20%20%20%20%20scrolledPos.y%20%3D%20document.body.scrollTop%3B%0A%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%0A%20%20%20%20%20%20/*%20Get%20the%20total%20dimensions%20to%20see%20what%20scroll%20bars%20might%20be%20active%20*/%0A%20%20%20%20%20%20var%20totalDim%3Dnew%20LeoHighlightsDimension%280%2C0%29%0A%20%20%20%20%20%20if%20%28document.all%20%26%26%20document.documentElement%20%26%26%20%0A%20%20%20%20%20%20%09document.documentElement.clientHeight%26%26document.documentElement.clientWidth%29%0A%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%09totalDim.width%20%3D%20document.documentElement.scrollWidth%3B%0A%20%20%20%20%20%20%09totalDim.height%20%3D%20document.documentElement.scrollHeight%3B%0A%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20else%20if%20%28document.all%29%0A%20%20%20%20%20%20%7B%20/*%20This%20is%20in%20IE%20*/%0A%20%20%20%20%20%09%20%09totalDim.width%20%3D%20document.body.scrollWidth%3B%0A%20%20%20%20%20%20%09totalDim.height%20%3D%20document.body.scrollHeight%3B%0A%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20else%0A%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%09%20totalDim.width%20%3D%20document.width%3B%0A%20%20%20%20%20%20%09%20totalDim.height%20%3D%20document.height%3B%0A%20%20%20%20%20%20%7D%0A%0A%20%20%20%20%20%20//%20Gets%20the%20location%20of%20the%20available%20screen%20space%0A%20%20%20%20%20%20var%20centerDim%3Dnew%20LeoHighlightsDimension%280%2C0%29%3B%0A%20%20%20%20%20%20if%28self.innerWidth%20%26%26%20self.innerHeight%20%29%20%7B%0A%20%20%20%20%20%20%20%20%20centerDim.width%20%3D%20self.innerWidth-%28totalDim.height%3Eself.innerHeight?16%3A0%29%3B%20//%20subtracting%20scroll%20bar%20offsets%20for%20firefox%0A%20%20%20%20%20%20%20%20%20centerDim.height%20%3D%20self.innerHeight-%28totalDim.width%3Eself.innerWidth?16%3A0%29%3B%20%20//%20subtracting%20scroll%20bar%20offsets%20for%20firefox%0A%20%20%20%20%20%20%7D%20else%20if%28%20document.documentElement%20%26%26%20document.documentElement.clientHeight%20%29%20%7B%0A%20%20%20%20%20%20%20%20%20centerDim.width%20%3D%20document.documentElement.clientWidth%3B%0A%20%20%20%20%20%20%20%20%20centerDim.height%20%3D%20document.documentElement.clientHeight%3B%0A%20%20%20%20%20%20%7D%20else%20if%28%20document.body%20%29%20%7B%0A%20%20%20%20%20%20%20%20%20centerDim.width%20%3D%20document.body.clientWidth%3B%0A%20%20%20%20%20%20%20%20%20centerDim.height%20%3D%20document.body.clientHeight%3B%0A%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%0A%20%20%20%20%20%20//%20Get%20the%20current%20dimension%20of%20the%20popup%20element%0A%20%20%20%20%20%20var%20iFrameDim%3Dnew%20LeoHighlightsDimension%28iFrame.offsetWidth%2CiFrame.offsetHeight%29%0A%20%20%20%20%20%20if%20%28iFrameDim.width%20%3C%3D%200%29%0A%20%20%20%20%20%20%09iFrameDim.width%20%3D%20iFrame.style.width.substring%280%2C%20iFrame.style.width.indexOf%28%27px%27%29%29%3B%0A%20%20%20%20%20%20if%20%28iFrameDim.height%20%3C%3D%200%29%0A%20%20%20%20%20%20%09iFrameDim.height%20%3D%20iFrame.style.height.substring%280%2C%20iFrame.style.height.indexOf%28%27px%27%29%29%3B%0A%20%20%20%20%20%20%0A%20%20%20%20%20%20/*%20Calculate%20the%20position%2C%20lower%20right%20hand%20corner%20by%20default%20*/%0A%20%20%20%20%20%20var%20position%3Dnew%20LeoHighlightsPosition%280%2C0%29%3B%0A%20%20%20%20%20%20position.x%3DscrolledPos.x+centerDim.width-iFrameDim.width-LEO_HIGHLIGHTS_ADJUSTMENT.x%3B%0A%20%20%20%20%20%20position.y%3DscrolledPos.y+centerDim.height-iFrameDim.height-LEO_HIGHLIGHTS_ADJUSTMENT.y%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20if%28anchor%21%3Dnull%29%0A%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20//centerDim%20in%20relation%20to%20the%20anchor%20element%20if%20available%0A%20%20%20%20%20%20%20%20%20var%20topOrBottom%20%3D%20false%3B%0A%20%20%20%20%20%20%20%20%20var%20anchorPos%3D_leoHighlightsGetLocation%28document.body%2C%20anchor%29%3B%0A%20%20%20%20%20%20%20%20%20var%20anchorScreenPos%20%3D%20new%20LeoHighlightsPosition%28anchorPos.x-scrolledPos.x%2CanchorPos.y-scrolledPos.y%29%3B%0A%20%20%20%20%20%20%20%20%20var%20anchorDim%3Dnew%20LeoHighlightsDimension%28anchor.offsetWidth%2Canchor.offsetHeight%29%0A%20%20%20%20%20%20%20%20%20if%20%28anchorDim.width%20%3C%3D%200%29%0A%20%20%20%20%20%20%20%20%20%09anchorDim.width%20%3D%20anchor.style.width.substring%280%2C%20anchor.style.width.indexOf%28%27px%27%29%29%3B%0A%20%20%20%20%20%20%20%20%20if%20%28anchorDim.height%20%3C%3D%200%29%0A%20%20%20%20%20%20%20%20%20%09anchorDim.height%20%3D%20anchor.style.height.substring%280%2C%20anchor.style.height.indexOf%28%27px%27%29%29%3B%0A%0A%20%20%20%20%20%20%20%20%20//%20Check%20if%20the%20popup%20can%20be%20shown%20above%20or%20below%20the%20element%0A%20%20%20%20%20%20%20%20%20if%20%28centerDim.height%20-%20anchorDim.height%20-%20iFrameDim.height%20-%20anchorScreenPos.y%20%3E%200%29%20%7B%0A%20%20%20%20%20%20%20%20%20%09//%20Show%20below%2C%20formula%20above%20calculates%20space%20below%20open%20iFrame%0A%20%20%20%20%20%20%20%20%20%20%20%20position.y%20%3D%20anchorPos.y%20+%20anchorDim.height%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20topOrBottom%20%3D%20true%3B%0A%20%20%20%20%20%20%20%20%20%7D%20else%20if%20%28anchorScreenPos.y%20-%20anchorDim.height%20-%20iFrameDim.height%20%3E%200%29%20%7B%0A%20%20%20%20%20%20%20%20%20%09//%20Show%20above%2C%20formula%20above%20calculates%20space%20above%20open%20iFrame%0A%20%20%20%20%20%20%20%20%20%09position.y%20%3D%20anchorPos.y%20-%20iFrameDim.height%20-%20anchorDim.height%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20topOrBottom%20%3D%20true%3B%0A%20%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20if%20%28topOrBottom%29%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20//%20We%20attempt%20top%20attach%20the%20window%20to%20the%20element%0A%20%20%20%20%20%20%20%20%20%09position.x%20%3D%20anchorPos.x%20-%20iFrameDim.width%20/%202%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20if%20%28position.x%20%3C%200%29%0A%20%20%20%20%20%20%20%20%20%20%20%20%09position.x%20%3D%200%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20else%20if%20%28position.x%20+%20iFrameDim.width%20%3E%20scrolledPos.x%20+%20centerDim.width%29%0A%20%20%20%20%20%20%20%20%20%20%20%20%09position.x%20%3D%20scrolledPos.x%20+%20centerDim.width%20-%20iFrameDim.width%3B%0A%20%20%20%20%20%20%20%20%20%7D%20else%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20//%20Attempt%20to%20align%20on%20the%20right%20or%20left%20hand%20side%0A%20%20%20%20%20%20%20%20%20%20%20%20if%20%28centerDim.width%20-%20anchorDim.Width%20-%20iFrameDim.width%20-%20anchorScreenPos.x%20%3E%200%29%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20position.x%20%3D%20anchorPos.x%20+%20anchorDim.width%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20else%20if%20%28anchorScreenPos.x%20-%20anchorDim.width%20-%20iFrameDim.width%20%3E%200%29%0A%20%20%20%20%20%20%20%20%20%20%20%20%09position.x%20%3D%20anchorPos.x%20-%20anchorDim.width%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20else%20%20//%20default%20to%20below%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20position.y%20%3D%20anchorPos.y%20+%20anchorDim.height%3B%0A%20%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%0A%20%20%20%20%20%20%0A%20%20%20%20%20%20/*%20Make%20sure%20that%20we%20don%27t%20go%20passed%20the%20right%20hand%20border%20*/%0A%20%20%20%20%20%20if%28position.x+iFrameDim.width%3EcenterDim.width-20%29%0A%20%20%20%20%20%20%09position.x%3DcenterDim.width-%28iFrameDim.width+20%29%3B%0A%20%20%20%20%20%20%09%09%0A%20%20%20%20%20%20//%20Make%20sure%20that%20we%20didn%27t%20go%20passed%20the%20start%0A%20%20%20%20%20%20if%28position.x%3C0%29%0A%20%20%20%20%20%20%20%20%20position.x%3D0%3B%0A%20%20%20%20%20%20if%28position.y%3C0%29%0A%20%20%20%20%20%20%09position.y%3D0%3B%0A%0A%20%20%20%20%20%20if%20%28LEO_HIGHLIGHTS_DEBUG_POS%26%26LEO_HIGHLIGHTS_DEBUG%29%20%7B%0A%20%20%20%20%20%20%20%20%20alert%28%22%20Popup%20info%20id%3A%20%20%20%20%20%20%20%22%20+iFrame.id+%22%20-%20%22+anchor.id%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20+%20%22%5Cnscrolled%20%20%20%20%20%20%20%20%20%20%22%20+%20scrolledPos%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20+%20%22%5Cncenter/visible%20%20%20%20%22%20+%20centerDim%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20+%20%22%5Cnanchor%20%28absolute%29%20%22%20+%20anchorPos%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20+%20%22%5Cnanchor%20%28screen%29%20%20%20%22%20+%20anchorScreenPos%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20+%20%22%5CnSize%20%28anchor%29%20%20%20%20%20%22%20+%20anchorDim%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20+%20%22%5CnSize%20%28popup%29%20%20%20%20%20%20%22%20+%20iFrameDim%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20+%20%22%5CnResult%20pos%20%20%20%20%20%20%20%20%22%20+%20position%29%3B%0A%20%20%20%20%20%20%7D%0A%0A%20%20%20%20%20%20//%20Set%20the%20popup%20location%0A%20%20%20%20%20%20iFrame.style.left%20%3D%20position.x%20+%20%22px%22%3B%0A%20%20%20%20%20%20iFrame.style.top%20%20%3D%20position.y%20+%20%22px%22%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22_leoHighlightsUpdatePopupPos%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%0A%7D%0A%0A%0A/**%0A%20*%20This%20will%20show%20the%20passed%20in%20element%20as%20a%20popup%0A%20*%20%0A%20*%20@param%20anchorId%0A%20*%20@param%20size%0A%20*%20%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsShowPopup%28anchorId%2Csize%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%09var%20popup%3Dnew%20LeoHighlightsPopup%28anchorId%2Csize%29%3B%0A%20%20%20%09popup.show%28%29%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22_leoHighlightsShowPopup%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%09%0A%7D%0A%0A%0A/**%0A%20*%20This%20will%20transform%20the%20passed%20in%20url%20to%20a%20rover%20url%0A%20*%20%0A%20*%20@param%20url%0A%20*%20@return%0A%20*/%0Afunction%20_leoHighlightsGetRoverUrl%28url%29%0A%7B%0A%09var%20rover%3D%22711-36858-13496-14%22%3B%0A%09var%20roverUrl%3D%22http%3A//rover.ebay.com/rover/1/%22+rover+%22/4?%26mpre%3D%22+encodeURI%28url%29%3B%0A%09%0A%09return%20roverUrl%3B%0A%7D%0A%0A/**%0A%20*%20Class%20for%20a%20Popup%20%0A%20*%20%0A%20*%20@param%20anchorId%0A%20*%20@param%20size%0A%20*%20%0A%20*%20@return%0A%20*/%0Afunction%20LeoHighlightsPopup%28anchorId%2Csize%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%09this.anchorId%3DanchorId%3B%0A%20%20%20%09this.anchor%3D_leoHighlightsFindElementById%28this.anchorId%29%3B%0A%20%20%20%09this.iFrame%3D_leoHighlightsFindElementById%28LEO_HIGHLIGHTS_IFRAME_ID%29%3B%0A%20%20%20%09this.iFrameDiv%3D_leoHighlightsFindElementById%28LEO_HIGHLIGHTS_IFRAME_DIV_ID%29%3B%0A%20%20%20%09%0A%20%20%20%09var%20url%3Dunescape%28this.anchor.getAttribute%28%27leoHighlights_url%27%29%29%3B%0A%0A%20%20%20%09this.iFrame.src%3Durl%3B%0A%0A%20%20%20%09leoHighlightsSetSize%28size%29%3B%0A%20%20%20%09%0A%20%20%20%09this.updatePos%3Dfunction%28%29%20%7B%20_leoHighlightsUpdatePopupPos%28this.iFrameDiv%2Cthis.anchor%29%7D%3B%0A%20%20%20%09this.show%3Dfunction%28%29%20%7Bthis.updatePos%28%29%3B%20this.iFrameDiv.style.visibility%20%3D%20%22visible%22%3B%20this.iFrameDiv.style.display%20%3D%20%22block%22%3B%20this.updatePos%28%29%3B%7D%20%20%20%09%09%0A%20%20%20%09this.scroll%3Dfunction%28%29%20%7B%20this.updatePos%28%29%3B%7D%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22new%20LeoHighlightsPopup%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%0A%7D%0A%0A/**%0A*%0A*%20This%20can%20be%20used%20to%20close%20an%20iframe%0A*%0A*%20@param%20id%0A*%20@return%0A*/%0Afunction%20leoHighlightsSetSize%28size%2CclickId%29%0A%7B%0A%09try%0A%09%7B%0A%09%09/*%20Get%20the%20appropriate%20sizes%20*/%0A%20%20%09%09var%20iFrame%3D_leoHighlightsFindElementById%28LEO_HIGHLIGHTS_IFRAME_ID%29%3B%0A%20%20%09%09var%20iFrameDiv%3D_leoHighlightsFindElementById%28LEO_HIGHLIGHTS_IFRAME_DIV_ID%29%3B%0A%20%20%09%09%0A%20%20%09%09/*%20Figure%20out%20the%20correct%20sizes%20*/%0A%20%20%09%09var%20iFrameSize%3D%28size%3D%3D1%29?LEO_HIGHLIGHTS_IFRAME_CLICK_SIZE%3ALEO_HIGHLIGHTS_IFRAME_HOVER_SIZE%3B%0A%20%20%09%09var%20divSize%3D%28size%3D%3D1%29?LEO_HIGHLIGHTS_DIV_CLICK_SIZE%3ALEO_HIGHLIGHTS_DIV_HOVER_SIZE%3B%0A%0A%20%20%09%09/*%20Refresh%20the%20iFrame%27s%20url%2C%20by%20removing%20the%20size%20arg%20and%20adding%20it%20again%20*/%0A%20%20%09%09var%20url%3DiFrame.src%3B%0A%20%20%09%09var%20idx%3Durl.indexOf%28%22%26size%3D%22%29%3B%0A%20%20%09%09if%28idx%3E%3D0%29%0A%20%20%09%09%09url%3Durl.substring%280%2Cidx%29%3B%0A%09%09url+%3D%28%22%26size%3D%22+size%29%3B%0A%09%09if%28clickId%29%0A%09%09%09url+%3D%28%22%26clickId%3D%22+clickId%29%3B%0A%09%09%0A%20%20%09%09iFrame.src%3Durl%3B%0A%20%20%09%09%0A%20%20%09%09/*%20Clear%20the%20hover%20flag%2C%20if%20the%20user%20shows%20this%20at%20full%20size%20*/%0A%20%20%09%09if%28size%3D%3D1%26%26_leoHighlightsPrevElem%29%0A%20%20%09%09%09_leoHighlightsPrevElem.hover%3Dfalse%3B%0A%20%20%09%09%0A%20%20%09%09_leoHighlightsSetSize%28iFrame%2CiFrameSize%29%3B%0A%20%20%09%09_leoHighlightsSetSize%28iFrameDiv%2CdivSize%29%3B%0A%09%7D%0A%09catch%28e%29%0A%09%7B%0A%09%09_leoHighlightsReportExeception%28%22leoHighlightsSetSize%28%29%22%2Ce%29%3B%20%20%20%09%0A%09%7D%0A%7D%0A%0A/**%0A%20*%20Start%20the%20popup%20a%20little%20bit%20delayed.%0A%20*%20Somehow%20IE%20needs%20some%20time%20to%20find%20the%20element%20by%20id.%0A%20*%20%0A%20*%20@param%20anchorId%0A%20*%20@param%20size%0A%20*%20%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsShowPopup%28anchorId%2Csize%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%09%09var%20elem%3D_leoHighlightsFindElementById%28anchorId%29%3B%0A%20%20%09%09if%28_leoHighlightsPrevElem%26%26%28_leoHighlightsPrevElem%21%3Delem%29%29%0A%20%20%09%09%09_leoHighlightsPrevElem.shown%3Dfalse%3B%0A%20%20%09%09elem.shown%3Dtrue%3B%0A%09%09_leoHighlightsPrevElem%3Delem%3B%0A%20%20%20%09%0A%20%20%20%09/*%20FF%20needs%20to%20find%20the%20element%20first%20*/%0A%20%20%20%09_leoHighlightsFindElementById%28anchorId%29%3B%0A%20%20%20%09%0A%20%20%20%09setTimeout%28%22_leoHighlightsShowPopup%28%5C%27%22+anchorId+%22%5C%27%2C%5C%27%22+size+%22%5C%27%29%3B%22%2C10%29%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22leoHighlightsShowPopup%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%09%0A%7D%0A%0A/**%0A*%0A*%20This%20can%20be%20used%20to%20close%20an%20iframe%0A*%0A*%20@param%20id%0A*%20@return%0A*/%0Afunction%20leoHighlightsHideElem%28id%29%0A%7B%0A%09try%0A%09%7B%0A%09%09/*%20Get%20the%20appropriate%20sizes%20*/%0A%20%20%09%09var%20elem%3D_leoHighlightsFindElementById%28id%29%3B%0A%20%20%09%09if%28elem%29%0A%20%20%09%09%09elem.style.visibility%3D%22hidden%22%3B%0A%20%20%09%09%0A%20%20%09%09/*%20Clear%20the%20page%20for%20the%20next%20run%20through%20*/%0A%20%20%09%09var%20iFrame%3D_leoHighlightsFindElementById%28LEO_HIGHLIGHTS_IFRAME_ID%29%3B%0A%20%20%09%09if%28iFrame%29%0A%20%20%09%09%09iFrame.src%3D%22about%3Ablank%22%3B%0A%20%20%09%09%0A%20%20%09%09%0A%20%20%09%09if%28_leoHighlightsPrevElem%29%0A%20%20%09%09%7B%0A%20%20%09%09%09_leoHighlightsPrevElem.shown%3Dfalse%3B%0A%20%20%09%09%09_leoHighlightsPrevElem%3Dnull%3B%0A%20%20%09%09%7D%0A%09%7D%0A%09catch%28e%29%0A%09%7B%0A%09%09_leoHighlightsReportExeception%28%22leoHighlightsHideElem%28%29%22%2Ce%29%3B%20%20%20%09%0A%09%7D%0A%7D%0A%0A/**%0A*%0A*%20This%20can%20be%20used%20to%20close%20an%20iframe.%0A*%20Since%20the%20iFrame%20is%20reused%20the%20frame%20only%20gets%20hidden%0A*%0A*%20@return%0A*/%0Afunction%20leoHighlightsIFrameClose%28%29%0A%7B%0A%20%20try%0A%20%20%7B%0A%09%20%20_leoHighlightsSimpleGwCallBack%28%22LeoHighlightsHideIFrame%22%29%3B%0A%20%20%7D%0A%20%20catch%28e%29%0A%20%20%7B%0A%09%20%20_leoHighlightsReportExeception%28%22leoHighlightsIFrameClose%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%7D%0A%7D%0A%0A/**%0A%20*%20This%20should%20handle%20the%20click%20events%0A%20*%20%0A%20*%20@param%20anchorId%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsHandleClick%28anchorId%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%09%09var%20anchor%3D_leoHighlightsFindElementById%28anchorId%29%3B%0A%20%20%09%09anchor.hover%3Dfalse%3B%0A%20%20%09%09if%28anchor.startTimer%29%0A%20%20%09%09%09clearTimeout%28anchor.startTimer%29%3B%0A%20%20%20%09%0A%20%20%09%09leoHighlightsEvent%28%22clicked%22%29%3B%0A%20%20%20%09leoHighlightsShowPopup%28anchorId%2C1%29%3B%0A%20%20%20%09return%20false%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22leoHighlightsHandleClick%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%09%0A%7D%0A%0A/**%0A%20*%20This%20should%20handle%20the%20hover%20events%0A%20*%20%0A%20*%20@param%20anchorId%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsHandleHover%28anchorId%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%09%09var%20anchor%3D_leoHighlightsFindElementById%28anchorId%29%3B%0A%20%20%09%09anchor.hover%3Dtrue%3B%0A%20%20%09%09%0A%20%20%09%09leoHighlightsEvent%28%22hovered%22%29%3B%0A%20%20%20%09leoHighlightsShowPopup%28anchorId%2C0%29%3B%0A%20%20%20%09return%20false%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22leoHighlightsHandleHover%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%09%0A%7D%0A%0A/**%0A%20*%20This%20will%20handle%20the%20mouse%20over%20setup%20timers%20for%20the%20appropriate%20timers%0A%20*%20%0A%20*%20@param%20id%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsHandleMouseOver%28id%29%0A%7B%0A%09try%0A%09%7B%0A%09%09var%20anchor%3D_leoHighlightsFindElementById%28id%29%3B%09%09%0A%0A%09%09/*%20Clear%20the%20end%20timer%20if%20required%20*/%0A%09%09if%28anchor.endTimer%29%0A%09%09%09clearTimeout%28anchor.endTimer%29%3B%0A%09%09anchor.endTimer%3Dnull%3B%0A%09%09%0A%09%09anchor.style.background%3DLEO_HIGHLIGHTS_BACKGROUND_STYLE_HOVER%3B%0A%09%09%0A%09%09/*%20The%20element%20is%20already%20showing%20we%20are%20done%20*/%0A%09%09if%28anchor.shown%29%0A%09%09%09return%3B%0A%09%09%0A%09%09/*%20Setup%20the%20start%20timer%20if%20required%20*/%0A%09%09anchor.startTimer%3DsetTimeout%28function%28%29%7B%0A%09%09%09leoHighlightsHandleHover%28anchor.id%29%3B%0A%09%09%09anchor.hover%3Dtrue%3B%0A%09%09%09%7D%2C%0A%09%09%09LEO_HIGHLIGHTS_SHOW_DELAY_MS%29%3B%0A%09%7D%0A%09catch%28e%29%0A%09%7B%0A%09%09_leoHighlightsReportExeception%28%22leoHighlightsHandleMouseOver%28%29%22%2Ce%29%3B%20%20%20%09%0A%09%7D%0A%7D%0A%0A/**%0A%20*%20This%20will%20handle%20the%20mouse%20over%20setup%20timers%20for%20the%20appropriate%20timers%0A%20*%20%0A%20*%20@param%20id%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsHandleMouseOut%28id%29%0A%7B%0A%09try%0A%09%7B%09%0A%09%09var%20anchor%3D_leoHighlightsFindElementById%28id%29%3B%0A%09%09%0A%09%09/*%20Clear%20the%20start%20timer%20if%20required%20*/%0A%09%09if%28anchor.startTimer%29%0A%09%09%09clearTimeout%28anchor.startTimer%29%3B%0A%09%09anchor.startTimer%3Dnull%3B%0A%09%09%0A%09%09anchor.style.background%3DLEO_HIGHLIGHTS_BACKGROUND_STYLE_DEFAULT%3B%0A%09%09if%28%21anchor.shown||%21anchor.hover%29%0A%09%09%09return%3B%0A%09%09%0A%09%09/*%20Setup%20the%20start%20timer%20if%20required%20*/%0A%09%09anchor.endTimer%3DsetTimeout%28function%28%29%7B%0A%09%09%09leoHighlightsHideElem%28LEO_HIGHLIGHTS_IFRAME_DIV_ID%29%3B%0A%09%09%09anchor.shown%3Dfalse%3B%0A%09%09%09_leoHighlightsPrevElem%3Dnull%3B%0A%09%09%09%7D%2CLEO_HIGHLIGHTS_HIDE_DELAY_MS%29%3B%0A%09%7D%0A%09catch%28e%29%0A%09%7B%0A%09%09_leoHighlightsReportExeception%28%22leoHighlightsHandleMouseOut%28%29%22%2Ce%29%3B%20%20%20%09%0A%09%7D%0A%7D%0A%0A/**%0A%20*%20This%20handles%20the%20mouse%20movement%20into%20the%20currently%20opened%20window.%0A%20*%20Just%20clear%20the%20close%20timer%0A%20*%20%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsHandleIFrameMouseOver%28%29%0A%7B%0A%09try%0A%09%7B%0A%09%09if%28_leoHighlightsPrevElem%26%26_leoHighlightsPrevElem.endTimer%29%0A%09%09%09clearTimeout%28_leoHighlightsPrevElem.endTimer%29%3B%0A%09%7D%0A%09catch%28e%29%0A%09%7B%0A%09%09_leoHighlightsReportExeception%28%22leoHighlightsHandleIFrameMouseOver%28%29%22%2Ce%29%3B%20%20%20%09%0A%09%7D%0A%7D%0A%0A/**%0A%20*%20This%20handles%20the%20mouse%20movement%20into%20the%20currently%20opened%20window.%0A%20*%20Just%20clear%20the%20close%20timer%0A%20*%20%0A%20*%20@param%20id%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsHandleIFrameMouseOut%28%29%0A%7B%0A%09try%0A%09%7B%0A%09%09if%28_leoHighlightsPrevElem%29%0A%09%09%09leoHighlightsHandleMouseOut%28_leoHighlightsPrevElem.id%29%3B%0A%09%7D%0A%09catch%28e%29%0A%09%7B%0A%09%09_leoHighlightsReportExeception%28%22leoHighlightsHandleIFrameMouseOut%28%29%22%2Ce%29%3B%20%20%20%09%0A%09%7D%0A%7D%0A/**%0A%20*%20This%20is%20a%20method%20is%20used%20to%20make%20the%20javascript%20within%20IE%20runnable%0A%20*/%0Avar%20leoHighlightsRanUpdateDivs%3Dfalse%3B%0Afunction%20leoHighlightsUpdateDivs%28%29%0A%7B%0A%09try%0A%09%7B%0A%09%09/*%20Check%20if%20this%20is%20an%20IE%20browser%20and%20if%20divs%20have%20been%20updated%20already%20*/%0A%09%09if%28document.all%26%26%21leoHighlightsRanUpdateDivs%29%0A%09%09%7B%0A%09%09%09leoHighlightsRanUpdateDivs%3Dtrue%3B%20//%20Set%20early%20to%20prevent%20running%20twice%0A%09%09%09for%28var%20i%3D0%3Bi%3CLEO_HIGHLIGHTS_MAX_HIGHLIGHTS%3Bi++%29%0A%09%09%09%7B%0A%09%09%09%09var%20id%3D%22leoHighlights_Underline_%22+i%3B%0A%09%09%09%09var%20elem%3D_leoHighlightsFindElementById%28id%29%3B%0A%09%09%09%09if%28elem%3D%3Dnull%29%0A%09%09%09%09%09break%3B%0A%09%09%09%09%0A%09%09%09%09if%28%21elem.leoChanged%29%0A%09%09%09%09%7B%0A%09%09%09%09%09elem.leoChanged%3Dtrue%3B%0A%09%09%09%09%0A%09%09%09%09%09/*%20This%20will%20make%20javaScript%20runnable%20*/%09%09%09%09%0A%09%09%09%09%09elem.outerHTML%3Delem.outerHTML%3B%0A%09%09%09%09%7D%0A%09%09%09%7D%0A%09%09%7D%0A%09%7D%0A%09catch%28e%29%0A%09%7B%0A%09%09_leoHighlightsReportExeception%28%22leoHighlightsUpdateDivs%28%29%22%2Ce%29%3B%20%20%20%09%0A%09%7D%0A%7D%0A%0Aif%28document.all%29%0A%09setTimeout%28leoHighlightsUpdateDivs%2C200%29%3B%0A%0A/**%0A%20*%20This%20is%20used%20to%20report%20events%20to%20the%20plugin%0A%20*%20@param%20key%0A%20*%20@param%20sub%0A%20*%20@return%0A%20*/%0Afunction%20leoHighlightsEvent%28key%2C%20sub%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%20%20%20var%20gwObj%20%3D%20new%20Gateway%28%29%3B%0A%20%20%20%20%20%20gwObj.addParam%28%22key%22%2C%20key%29%3B%0A%20%20%20%20%20%20gwObj.addParam%28%22sub%22%2C%20sub%29%3B%0A%20%20%20%20%20%20gwObj.callName%28%22LeoHighlightsEvent%22%29%3B%09%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22leoHighlights%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%0A%7D%0A%0A/*--*/%0A/*%20Methods%20provided%20to%20the%20highlight%20providers...%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20*/%0A/*--*/%0A%0A/**%0A%20*%20This%20will%20redirect%20the%20top%20window%20to%20the%20passed%20in%20url%0A%20*%20%0A%20*%20@param%20url%0A%20*%20@param%20parentId%0A%20*%20@return%0A%20*/%0Afunction%20leoHL_RedirectTop%28url%2CparentId%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%09%09leoHighlightsEvent%28%22clicked.2eBay%22%29%3B%0A%20%20%20%09_leoHighlightsRedirectTop%28url%29%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22leoHL_RedirectTop%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%0A%7D%0A%0A/**%0A%20*%20This%20will%20set%20the%20size%20of%20the%20iframe%0A%20*%20%0A%20*%20@param%20url%0A%20*%20@param%20parentId%0A%20*%20%0A%20*%20@return%0A%20*/%0Afunction%20leoHl_setSize%28size%2Curl%29%0A%7B%0A%20%20%20try%0A%20%20%20%7B%0A%20%20%20%09/*%20Get%20the%20clickId%20*/%0A%20%20%20%09var%20clickId%3D_leoHighlightsGetUrlArg%28%20url%2C%22clickId%22%29%0A%20%20%20%09%0A%20%20%20%20%20%20var%20gwObj%20%3D%20new%20Gateway%28%29%3B%0A%20%20%20%20%20%20gwObj.addParam%28%22size%22%2Csize%29%3B%0A%20%20%20%20%20%20if%28clickId%29%0A%20%20%20%20%20%20%20%20%20gwObj.addParam%28%22clickId%22%2CclickId+%22_blah%22%29%3B%0A%20%20%20%20%20%20gwObj.callName%28%22LeoHighlightsSetSize%22%29%3B%0A%20%20%20%7D%0A%20%20%20catch%28e%29%0A%20%20%20%7B%0A%20%20%20%09_leoHighlightsReportExeception%28%22leoHl_setSize%28%29%22%2Ce%29%3B%20%20%20%09%0A%20%20%20%7D%0A%7D%0A");