AdSensor is a Windows Vista/Windows 7 Sidebar gadget that monitors your AdSense account. Now you can keep track of your Internet riches without logging into the AdSense Web page. You can read more about it here.
This update adds 4 new backgrounds that you can select using your mouse wheel. Changes in http requests should make it more robust. Enjoy.
Available on the downloads page.
Programming Computers
Regular Expression Library – A Silverlight regular expression tester.
“wordwrap” for JavaScript - James Padolsey - This function emulates PHP’s wordwrap.
Using your Personal Computer
10 Useful Firefox Extensions to Supercharge Firebug - Though Firebug is already fully packed with features out of the box, several extensions out there can enhance its utility. In this article, you will find the 10 best Firefox extensions for Firebug that will make your life, as a developer or designer, easier.
Paul Thurrott's SuperSite for Windows: Microsoft Security Essentials Public Beta – Microsoft’s new security product has been meeting with favorable reviews. Here’s an in depth review of the beta.
Science and the Environment
Slashdot Science Story | Spaceport America Begins Construction - After getting their FAA license and securing funding, the 27 s quare mile development project has officially begun. The target date for completion is the end of 2010.
Electric cars seen as killer app for smart grid | Green Tech - Forward-looking utilities are gearing up to tap into the stored energy that plug-in electric vehicles can provide using smart-grid technology.
Light Sensor Breakthrough Could Enhance Digital Cameras - New research by a team of University of Toronto scientists could lead to substantial advancements in the performance of a variety of electronic devices including digital cameras.
IBM working on battery breakthrough - IBM announced today that it is developing a next-generation rechargeable battery capable of storing 10 times more energy than today's top lithium-ion batteries.
Strongest Evidence Yet that Saturn's Moon Has Liquid Water | Popular Science - In 2005, scientists found the first signs that Saturn's moon Enceladus might have a salty ocean beneath its icy outer shell. New evidence -- based on analysis by the NASA Cassini spacecraft, currently passing near Saturn -- reveals a high level of a sodium compound that could indicate the presence of water.
BBC NEWS | Science & Environment | 'Oldest musical instrument' found - Scientists in Germany have published details of flutes dating back to the time that modern humans began colonising Europe, 35,000 years ago.
Slashdot Hardware Story | Beamed Space Solar Power Plant To Open In 2016? - The Pacific Gas and Electricity Company, per this 'interview' with the CEO of Solaren on their affiliated site, announced PG&E's plans to buy 200MW of base-load power from a Solaren beamed space solar power plant by 2016." I wish the skeptic in me would be quiet.
On the Web
jQuery TOOLS - The missing UI library for the Web - a collection of the most important user-interface components for today's websites. This single JavaScript file weighs only 5.8 Kb.
10 impressive Adobe AIR apps | Webware – CNET - Since Adobe Systems relaunched its AIR marketplace, I've been spending some considerable time there. There are so many great apps, it's hard to pick just a handful worth talking about.
Ext - A foundation you can build on – Ext Core is a lightweight, high-performance cross-browser JavaScript library for building dynamic web pages.
jLinq - Javascript Query Language - jLinq is a Javascript library that lets you write queries against arrays of javascript objects. jLinq is completely extensible so you can write your add-ins and they will work with the rest of the framework without any additional programming!
Stuff I just Dig
Slashdot Technology Story | Kodak Kills Kodachrome – Sorry Paul Simon, but some really has taken away your Kodachrome.
XML Aficionado: Wireless charging… - WildCharge has announced that they will begin shipping their WildCharge Skin for the iPhone in July: the skin is a protective gel cover for the iPhone that also includes the contact module and charges the iPhone once it is placed on the WildCharger Charge Pad.
Map Label on Package – From KK LIfe Stream - “I thought this was pretty clever. I just received a package from FedEx. On its label was printed a map to my house. So instead of installing a GPS in every truck, FedEx prints out a map label. If the driver can't find the delivery place, they just look on the package itself. Brilliant!”
Toolmonger » Blog Archive » FYI: Why Tape Measure Claws Move Around – Only a tool geek like me would find this cool. Today a friend asked me a question that the folks at Stanley tell me they hear all the time: why does the claw — you know, the little catch at the end of your short tape measure — move back and forth? Is it just poorly attached? The short answer: no, the loose claw is no accident of manufacture. It’s loose on purpose.
Pick of the Week
Evernote - Take notes? This program organizes notes without getting in your way. Great for TODO lists. My only compliant is that the keyboard shortcuts are a bit odd.
I hunted around for a JavaScript method to convert URLs in a text stream to hyperlinks and came up short. I wrote this quickie method that works for the limited data I’ve thrown at it. There are likely more robust methods but darn if I could find one.
function convertUrlsToLinks(text)
{
var matchUrl = /(ftp|http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/|\/([\w#!:.?+=&%@!\-\/]))?/gi
return text.replace(matchUrl, '<a href="$&">$&</a>');
}
OK, JavaScript guru’s. Is there a better way?
XMLHttpRequest (XHR) is a DOM API that can be used inside a web browser scripting language, such as JavaScript, to send an HTTP request directly to a web server and load the server response data directly back into the scripting language. Once the data is within the scripting language, it is available as both an XML document, if the response was valid XML markup, and as plain text. (Thank you Wikipedia).
Generally, you’ll want to make these calls asynchronously so you don’t block the UI thread. Most examples go something like this.
var xhReq;
function ajax()
{
xhReq = new XMLHttpRequest();
xhReq.open("GET", "sumGet.phtml?figure1=5&figure2=10", true);
xhReq.onreadystatechange = onSumResponse;
xhReq.send(null);
}
function onSumResponse()
{
if (xhReq.readyState != 4) { return; }
var serverResponse = xhReq.responseText;
...
}
Since the callback does not provide the original request object, the request is saved in global variable. Yuck! Also, if you have more than one request you’ll need more than one global variable. Double Yuck!
Fortunately, JavaScript supports closures so you can use an anonymous method inline as follows.
function ajax()
{
var xhReq = new XMLHttpRequest();
xhReq.open("GET", "sumGet.phtml?figure1=5&figure2=10", true);
xhReq.onreadystatechange = function()
{
if (xhReq.readyState != 4) { return; }
var serverResponse = xhReq.responseText;
...
};
xhReq.send(null);
}
Even though xhReq is local, it can still be referenced in the callback function because of something called a “Closure”. Not all languages support closures, but JavaScript is one of them. In this case, the “Closure” allows us to use xhReq in our callback function even though the callback function will execute long after the ajax function finishes.
For simple callbacks, this is a good way to go since it keeps the logic together. However, there are times when you may want to have the callback in a separate, named function because it is lengthy or so it can be reused by other code. It may look like your stuck, but the answer is simple. Use an anonymous function to call your named function and pass the request object as a parameter.
function ajax()
{
var xhReq = new XMLHttpRequest();
xhReq.open("GET", "sumGet.phtml?figure1=5&figure2=10", true);
xhReq.onreadystatechange = function() { onSumResponse(xhReq); };
xhReq.send(null);
}
function onSumResponse(request)
{
if (request.readyState != 4) { return; }
var serverResponse = request.responseText;
...
}
We can now call ajax() as often as we wish without worrying about side-effects to global variables and our callback function is “local” to invocation of the request.
It may look a little odd to write functions as parameters to functions, but once you get use to it, it can make for better, more useful code.
Programming Computers
Windows API Code Pack for Microsoft .NET Framework - The Microsoft Windows SDK is a set of tools, code samples, documentation, compilers, headers, and libraries that developers can use to create applications that run on Microsoft Windows operating systems. The Windows SDK combines two formerly separate SDKs: the Platform SDK (PSDK) and the .NET Framework SDK. For more information on the Windows SDK, visit our MSDN Developer Center.
Episode 33: Getting the Scoop About Olso and M with Shawn Wildermuth : Deep Fried Bytes Technology Podcast - In this episode listeners will get some real world examples and use cases for using Oslo and M along with a clearer understanding about DSLs and what the future may hold.
VS Addin: Fast Add Reference Dialog - No more Coffee Break! – The buzz is that this extension rocks. Haven’t tried it myself yet but anything has to be better the current VS implementation.
CodeProject: A Project Dependency Graph Utility For Visual Studio 2008 – Here’s what looks to be another cool addin for VS 2008. The author, Marc Clifton is well regarded and has several very good article on Code Project.
TestDriven.Net 2.22 RTM - What’s New? – If I could only have one addin in Visual Studio, this would be it.
Using your Personal Computer
Use The Command Prompt To Open And Display Folder Contents In Windows Explorer – It’s as easy as “start .”
InfoQ: Opera Unite Gives the Power Back to the People - Opera Software has just released the latest version of their browser, Opera 10 Beta 1, incorporating a server technology called Opera Unite allowing users to directly connect to each other to share data and communicate without an intermediary running the necessary services for them.
Science and the Environment
Riversimple to Unveil Open Source Car in London This Month - The company plans to unveil its first car in London later this month, a small two-seater that weighs roughly 700 pounds. If you agree to lease one for 20 years (yes, 20), Riversimple will throw in the cost of fuel for the lifetime of the lease.
First floating wind turbine buoyed off Norway | Green Tech - Siemens and energy company StatoilHydro installed what they call the first large-scale floating turbine. The Hywind turbine will still have a ballast that is tied to the sea floor with cables.
CT Scan Nearly As Good As Regular Colonoscopy / Science News – Having just had one of these the CT option would have been much more pleasant.
Most Efficient And Stable Source Of Pure White Light Ever Achieved - Researchers are reporting the first use of a fundamentally new approach in the quest to snare the Holy Grail of the lighting industry: An LED (light-emitting diode) — those ultra-efficient, long-lived light sources — that emits pure white light.
Slashdot Science Story | "Definitive Evidence" For Ancient Lake On Mars - A UC Boulder research team has discovered evidence of a shoreline on Mars of a 3 billion year-old lake 80 square miles in area and 1,500 feet deep (roughly the equivalent of Lake Champlain).
On the Web
Imagine Google Living Inside Your Home - If Google were a real human being who happened to live in the same apartment as you, will that make your life any easier? Well, this video might give you a clue.
Explore Google Search – Google posts a page about it’s search features in response to the recent surge in popularity of Microsoft’s Bing search.
Lifehacker - Microsoft's Browser Comparison Chart Offends Anyone Who's Ever Used Another Browser – Insulating and irritating are the two words that come to mind when I read this chart. Microsoft FTL.
Asp.Net vs php : speed comparison - Why is the myth that php is faster than Asp.Net so prevalent? Asp.Net is faster than php, here are the facts.
Stuff I just Dig
World's Smallest VGA Display is Literally the Size of a Thumbnail | Popular Science - tiny displays to make sharp, high-end electronic viewfinders in HD video and still cameras.


Wikipedia as a Printed Book - Seriously! – This Wikipedia book has some 5,000 pages and it’s a compilation of 400+ featured articles all picked from Wikipedia. Now this is some serious bookage…
Pick of the Week
Ted Notepad - TED Notepad is a chrome-less freeware text editor. It offers 197 text-processing functions, innovative features and other advanced tools. All of them on hotkeys; all designed for quick advanced editing. This light-weight portable notepad replacement fits on any USB flash disk and loads instantly with no installation required. What I like about this editor is how darn fast it starts. Faster startup than Notepad. Lacks regular expression search/replace and syntax highlighting but the speed more than makes up for it.
Posted
Friday, June 19, 2009 |
0
Comments
Tags
.Net,
ASP.Net,
Browsers,
Freebies,
Links,
Online Applications,
Programming,
Science,
Technology
A couple of nice tweeks for this release. First, the layout has been improved to handle languages other than English better. Dutch turns out to be a challenging one to fit in Simply Weather’s small format. Here’s an example.
Check out the translation of “Humidity”. Also, the current conditions are sometimes long enough to wrap (otherwise it would over write the current temp).
I’ve also added a new “dark” background. Also, backgrounds can be changed using your mouse wheel. Don’t work if you can’t remember all this. The settings dialog has all the information you need.
The current temp in Celsius was missing the “degree” symbol (fixed). The weather images are cached locally in case Google changes the locations on me again. Enjoy.
Programming Computers
Unit Testing is Not a “Figure It Out Later” - If someone tells you to wait and do it later on the “next project”, it’s really not their decision. Unit testing is for programmers and is done while you code. It’s a decision done by the programmer because he/she cares about better code and less bugs for the good of the team, the business, and its users.
Guy Burstein : Getting Started with jQuery in Visual Studio 2008 – How to add add jQuery IntellSense in Visual Studio 2008, and how to add jQuery to a simple Web Application inside Visual Studio 2008.
Fabulous Adventures In Coding : What does the optimize switch do? - What optimizations the C# compiler performs when you specify the optimize switch. Answer, not much. The jitter does all the heavy lifting.
ASP.NET MVC and SOLID Programming Principles June 2009 : Steve Smith's Blog – Steve gave this talk for us at the Ann Arbor .NET users group. Confirms what I’ve experienced over the last year of unit testing and inversion of control.
Science and the Environment
Slashdot Hardware Story | "Colossal Magnetic Effect" Could Lead To Another Breakthrough In Storage Tech - Scientists with the Carnegie Institution for Science have discovered what could bring yet another massive advance in memory and storage.
Solar-Powered Infinium Race Car| Popular Science - More spacecraft than automobile, Infinium is plastered in black photovoltaic strips capable of drinking sunlight at rates rivaling the solar cells found on spacecraft. A specially-designed electric motor encased in one of the car’s three wheels peaks at 98 percent efficiency. The 50 lb lithium battery is 1/3 the size of the Chevy Volt’s and supplies the car for up to 200 miles without a drop of sunny fuel.
Using your Personal Computer
Rico Mariani's Performance Tidbits : Visual Studio 2010 Performance Part 2: Text Editor - Many people have reported that editing with the new editor is slower. I’ve experienced the same thing myself so I certainly do not want to accuse people of hallucinating but I thought it might be interesting to understand why that might happen, especially since this new editor is supposed to be better than the old.
Virtual Disk - Desk Topmost - Floats the desktop on top instead of minimizing all the windows. Interesting concept.
McAfee and Symantec fined over automatic subscription renewal – I’ve always thought of these programs more as viruses because of their aggressive renewal tactics. Apparently, the New York State agrees.
Lifehacker - Lifehacker Speed Tests: Safari 4, Chrome 2, and More – Confirms what I’ve experienced. Chrome fast, Internet Explorer slow.
Lifehacker - ViGlance Converts the Vanilla Taskbar into a Windows 7-like Superbar – Works surprisingly well. Nice feel and effects. Portable app. Just download and run.
Stuff I just Dig
Toolmonger » Blog Archive » It’s Just Cool (Or Hot): H2Glow - It makes your water glow as it flows out of the tap, blue if it’s safe to touch and red if it gets too hot.
Lifehacker - DIY Magnetic Fridge Pen - MacGyver Tip -If you've got a grocery list that lives on your refrigerator but never seem to have a pen nearby, reader Jay details how he made his own magnetic Bics on the cheap and easy.
What Really Prompts The Dog's 'Guilty Look' – Surprise, the dog doesn’t feel guilty at all. It’s just us projecting. Wonder how much grant money that cost?
Search Me - The New York Times > Magazine – Really cool pictures of data centers. Sort of like center folds for geeks.
PIck of the Week
Foxit Reader - For straight up reading and printing of PDF's, Foxit is the way to go. It's fast, light and does not assimilate your system compared to the Borg like Adobe Reader. Sumatra Reader is another one to keep an eye on.
Posted
Friday, June 12, 2009 |
0
Comments
Tags
.Net,
ASP.Net,
C#,
Browsers,
Freebies,
Life,
Links,
Online Applications,
PC Tips,
Programming,
Science,
Technology
Oddly, jQuery does not have delay function. The usual technique, from what I gather, is to use the animate function. Most examples use the opacity property as an animation target.
$(selector).animate( { opacity: 1}, 3000, function() { /* callback */ });
This works beautifully, but it does affect the “opacity” setting. Most of the time, it’s not an issue, unless you’re working on an element with a non-default opacity.
Interestingly, “animate({ }, 3000)” doesn’t work.
Then I tripped across this code at http://james.padolsey.com/javascript/jquery-delay-plugin/
$.fn.delay = function(time, callback){
// Empty function:
jQuery.fx.step.delay = function(){};
// Return meaningless animation, (will be added to queue)
return this.animate({delay:1}, time, callback);
}
Nice, but then some comments on http://stackoverflow.com/questions/316278/timeout-jquery-effects allowed me to modify it even further.
$.fn.delay = function(time, callback)
{
return this.animate({ opacity: '+=0' }, time, callback);
}
The “plus equal zero” tip supplies an animation target that does nothing without having to create the step delay function.
As a function, it’s chainable, so you can get some cool effects with little effort.
$("#status).fadeIn("fast").delay(3000).fadeOut("slow");
How did we ever program without the Internet?
I’m surprised at how much code I review that still does not take advantage of the newer constructs of C#. Here’s an (admittedly contrived) example.
static void Main()
{
var names = new[] { "name1", "name2", "name3", "name4", "name5", "name6", "name7" };
var count = 0;
foreach (var name in names)
{
if (name.Contains("name"))
count += 1;
}
Console.WriteLine(count);
}
Now compare it to this.
static void Main()
{
var names = new[] { "name1", "name2", "name3", "name4", "name5", "name6", "name7" };
Console.WriteLine(names.Count(name => name.Contains("name")));
}
Which would you prefer to maintain? Which one more clearly communicates the intent of the program?
If that’s not enough to convince you, consider that extension methods like Count() are static, which allows for further optimizations and parallel execution opportunities.
If you consider yourself a pro, you owe it to yourself (and your fellow developers) to keep on top of these things. Read books, pair program, embrace the changes and learn from others. People smarter than you and I have spent countless hours thinking about these things and improving them. Shouldn’t you take advantage of those efforts?
Science and the Environment
Breakthrough In Quantum Control Of Light: Implications For Banking, Drug Design, And More – Scientists use a superconducting electronic circuit known as a Josephson phase qubit to prepare highly unusual quantum states using microwave-frequency photons.
Subaru to sell electric Stella next month | The Car Tech blog – CNET - The Stella EV stores electricity in a lithium ion battery pack, powering a 47 kilowatt motor. Range is only about 56 miles, with a top speed of 62 mph. Subaru claims a recharge time of 15 minutes at a quick charging station, or 5 hours at a 200 volt AC outlet, which are typical numbers for current technology.
Programming Computers
Adventures in MVVM – Commanding with List Boxes – Continuing his series of “Adventures in MVVM”, Brian talks about a few different approaches to working with List Boxes with the MVVM pattern.
Tip#66: Did you know... how to insert quotes values automatically while typing the attrib values? - It's a nice time saver if you would like the HTML editor to automatically add quotes for the attribute values while you are typing.
David Hill's WebLog : Prism Quick Start Kit - Prism is a library of design patterns that work together to provide a solid architectural foundation on which you can build real-world Silverlight and WPF applications that are flexible and maintainable. Some of the patterns that Prism contains are fairly simple while others are more complex, but they are designed to work together to solve some of the challenges you face when building these real-world applications.
WCF Service References Generating Empty Proxy – If you have worked in WCF for anytime, you’ve likely found that the service reference update mechanism in WCF can be a bit flaky and often generates empty proxy classes. Here’s a few tips on how remedy the situation.
CThru and SilverUnit – Home – Great idea. Unfortunately, it requires Type Mock Isolator to run. Sure wish Microsoft would solve this problem.
JavaScript InfoVis Toolkit – Demos - Toolkit provides tools for creating Interactive Data Visualizations for the Web.
On the Web
Google throws down the gauntlet, announces plans to sell e-Books - In discussions with publishers at the annual BookExpo convention in New York over the weekend, Google signaled its intent to introduce a program by that would enable publishers to sell digital versions of their newest books direct to consumers through Google. The move would pit Google against Amazon.com, which is seeking to control the e-book market with the versions it sells for its Kindle reading device.
Google Docs gets x'ier with .docx and .xlsx support | Webware – CNET - Google Docs now supports .docx and .xlsx, two files formats found in nearly every modern day word processor or spreadsheet editor.
25 Best Programmer WebComic Strips – Interestingly (or sadly depending on your perspective) I’ve seen all but two of these before. Good for a smile or two.
Lifehacker - Notify Mee Sends an Email When a Downed Site Is Working Again - Just enter the afflicted web site's URL or any other link you're trying to reach and include your email so that Notify Mee can inform you when the site is up and running again. If the problem is on your end, Notify Mee will skip the email and let you know that the site is working fine.
Official Google Webmaster Central Blog: Introducing Page Speed - Page Speed is a tool we've been using internally to improve the performance of our web pages -- it's a Firefox Add-on integrated with Firebug.
Google LatLong: Introducing smart navigation in Street View: double-click to go (anywhere!) - You can now use Street View's smart navigation to travel to a new place just by double clicking on the place or object you would like to see. We have been able to accomplish this by making a compact representation of the building facade and road geometry for all the Street View panoramas using laser point clouds and differences between consecutive pictures.
Official Google Blog: Square your search results with Google Squared - Google Squared is an experimental search tool that collects facts from the web and presents them in an organized collection, similar to a spreadsheet.
Stuff I just Dig
Top Educational Websites For Children That Are Fun | MakeUseOf.com - Parents today have a far greater selection of fun games or sites that are also educational and won’t bore your poor kid to death.
Pick of the Week
JkDefrag - This guy should be given a metal in my opinion. Fast, complete and free, it does as good or better than the commercial disk defraggers and without all the useless graphics.
previous | next
powered by Bloget™