Background Music Queue with AVPlayer and iOS4

Update 2010-Nov-11: Apple has come out with AVQueuePlayer in iOS 4.1, and presumably most people are going to move to the latest version now that it performs well even on the 3G, but the AVPlayer can still be used to manually create a queuing of items, but if you want all the hard work to be done for you, with only a few limitations, then use AVQueuePlayer instead.

Update 2010-Oct-19: Apple has been updating their documentation slightly, and it has more information now with regard to setting up an asset. This is more specifically for video, but it might help fill in the blanks for just audio. AVPlayer Playback Guide

The iOS 4.0 framework introduced AVPlayer which allows playing a MP3s from the iTunes Music Library in the background without using the iPod music player.  This has a couple benefits over the MPMusicPlayerController in that you can add new items, stop, or play music in the background. Also, a custom icon can represent your app in the multitasking menu where the ipod controls are located. If you stick with [MPMusicPlayerController iPodMusicPlayer] you can play music in the background through the ipod player, but once an app goes into the background, it no longer has control over the playback of the music.
Continue reading

Microsoft marries jQuery for VS 2010

According to Scott Guthrie, jQuery will be integrated into Microsoft’s Asp.Net platform including Visual Studio 2010. They plan to basically just give developers a much better experience while using it along with Asp.Net AJAX, but they will use the main branch from jQuery and adhere to its MIT open source license.  Javascript intellisense is already implemented in the 2008 line of Visual Studio, but this will enhance the jQuery library with better intellisense documentation. This is definitely great news.

Correct Click Event on Typing Enter

If you work with ASP.Net and have multiple buttons on the form that correspond to different textboxes you’ve probably run into the problem of a user pressing the “Enter” key and submitting to the wrong button’s server “Click” event.

I finally found the solution @ http://forums.asp.net/p/1292662/2501472.aspx using Panel and DefaultButton.

You can put TextBox and Button inside the Panel and use DefaultButton property. In that case you will not need any javascript:

<asp:Panel ID="Panel1" runat="server" DefaultButton="Button1">

Meepers Reborn After 10 Years

Back in my early teen years I learned about this programming thing called BASIC, and from there borrowed/bought a bunch of books to learn how to make a video game (amongst VB 6.0 apps). The game I decided to make is reminiscent of one of my favorite games, The Legend of Zelda for the original Nintendo Entertainment System. It is meant to only be the dungeons of the game, and thus currently has no design for an overworld. The game was created in the mid-1990s. I created it as a result of my learning how to program in C. It was developed through the reading of the book Teach Yourself Game Programming In 21 Days by Andre LaMothe. I am now going to recreated the game using C# and XNA Game Studio 2.0 in order to get the game up and running as quick as possible. This way I might even be able to play it on my XBox360.

Websites as Zip files?

I was just thinking, while reading some posts on how to improve Apple’s new image skimming technology, how to make websites load faster.  I think that in the future websites should be downloaded as single compressed files, or a handful of compressed files in order to utilize parallelization. This way you could wrap all your images up in a .zip file, all your javascript files, all your content, etc. Sure there could still be some images loaded dynamically or separately, as well as other resources, but if you can get a speed increase by using a hack of embedding a bunch of 160×160 pixel images into a single 160×3200 pixel image in order to eliminate the multiple requests, why couldn’t you do the same thing by archiving all the images into a single or handful of archive files, and then having the browser automatically decompress or just unarchive the images and display them.

There of course needs to be new technology in place for this to happen, but I think it could be a good idea? Maybe having the images referenced differently <img src=”image.zip?imgLogo.gif”> or new attribute <img src=”imgLogo.gif” archive=”imageMain.zip”> or it could be somehow seemless using headers, or some other method where the images would download once as an archive and then be treated like cached images.

Just a quick rambling and as always I always love to hear other people’s thoughts.

Radical UI Ideas – No Applications? No Desktop?

Aza Raskin from the humanized.com team spoke at one of Google’s Tech Talks about user interface design. He starts with talking about user interface and interaction and his ideas on things to avoid and what needs to change.  One cool thing he discussed was how there needs to be services, and a universal access interface (basically APIs) that would allow any interface to be used for any service and thus would allow the focus to move from the tools to the content itself and what you are trying to do with it.

The rest of the talk is mainly about how the desktop is useless for the most part as it does nothing for you in terms of content. Content is key, it’s all we care about. We want to create and manipulate content.

He speaks about removing the idea of the application, as they are silos in terms of user interface and content interaction.  He presented how Microsoft Word becomes bloated trying to be Mathematica for calculations, and Photoshop for editing images, as well as being a word processor, but it does so poorly. Applications also cause user interface to become stale and toolboxes come along to make development easy but non-innovative.

He showed of Enso a product they have developed that marries the graphical user interface (GUI) with the command line interface (CLI).  Non-technical people are used to CLI whenever they use google to search for something. So what Enso does is allow you to select something, then hold down the capslock key and start typing commands to manipulate the content, such as spell check, calculate, flip image horizontally, and many more. It also has a navigation command set so you can open an application or document, or switch to a different window, etc.  It’s tough to explain it all, much better to see it in action, so just watch the video. It’s long, but very informative for those interested in user interface and design.