Presing Enter Key, opening the Window POP again, In IE Browser

Hello Webix Team,

We have a form with many components (Text Box.Date Picker), for one of the text box I am pulling the values from Window POP, to achieve this we have a link after the text box, on click of it, I am opening a window, where user will select the data, and I pushing this data to the text box, now the issue here is, when I go to other text box , and placed the curser in the that text box, and clicks on Enter Button in Key board, this action again call the same window pop.

But I haven’t clicked on the pop link, even though it is firing an action and opening the same pop.

Below is the code, I have written for TextBox and POP.

{
	view : "text",
	value : "",
	label : Country,
	labelWidth : 130,
	width : 320,
	labelAlign : "right",
	id : "Country"
},

{
	view : "toggle",
	type : "image",
	image : "picker.png",
	width : 30,
	click : "openCountryPage()",
	id : "CountryLookup"
}

If you see in the above code, “openCountryPage()” function is called on pressing of Enter Button

The click function can be triggered by Enter key only if toggle button is in focus.
If you have clicked in text input and focus is there ( active cursor is blinking in the input ) toggle button must not react on any hot keys.

Are you moving focus to different input by clicking on it, or by calling focus method through JS API ?

Hello Maksim,

I am not handling any focus event, what I am doing here is just when I clicking on openCountryPage() and open a pop, once I choose the country I am populating the Country in Country Text Box, and now when I place the curser using the mouse in other text box, and press Enter, the openCountryPage() pop function again called and this will open the pop.

So here I am not handling Focus through program, I would appreciate If you could please let us know, how can do in webix way,like how I can change the focus, when I am moving the curser to other text box.

and also I would like to tell you that it is happening only in IE browser, not in chrome.

Hello Maksim,

Please paste the below code and create an html file and test the issue here, this issue is coming in IE 9 and 10 as well.

#areaA{ margin: 30px; } Basic Initialization
	<div id="areaA"></div>


	<script type="text/javascript" charset="utf-8">
    function openCustomerPage(){
		alert("Customer Page is open");
	}
		webix.ui({
			container:"areaA",
			view:"form", scroll:false,
			width:300,

			elements:[
				{ view:"text", label:"Email"},
				{ view:"text", label:"Password"},
                {
								view : "text",
								value : "",
								label : "Customer",
								labelWidth : 130,
								width : 320,
								labelAlign : "right",
								id : "customerName"
				},
				{
					cols : [
							
							{
								view : "toggle",
								type : "image",
								image : "../../../codebase/iconSearch.gif",
								width : 30,
								click : "openCustomerPage",
								id : "customerNameLookup"
							},
							{
								cols : [ {
									view : "text",
									value : "",
									id : "customerId",
									hidden : true
								} ]
							} ]
				},
				{ margin:5, cols:[
					{ view:"button", label:"Login" , type:"form" },
					{ view:"button", label:"Cancel" }
				]}
			]
		});
	</script>
</body>

Hello Maksim,

Did you find the solution for the above problem, which we are facing in IE browser, please let us know.

Hi Raj

Yep, I was able to confirm the issue, thanks for the code snippet.
We just have published Webix 2.1.1 and it contains fix for this issue as well

You can grab pro version from customer section. Due to severity of one of fixed issues, gpl version was updated as well. You can grab the updated package from webix.com