Skip to content

Instantly share code, notes, and snippets.

@TomTasche
TomTasche / gist:796504
Created January 26, 2011 10:08
OpenOffice Document Reader - File Chooser
java.lang.OutOfMemoryError: bitmap size exceeds VM budget
at android.graphics.Bitmap.nativeCreate(Native Method)
at android.graphics.Bitmap.createBitmap(Bitmap.java:468)
at android.graphics.Bitmap.createBitmap(Bitmap.java:435)
at android.graphics.Bitmap.createScaledBitmap(Bitmap.java:340)
at android.graphics.BitmapFactory.finishDecode(BitmapFactory.java:488)
at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:462)
at android.graphics.BitmapFactory.decodeResourceStream(BitmapFactory.java:323)
at android.graphics.drawable.Drawable.createFromResourceStream(Drawable.java:697)
at android.content.res.Resources.loadDrawable(Resources.java:1709)
@TomTasche
TomTasche / School going Google.
Created April 11, 2011 06:00
Theses about migrating my school to Google Apps?
So, I want to migrate my school to Google Apps. Problem is, that we're a technical school (http://translate.google.com/translate?js=n&prev=_t&hl=en&ie=UTF-8&layout=2&eotf=1&sl=auto&tl=en&u=http%3A%2F%2Fwww.htl.rennweg.at%2F) and Google Apps isn't that attractive for most of us (considering you could create your own Gmail Account within seconds...).
In order to make Google Apps more attractive, I thought about something like offers for cheaper Android phones / tablets and / or ChromeOS netbooks. Additionally, someone asked if it's possible to maintain some kind of default content set that's available for every new account (important contacts, documents, ...).
My theses would then deal with the dis- / advantages of migrating schools to Google Apps, and maybe how behavior changes when using Google-only (Android + ChromeOS + Google Apps) in classroom (how do people share documents? how do they communicate?).
What do you think? Ever done before? Interesting? Stupid? Feedback welcome. :)
Have a great day
Tom
{"id":1,"text":"Tom³ Tag","timestamp":"Apr 23, 2011 12:11:43 PM","url":"http://threetimestom.com/","author":{"id":1,"name":"Tom"}}
@TomTasche
TomTasche / uservoice_announcify.js
Created April 26, 2011 16:16
UserVoice - Announcify
<script type="text/javascript">
(function() {
var uv = document.createElement('script'); uv.type = 'text/javascript'; uv.async = true;
uv.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'widget.uservoice.com/1I1faem5ZQM8ojOSkiew.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(uv, s);
})();
</script>
<receiver android:name=".CallListener">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
<action android:name="android.intent.action.USER_PRESENT" />
</intent-filter>
</receiver>
@TomTasche
TomTasche / JUrlExpander.java
Created July 25, 2011 14:40
How To: Expand a shortened URL in Java
import java.io.IOException;
import java.net.HttpURLConnection;
import java.net.MalformedURLException;
import java.net.URL;
/**
* http://blog.tomtasche.at/2011/07/how-to-expand-shortened-url-in-java.html
*
* @author Thomas Taschauer
*
@TomTasche
TomTasche / mobfox_ads.java
Created July 28, 2011 13:35
MobFox's instructions on how to implement their ads on Android. Faulty.
MobFoxView mobfoxView = new MobFoxView(this, publisherId, test, includeLocation, boolean animation);
@TomTasche
TomTasche / bloki_integration.html
Created August 3, 2011 20:03
How To integrate Bloki with two simple lines of code
<link href="http://bloki-engine.appspot.com/style/uservoice/horizontal_red.css"
rel="stylesheet" type="text/css" />
<script language='javascript'
src='http://bloki-engine.appspot.com/submit/submit.nocache.js'
type='text/javascript'></script>
@TomTasche
TomTasche / bloki_sample.html
Created August 3, 2011 20:07
Sample Bloki integration
<html>
<head>
<title>Bloki!</title>
<!-- It's *really* important to add these two lines *before* you add your own stylesheets!
Otherwise your style will break bad -->
<link href="http://bloki-engine.appspot.com/style/uservoice/horizontal_red.css"
rel="stylesheet" type="text/css" />
<script language='javascript'
src='http://bloki-engine.appspot.com/submit/submit.nocache.js'
@TomTasche
TomTasche / GWT_native.java
Created August 6, 2011 09:45
Native methods in GWT rock! Here an example how to access the page's body.
private native Element getBody() /*-{
return document.getElementsByTagName('body')[0];
}-*/;