-
Strange bug in textinput component
Hi,
This is really strange...I have been searching crazy before i knew what caused it, looks like its the textinput component.
I set up a test :
http://www.silverware.be/pushme/pushme.swf
http://www.silverware.be/pushme/pushme.fla
If i select the text and try to click the button twice it wont work, The second hit doesnt get executed.
If i move the mouse a litlle before i push the second time it works...
If i remove the textcomponen it works
strange isnt it
anyone has any ideas?
grtz
-
Total Universe Mod
It has nothing to do with your text fields, they dont even have instance names.
You're using onPress which only means when the mouse button is depressed. What you want is onRelease
-
Hi jAQUAN,
thnx for looking into this.
i changed it to onrelease and even added instance names to the textfields,
but thats not it...
let me rephrase the problem
1. Select a piece of text
2. Click the button (you see that its clicked cause the color changed and the counter goes up)
3. Without changing the mouse position, click it again, you see that it isnt clicked, color doesnt change, counter doesnt go up
-
Monkey Moderator
One way round your bug is to get the button to change the current Selection as the component uses this to keep track of the selected text in it's textbox.
(actually my recommended way round the bug is to delete the components panel!)
name your button 'btn'....
Code:
on (press)
{
info.text = teller;
teller += 1;
// stops the crappy yellow box appearing
btn._focusrect = false;
// sets the selection to the button which is kind of a meaningless workaround
Selection.setFocus(btn);
}
www.lexicon-design.co.uk
If we aren't supposed to eat animals, then why are they made of meat?
If Vegetarians like animals so much, why do they eat all their food?
-
-
Total Universe Mod
ah, I didn't see that. glad you got it fixed
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|