From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out.smtp-auth.no-ip.com (out.smtp-auth.no-ip.com [8.23.224.60]) by hurricane.the-brannons.com (Postfix) with ESMTPS id AD40477EF7 for ; Thu, 31 Dec 2015 18:09:40 -0800 (PST) X-No-IP: carhart.net@noip-smtp X-Report-Spam-To: abuse@no-ip.com Received: from carhart.net (unknown [99.52.200.227]) (Authenticated sender: carhart.net@noip-smtp) by smtp-auth.no-ip.com (Postfix) with ESMTPA id 5D1D540121C for ; Thu, 31 Dec 2015 18:10:09 -0800 (PST) Received: from carhart.net (localhost [127.0.0.1]) by carhart.net (8.13.8/8.13.8) with ESMTP id u012A8rF026160 for ; Thu, 31 Dec 2015 18:10:08 -0800 Received: from localhost (kevin@localhost) by carhart.net (8.13.8/8.13.8/Submit) with ESMTP id u012A7hL026130 for ; Thu, 31 Dec 2015 18:10:07 -0800 Date: Thu, 31 Dec 2015 18:10:07 -0800 (PST) From: Kevin Carhart To: Edbrowse-dev@lists.the-brannons.com In-Reply-To: <20151131095446.eklhad@comcast.net> Message-ID: References: <20151129214611.eklhad@comcast.net> <20151131095446.eklhad@comcast.net> User-Agent: Alpine 2.03 (LRH 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Subject: [Edbrowse-dev] telling JS about allowXHR X-BeenThere: edbrowse-dev@lists.the-brannons.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Edbrowse Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Jan 2016 02:09:40 -0000 I was wondering how to get the allowXHR flag into javascript, and what is the proper moment to do it. Could I set it on the JS window, at the top of jsRunScriptResult? set_property_bool(cw->winobj, "allowXHR", allowXHR); This way JS will always have the updated preference. Javascript can be responsible for having a try-catch or similar, so that XHR does not run, but everything else can continue. thanks Kevin