HighDots Forums  

Showing focus

Javascript JavaScript language (comp.lang.javascript)


Discuss Showing focus in the Javascript forum.



Reply
 
Thread Tools Display Modes
  #11  
Old   
sheldonlg
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 02:40 PM






SAM wrote:
Quote:
sheldonlg a écrit :

http://www.sheldonlg.com/multiplesel.../multiple5.php

Apparently no problem with focus (Fx 2 Mac)

Correct! This is the sample app and it works. I cannot reproduce the
problem in a simple app, and I cannot point you to the actual app since
that is behind firewalls and accessible only via VPN (it is an intranet
app). If I could reproduce the problem in a simple app, I would be 3/4
of the way to a solution.


Reply With Quote
  #12  
Old   
SAM
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 02:58 PM






sheldonlg a écrit :
Quote:
SAM wrote:

is your div in same form that the form in rear when this div comes at
front ?

No, a form was not needed for the complete screen since there is no
submittal anywhere. It is all with AJAX.
Ajax has nothing to do about correct HTML code ... it does what you ask
to him.

Quote:
This, though, is in its own
form in order to use the multiple selection stuff.
I asked that because I think IE has some difficulties with forms
displayed over another element (specialy to focus the front form's
elements).

Quote:
does that happens also with Firefox ?

I haven't even done IE. I do all my development first on Firefox
because of its tremendous developer tools.
Ha! ? OK .

All seems to work fine in your example.

--
sm


Reply With Quote
  #13  
Old   
sheldonlg
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 03:14 PM



SAM wrote:
Quote:
sheldonlg a écrit :
I have a problem with not seeing the current focus while in a
particular screen in a my app. The focus does not show for a
type=text or textarea. I have tried to reproduce this problem in a
test application, but have not been successful is doing that.

The actual app has a screen which is displayed on a template and the
contents are the return from an AJAX call. In that content there is a
hidden block. Clicking on a button in the displayed area causes that
hidden block to appear (with a gray background in a fixed location on
the screen). It is in that area that I have both text fields and text
areas. I also have dropdown lists and buttons. Only the text areas
and text fields do not display focus when there, but I can type into
them so I know that focus is there.

CSS (for others than IE) :

input { background: silver }
input:focus { background: white }

HTML :

input onfocus="if(IE) this.background='white';"
onblur="if(IE) this.background='';"
id="hiddenInput" name="Name"

JS :

IE = false; /*@cc_on IE=true; @*/



is your div styled visibity: hidden; or display: none; ?

is your div in same form that the form in rear when this div comes at
front ?

does that happens also with Firefox ?


I tried the CSS stuff. That does what it says, but it doesn't solve my
problem. Let me more precise.

When that form comes up, the cursor everywhere is that left-up pointing
arrow. When the mouse is over a text field or a text area element, the
cursor changes to a vertical I-beam. However, the blinking vertical
line does not appear in the text field or the text area if I click on
them to set focus there. However, focus is set there as I can type in
information. I want to have that blinking vertical bar on as visual
feedback as to where the focus is.


Reply With Quote
  #14  
Old   
mynameisnobodyodyssea@googlemail.com
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 03:33 PM



On Mar 18, 7:14 pm, sheldonlg <sheldonlg> wrote:
Quote:
When that form comes up, the cursor everywhere is that left-up
pointing
arrow. When the mouse is over a text field or a text area element, the
cursor changes to a vertical I-beam. However, the blinking vertical
line does not appear in the text field or the text area if I click on
them to set focus there. However, focus is set there as I can type in
information. I want to have that blinking vertical bar on as visual
feedback as to where the focus is.
It is difficult to see what the problem is without an
exact-ish example.
Did you try, instead of changing visibility from hidden to visible,
to change with JavaScript the value of inner.HTML


Reply With Quote
  #15  
Old   
sheldonlg
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 03:57 PM



mynameisnobodyodyssea (AT) googlemail (DOT) com wrote:
Quote:
On Mar 18, 7:14 pm, sheldonlg <sheldonlg> wrote:
When that form comes up, the cursor everywhere is that left-up
pointing
arrow. When the mouse is over a text field or a text area element, the
cursor changes to a vertical I-beam. However, the blinking vertical
line does not appear in the text field or the text area if I click on
them to set focus there. However, focus is set there as I can type in
information. I want to have that blinking vertical bar on as visual
feedback as to where the focus is.

It is difficult to see what the problem is without an
exact-ish example.
I know. I wish I could reproduce it here.

Quote:
Did you try, instead of changing visibility from hidden to visible,
to change with JavaScript the value of inner.HTML
No, there is much to much to generate to then use an innerHTML setting.


Reply With Quote
  #16  
Old   
mynameisnobodyodyssea@googlemail.com
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 04:48 PM



On Mar 18, 7:57 pm, sheldonlg <sheldonlg> wrote:
Quote:
It is difficult to see what the problem is without an
exact-ish example.

I know. I wish I could reproduce it here.

Did you try, instead of changing visibility from hidden to visible,
to change with JavaScript the value of inner.HTML

No, there is much to much to generate to then use an innerHTML setting.
Just to state the obvious:
check for error messages in the Firefox error console,
check valid HTML, CSS etc.
I see that you use in your example tables in the form.
Maybe try the form without tables, just in case,
sometimes tables in forms can create problems.


Reply With Quote
  #17  
Old   
SAM
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 08:12 PM



sheldonlg a écrit :
Quote:
No, there is much to much to generate to then use an innerHTML setting.
With your last test : Oll Korrect with Fx (mouse's pointer over fields)

Next test with a form in rear ?

--
sm


Reply With Quote
  #18  
Old   
SAM
 
Posts: n/a

Default Re: Showing focus - 03-18-2008 , 08:28 PM



sheldonlg a écrit :
Quote:
I tried the CSS stuff. That does what it says, but it doesn't solve my
problem. Let me more precise.

When that form comes up, the cursor everywhere is that left-up pointing
arrow. When the mouse is over a text field or a text area element, the
cursor changes to a vertical I-beam.
input:hover, textarea:hover { cursor: text }

#dimensions input:hover[type=text] { cursor: text }
#dimensions input:focus[type=text] { cursor: wait }

<http://www.w3.org/TR/CSS21/ui.html#propdef-cursor>

Quote:
However, the blinking vertical
line does not appear in the text field or the text area if I click on
them to set focus there.
I have no solution for that.
Overall I can't get this not blinking cursor

--
sm


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.