<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" media="screen" href="/styles/xslt/rss.xslt"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:c9="http://channel9.msdn.com">
<channel>
	<title>Channel 9 Forums - Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
	<atom:link rel="self" type="application/rss+xml" href="http://channel9.msdn.com/Forums/rss"></atom:link>
	<image>
		<url>http://mschnlnine.vo.llnwd.net/d1/Dev/App_Themes/C9/images/feedimage.png</url>
		<title>Channel 9 Forums - Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
		<link>http://channel9.msdn.com/Forums</link>
	</image>
	<description>Channel 9 keeps you up to date with the latest news and behind the scenes info from Microsoft that developers love to keep up with. From LINQ to SilverLight – Watch videos and hear about all the cool technologies coming and the people behind them.</description>
	<link>http://channel9.msdn.com/Forums</link>
	<language>en</language>
	<pubDate>Sun, 19 May 2013 23:27:16 GMT</pubDate>
	<lastBuildDate>Sun, 19 May 2013 23:27:16 GMT</lastBuildDate>
	<generator>Rev9</generator>
	<c9:totalResults>6</c9:totalResults>
	<c9:pageCount>-6</c9:pageCount>
	<c9:pageSize>-1</c9:pageSize>
	<item>
		<title>Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
		<description><![CDATA[<p>Hello, I am creating a rudimentary game for educational purposes.&nbsp; I simply want to show at random intervals of time (up to 3 seconds) 1 to all images in a 5 image array.&nbsp; The images will display at random locations within the canvas.&nbsp; The images will disappear in random intervals of time (up to 3 seconds).&nbsp; If the user clicks on an image before it disappears a running score is displayed and the image lights up with a yellow border.&nbsp; I am using CSS for class types to light up if the image is clicked.&nbsp; I can addEventListeners to the various images created and I&nbsp;set the className as appropriate.&nbsp; I use ctx = canvas.getContext(&quot;2d&quot;) and ctx.drawImage to show the image.&nbsp; The image is never getting the event.&nbsp; Any code snippet to help me out?&nbsp; Maybe I am barking up the wrong tree using Canvas?&nbsp; I am hoping the experts in the coffee house can show me the code snip for this very simple example.&nbsp; codeShow samples do not quite have the pieces for this.&nbsp; Thanks</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/f48d89d71b50476a9c09a14601374238#f48d89d71b50476a9c09a14601374238</link>
		<pubDate>Mon, 14 Jan 2013 18:53:15 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/f48d89d71b50476a9c09a14601374238#f48d89d71b50476a9c09a14601374238</guid>
		<dc:creator>123logd</dc:creator>
		<slash:comments>6</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/123logd/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
		<description><![CDATA[<p>Did you try to do a detailed post with code on StackOverflow? There's probably devs there that watch posts with tags&nbsp;with HTML5&nbsp;and Canvas. Then you're reaching a thousand devs instead of two here that might know <img src='http://ecn.channel9.msdn.com/o9/content/images/emoticons/emotion-1.gif?v=c9' alt='Smiley' /></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/a0e33e8d9ea84428a42aa146014d1edd#a0e33e8d9ea84428a42aa146014d1edd</link>
		<pubDate>Mon, 14 Jan 2013 20:12:51 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/a0e33e8d9ea84428a42aa146014d1edd#a0e33e8d9ea84428a42aa146014d1edd</guid>
		<dc:creator>Harlequin</dc:creator>
		<slash:comments>6</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Harlequin/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
		<description><![CDATA[<p>Why use a canvas? Why not use an img element and move it around with JavaScript? If these are images that you need to draw dynamically, you need to add the event handler to the canvas element, and then figure if the click coordinates are within the bounds of any of the images you drew.</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/2aaf146beae04a2c83f6a146014da7ac#2aaf146beae04a2c83f6a146014da7ac</link>
		<pubDate>Mon, 14 Jan 2013 20:14:48 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/2aaf146beae04a2c83f6a146014da7ac#2aaf146beae04a2c83f6a146014da7ac</guid>
		<dc:creator>cbae</dc:creator>
		<slash:comments>6</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/cbae/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
		<description><![CDATA[<p></p><blockquote><div class="quoteText"><p></p><p><a class="permalink" title="Post Permalink" href="/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/2aaf146beae04a2c83f6a146014da7ac">6 minutes&nbsp;ago</a>, <a href="/Niners/cbae">cbae</a> wrote</p><p>Why use a canvas? Why not use an img element and move it around with JavaScript?</p><p></p></div></blockquote><p></p><p>Indeed, when you put something on a canvas it becomes part of the canvas. No more css or onclick events. Just use a div as container with &quot;position: relative;&quot; and put img element in there with &quot;position: absolute;&quot;</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/70b9fd607eb54f43b99aa1460150db2d#70b9fd607eb54f43b99aa1460150db2d</link>
		<pubDate>Mon, 14 Jan 2013 20:26:27 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/70b9fd607eb54f43b99aa1460150db2d#70b9fd607eb54f43b99aa1460150db2d</guid>
		<dc:creator>ZippyV</dc:creator>
		<slash:comments>6</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/ZippyV/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
		<description><![CDATA[<p>Thank you.&nbsp; I will proceed without Canvas.&nbsp; So, what applications are ideal for Canvas?</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/baeff0f615a648a88d0da146016c21fd#baeff0f615a648a88d0da146016c21fd</link>
		<pubDate>Mon, 14 Jan 2013 22:05:46 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/baeff0f615a648a88d0da146016c21fd#baeff0f615a648a88d0da146016c21fd</guid>
		<dc:creator>123logd</dc:creator>
		<slash:comments>6</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/123logd/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Getting images created in a Canvas context to respond to an event</title>
		<description><![CDATA[<p>If you create a game that uses a game loop, then you're not going to responding to events on individual elements on the screen. You would simply calculate movements of the player/enemies, determine collisions, and then refresh the screen by redrawing everything. That's when you would use a canvas.</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/248364e1762f43ea9a02a146017ca6fd#248364e1762f43ea9a02a146017ca6fd</link>
		<pubDate>Mon, 14 Jan 2013 23:05:54 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/Getting-images-created-in-a-Canvas-context-to-respond-to-an-event/248364e1762f43ea9a02a146017ca6fd#248364e1762f43ea9a02a146017ca6fd</guid>
		<dc:creator>cbae</dc:creator>
		<slash:comments>6</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/cbae/Discussions/RSS</wfw:commentRss>
	</item>
</channel>
</rss>