Questions tagged [focusin]

34 questions
13
votes
3 answers

How to detect `focusin` support?

Thanks to Perfection kills, we can use the following JavaScript to detect event support: function hasEvent(ev) { var elem = document.createElement('a'), type = 'on' + ev, supported = elem[type] !== undefined; if (!supported)…
sdleihssirhc
  • 40,010
  • 5
  • 51
  • 67
9
votes
1 answer

Why event.bubbles is false for "focusin" and "focusout"?

Couple of minutes ago, I answered the question: What is the difference between focusin/focusout vs focus/blur in jQuery? The answer was: Short answer: focusin    bubbles, focus does not.         focusout bubbles, blur   does not. I tested it,…
gdoron is supporting Monica
  • 136,782
  • 49
  • 273
  • 342
5
votes
2 answers

Receiving two `focusin` events on focus

What I'm doing In some part of the code, I have a listener on focusin events, and in another part programmatically set the focus on an input. On Chrome, Safari, Firefox the event listener is called once, but on IE (including IE10), it is called…
avernet
  • 28,976
  • 43
  • 119
  • 160
4
votes
1 answer

Backbone.js focus event fires two events focus and focusin

The view part of my code using Backbone.js is something like this: var myView = Backbone.View.extend({ events: { 'focus .cell input' : "updateCurrentCell" }, updateCurrentCell: function(event) { …
viky
  • 542
  • 1
  • 7
  • 19
4
votes
0 answers

When content is empty, caret disappear in contenteditable

When div[contenteditable] to empty(like $(this).html("")) then caret disappeared. Is it bug? Also I found some other solution. using setTimeout function. but It's not perfect solution for me. when I use many contenteditables division moving focus…
AndrewAhn
  • 41
  • 3
3
votes
3 answers

jquery: when i click a div, give focus to a textbox

$('.my-button').click(function() { $(".my-textbox").focus() }); Before Jquery 1.4 this used to be the way to call focus to a textbox, now it doesn't work. When I click the button, I want to call focus to the textbox, what i mean by "focus", is…
android.nick
  • 10,260
  • 22
  • 70
  • 111
3
votes
0 answers

How to fire a focusin event in a crossbrowser way?

I've found very hard to manually trigger a focusin event using just Javascript (no jQuery) for it for a test suite. Apparently when the browser does not have the focus (that can happen only in tests) I want to simulate the focusin event myself. I've…
miguel.camba
  • 1,676
  • 1
  • 13
  • 19
2
votes
2 answers

How to exclude Id from focusout

With Jquery, focusout is just called when you click anywhere out of the focused area when "focusout" is set. How do I exclude some id(s) from activiting the "focusout" function. ? e.g here. You have an input text field ( id="A")that hides some div…
Blessing Thinker
  • 251
  • 1
  • 3
  • 12
1
vote
1 answer

What do the focusIn and focusOut event types mean?

I am reading a book on Tkinter and so far making good progress understanding the concepts for a gui I want to make. One thing unexplained in the book is the concept of focusIn and focusOut. I have looked at the tcl.tk explanation and cannot…
Windy71
  • 577
  • 3
  • 15
1
vote
1 answer

tkinter: Dynamically change label text without repetitive If testing

I want unique messages associated with certain widget names to display as a single label's text when those widgets take focus. The messages are values in a dictionary corresponding to the dictionary's keys which are strings identical to the widget…
Luther
  • 367
  • 3
  • 15
1
vote
2 answers

Jquery toggle between focus

ok my piece of code looks sth like this:
1
vote
1 answer

Why the "focusin" event handler isn't called?

Why in the following code the focusin event handler isn't called ? HTML:
Click Here
JS: $(function() { $('input').live('focusin', function() { …
Misha Moroshko
  • 148,413
  • 200
  • 467
  • 700
1
vote
0 answers

tinymce popup in bootstrap modal - focusin does not work in Chrome anymore?

I have this quick fix for overriding the built in block on focusin in bootstrap dialogs when using TinyMCE inside it. It used to work on Chrome and Firefox. But now it does not work on Chrome anymore, /** * Prevent bootstrap dialog from blocking…
laukok
  • 47,545
  • 146
  • 388
  • 689
1
vote
2 answers

How to trigger a function once, after focusin on input element?

I want to trigger a function only one time at focusin in a element input. The follow code calls the function in a infinite loop. $(document).on("focusin",".dateRangeEducLev",function(e){ …
zwitterion
  • 3,958
  • 9
  • 43
  • 64
1
vote
0 answers

why focusout missing selected option(s)?

i'm using jquery focusin and focusout for expand and minimize a multiple option select on a form: $("#orgns").focusin(function() { $(this).attr({'size':10}); }) .focusout(function() { $(this).attr({'size':1}); }); every thing is ok, and 1 line…
APH
  • 21
  • 6
1
2 3