Tag Archives: twitter

Tony Hawk Ride Feet On: I Almost Killed Myself [Tony Hawk Ride]

Related tweets from Twitter: coge3 : @bryaneward closed door demo. Couldn’t get in. 2009-06-04T17:56:01Z - Reply - View Tweet jodanmitchell : Markg81 - could you have a video demo on Word 07? The push to advising staff of the implications of the change is needed b4 end of term. 2009-06-04T17:55:42Z - Reply - View Tweet Mark_Monster : RT Demo of XAML rendering enginge for mobile devices: http://bit.ly/4MkRC Possible Silverlight rendering enginge for Windows Mobile 7? 2009-06-04T17:55:

Read more:
Tony Hawk Ride Feet On: I Almost Killed Myself [Tony Hawk Ride]

Google Wave: the sky is falling and Flash/Silverlight are dead

At the Google I/O conference this past week, they announced Google Wave .  Almost immediately, I started seeing Twitter replies, blog posts and various articles talking about how Google Wave is going to kill Flash/ Silverlight /JavaFX.  None of these made sense to me…and at that point I’d yet to see anything about Wave anyway.  I posed a few questions on Twitter as to why people felt Wave was an RIA platform killer (that’s what I was reading into a lot of the buzz against things like Si

Continued here:
Google Wave: the sky is falling and Flash/Silverlight are dead

Silverlight team and Twitter

The other night

Twilight 1.5: Multiple Views with MVVM

You may have noticed the new look for the Twilight Twitter Badge on my blog a few weeks ago. I wanted to add a few new looks for the badge and got one of them done but then decided I need to spend some more time on it before releasing it because I didn’t like the way the code was turning out. There were a couple of things I didn’t like: The code was too tightly coupled to the views/skins. This made it hard to add new views/skins without duplicating code. The views/skins weren’t blendable at all. To start my rework I began with this post by the Expression Blend/Design team on simulating sample data in Blend . The post is a very simple yet workable solution for displaying design time data in Blend so that you can work on the layout of your application. The only change I made was how I detected design mode . After playing around with that sample I decided that to implement this in Twilight I would need to switch to a Model-View-ViewModel approach so I started doing some research into using this approach with Silverlight. In my research I came across this post by Ryan Keeter on using MVVM in Silverlight. It was a nice simple explanation that made sense to me so I set out to combine the expression team example and this MVVM example. What I ended up with is pretty close to MVVM. I say pretty close because I don’t think it fully fits since the ViewModels hook into some of the Views Storyboard events and also control the Views VisualState transitions. Maybe that fits into MVVM, but it probably breaks some of the rules. However, for this tiny application it makes things a lot easier. I still have multiple Views per ViewModel and the Views have zero code which is what I really wanted. There are two ViewModels that I’m using: ListViewModel and RotatingViewModel. Then on top of these two ViewModels are four Views: Default, Large, Small, and Tiny. ListViewModel Views

Detecting Design Mode in Silverlight

One of the things I’ve been trying to getting a better understanding of is how to make the Silverlight projects I work on more blendable : In general, WPF and Silverlight controls should be “blendable”. ItemsControls need to display representative data within the design surface. The problem, at least for me, is that every example out there to detect design mode uses: var designMode = !HtmlPage.IsEnabled; Since the Html Bridge is disable inside of Blend, this does work for the most part, but what about when your xap is hosted on another server? In this case the Html Bridge is disabled by default so if someone doesn’t configure it correctly they will get your design time data. Mode HtmlPage.IsEnabled Blend false Visual Studio false Local Xap true Remote Xap false* Streaming Silverlight true** * This can be changed to true, but it is disabled by default . ** Enabled by default So I was trying to come up with another method to detect design mode in Silverlight and here is the best I have come up with so far: public bool IsDesignTime() { try { var host = Application.Current.Host.Source; return false ; } catch { return true ; } } What happens is that Application.Current.Host.Source works great when the plugin is hosted in a web page and will return the path to the xap file, but in design mode trying to access that property throws an exception. So if you hit the exception then you’re in design mode, otherwise you’re in a web page. Not super elegant but it feels better to me than checking if the Html Bridge is enabled since that isn’t a true check. Update: As Tom mentions in the comments, you can also use DesignerProperties.GetIsInDesignMode. But if your goal is to make your project more blendable then Visual Studio support might not be important. Mode DesignerProperties.GetIsInDesignMode Blend true Visual Studio false Local Xap false Remote Xap false Streaming Silverlight false So with this check worst case you get no data in the Visual Studio designer, but the Visual Studio designer isn’t that great anyway. Blend is the real goal. So instead instead of the above code you can use this code instead: public bool IsDesignTime() { return DesignerProperties.GetIsInDesignMode(Application.Current.RootVisual); } Thanks for the tip Tom! This work is licensed under a Creative Commons Attribution By license.

See more here: 
Detecting Design Mode in Silverlight

Twilight 1.1: Using a Yahoo Pipes Proxy

I just pushed a minor update to Twilight that you can now download on the codeplex site (version 1.1). I really wanted to allow the xap file to be hosted on other servers since many bloggers don’t have the ability to host their own xap files. After reading Scott Barnes’ post about replacing his header with Silverlight I decided I would take a similar approach. Instead of using a callback or trying to get the data directly, Scott followed Jonas’ post on using Yahoo Pipes to proxy data to Silverlight . I took the same approach and during the process refactored some of the code by moving all the data logic out to a separate set of classes. Now when the xap loads it checks to see if it can access the Html Bridge and makes sure it is on the same domain. If it is then it will just use the standard Twitter callback method, otherwise it uses the yahoo pipes proxy I created. The pipe I created simple takes a username and the number of tweets to return and grabs the twitter xml. I then use an HttpRequest in my code to get this xml from yahoo formatted as json which matches up to the json that I was getting from Twitter with the exception that there are a few wrapper objects I have to go through to get the tweets. I also moved all the update logic out of the page class and into the base data provider class since that made a lot more sense. I think the new code makes it much cleaner and the end result is you can now just stick the object tag up on your blog and leave the xap hosted on my server if you’d like. Here is the html you can use for the hosted version: