focus

Windows 7: Prevent application from losing focus

北战南征 提交于 2021-02-17 19:08:10
问题 I have a self-made fullscreen application for Windows 7 written in C++ which should run for a long time on its own as a public presentation. Problem is, there are several applications or drivers or Windows itself that steal focus from time to time and/or especially at system startup. Result is: My fullscreen application gets minimimized. It is very annoying and nearly impossible to always find out which things you have to deactivate to prevent that. Especially because those focus stealing

Angular/Typescript - Change background color of a span when a link is clicked

旧巷老猫 提交于 2021-02-11 14:50:41
问题 I'm trying to change the color of a span when a link is clicked in order to indicate that it's checked. This must work in the form of a radio button, meaning that the color must disappear if another link is clicked (checked). I tried various methods using only html and css, but unfortunately I never managed to get it to work using :focus. At the moment, when I click on one of the filters there is no indication that one of the categories has been activated, heavily impacting the UX. I believe

KIVY: Carousel inside another carousel

元气小坏坏 提交于 2021-02-11 12:40:13
问题 I'm trying to have a carousel inside another carousel. It's KivyMD so I have MDTabs which is based off of carousel and I wish to put another one inside of that. I did it but the parent carousel (the MDTabs) grabs focus and when I try to swipe the child carousel the focus goes to the parent instead and it switches tabs instead of switching slides inside the carousel. If I wait for the scroll_timeout of the parent carousel I can swipe and switch slides but this is basically unusable for the end

Vanilla javascript Trap Focus in modal (accessibility tabbing )

[亡魂溺海] 提交于 2021-02-10 12:36:19
问题 This should be pretty simple but for some reason it isn't working, I'm getting the proper console.logs at the right time, but the focus isn't going to the correct place, please refer to my jsfiddle https://jsfiddle.net/bqt0np9d/ function checkTabPress(e) { "use strict"; // pick passed event of global event object e = e || event; if (e.keyCode === 9) { if (e.shiftKey) { console.log('back tab pressed'); firstItem.onblur=function(){ console.log('last a focus left'); lastItem.focus(); }; e

Vanilla javascript Trap Focus in modal (accessibility tabbing )

℡╲_俬逩灬. 提交于 2021-02-10 12:35:16
问题 This should be pretty simple but for some reason it isn't working, I'm getting the proper console.logs at the right time, but the focus isn't going to the correct place, please refer to my jsfiddle https://jsfiddle.net/bqt0np9d/ function checkTabPress(e) { "use strict"; // pick passed event of global event object e = e || event; if (e.keyCode === 9) { if (e.shiftKey) { console.log('back tab pressed'); firstItem.onblur=function(){ console.log('last a focus left'); lastItem.focus(); }; e

Focus sibling window in Chrome

为君一笑 提交于 2021-02-08 09:32:49
问题 I've got an application which has several child windows. For user experience reasons, sometimes we want to re-use these windows instead of always opening new ones. So the main window has two child windows, A and B. The user is using Child A. As a result of their action in Child A, we wish to focus Child B and perform an action on it. I have complete control of the source for all windows involved. Unfortunately, it seems like Child A no longer has the right to focus Child B in Chrome. The main

Focus sibling window in Chrome

落花浮王杯 提交于 2021-02-08 09:32:47
问题 I've got an application which has several child windows. For user experience reasons, sometimes we want to re-use these windows instead of always opening new ones. So the main window has two child windows, A and B. The user is using Child A. As a result of their action in Child A, we wish to focus Child B and perform an action on it. I have complete control of the source for all windows involved. Unfortunately, it seems like Child A no longer has the right to focus Child B in Chrome. The main

Unable to set focus on an input of Twitter Bootstrap's Typeahead

蓝咒 提交于 2021-02-07 11:32:32
问题 When I remove these attributes: data-source="<?=str_replace('"', '"', json_encode($equipment, JSON_HEX_TAG | JSON_HEX_APOS)); ?>" data-items="4" data-provide="typeahead" I am able to perform this: $(document).ready(function() { $('.first').focus(); }); This is my HTML markup for this: <div class="itemx"> <input type="text" class="input-large first" autocomplete="off" placeholder="Equipment Name/Label" name="equip[]" data-source="<?=str_replace('"', '"', json_encode($equipment, JSON_HEX_TAG |

How to set the cursor position at the end of a string in a text field using jQuery?

左心房为你撑大大i 提交于 2021-02-07 10:37:43
问题 I am using jQuery 1.6 and I have a text field for which I would like the cursor to be positioned at the end of the string\text after the field receives focus. Is there a trivial or easy to do this? At this time I am using the following code: $jQ('#css_id_value').focus(function(){ this.select(); }); $jQ('css_id_value').focus(); 回答1: $('#foo').focus(function() { if (this.setSelectionRange) { this.setSelectionRange(this.value.length, this.value.length); } else if (this.createTextRange) { // IE

How to set the cursor position at the end of a string in a text field using jQuery?

谁说我不能喝 提交于 2021-02-07 10:37:17
问题 I am using jQuery 1.6 and I have a text field for which I would like the cursor to be positioned at the end of the string\text after the field receives focus. Is there a trivial or easy to do this? At this time I am using the following code: $jQ('#css_id_value').focus(function(){ this.select(); }); $jQ('css_id_value').focus(); 回答1: $('#foo').focus(function() { if (this.setSelectionRange) { this.setSelectionRange(this.value.length, this.value.length); } else if (this.createTextRange) { // IE