I was casting around for that some weeks ago, I think the closest I got was
overriding the onclick function in actionscript.
Of course that gets called for *any* click, but crucially the select ones will
be in there, and give you a reference to the element selected, from which you
can at least get innerhtml or outerhtml properties.
That project went to the bottom of the todo list before I resolved it to my
satisfaction, however :(
I was looking for some kind of "select" event, really. It may well be there and
I just missed it.
Perhaps it's worth seeing if there is a mail list or forum for webkit / safari
? I'd imagine the inner workings are close if not identical.
(And I've love to know the answer if you find it!)
-Original Message-
From: flexcoders@yahoogroups.com on behalf of polestar11
Sent: Thu 24/04/2008 16:09
To: flexcoders@yahoogroups.com
Subject: [flexcoders] AIR HTML component - html tag / text selection
Hi there
I'm trying to access selected html text from an HTML component in an
AIR app. I'm able to get selected text that excludes html tags by
calling a JS function: window.getSelection(). This excludes the HTML
tags though.
I've tried using my HTML component's textSnapshot property this has a
charCount of zero.
Does anyone have good suggestions on how to get:
a) the parent tag or id of a selected piece of text either via AIR or JS
b) how to get the raw text of a selection (that includes tags) via AIR
or JS
Thanks
Tracy
__
This communication is from Primal Pictures Ltd., a company registered in
England and Wales with registration No. 02622298 and registered office: 4th
Floor, Tennyson House, 159-165 Great Portland Street, London, W1W 5PA, UK. VAT
registration No. 648874577.
This e-mail is confidential and may be privileged. It may be read, copied and
used only by the intended recipient. If you have received it in error, please
contact the sender immediately by return e-mail or by telephoning +44(0)20 7637
1010. Please then delete the e-mail and do not disclose its contents to any
person.
This email has been scanned for Primal Pictures by the MessageLabs Email
Security System.
__<>