<?xml version="1.0" encoding="UTF-8"?> <rss version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:wfw="http://wellformedweb.org/CommentAPI/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
><channel><title>Stroep &#187; code</title> <atom:link href="http://blog.stroep.nl/tag/code/feed/" rel="self" type="application/rss+xml" /><link>http://blog.stroep.nl</link> <description>Just a collection of random works - Mark Knol</description> <lastBuildDate>Tue, 07 Sep 2010 07:08:59 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.0.1</generator> <item><title>Update Image class &#8211; added contextMenu</title><link>http://blog.stroep.nl/2009/11/add-contextmenu-to-images/</link> <comments>http://blog.stroep.nl/2009/11/add-contextmenu-to-images/#comments</comments> <pubDate>Fri, 06 Nov 2009 17:35:13 +0000</pubDate> <dc:creator>Mark Knol</dc:creator> <category><![CDATA[Other]]></category> <category><![CDATA[actionscript]]></category> <category><![CDATA[as3]]></category> <category><![CDATA[code]]></category> <category><![CDATA[snippet]]></category><guid isPermaLink="false">http://blog.stroep.nl/?p=812</guid> <description><![CDATA[<img src="/wp-content/uploads/image-contextmenu.jpg" alt="" class="alignleft" />I've updated my <a href="http://blog.stroep.nl/2009/06/nlstroeputilsimage/">Image class</a>. It is irritating flashsites break the right-click contextmenu. Well, I can't fix that and Adobe should look at that, but I think it would nice to add some of the browser - features to my image class. ]]></description> <content:encoded><![CDATA[<p><img src="/wp-content/uploads/image-contextmenu.jpg" alt="" class="alignleft" />I&#8217;ve updated my <a href="http://blog.stroep.nl/2009/06/nlstroeputilsimage/">Image class</a>. It is irritating flashsites break the right-click contextmenu. Well, I can&#8217;t fix that and Adobe should look at that, but I think it would nice to add some of the browser &#8211; features to my image class.</p><p>Currently I have these options added to the Image class:</p><blockquote><p> <strong>View image</strong><br /> Views image in new window/tab. I used NavigateToURL to make this happen.</p><p><strong>Save Image as..</strong><br /> Saves image on your computer. I used my ImageClass.saveLocal() to make this happen. This is only available within FP10, but I think this is no problem anymore because < a href = "http://www.adobe.com/products/player_census/flashplayer/version_penetration.html" > 93 %</a> (September 2009) has FlashPlayer 10, so most people have it, and I don&#8217;t support outdated software <img src='http://blog.stroep.nl/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /></p><p><strong>Copy Image location</strong><br /> Copies the url to the clipboard, using System.setClipboard(url). It&#8217;s a pity I can&#8217;t create a &#8216;Copy Image&#8217; function, because pushing bitmapdata into the clipboard is only supported in AIR.</p><p><strong>Send Image</strong><br /> Sends the url to the mail-client, using &#8220;mailto:&#038;body=&#8221; + src. Also a pity; I can&#8217;t add the image directly into the mail.</p></blockquote><p><strong>How to enable the contextmenu:</strong></p><div class="bbCSH" style="font-family: monospace;"> <span style="color: #0066CC;">import</span> nl.<span style="color: #006600;">stroep</span>.<span style="color: #006600;">utils</span>.<span style="color: #006600;">Image</span>;</p><p><span style="color: #000000; ">var</span> myImage:Image = <span style="color: #000000; ">new</span> Image<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;myImage.jpg&quot;</span><span style="color: #66cc66;">&#41;</span>;<br /> myImage.<span style="color: #006600;">enableContextMenu</span> = <span style="color: #000000; ">true</span>; <span style="color: #808080; font-style: italic;">// enable it!</span><br /> <span style="color: #0066CC;">this</span>.<span style="color: #006600;">addChild</span><span style="color: #66cc66;">&#40;</span>myImage<span style="color: #66cc66;">&#41;</span>;<br /> &nbsp;</div><p> I still love this class, I use it a lot. I want to encourage you to please add these kind of usability things to your apps / websites. And share them! Yes, it takes some extra time to create/add it, because this IS the finishing touch, but a lot of people will like this kind of features.</p><p><strong>Download</strong><br /> Check out the <a href="http://code.google.com/p/stroep/source/browse/trunk/nl/stroep/utils/Image.as">Image class</a> at<a href="http://code.google.com/p/stroep">googlecode</a></p> ]]></content:encoded> <wfw:commentRss>http://blog.stroep.nl/2009/11/add-contextmenu-to-images/feed/</wfw:commentRss> <slash:comments>3</slash:comments> </item> <item><title>Stroep @ Googlecode</title><link>http://blog.stroep.nl/2009/06/stroep-googlecode/</link> <comments>http://blog.stroep.nl/2009/06/stroep-googlecode/#comments</comments> <pubDate>Thu, 04 Jun 2009 19:33:32 +0000</pubDate> <dc:creator>Mark Knol</dc:creator> <category><![CDATA[Code snippets]]></category> <category><![CDATA[actionscript]]></category> <category><![CDATA[code]]></category> <category><![CDATA[google]]></category> <category><![CDATA[googlecode]]></category><guid isPermaLink="false">http://blog.stroep.nl/?p=647</guid> <description><![CDATA[<img src="http://blog.stroep.nl/wp-content/googlecode.jpg" alt="" title="googlecode" width="100" height="100" class="alignleft size-full wp-image-652" />Today I created a <a href="http://code.google.com/">googlecode </a>account. Now I can easily share code with you guys. :)<strong>check it out</strong> <a href="http://code.google.com/p/stroep/">http://code.google.com/p/stroep/</a> ..or directly go to the source: <a href="http://code.google.com/p/stroep/source/browse/">http://code.google.com/p/stroep/source/browse/</a>]]></description> <content:encoded><![CDATA[<p><img src="http://blog.stroep.nl/wp-content/googlecode.jpg" alt="" title="googlecode" width="100" height="100" class="alignleft size-full wp-image-652" />Today I created a <a href="http://code.google.com/">googlecode </a>account. Now I can easily share actionscript classes with you guys <img src='http://blog.stroep.nl/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /></p><p><strong>check it out</strong><br /> <a href="http://code.google.com/p/stroep/">http://code.google.com/p/stroep/</a><br /> ..or directly go to the source:<br /> <a href="http://code.google.com/p/stroep/source/browse/">http://code.google.com/p/stroep/source/browse/</a></p> ]]></content:encoded> <wfw:commentRss>http://blog.stroep.nl/2009/06/stroep-googlecode/feed/</wfw:commentRss> <slash:comments>2</slash:comments> </item> </channel> </rss>