2011 Oct 17, 5:58
Essentially anybody can resolve it however they like except for tokens from the about URI special token registry which currently only contains 'blank'.
technical 2011 Aug 31, 10:03Awesome shirt of Tesla/Edison in the style of the AC/DC logo.
science humor electricity tesla edison tshirt shirt wishlist 2011 May 24, 11:00
I always have trouble remembering where the opt goes in SAL in the __deref_out case. The mnemonic is pretty simple: the
_opt at the start of the SAL is for the pointer value at the start of the function. And the _opt at the end of the SAL is for the dereferenced pointer value at the end of the function.
SAL
|
foo == nullptr allowed at function start?
|
*foo == nullptr allowed at function end?
|
__deref_out void **foo
|
No
|
No
|
__deref_opt_out void **foo
|
Yes
|
No
|
__deref_out_opt void **foo
|
No
|
Yes
|
__deref_opt_out_opt void **foo
|
Yes
|
Yes
|
.
sal technical programming 2011 Apr 5, 10:00
For my GeolocMock weekend project I intended to use the Bing Maps API to display a map in a WebBrowser control and allow the user to
interact with that to select a location to be consumed by my application. Getting my .NET code to talk to the JavaScript in the WebBrowser control was surprisingly easy.
To have .NET execute JavaScript code you can use the InvokeScript method passing the name of the JavaScript function to execute and an object array of parameters to pass:
this.webBrowser2.Document.InvokeScript("onLocationStateChanged",
new object[] {
latitudeTextBoxText,
longitudeTextBoxText,
altitudeTextBoxText,
uncertaintyTextBoxText
});
The other direction, having JavaScript call into .NET is slightly more complicated but still pretty easy as far as language interop goes. The first step is to mark your assembly as ComVisible so
that it can interact with JavaScript via COM. VS had already added a ComVisible declaration to my project I just had to change the value to true.
[assembly: ComVisible(true)]
Next set ObjectForScripting attribute to the object you want to expose to JavaScript.
this.webBrowser2.ObjectForScripting = this.locationState;
Now that object is exposed as window.external in JavaScript and you can call methods on it.
window.external.Set(lat, long, alt, gUncert);
However you don't seem to be able to test for the existence of methods off of it. For example the following JavaScript generates an exception for me even though I have a Set method:
if (window.external && window.external.Set) {
javascript webbrowser .net technical csharp 2011 Feb 17, 1:01Brian Christian on his involvement in the 2009 Turing Test and his goal of winning Most Human Human.
history ai science 2010 Aug 20, 11:20
For a new project I'm working on involving IE's installed Accelerators and OpenSearch search providers via the Windows 7
Accelerator Platform, I've created a C#/COM interop class for those APIs.
Download the osinterop.cs interop file here.
technical accelerator csharp com 2010 Jun 7, 2:40Maps of where tourists vs locals take photos in major cities like New York, San Francisco, etc. based on geotagged photos on Flickr.
geolocation geo geography map flickr photo tourist technical visualization 2010 Mar 9, 5:26I have often wondered where furniture stores get their fake TVs, PCs, etc. Yes, apparently there is a store where they buy that. Now about the chotchkies in Applebees or Red Robin...
electronics fake tv pc store purchase 2010 Mar 5, 6:06iPhone vs Android adoption per state and per gender. Apparently I'm out of my demographic with my G1.
android apple iphone g1 statistics cellphone google 2010 Jan 29, 3:54
Raymond Chen has some thought experiments useful for discovering various kinds of stupidity in software design:
Tim Berners-Lee's principles of Web design includes my favorite: Test of Independent Invention. This has a thought experiment containing the construction of the MMM (Multi-Media Mesh) with
MRIs (Media Resource Identifiers) and MMTP (Muli-Media Transport Protocol).
The Internet design principles (RFC 1958) includes the Robustness Principle: be strict when sending and tolerant when receiving. A good one, but applied too liberally can lead to interop issues. For instance, consider web browsers.
Imagine one browser becomes so popular that web devs create web pages and just test out their pages in this popular browser. They don't ensure their pages conform to standards and accidentally end
up depending on the manner in which this popular browser tolerantly accepts non-standard input. This non-standard behavior ends up as de facto standard and future updates to the standard
essentially has had decisions made for it.
technical design principles software development 2010 Jan 20, 8:28GZip vs Deflate execution speeds. Deflate found to be much faster in particular cases and about the same in the rest.
gzip deflate performance technical http compression programming development blog 2010 Jan 19, 1:49Fonts are back in! "In this collection, we’d like to present an overview of 50 of the best Free, New and High-quality Modern, Handwritten, grunge, Cartoon style fonts for clean and professional
designs in 2009."
font typography text download design free 2009 Dec 31, 4:40"Nokia has been struggling a bit this year, but this "hack it" to get your phone unboxing is pretty interesting. Once you "root" the box it opens up and a little puff of smoke appears, along with
your phone (if you're a phone / gadget reviewer)." Makes me wonder how many devs and engineers they had working on the box to contain this phone.
phone video cellphone hack 2009 Dec 17, 12:06The Waxy list of supercuts (http://waxy.org/2008/04/fanboy_supercuts_obsessive_video_montages/) is ripe material for YouTube Doubler. For instance, I simply pop in Big Lebowski dude montage and Lost
dude montage and...
humor dude tv movie big-lebowski lost 2009 Dec 3, 1:54Uses Amazon's mechanical Turk program to test framing: "Framing the outcomes in positive vs. negative terms produced a reversal of participants’ preferences for the two programs. In condition 1, the
majority of respondents (69.4%) favored Program A, exhibiting risk aversion. In condition 2, the majority of respondents (65.3%) favored Program B, exhibiting risk seeking."
via:pskomoroch science experiment social risk security mechanicalturk amazon 2009 Nov 25, 7:09Relative URI resolution differences in browsers vs programming language libraries.
via:ericlaw url uri rfc web browser programming dotnet java technical 2009 Oct 30, 10:33"What does a Uniform Resource Identifier (URI) mean? Does it have a sense, and can it refer to things?" I hope it will cover some of the new scheme vs always HTTP scheme and distinct vs not distinct
URLs for a real world object and its web page perma-arguments.
via:connolly url uri w3c semanticweb http todo technical 2009 Sep 11, 8:39"In the W3C Media Fragment Working Group (MFWG) we have had long discussions about the use of the URI query (”?”) or the URI fragment (”#”) addressing approach for addressing directly into media
fragments, and the diverse new HTTP headers required to serve such URI requests, considering such side conditions as the stripping-off of fragment parameters from a URI by Web browsers, or the
existence of caching Web proxies."
fragment uri via:connolly media url query http http-header 2009 Sep 10, 6:42"Although HTML and XHTML appear to have similarities in their syntax, they are significantly different in many ways."
html html5 xml xhtml whatwg wiki technical 2009 Aug 24, 9:52Notes on how bin diff'ing tools work and thoughts on defeating them. "We call the threat "1-day exploits". Just few minutes after the release of patches, binary diffing technique can be used to
identify the vulnerabilities that the security patches are remedying."
exploit security binary diff tool research technical system:filetype:pdf system:media:document