wiln / flexlib

Automatically exported from code.google.com/p/flexlib
0 stars 0 forks source link

PromptingTextInput #155

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a form with two formitems. Both using promptingtextinput. Provide
some value for prompt property.
2. Attach standard validator with minlength=1 to both formitems.
3. Add a submit button to execute validator.validate() on click event;
4. On execution, do not click on formitems, instead click on the submit
button. This should execute the validator methods.

What is the expected output? What do you see instead?
The PromptingTextInput does not show a red border to highlight the error.
If I use the TextInput, it does properly. I believe the Prompting
functionality has changed the default behavior. 

Now try executing one more item. This time, click and tab through the
formitems without entering any data. The red border shows properly even
with the prompt value set to some string. So the Red Border isn't covered
by the prompting, but the default behavior has changed. Same issue with
PromptingTextArea.

What version of the product are you using? On what operating system?
FB3 / XP

Please provide any additional information below.

Original issue reported on code.google.com by ond...@gmail.com on 25 Aug 2008 at 8:09

Attachments:

GoogleCodeExporter commented 8 years ago
I was having a problem with binding to the text.  Text length was 0 until more 
than one character was typed.  
Fixed it be opening up the source and replaces get text with 

override public function get text():String
    {   
        // If the text has changed      
        if( super.text == _prompt )
        {
            // Skip the prompt text value
            return "";
        }
        else
        {
            return super.text;
        }       
    }

Original comment by cha...@gmail.com on 12 Sep 2008 at 12:06

GoogleCodeExporter commented 8 years ago

Original comment by dmcc...@gmail.com on 8 Jan 2009 at 5:52

GoogleCodeExporter commented 8 years ago

Original comment by olarivain@gmail.com on 29 Mar 2010 at 1:28

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a form with two formitems. Both using promptingtextinput. Provide
some value for prompt property.
2. Attach standard validator with minlength=1 to both formitems.
3. Add a submit button to execute validator.validate() on click event;
4. On execution, do not click on formitems, instead click on the submit
button. This should execute the validator methods.

What is the expected output? What do you see instead?
The PromptingTextInput does not show a red border to highlight the error.
If I use the TextInput, it does properly. I believe the Prompting
functionality has changed the default behavior. 

I have tried below code , but not working.
please provide more details

override public function get text():String
    {   
        // If the text has changed      
        if( super.text == _prompt )
        {
            // Skip the prompt text value
            return "";
        }
        else
        {
            return super.text;
        }       
    }

Thanks

Original comment by dharakha...@gmail.com on 14 Apr 2011 at 1:41

GoogleCodeExporter commented 8 years ago
I have solved other problems related to the prompting components.
You can find the text area version here : 
http://code.google.com/p/flexlib/issues/detail?id=139#c9

Can you please check if you have the same problem with my patch ?
I can't currently do that...

Original comment by switcher...@gmail.com on 22 Apr 2011 at 12:38