<?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>Toxic Bakery</title>
	<atom:link href="http://www.toxicbakery.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.toxicbakery.com</link>
	<description>Where the good stuff is made</description>
	<lastBuildDate>Wed, 12 Sep 2012 14:26:54 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>Voice Command</title>
		<link>http://www.toxicbakery.com/android-applications/voice-command/</link>
		<comments>http://www.toxicbakery.com/android-applications/voice-command/#comments</comments>
		<pubDate>Wed, 12 Sep 2012 14:18:58 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Android Applications]]></category>
		<category><![CDATA[Android Development]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Launcher]]></category>
		<category><![CDATA[Voice Command]]></category>

		<guid isPermaLink="false">http://www.toxicbakery.com/?p=341</guid>
		<description><![CDATA[Voice Command sets your desktop free and keeps you out of your application drawer. I have grown extremely tired of looking for applications in different places on all my devices and the problem is multiplied on my phone where have quite a few applications installed. With Voice Command it is now possible to speak the [...]]]></description>
				<content:encoded><![CDATA[<p>Voice Command sets your desktop free and keeps you out of your application drawer. I have grown extremely tired of looking for applications in different places on all my devices and the problem is multiplied on my phone where have quite a few applications installed. With Voice Command it is now possible to speak the name of the application and launch it instantly. Additionally you can rename hard to say applications making them easier to open by voice. </p>
<blockquote><p><a href="https://play.google.com/store/apps/details?id=com.ToxicBakery.apps.voicecommand" title="Voice Command on Google Play Store">Voice Command on Google Play</a>: Open apps with your voice! Access any of your applications in seconds. Customize the names of your applications making them easier to speak. Replace endless pages of apps with a single icon, Voice Command.</p></blockquote>
<p>Voice Command is available for free on the <a href="https://play.google.com/store/apps/details?id=com.ToxicBakery.apps.voicecommand" title="Voice Command on Google Play" target="_blank">Google Play Store</a> and does not include any advertisements.</p>

<a href='http://www.toxicbakery.com/android-applications/voice-command/attachment/1/' title='Awaiting voice input.'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/09/1-150x150.jpg" class="attachment-thumbnail" alt="Awaiting voice input." /></a>
<a href='http://www.toxicbakery.com/android-applications/voice-command/attachment/2/' title='Voice search results'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/09/2-150x150.jpg" class="attachment-thumbnail" alt="Voice search results" /></a>
<a href='http://www.toxicbakery.com/android-applications/voice-command/attachment/3/' title='Voice application dictionary.'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/09/3-150x150.jpg" class="attachment-thumbnail" alt="Voice application dictionary." /></a>
<a href='http://www.toxicbakery.com/android-applications/voice-command/attachment/4/' title='Voice dictionary help.'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/09/4-150x150.jpg" class="attachment-thumbnail" alt="Voice dictionary help." /></a>
<a href='http://www.toxicbakery.com/android-applications/voice-command/attachment/5/' title='Voice dictionary application search.'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/09/5-150x150.jpg" class="attachment-thumbnail" alt="Voice dictionary application search." /></a>
<a href='http://www.toxicbakery.com/android-applications/voice-command/attachment/6/' title='Optional persistent notification for easy opening.'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/09/6-150x150.jpg" class="attachment-thumbnail" alt="Optional persistent notification for easy opening." /></a>

]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/android-applications/voice-command/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cube Complex Live Wallpaper</title>
		<link>http://www.toxicbakery.com/android-applications/cube-complex-live-wallpaper/</link>
		<comments>http://www.toxicbakery.com/android-applications/cube-complex-live-wallpaper/#comments</comments>
		<pubDate>Sat, 14 Apr 2012 16:25:35 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Android Applications]]></category>

		<guid isPermaLink="false">http://www.toxicbakery.com/?p=310</guid>
		<description><![CDATA[We just released a new wallpaper that we hope you will all enjoy. The concept of the wallpaper is a large collection of cubes spinning in space where individual cubes can slide around to new locations. Cube Complex on Google Play: Experience an always changing multi-colored background of shifting cubes that glow with light. The camera [...]]]></description>
				<content:encoded><![CDATA[<p>We just released a new wallpaper that we hope you will all enjoy. The concept of the wallpaper is a large collection of cubes spinning in space where individual cubes can slide around to new locations.</p>
<blockquote><p><a title="Cube Complex" href="https://play.google.com/store/apps/details?id=com.ToxicBakery.lwp.cubecomplex" target="_blank">Cube Complex on Google Play</a>: Experience an always changing multi-colored background of shifting cubes that glow with light. The camera and background transition to maintain a clean and unique appearance.</p></blockquote>
<p><a href="http://www.youtube.com/watch?v=ox5kH_A4TnU"><img src="http://img.youtube.com/vi/ox5kH_A4TnU/2.jpg"></a></p>
<p><a href="http://www.youtube.com/watch?v=ox5kH_A4TnU">Click here to view the video on YouTube</a>.</p>

<p>&nbsp;</p>
<div style="width: 640px;margin: 0 auto;text-align:center"><a href="http://www.toxicbakery.com/wp-content/uploads/2012/04/device-2012-04-11-204934.png" rel="wp-prettyPhoto[g310]"><img src="http://www.toxicbakery.com/wp-content/uploads/2012/04/device-2012-04-11-204934-180x300.png" alt="" title="Single Color Cubes" width="180" height="300" class="alignleft size-medium wp-image-315" /></a><a href="http://www.toxicbakery.com/wp-content/uploads/2012/04/device-2012-04-11-204249.png" rel="wp-prettyPhoto[g310]"><img src="http://www.toxicbakery.com/wp-content/uploads/2012/04/device-2012-04-11-204249-180x300.png" alt="" title="device-2012-04-11-204249" width="180" height="300" class="alignleft size-medium wp-image-314" /></a><a href="http://www.toxicbakery.com/wp-content/uploads/2012/04/device-2012-04-11-204158.png" rel="wp-prettyPhoto[g310]"><img src="http://www.toxicbakery.com/wp-content/uploads/2012/04/device-2012-04-11-204158-180x300.png" alt="" title="device-2012-04-11-204158" width="180" height="300" class="alignleft size-medium wp-image-313" /></a></div>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/android-applications/cube-complex-live-wallpaper/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Texts From Last Night Free</title>
		<link>http://www.toxicbakery.com/android-applications/texts-from-last-night-free/</link>
		<comments>http://www.toxicbakery.com/android-applications/texts-from-last-night-free/#comments</comments>
		<pubDate>Thu, 26 Jan 2012 00:57:27 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Android Applications]]></category>

		<guid isPermaLink="false">http://www.toxicbakery.com/?p=295</guid>
		<description><![CDATA[In my free time I have been working on a TFLN mobile app as I refuse to pay $0.99 for access to content that is otherwise freely provided. I&#8217;m certain others share in my dislike of spending money, so this app is for you! Anyways, due to the fact that they would probably have our [...]]]></description>
				<content:encoded><![CDATA[<p>In my free time I have been working on a TFLN mobile app as I refuse to pay $0.99 for access to content that is otherwise freely provided. I&#8217;m certain others share in my dislike of spending money, so this app is for you! Anyways, due to the fact that they would probably have our developer account beaten down by the Google copyright stick asap I am instead providing the app here instead. If you have any questions or comments, leave them below. Enjoy!</p>
<p>Android Download: <a rel="nofollow" title="Texts From Last Night mobile application for Android" href="http://www.toxicbakery.com?wp_ct=1">Texts From Last Night APK</a></p>

<a href='http://www.toxicbakery.com/android-applications/texts-from-last-night-free/attachment/tablet2/' title='TFLN Tablet Portait'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/01/tablet2-150x150.png" class="attachment-thumbnail" alt="TFLN Tablet Portait" /></a>
<a href='http://www.toxicbakery.com/android-applications/texts-from-last-night-free/attachment/tablet1/' title='TFLN Tablet Landscape'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/01/tablet1-150x150.png" class="attachment-thumbnail" alt="TFLN Tablet Landscape" /></a>
<a href='http://www.toxicbakery.com/android-applications/texts-from-last-night-free/attachment/phone1/' title='TFLN Phone Portait'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/01/phone1-150x150.png" class="attachment-thumbnail" alt="TFLN Phone Portrait" /></a>
<a href='http://www.toxicbakery.com/android-applications/texts-from-last-night-free/attachment/phone2/' title='TFLN Phone Landscape'><img width="150" height="150" src="http://www.toxicbakery.com/wp-content/uploads/2012/01/phone2-150x150.png" class="attachment-thumbnail" alt="TFLN Phone Portrait" /></a>

]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/android-applications/texts-from-last-night-free/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Froyo Lives</title>
		<link>http://www.toxicbakery.com/outside-news/froyo-lives/</link>
		<comments>http://www.toxicbakery.com/outside-news/froyo-lives/#comments</comments>
		<pubDate>Fri, 03 Jun 2011 18:29:09 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Outside News]]></category>

		<guid isPermaLink="false">http://www.toxicbakery.com/?p=277</guid>
		<description><![CDATA[A good friend of ours, Erin from Erin Creative Design, entered in the Woot shirt design derby and to show our support we present you with this shameless plug. If you have previously purchased a shirt from Woot and you like the design please show your support by voting it up.]]></description>
				<content:encoded><![CDATA[<div><div id="attachment_278" class="wp-caption alignright" style="width: 310px"><a href="http://www.toxicbakery.com/wp-content/uploads/2011/06/097d7a29-c74f-47a7-9a37-10bf54b17392.jpg" rel="wp-prettyPhoto[g277]"><img src="http://www.toxicbakery.com/wp-content/uploads/2011/06/097d7a29-c74f-47a7-9a37-10bf54b17392-300x300.jpg" alt="Froyo Lives tshirt design" title="Froyo Lives" width="300" height="300" class="size-medium wp-image-278" /></a><p class="wp-caption-text">Froyo Lives tshirt design</p></div></p>
<p>A good friend of ours, Erin from <a href="http://www.erincreativedesign.com/">Erin Creative Design</a>, entered in the Woot shirt design derby and to show our support we present you with this shameless plug.</p>
<p>If you have previously purchased a shirt from Woot and you like the design please show your support by voting it up.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/outside-news/froyo-lives/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android Bacteria &#8211; Now a Live Wallpaper</title>
		<link>http://www.toxicbakery.com/live-wallpaper/android-bacteria-now-a-live-wallpaper/</link>
		<comments>http://www.toxicbakery.com/live-wallpaper/android-bacteria-now-a-live-wallpaper/#comments</comments>
		<pubDate>Sun, 22 May 2011 21:27:50 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Live Wallpaper]]></category>
		<category><![CDATA[AndEngine]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Bacteria]]></category>
		<category><![CDATA[Canvas]]></category>
		<category><![CDATA[OpenGL]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Toxic Bakery]]></category>

		<guid isPermaLink="false">http://www.toxicbakery.com/?p=269</guid>
		<description><![CDATA[Its been a long few days to make everything work however I finally got everything transitions from canvas to OpenGL. Canvas was ideal as it was the easiest to quick develop for however for wallpapers the canvas implementation is seriously flawed. The issue is that cpu throttling directly affects canvas rendering as its not hardware [...]]]></description>
				<content:encoded><![CDATA[<div id="attachment_270" class="wp-caption alignright" style="width: 190px"><a href="http://www.toxicbakery.com/wp-content/uploads/2011/05/device1.png" rel="wp-prettyPhoto[g269]"><img src="http://www.toxicbakery.com/wp-content/uploads/2011/05/device1-180x300.png" alt="Android Bacteria Live Wallpaper" title="Android Bacteria Live Wallpaper" width="180" height="300" class="size-medium wp-image-270" /></a><p class="wp-caption-text">Android Bacteria Live Wallpaper</p></div>
<p>Its been a long few days to make everything work however I finally got everything transitions from canvas to OpenGL. Canvas was ideal as it was the easiest to quick develop for however for wallpapers the canvas implementation is seriously flawed. The issue is that cpu throttling directly affects canvas rendering as its not hardware accelerated before 3.0. Without the hardware acceleration the canvas drawing gets gets super choppy and reduced to 1-2 frames per second which is completely useless.</p>
<p>Also it may be good to note the OpenGL implementation is entirely thanks to AndEngine and a few awesome plugins that can be found on their forum. Without it, converting my code to OpenGL from canvas would have take much longer to complete.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/live-wallpaper/android-bacteria-now-a-live-wallpaper/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Android Bacteria!</title>
		<link>http://www.toxicbakery.com/live-wallpaper/android-bacteria/</link>
		<comments>http://www.toxicbakery.com/live-wallpaper/android-bacteria/#comments</comments>
		<pubDate>Mon, 16 May 2011 18:02:08 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Live Wallpaper]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Bacteria]]></category>

		<guid isPermaLink="false">http://www.toxicbakery.com/?p=251</guid>
		<description><![CDATA[We both love the stock microbes live wallpaper that comes with Android and have had the idea of making something similar that is a little more interactive. To step us apart from Microbes we are adding features such as classes of bacteria, customization to create your own bacteria, possibly invade your friends phones with your [...]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.toxicbakery.com/wp-content/uploads/2011/05/device.png" rel="wp-prettyPhoto[g251]"><img src="http://www.toxicbakery.com/wp-content/uploads/2011/05/device-180x300.png" alt="Android Bacteria" title="device" width="180" height="300" class="size-medium wp-image-252" style="float:right;margin:4px;" /></a>We both love the stock microbes live wallpaper that comes with Android and have had the idea of making something similar that is a little more interactive. To step us apart from Microbes we are adding features such as classes of bacteria, customization to create your own bacteria, possibly invade your friends phones with your bacteria and many more. Stay tuned for more details and enjoy the screen shot in the mean time.</p>
<div style="clear:both"></div>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/live-wallpaper/android-bacteria/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Help Activities And You!</title>
		<link>http://www.toxicbakery.com/android-development/help-activities-and-you/</link>
		<comments>http://www.toxicbakery.com/android-development/help-activities-and-you/#comments</comments>
		<pubDate>Fri, 04 Feb 2011 07:23:14 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Android Development]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Help Files]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Intents]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[ListView]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Web Design]]></category>
		<category><![CDATA[WebView]]></category>

		<guid isPermaLink="false">http://toxicbakery.com/?p=222</guid>
		<description><![CDATA[One of the hardest features to include in your Android applications is the help feature. The help feature aims to teach your users how to properly use your application, avoid common pitfalls and even let them know about bugs you are aware of and currently working on. Unfortunately the more information you need to shove [...]]]></description>
				<content:encoded><![CDATA[<p>One of the hardest features to include in your Android applications is the help feature. The help feature aims to teach your users how to properly use your application, avoid common pitfalls and even let them know about bugs you are aware of and currently working on. Unfortunately the more information you need to shove into the help, the more cumbersome it becomes to manage your applications help and the less likely you are to spend time keeping it current.</p>
<p>So what can we do to make our lives, the developer, a little easier while at the same time getting the user better content? The answer to all your problems is the WebView. WebViews can be created in the activity with only a few lines and are quite powerful. They can process Javascript, CSS and of course basic HTML although a lesser known feature may be the fact that from your activity you can actually communicate bidirectionally with your in page Javascript however thats a discussion for another day.<br />
<span id="more-222"></span><br />
First lets take a look at how we can break up a large help file into a few pages.</p>
<div style="width: 390px;margin: 0 auto;">
<div style="float:left;margin-right:30px;"><a href="http://toxicbakery.com/wp-content/uploads/2011/02/device.png" rel="wp-prettyPhoto[g222]"><img src="http://toxicbakery.com/wp-content/uploads/2011/02/device-180x300.png" alt="" title="device" width="180" height="300" class="alignnone size-medium wp-image-223" /></a></div>
<div style="float:left;"><a href="http://toxicbakery.com/wp-content/uploads/2011/02/device1.png" rel="wp-prettyPhoto[g222]"><img src="http://toxicbakery.com/wp-content/uploads/2011/02/device1-180x300.png" alt="" title="device1" width="180" height="300" class="alignnone size-medium wp-image-224" /></a></div>
<div style="clear:both;"></div>
</div>
<p>Here we can see a ListView of help topics on the left and a help page on the right which is actually a WebView. Now I&#8217;m not going to discuss how to build a custom ListView as that is outside the scope of this tutorial instead we are just going to focus on how do you go from a ListView to a WebView fluidly. Personally I broke this into two separate Activities as I like to keep my segments of code as small as possible and multiple files just makes me feel clean.</p>
<p>ListView Activity</p>
<pre class="brush:java">
clickListener = new OnItemClickListener() {
	@Override
	public void onItemClick(AdapterView<?> adapter, View view, int position, long id) {
		Intent myIntent = new Intent(getApplicationContext(), ActHelpWebView.class);
		myIntent.putExtra("filename", helpDisplay.get(position)[2]);
		startActivity(myIntent);
	}
};
</pre>
<p>Here we can see the listener I used for my ListView which simply launches our Activity that contains the WebView. It is also key to note that here I am passing along the data of which file to open with the Intent. This is done in my case by using a List<String[]> where the array looks like this {&#8220;icon to use&#8221;, &#8220;title&#8221;, &#8220;htmlpage&#8221;}. With this knowledge it makes sense why I am passing helpDisplay.get(position)[2] as that is the help file that the user has requested to be loaded.<br />
<!--more--></p>
<p>Now that we have passed the Intent we need to have a few things setup before we move forward. First you need to have your &#8216;mini&#8217; site ready to go. For me I just created a simple style sheet in CSS and then made a single page layout that I filled in with all my content and images. You can store all of these files in the assets directory of your application as seen below. Just a reminder, your assets folder goes into your root application directory and not into the &#8216;res&#8217; directory.</p>
<div style="width: 227px;margin: 0 auto;"><a href="http://toxicbakery.com/wp-content/uploads/2011/02/screenshot.png" rel="wp-prettyPhoto[g222]"><img src="http://toxicbakery.com/wp-content/uploads/2011/02/screenshot.png" alt="Assets help screenshot" title="Assets help screenshot" width="227" height="288" class="alignnone size-full wp-image-233" /></a></div>
<p>Now that we have the Intent and our assets ready to go lets finally make our WebView and hopefully educate our users a little better than before. To do this we need to first receive our intent, create our WebView and finally pass the file location to the WebView for processing.</p>
<pre class="brush:java">
public class ActHelpWebView extends Activity {
	
	private Context context;
	private WebView webView;
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		this.context = this;
		setupWebView();
		displayHelpPage(getIntent().getStringExtra("filename"));
	}
	
	/**
	 * Private method to launch the webview for the requested filename
	 * @param filename
	 */
	private void displayHelpPage(String filename) {
        webView.loadUrl("file:///android_asset/help/" + filename);
        setContentView(webView);
	}
	
	/**
	 * Private method to initialize our webview
	 */
	private void setupWebView() {
        webView = new WebView(context);
        webView.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT));
        webView.setBackgroundColor(color.black);
	}

}
</pre>
<p>This should launch your WebView with all the default parameters. In certain cases you may want to enable additional features such as zooming, Javascript or Activity to Javascript communication as mentioned earlier. There are a variety of ways you can further this however I believe a few Stack Overflow searches can aid you past this point.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/android-development/help-activities-and-you/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android App Stats Update</title>
		<link>http://www.toxicbakery.com/android-applications/android-app-stats-update/</link>
		<comments>http://www.toxicbakery.com/android-applications/android-app-stats-update/#comments</comments>
		<pubDate>Fri, 26 Nov 2010 07:39:31 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Android Applications]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Android Market]]></category>
		<category><![CDATA[App Stats]]></category>
		<category><![CDATA[Google Services]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Toxic Bakery]]></category>

		<guid isPermaLink="false">http://toxicbakery.com/?p=183</guid>
		<description><![CDATA[Today we have some unfortunate news to report on. Google has changed the Android Market in several ways and unfortunately one of these changes has crippled searches. All searches of the Android Market now require a valid device id which is unfortunately quite difficult to retrieve on certain devices. However on essentially all devices you [...]]]></description>
				<content:encoded><![CDATA[<div id="attachment_184" class="wp-caption alignright" style="width: 275px"><a href="http://toxicbakery.com/wp-content/uploads/2010/11/0947-e1290756769974.jpg" rel="wp-prettyPhoto[g183]"><img src="http://toxicbakery.com/wp-content/uploads/2010/11/0947-e1290756769974.jpg" alt="Android Market Image" title="Android Market" width="265" height="254" class="size-full wp-image-184" /></a><p class="wp-caption-text">Android Market</p></div>
<p>Today we have some unfortunate news to report on. Google has changed the Android Market in several ways and unfortunately one of these changes has crippled searches. All searches of the Android Market now require a valid device id which is unfortunately quite difficult to retrieve on certain devices. However on essentially all devices you must have root to even attempt the process.</p>
<p>As you may know, App Stats already includes a method of retrieving this ID for users with root on their device however this will not work for all phones. Currently we are trying to come up with work around methods to resolve this issue for everyone unfortunately it will take some time to compensate for this critical change made on Google&#8217;s end of things.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/android-applications/android-app-stats-update/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creating Email Intents In Android With Attachments</title>
		<link>http://www.toxicbakery.com/android-development/creating-emails-android/</link>
		<comments>http://www.toxicbakery.com/android-development/creating-emails-android/#comments</comments>
		<pubDate>Fri, 19 Nov 2010 20:25:13 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Android Development]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Attachments]]></category>
		<category><![CDATA[Email Intent]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[multiple attachments]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[sending attachments]]></category>

		<guid isPermaLink="false">http://toxicbakery.com/?p=168</guid>
		<description><![CDATA[If you are attempting or have attempted creating the proper email intent in Android you know its poorly documented and there are a lot of conflicted, untested and often plain wrong examples out there. That said hopefully I can clear up some of the confusion from the research I put into figuring it out. First, [...]]]></description>
				<content:encoded><![CDATA[<p>If you are attempting or have attempted creating the proper email intent in Android you know its poorly documented and there are a lot of conflicted, untested and often plain wrong examples out there. That said hopefully I can clear up some of the confusion from the research I put into figuring it out.</p>
<p>First, sending an email is actually pretty easy and I am sure from a simple Google search most developers could have an email sent in a few minutes of after copying and pasting. The trick comes from when you need to add attachments and this is what is confusing. Without making it obvious, the stock Google applications can not handle multiple attachments and the only email application, that I know of, which can handle an intent with multiple attachments is K9 email. That said, you definitely do not want to rely on the user having a specific email application.</p>
<p><span id="more-168"></span>
<p>So how do we get around this? Zip files. I hate having to use zip files when it comes to something as simple as sending a few pictures however its the only thing I could find that actually worked as intended. Using the code below you can create a class to handle file zipping. Its important to note that to send the attachment, the intents seem to need to have global access to the files. To do this you can temporarily store the zip file on your SD card by using Environment.</p>
<p>This code is thanks to an article written by <a target="blank" href="http://www.jondev.net/cv-resume">Jon Simon</a> located here <a target="blank" href="http://www.jondev.net/articles/Zipping_Files_with_Android_(Programmatically)">Zipping Files with Android</a></p>
<pre class="brush:java">
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.util.zip.ZipEntry;
import java.util.zip.ZipOutputStream;

public class Zip {
	private static final int BUFFER = 2048;

	private String[] _files;
	private String _zipFile;

	/**
	 * This class allows for the automated creation of Zip files when given a String array of file paths. 
	 * 
	 * @param files - String array containing the path of all the files to be zipped
	 * @param zipFile - The destination of the Zip file.
	 */
	public Zip(String[] files, String zipFile) {
		_files = files;
		_zipFile = zipFile;
		doZip();
	}
	 
	/**
	 * Private method to handle building a Zip file
	 */
	private void doZip() {
		try {
			BufferedInputStream origin = null;
			FileOutputStream dest = new FileOutputStream(_zipFile);

			ZipOutputStream out = new ZipOutputStream(new BufferedOutputStream(
					dest));

			byte data[] = new byte[BUFFER];

			for (int i = 0; i < _files.length; i++) {
				System.out.println("Adding: " + _files[i]);
				FileInputStream fi = new FileInputStream(_files[i]);
				origin = new BufferedInputStream(fi, BUFFER);
				ZipEntry entry = new ZipEntry(_files[i].substring(_files[i].lastIndexOf("/") + 1));
				out.putNextEntry(entry);
				int count;
				while ((count = origin.read(data, 0, BUFFER)) != -1) {
					out.write(data, 0, count);
				}
				origin.close();
			}

			out.close();
		} catch (Exception e) {
			e.printStackTrace();
		}

	}
}
</pre>
<p><!--more--></p>
<p>Okay so now that we zipped our images (or whatever you needed to zip) here is how you actually create and send an email.</p>
<pre class="brush:java">
//first zip the files
new Zip(fileStringArray, zipDestinationString);
Intent intent = new Intent(Intent.ACTION_SEND);
intent.putExtra(Intent.EXTRA_EMAIL, new String[]{"someaddress@somesite.com"});
intent.putExtra(Intent.EXTRA_SUBJECT, "Email Subject");
intent.putExtra(Intent.EXTRA_TEXT, "Email Message");
intent.setType("application/zip");
intent.putExtra(Intent.EXTRA_STREAM, Uri.parse("file://" + zipDestinationString));
startActivity(Intent.createChooser(intent, "Send Email"));
</pre>
<p>And presto, when you run that code you a chooser should pop up asking the user how they want to handle the request. For me I get the option of Bluetooth or using Gmail. As always if you feel I left something out or have  questions just leave a comment.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/android-development/creating-emails-android/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>Xinha, You Should Be Using It!</title>
		<link>http://www.toxicbakery.com/technology/xinha-you-should-be-using-it/</link>
		<comments>http://www.toxicbakery.com/technology/xinha-you-should-be-using-it/#comments</comments>
		<pubDate>Fri, 19 Nov 2010 17:39:33 +0000</pubDate>
		<dc:creator>tencent</dc:creator>
				<category><![CDATA[Tech Related]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Rich Text Editor]]></category>
		<category><![CDATA[RTE]]></category>
		<category><![CDATA[Web Design]]></category>
		<category><![CDATA[Xinha]]></category>

		<guid isPermaLink="false">http://toxicbakery.com/?p=159</guid>
		<description><![CDATA[I was recently working on a project and I needed a rich text editor for a piece of the project. All of the editors I could find functioned well however the HTML they would write was just plain wrong. Every single one I tried, other than Xinha, would place lines of text in div tags [...]]]></description>
				<content:encoded><![CDATA[<div class="wp-caption alignleft" style="width: 105px"><a href="http://trac.xinha.org/" target="blank"><img title="Rich Text Editor" src="http://trac.xinha.org/chrome/common/trac_banner.png" alt="Rich Text Editor" width="95" height="100" /></a><p class="wp-caption-text">Rich Text Editor</p></div>
<p>I was recently working on a project and I needed a rich text editor for a piece of the project. All of the editors I could find functioned well however the HTML they would write was just plain wrong. Every single one I tried, other than Xinha, would place lines of text in div tags and empty lines would be a break tag wrapped in divs. If you are SEO savvy you know that just randomly wrapping a ton of text in div tags all over your site certainly wont be helping you any and paragraphs are the way to go.</p>
<p>That in mind I finally found Xinha and creating paragraphs properly wasn&#8217;t the only thing it did well. Its over the top customizable! Best of all its easy to understand how to customize it and if you need to run multiple customizations its very easy to support that as well. Furthermore compliance was  a top priority for the Xinha team so you will find it works well across a lot browser versions. So if you need a text editor for a project, look no further.</p>
<p><a class="aligncenter" title="Xinha Rick Text Editor" href="http://trac.xinha.org/" target="_blank">Xinha Rich Text Editor</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.toxicbakery.com/technology/xinha-you-should-be-using-it/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using n/a
Database Caching 2/7 queries in 0.053 seconds using disk: basic
Object Caching 2010/2016 objects using disk: basic

 Served from: toxicbakery.com @ 2013-06-20 06:42:56 by W3 Total Cache -->