Tuesday, November 20, 2007

Is Flock My Next Favorite Browser?

Just installed Flock, the new 'social' web browser. Not that I'm much of a socialite, but I was have wanted to check it out for awhile now. The install was painless and let me import all my Firefox bookmarks, cookies and history.

I have to say the built-in blog tool is pretty cool too. A couple rounds of logging in to my Blogger account and I've now got a handy blog posting tool I can quickly access anytime.

What I'm most interested in though performance; some posts have alluded to a smaller and more stable footprint than Firefox beta 3.0.

Here's to alternate surfing! Get yours at flock.com and let me know what your experience is like.

Blogged with Flock

[+/-] Read More...

Wednesday, June 20, 2007

Flex native drag-n-drop an image from external applications

Adobe AIR provides some nice tools for interacting with the desktop; local database, filesystem, clipboard and native drag and drop. I have been working on a project which requires the ability to drag images from any source and drop them into a container. Should be a simple task. All of the examples like Christophe Coenraets SalesBuilder on Air and the sample apps from Adobe sure make it look easy enough, but none of them explore what I needed to do; they all drag items out of the container, but not in.

Now given AIR is still a beta release, I hope what I present below will not be needed in the future because this took a while to figure out. Maybe I missed something, so if anyone points out an easier way to do this, I'm all ears.

It seemed the obvious thing to do is something along the lines of:


var data:BitmapData = e.transferable.dataForFormat(TransferableFormats.BITMAP_FORMAT) as BitmapData;
myCanvas.addChild(data.content);

Burn! The bitmapData object appears to have data; it has height, width and rectangle properties, the size value indicates there's data in there, but when attempting to add the image to myCanvas, addChild reports an error of 'child must be non null'. I just couldn't reach in and get at the bits.

This led me down a rosy path of trying just about everything I could think to get that pretty picture I wanted to drag in. I ended up with the following. It basically serializes the transfer object's data to file, then I simply pick it back up as an image (note there are no format checks or validation in this example... study purposes only).

Note that you will need the PNGEncoder class, adopted by Adobe from Tinic Uro. These are working versions for Flex 2 and 3.

JPGEncoder.as (text)
PNGEnc (text)

<?xml version="1.0" encoding="utf-8"?>
<mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml"
applicationComplete="init()" layout="absolute">

<mx:Script>
<![CDATA[
import flash.filesystem.*;
import flash.geom.Matrix;
import flash.display.IBitmapDrawable;
import flash.display.BitmapData;
import flash.display.Bitmap;
import flash.desktop.*;
import flash.events.NativeDragEvent;
import mx.controls.Image;

public function init():void {
myCanvas.addEventListener(NativeDragEvent.NATIVE_DRAG_ENTER, nativeDragEnter);
myCanvas.addEventListener(NativeDragEvent.NATIVE_DRAG_DROP, nativeDragDrop);
}

public function nativeDragEnter(e:NativeDragEvent):void {
if (DragManager.dragInitiator == myCanvas) return; // If your dragging over yourself, ignore
DragManager.acceptDragDrop(myCanvas);
}

public function nativeDragDrop(e:NativeDragEvent):void {
var data:BitmapData = e.transferable.dataForFormat(TransferableFormats.BITMAP_FORMAT) as BitmapData;
var img:Image = encodeImage(data);
myCanvas.addChild(img);
}

private function encodeImage(data:BitmapData):Image {
// write transfer object's data to file
var stream:FileStream = new FileStream();
var matrix:Matrix = new Matrix();
matrix.translate( 0 - ( data.rect.x + 1 ), 0 - ( data.rect.y + 1 ) );
data.draw( data, matrix );

var png:* = null;
png = PNGEncoder.encode(data);

var file:File = File.applicationResourceDirectory.resolve( "tmp.png" );
stream.open( file, FileMode.WRITE );
stream.writeBytes( png, 0, 0 );
stream.close();

// now we can load the image back in
var img:Image = new Image();
img.load(file.nativePath);
return img;
}


]]>
</mx:Script>

<mx:Canvas id="myCanvas" width"400" height="300" backgroundColor="#FFFFFF">
</mx:Canvas>

</mx:WindowedApplication>

Now, with the added call in the nativeDragDrop() function, we have what we need:

var data:BitmapData = e.transferable.dataForFormat(TransferableFormats.BITMAP_FORMAT) as BitmapData;
var img:Image = encodeImage(data);
myCanvas.addChild(img);

Simple? Not exactly. Obvious? Certainly not! But, it shows that Flex can do quite a lot, with a little elbow grease. I am looking forward to the next AIR release, which should fix a number of other bugs and missives that will make our apps really fly.

[+/-] Read More...

Monday, June 11, 2007

Already widgetized

No sooner do I give the code to embed a Sprout, Jeff puts one up on his site and gives a full-blown review. Thanks man!

You should get over to http://www.edutechie.com and find out how one dedicated person is actually doing something for education. Jeff is a professional student... er... lifelong student who didn’t want to leave education, so he got a job at a university working in instructional technology and supports six large departments on campus which include numerous smaller organizations. And yet he still has time to write up some fascinating and thought-provoking articles.

