Tag: google chrome

Layered background images fail to render when window is scaled large in Chrome

This part of the code is supposed to show an area with multiple overlapping images. Each layer has a set of image options, so layers can be mixed. Problem: I have a problem with these overlapping images in Chrome. They are positioned absolute and with set z-indexes. They show as expected in “normal” browser size […]

How to trace the origin of a Javascript (XHR) generated HTML element with Chrome's Web Developer Tools?

I am interested in an HTML page that uses an XHR object to request JSON data from the server and then some Javascript (jQuery) code is used to translate these data into HTML-markedup elements. I wonder if it is possible to trace the “origin” of some HTML element using Chrome Web Developer Tools. That is, […]

Sending Data USB Port from Browser for EPOS

Tricky question this and I am not sure it can be resolved. I am developing an EPOS system which runs entirely in the browser (preferring Google Chrome) A couple of customers have mentioned the apparent need for it to be able to open a till drawer when they complete a sale. The user presses the […]

Chrome VM files duplicate javascript

I have a problem developing a website. I am using chrome to debug javascript functions. On one of my pages I see the following: You can see that my own javascript file gets executed, search.js. There is a duplicate of this file, called VM1769. This file also executes the same code, so a search request […]

What can cause requestAnimationFrame to drop frames in an efficient webgl loop?

I have been programming a javascript demo/test to learn WebGL. I have a fairly efficient game loop structure that (according to Chrome Dev Tools) only takes 1-2 milliseconds to run. I am using requestAnimationFrame to schedule the running of the loop (because this is apparently the “proper” way to perform 60fps animation). When I look […]

Is there a way to control Chrome GC?

I am working with quite large volume of data. Mechanism: JavaScript is reading WebSQL database, then assembles data into Object that has tree structure. Then applies to tree object knockout.js (makes elements observable) then data-binds and then applies Jquery Mobile UI at the end. Whole process takes unacceptable amount of time. I have already optimized […]

Apparently missing ) gets fixed in jQuery :not(.class on all but Safari?

I had a jQuery Syntax-Error in my Script but only Safari throw an exception. $(“#id:not(.class”).length The :not wasn’t closed by ). In Safari length was 0, in all other browser it was the correct value if the error hadnt exist. Could it possible that Chrome, Firefox, Opera, Internet Explorer fixes these errors on the fly?

$(document).width reported differently in PC Chrome vs Mac Chrome

So I have some footer function code: $(document).ready(function () { $(“<a class=\”dropdown-toggle dropdown-toggle-new disabled\” data-toggle=\”dropdown\” data-target=\”#\” style=\”text-align:right; float:right; display:inline; cursor:pointer\”>+</a><br clear=\”both\”/><br clear=\”both\”/>”).insertAfter(“footer .dropdown-toggle”); $(“.dropdown-toggle-new”).css({ “display”: “none” }); $(‘li.dropdown .dropdown-toggle-new’).click(function () { $(this).parent().children(‘ul.dropdown-menu’).toggle(300); }); $( window ).resize(changeFooter); changeFooter(); function changeFooter(){ if ($( document ).width() > 767){ $(‘li.dropdown .dropdown-toggle-new’).parent().children(‘ul.dropdown-menu’).show(); $(“.dropdown-toggle-new”).css({ “display”: “none” }); } else { $(“.dropdown-toggle-new”).css({ […]

Removing generated inline styles in contentEditable while preserving original selection in Chrome

I have a content editable element on my page and while it works somehow I’m having some problems in Google Chrome browser because it seems to sometimes wrap element into span elements with inline styles which is particularly irritating. If I call document.execCommand(“removeFormat”, false, null); after block/paragraph conversion it does remove those spans. But there […]

Select URL for copying in mobile chrome

I’ve been trying around for some time and searched and searched for solutions with no results so far. The problem: I have an URL in a webpage that I want to select as a whole to copy it from a mobile browser. For Firefox I’m using a readonly input of type text and with the […]