[+/-] Read More...

Saturday, June 9, 2007

Sprouts as a Widget?

You can now take a Sprouts tree and transplant it out into the wild:



I have implemented this feature in the Publish option. A popup with generated embed code lets you copy to the system clipboard, which you can then paste into wherever you want.

Big shout out to Jeff V. for prodding me to make Sprouts available as a widget - great idea Jeff!

[+/-] Read More...

Saturday, April 28, 2007

A graphic visualizer for web searches

I'd like to introduce you to Sprouts - a free online service that will let you create graphical trees of related web search items using a visual designer.

Sprouts is pre-pre-alpha, a lot of features are missing and stuff may break, like handling RSS feed variations. But I need your feedback. Is this a viable tool? Would you use it? Should I continue down this path?

Try out the demo here and give me your comments, thoughts, and feedback here on this blog. If you would like an account which allows you to save trees, let me know here or email me.

Quick status update

I can now serialize tree nodes, which means I can now write to database, file, or whatever, which I've desperately needed to get to the next step. I'll first write them out as HTML below the tree control area and provide an RSS feed. Hope to be able to spend time this weekend and flesh this part out and get an update out.

By wiring the addChild event on the SpringGraph component, you can query relatedObject.data to get an instance of the newly added graph object, not just an external reference to the Item object. I'm sure I'll be refactoring some code later on to take better advantage of Mark's control, there's a lot to it, and even more that appears to be undocumented. But, for now I'm pleased as punch that I keep finding more ways to use it.

Saving trees... to database

I now have trees saving to a database and a very basic user profiles in place. Each node and tree root is stored as separate records, and all relevant node data being stored. There is a bucket field for each graph item on the tree where some extra node information is being stored, and I haven't tested how well that info is getting stored, but this shouldn't impact overall data stores right now.

For now I plan on creating users via an invite-only system, but you'll be able to create and store trees to your user account, login later, and retrieve any of your previous work.

This is all obviously leading up to a beta launch, so if you have any input or features you'd like to see in Sprouts, just let me know. I still have plenty of work to do, but I do want to make sure I get all your great ideas in the next cycle.

[+/-] Read More...

Getting goal oriented

Putting up another little project in the GTD category. Taking a page from David Seah's Printable CEO series, I've come away with a simple task/goal manager that's more than a to-do list, but not a full blown project manager. More like a personal task manager to help set and achieve a wide range of goals, from daily tasks to life-long ambitions.

This project takes up the majority of the browser, so click here to run this project. Some screenshots below.


create stacks of goals


open a goal for it's task list

I'm not sure where this one will go, so if you have any ideas...

[+/-] Read More...

Timer project

I've been thinking about GTD lately and came up with this idea for time management while I was on vacation. I know, be-here-now, but actually we had a wonderful time in Greece and these kinds of ideas only come to me while falling asleep or in the middle of the night.

View more of the timer project here.
So, clicking the little nubs around the clock face brings up an event scheduler, and starting the timer to the right activates little red tickers. I still have to wire up the alarm when a scheduled event is reached, and there is no data store yet, but I thought I'd present it and hopefully get some early feedback.

[+/-] Read More...

Tuesday, January 2, 2007

We do good stuff for great people

Our focus on customer success is what sets us apart. Yeah, we build applications, but more important, we build long-standing relationships with our valued clients through commited teamwork, consistent delivery and on-going service. Check out some of our work below.

Big Picture Branding Co.



View
A beautiful concept site done completely in Flash, created for a potential web marketing and design firm.

Degailia Inc.



View
A start-up travel services company which provided a low cost alternative to large reservation systems for travel agencies. Involved a desktop application, interfacing with web-services to scrape HTML booking details from airline, hotel, rental car and travel service sites. Championed a web-based data service design for start-up travel services company, before the term 'web services' was defined.

Blueberry Systems



View
As co-founder, I designed a multi-tier, component oriented mortgage system in VB.Net, accessing an extensive SQL Server database through XML web services. Features Smart Client for hands-free distribution, custom object inheritance architecture for plug-in framework model and rules-based data mapping for third-party data integration. The website mimics the actual desktop application.

Greenwood Village Chamber of Commerce



View
Re-brand Chamber of Commerce with new website and updated logo. Site includes dynamic ASP pages for on-line event scheduling, data-driven resource and membership pages.


Shadownet



Developed custom Visual Basic applications leveraging a proprietary multi-tier, client-server, XML, RDS and COM+ based architecture. Utilized a SQL-Server backend for mutli-dimensional data warehousing. Created Flash-based website for Shadownet, complete with customer area for issue tracking and product downloads.

e-BookBot



Submitted to a potential client developing a desktop manager systems for e-book enthusiasts. Proposal included development of both desktop and web service components.

EMS Journal



Although this client has since closed shop, the EMS Journal was a wonderful site for emergrency medical pros to decompress in an on-line zen garden full of peaceful quotes and amuzing and antecdotes, and a built-in forum to share stories and knowledge.


Software Odyssey v1.0



Okay, a bit outdated, but it was a real cool Flash experiment in mathmatics and alternative menu and site navigation.

[+/-] Read More...