diff --git a/content/flash_home.html b/content/flash_home.html
index d990b55..268cbb2 100644
--- a/content/flash_home.html
+++ b/content/flash_home.html
@@ -42,6 +42,21 @@
 
 <script type='text/javascript'>
 
+function launchApp(str) {
+  window.status="umeStartApp:"+str+":"+str;
+  return str + " received";
+ }
+
+function getFlashMovie(movieName) {
+  var isIE = navigator.appName.indexOf("Microsoft") != -1;
+  return (isIE) ? window[movieName] : document[movieName];
+ }
+
+function umeEvent(name,value) {
+   var movie = getFlashMovie("themovie");
+   movie.umeEvent(name,value);
+}
+
 function getFlashFile() {
    var haveFlash = false;
    var flashVer = 0;
@@ -73,7 +88,7 @@ function getFlashFile() {
       } else if (screen.width==800 && screen.height==480) {
 	 flashFile = "flash_home_800x480.swf";
       }
-      flashDiv.innerHTML = "<embed src='" + flashFile + "' width='" + screen.width + "px' height='" + (screen.height - 52) + "px' />";
+      flashDiv.innerHTML = "<embed name='themovie'  src='" + flashFile + "' width='" + screen.width + "px' height='" + (screen.height - 52) + "px' />";
    } 
    flashDiv.style.visibility="visible";
 }
diff --git a/src/flash_home.fla b/src/flash_home.fla
index 2506a54..53caa36 100755
Binary files a/src/flash_home.fla and b/src/flash_home.fla differ
diff --git a/src/gui.as b/src/gui.as
index efc5de6..4aed367 100755
--- a/src/gui.as
+++ b/src/gui.as
@@ -1,269 +1 @@
-﻿
-// ----------------------------------------------------
-// Linux UMD/MID Flash Home Screen
-// GUI Stuffs
-// Intel Corporation
-// ----------------------------------------------------
-
-
-// GUI globals
-var conf_xml = new XML();			// configuration XML file (conf.xml)
-var b_sliding = false;				// tracks icon sliding in progress to prevent weird race conditions
-var snd_click = new Sound();		// click sound (attached in init())
-var apps = [];						// array of app launchers (icons + captions)
-var backgrounds = [];				// array of available background images specified in conf.xml
-var bg_current = 1;					// hack way of keeping track of what background is displaying (1=default)
-var my_path = "";					// path to conf.xml and support files, passed as a parameter to the SWF
-var this_build = "0.3.1";			// specific flash build 
-var launching_id = 1000				// currently loading app (not sure about the 1000, it's late)
-var num_icons_visible = 4;			// icons showing at once. 4 works, 5 is also good.  could be dynamic
-var icon_spacing = -1;				// distance between icons and to left/right of icons to edge (all equal)
-
-// debug output function
-function console(s,b_plaintext)
-{
-	mc_console.txt_console.text += s + "\n";
-	mc_console.txt_console.scroll = mc_console.txt_console.maxscroll;
-}
-
-// update the UI and load config file
-function init()
-{
-	mc_console._visible = false;
-	console("MID Flash Home - Build " + this_build);
-	console("------------------------------\n");
-	console("Starting " + dateTimeStamp());
-	
-	// get path to conf.xml and support files
-	my_url = this._url;
-	my_pos = my_url.lastIndexOf("=");
-	
-	// if a path is specified
-	if (my_pos > 0)
-	{
-		my_path = my_url.substring(my_pos+1, my_url.length);
-		console("Path = " + my_path);
-	}
-	
-	if (my_path.length > 0)
-		my_path = my_path + "/"
-	
-	snd_click.attachSound("click1"); // init click sound
-	
-	// attempt to load XML configuration file
-	conf_xml.ignoreWhite = true;
-	conf_xml.onLoad = conf_xmlloaded;
-	conf_xml.load(my_path + "conf.xml");
-	
-	icon_spacing = (Stage.width / (num_icons_visible + 1));  //space left & right, and middle
-	console("Stage dimensions: (" + Stage.height + "," + Stage.width + ")" );
-}
-
-// read XML configuration file
-function conf_xmlloaded(success) 
-{
-	if (success) 
-	{
-		// get connection settings
-		server = conf_xml.firstChild.childNodes[0].attributes.server;
-		port = conf_xml.firstChild.childNodes[0].attributes.port;
-		
-		// set background image (default)
-		mc_background.loadMovie(my_path + conf_xml.firstChild.childNodes[1].attributes.image);
-		
-		// load up additional backgrounds in case we want to switch them dynamically
-		var bgcount = conf_xml.firstChild.childNodes.length;
-		for (i = 1; i < bgcount; i++)
-		{
-			backgrounds[i] = my_path + conf_xml.firstChild.childNodes[i].attributes.image;
-		}
-		
-		// load app icons and titles
-		var total_apps = conf_xml.lastChild.childNodes.length;
-		var app_id;
-		var app_title;
-		var app_icon;
-		var xpos = 0;
-		
-		// disable slider butons if there's 4 or less apps
-		/*if (total_apps < 5)
-		{
-			btn_slider_right._alpha = 5;
-			btn_slider_right._alpha = 5;
-		}
-		*/
-		for (i = 0; i < total_apps ; i++)
-		{
-			// get app attributes
-			app_id = conf_xml.lastChild.childNodes[i].attributes.id;
-			app_title = conf_xml.lastChild.childNodes[i].attributes.title;
-			app_icon = my_path + conf_xml.lastChild.childNodes[i].attributes.icon;
-			app_path = conf_xml.lastChild.childNodes[i].attributes.path;
-			
-			// create app launcher instance and set id, title, icon
-			apps[i] = _root.mc_slider.attachMovie("app_launcher","app_launcher"+i,1000+i);
-			apps[i].app_title.text = app_title;
-			apps[i].app_title_shadow.text = app_title;
-			apps[i].mc_icon.loadMovie(app_icon);
-			apps[i].mc_progress._visible = false;
-			apps[i].launching = false;
-			
-			// set the id and title properties (vs. the above which is just for the UI)
-			apps[i].id = parseInt(app_id);
-			apps[i].title = app_title;
-			apps[i].path = app_path;
-			
-			// set launcher position
-			xpos = xpos + icon_spacing; //205;   //160 for 800 width
-			apps[i]._x = Math.round(xpos);
-		}
-
-		mc_slider._width = Math.round(icon_spacing * (total_apps ));
-		// center the slider now that we've loaded apps icons etc
-		//mc_slider._x = 390 - (mc_slider._width / 2);   //335=(160*2) for 800, 420= ~(205*2) for 1024
-		//take all the icons > num_icons_visible, split them in half, and slide over that many icons to start in the middle
-		var icons_not_shown = total_apps - num_icons_visible;
-		console("icons not shown: " + icons_not_shown);
-		if (total_apps < num_icons_visible) {
-			mc_slider._x =  Math.round(((Stage.width - ((total_apps -1) * icon_spacing)) / 2) - icon_spacing);
-			console("icons not shown: " + icons_not_shown + ", mc_slider.x: " + mc_slider._x + ", total_apps: " + total_apps + 
-					", icon_spacing: " + icon_spacing + ", " );			
-		} else {
-			mc_slider._x =  - (Math.round(icons_not_shown / 2)) * icon_spacing; //split icons, 1/2 to left, 1/2 to right
-		}
-		updateSliderButtons();  
-			
-		console("loaded " + my_path + "conf.xml");
-		mc_console._visible = false;
-		
-		// now we try to connect
-		socketConnect();
-	} 
-	else 
-	{
-		console("*** failed to load " + my_path + "conf.xml");
-	}
-}
-
-
-// background switching hack
-btn_bgswitch.onPress = function()
-{
-	if (bg_current < (backgrounds.length - 1))
-		bg_current++
-	else
-		bg_current = 1;
-	
-	console("Switching background: " + backgrounds[bg_current]);
-	mc_background.loadMovie(backgrounds[bg_current]);
-}
-
-// update the transparency of the slider button to the left/right
-function updateSliderButtons()
-{
-	//update slider buttons
-	btn_slider_left._alpha = (mc_slider._x >=0 ? 5 : 50);  //we've reached the end
-	btn_slider_right._alpha = (mc_slider._x + mc_slider._width >= Stage.width ? 50 : 5);
-	
-	console("mc_slider._x: " + mc_slider._x  + ", mc_slider._width: " + mc_slider._width + ", Stage.width: " + Stage.width);	
-}
-
-// move the slider
-function slider(dir)
-{
-	snd_click.start();
-	b_sliding = true;
-	
-	var current_x = mc_slider._x;
-	var easeType = mx.transitions.easing.Regular.easeOut;
-	var time = .7;
-	var mc = mc_slider;
-	var begin = current_x;
-	var end = current_x;
-
-	var slide_x = icon_spacing * num_icons_visible;
-	end = current_x + (dir == "right" ? (-slide_x) : slide_x);
-
-	ballTween = new mx.transitions.Tween(mc, "_x", easeType, begin, end, time, true);
-	
-	//subscribe to be notified when animation completes
-	ballTween.onMotionFinished = function() {
-		b_sliding = false;
-		updateSliderButtons();		
-	};
-}
-
-// main slider left button release
-btn_slider_right.onPress = function()
-{
-	if (b_sliding == false)	{
-		if (btn_slider_right._alpha > 5) {
-			slider("right");
-		}
-	}
-}
-
-// main slider left button release
-btn_slider_left.onPress = function()
-{
-	if (b_sliding == false)	{
-		if (btn_slider_left._alpha > 5) {
-			slider("left");
-		}
-	}
-}
-
-// launch app when icon is clicked on
-function launchApp(id)
-{
-	if (apps[id].launching == false)
-	{
-		snd_click.start();
-		console("launch '" + apps[id].title + "' (id=" + apps[id].id + ")");
-		
-		if (connected == true)
-		{
-			apps[id].mc_progress._visible = true;
-			apps[id].mc_icon._alpha = 40;
-			apps[id].launching = true;
-			//launch the app
-			socketCommand("<applaunch id=\""+ apps[id].id + "\" name=\"" + apps[id].title + "\" path=\"" + apps[id].path + "\"/>");
-			//create a 3 second delay then hide the progress icon.
-			setTimeout(hideIconProgress,3000,id);
-		}
-		else
-			console("not connected");
-	}
-}
-
-
-
-// hide app launch progress animation and run application
-function hideIconProgress(id)
-{
-	apps[id].mc_progress._visible = false;
-	apps[id].mc_icon._alpha = 100;
-	apps[id].launching = false;
-}
-
-// this is for debugging in flash using a tester socket server that sends back an app launch completion msg
-function fakelaunch()
-{
-	socketCommand("launchtest");
-}
-// -----------------------------------------------------------
-// start flash
-init()
-// toggle debug output window
-consoleListener = new Object();
-consoleListener.onKeyUp = function() {	
-		if (Key.getCode() == 16) // shift key
-		{
-			if (mc_console._visible == true)
-				mc_console._visible = false;
-			else
-				mc_console._visible = true;
-		}
-	}
-// listen for key press
-Key.addListener(consoleListener);
+﻿import flash.external.ExternalInterface;import flash.events.Event;// ----------------------------------------------------// Linux UMD/MID Flash Home Screen// GUI Stuffs// Intel Corporation// ----------------------------------------------------// GUI globalsvar conf_xml = new XML();			// configuration XML file (conf.xml)var b_sliding = false;				// tracks icon sliding in progress to prevent weird race conditionsvar snd_click = new Sound();		// click sound (attached in init())var apps = [];						// array of app launchers (icons + captions)var backgrounds = [];				// array of available background images specified in conf.xmlvar bg_current = 1;					// hack way of keeping track of what background is displaying (1=default)var my_path = "";					// path to conf.xml and support files, passed as a parameter to the SWFvar this_build = "0.3.1";			// specific flash build var launching_id = 1000				// currently loading app (not sure about the 1000, it's late)var num_icons_visible = 4;			// icons showing at once. 4 works, 5 is also good.  could be dynamicvar icon_spacing = -1;				// distance between icons and to left/right of icons to edge (all equal)function umeEvent(p_name:String, p_value:String):Void { console("Got text from Javascript " + p_name);}ExternalInterface.addCallback("umeEvent", this, umeEvent);// debug output functionfunction console(s,b_plaintext){	mc_console.txt_console.text += s + "\n";	mc_console.txt_console.scroll = mc_console.txt_console.maxscroll;}// update the UI and load config filefunction init(){	mc_console._visible = false;	console("MID Flash Home - Build " + this_build);	console("------------------------------\n");	console("Starting " + dateTimeStamp());		// get path to conf.xml and support files	my_url = this._url;	my_pos = my_url.lastIndexOf("=");		// if a path is specified	if (my_pos > 0)	{		my_path = my_url.substring(my_pos+1, my_url.length);		console("Path = " + my_path);	}		if (my_path.length > 0)		my_path = my_path + "/"		snd_click.attachSound("click1"); // init click sound		// attempt to load XML configuration file	conf_xml.ignoreWhite = true;	conf_xml.onLoad = conf_xmlloaded;	conf_xml.load(my_path + "conf.xml");		icon_spacing = (Stage.width / (num_icons_visible + 1));  //space left & right, and middle	console("Stage dimensions: (" + Stage.height + "," + Stage.width + ")" );}// read XML configuration filefunction conf_xmlloaded(success) {	if (success) 	{		// get connection settings		server = conf_xml.firstChild.childNodes[0].attributes.server;		port = conf_xml.firstChild.childNodes[0].attributes.port;				// set background image (default)		mc_background.loadMovie(my_path + conf_xml.firstChild.childNodes[1].attributes.image);				// load up additional backgrounds in case we want to switch them dynamically		var bgcount = conf_xml.firstChild.childNodes.length;		for (i = 1; i < bgcount; i++)		{			backgrounds[i] = my_path + conf_xml.firstChild.childNodes[i].attributes.image;		}				// load app icons and titles		var total_apps = conf_xml.lastChild.childNodes.length;		var app_id;		var app_title;		var app_icon;		var xpos = 0;				// disable slider butons if there's 4 or less apps		/*if (total_apps < 5)		{			btn_slider_right._alpha = 5;			btn_slider_right._alpha = 5;		}		*/		for (i = 0; i < total_apps ; i++)		{			// get app attributes			app_id = conf_xml.lastChild.childNodes[i].attributes.id;			app_title = conf_xml.lastChild.childNodes[i].attributes.title;			app_icon = my_path + conf_xml.lastChild.childNodes[i].attributes.icon;			app_path = conf_xml.lastChild.childNodes[i].attributes.path;						// create app launcher instance and set id, title, icon			apps[i] = _root.mc_slider.attachMovie("app_launcher","app_launcher"+i,1000+i);			apps[i].app_title.text = app_title;			apps[i].app_title_shadow.text = app_title;			apps[i].mc_icon.loadMovie(app_icon);			apps[i].mc_progress._visible = false;			apps[i].launching = false;						// set the id and title properties (vs. the above which is just for the UI)			apps[i].id = parseInt(app_id);			apps[i].title = app_title;			apps[i].path = app_path;						// set launcher position			xpos = xpos + icon_spacing; //205;   //160 for 800 width			apps[i]._x = Math.round(xpos);		}		mc_slider._width = Math.round(icon_spacing * (total_apps ));		// center the slider now that we've loaded apps icons etc		//mc_slider._x = 390 - (mc_slider._width / 2);   //335=(160*2) for 800, 420= ~(205*2) for 1024		//take all the icons > num_icons_visible, split them in half, and slide over that many icons to start in the middle		var icons_not_shown = total_apps - num_icons_visible;		console("icons not shown: " + icons_not_shown);		if (total_apps < num_icons_visible) {			mc_slider._x =  Math.round(((Stage.width - ((total_apps -1) * icon_spacing)) / 2) - icon_spacing);			console("icons not shown: " + icons_not_shown + ", mc_slider.x: " + mc_slider._x + ", total_apps: " + total_apps + 					", icon_spacing: " + icon_spacing + ", " );					} else {			mc_slider._x =  - (Math.round(icons_not_shown / 2)) * icon_spacing; //split icons, 1/2 to left, 1/2 to right		}		updateSliderButtons();  					console("loaded " + my_path + "conf.xml");		mc_console._visible = false;	} 	else 	{		console("*** failed to load " + my_path + "conf.xml");	}}// background switching hackbtn_bgswitch.onPress = function(){	if (bg_current < (backgrounds.length - 1))		bg_current++	else		bg_current = 1;		console("Switching background: " + backgrounds[bg_current]);	mc_background.loadMovie(backgrounds[bg_current]);}// update the transparency of the slider button to the left/rightfunction updateSliderButtons(){	//update slider buttons	btn_slider_left._alpha = (mc_slider._x >=0 ? 5 : 50);  //we've reached the end	btn_slider_right._alpha = (mc_slider._x + mc_slider._width >= Stage.width ? 50 : 5);		console("mc_slider._x: " + mc_slider._x  + ", mc_slider._width: " + mc_slider._width + ", Stage.width: " + Stage.width);	}// move the sliderfunction slider(dir){	snd_click.start();	b_sliding = true;		var current_x = mc_slider._x;	var easeType = mx.transitions.easing.Regular.easeOut;	var time = .7;	var mc = mc_slider;	var begin = current_x;	var end = current_x;	var slide_x = icon_spacing * num_icons_visible;	end = current_x + (dir == "right" ? (-slide_x) : slide_x);	ballTween = new mx.transitions.Tween(mc, "_x", easeType, begin, end, time, true);		//subscribe to be notified when animation completes	ballTween.onMotionFinished = function() {		b_sliding = false;		updateSliderButtons();			};}// main slider left button releasebtn_slider_right.onPress = function(){	if (b_sliding == false)	{		if (btn_slider_right._alpha > 5) {			slider("right");		}	}}// main slider left button releasebtn_slider_left.onPress = function(){	if (b_sliding == false)	{		if (btn_slider_left._alpha > 5) {			slider("left");		}	}}// launch app when icon is clicked onfunction launchApp(id){	if (apps[id].launching == false)	{		snd_click.start();		console("launch '" + apps[id].title + "' (id=" + apps[id].id + ")");				apps[id].mc_progress._visible = true;		apps[id].mc_icon._alpha = 40;		apps[id].launching = true;		var appName:String = apps[id].path;		var className:String = "test"; 		var result:Object = ExternalInterface.call("launchApp", appName, className);		//create a 3 second delay then hide the progress icon.		setTimeout(hideIconProgress,3000,id);	}}// hide app launch progress animation and run applicationfunction hideIconProgress(id){	apps[id].mc_progress._visible = false;	apps[id].mc_icon._alpha = 100;	apps[id].launching = false;}// this is for debugging in flash using a tester socket server that sends back an app launch completion msgfunction fakelaunch(){	socketCommand("launchtest");}// -----------------------------------------------------------// start flashinit()// toggle debug output windowconsoleListener = new Object();consoleListener.onKeyUp = function() {			if (Key.getCode() == 16) // shift key		{			if (mc_console._visible == true)				mc_console._visible = false;			else				mc_console._visible = true;		}	}// listen for key pressKey.addListener(consoleListener);
\ No newline at end of file
diff --git a/src/mobile-basic-home-plugin.cpp b/src/mobile-basic-home-plugin.cpp
index 9624f89..a6f0b0b 100644
--- a/src/mobile-basic-home-plugin.cpp
+++ b/src/mobile-basic-home-plugin.cpp
@@ -9,8 +9,9 @@
  * Copyright 2007 Intel Corporation
  *
  * Contributors:
+ * Michael Frey <michael.frey@pepper.com>
  * Rusty Lynch <rusty.lynch@intel.com>
- *
+ * 
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public License
  * version 2.1 as published by the Free Software Foundation.
@@ -27,6 +28,15 @@
  *
  */
 
+#include <errno.h>
+#include <sys/resource.h>
+#include <string.h>
+#include <fcntl.h>
+#include <unistd.h>
+
+#include <glib.h>
+#include <glib/gstdio.h>
+#include <glib/gi18n.h>
 #include <gtk/gtk.h>
 #include <glib-object.h>
 #include <string.h>
@@ -48,27 +58,161 @@
 
 HD_DEFINE_PLUGIN (MobileBasicHomePlugin, mobile_basic_home_plugin, HILDON_DESKTOP_TYPE_HOME_ITEM);
 
+static GtkWidget *mozembed = gtk_moz_embed_new();
+
+
+static gboolean umeEvent(ue_event *event)
+{
+
+  //g_print("call javascript\n");
+  gtk_moz_embed_load_url(GTK_MOZ_EMBED(mozembed), g_strdup_printf("javascript:umeEvent('%s','%s')",event->name, event->value));
+  
+  return FALSE;
+}
+
+gpointer home_main_loop(gpointer arg)
+{
+  ue_event event;
+
+  strcpy(event.name,"test");
+  strcpy(event.value,"test");
+
+  while (1) {
+    sleep (15);
+    g_idle_add((GSourceFunc)umeEvent, &event);
+  }
+  
+  return (NULL);
+}
+
+static void umeStartApp(gchar *app_name, gchar *class_name) 
+{
+  gchar *program = NULL;
+  GError *error = NULL;
+
+  program = g_find_program_in_path (app_name);
+  g_print("launchApp from home plugin %s\n", app_name);
+
+  if (program)
+    {
+      gint argc;
+      gchar **argv;
+      GPid child_pid;
+      
+      if (g_shell_parse_argv (program, &argc, &argv, &error))
+        {
+          g_spawn_async (
+                         /* Child's current working directory,
+                            or NULL to inherit parent's */
+                         NULL,
+                         /* Child's argument vector. [0] is the path of
+                            the program to execute */
+                         argv,
+                         /* Child's environment, or NULL to inherit
+                            parent's */
+                         NULL,
+                         /* Flags from GSpawnFlags */
+                         (GSpawnFlags)0,
+                         /* Function to run in the child just before
+                            exec() */
+                         NULL,
+                         /* User data for child_setup */
+                         NULL,
+                         /* Return location for child process ID or NULL */
+                         &child_pid,
+                         /* Return location for error */
+                         &error);
+        }
+      
+      if (error)
+        {
+          g_warning ("Others_menu_activate_app: failed to execute %s: %s.",
+                     program, error->message);
+          
+          g_clear_error (&error);
+        }
+      else
+        {
+          int priority;
+          errno = 0;
+          gchar *oom_filename;
+          int fd;
+          
+          /* If the child process inherited desktop's high priority,
+           * give child default priority */
+          priority = getpriority (PRIO_PROCESS, child_pid);
+          
+          if (!errno && priority < 0)
+            {
+              setpriority (PRIO_PROCESS, child_pid, 0);
+            }
+          
+          /* Unprotect from OOM */
+          oom_filename = g_strdup_printf ("/proc/%i/oom_adj",
+                                          child_pid);
+          fd = open (oom_filename, O_WRONLY);
+          g_free (oom_filename);
+          
+          if (fd >= 0)
+            {
+              write (fd, "0", sizeof (char));
+              close (fd);
+            }
+          
+        }
+      
+     }
+}
+
+void
+js_status_cb (GtkMozEmbed *embed)
+{
+ char *message;
+ gchar** tokens;
+
+ message = gtk_moz_embed_get_js_status(embed);
+  if (message) {
+    //g_print("js_status_cb %s\n", message);
+    tokens = g_strsplit(message, ":", 0);
+    if (tokens[0] != NULL) {
+      if (g_ascii_strncasecmp(tokens[0],"umeStartApp", 9) == 0) {
+        umeStartApp(tokens[1], tokens[2]);
+      }
+    }
+    g_free(message);
+  }
+}
+
 static void
 mobile_basic_home_plugin_init (MobileBasicHomePlugin *home_plugin)
 {
-	gtk_moz_embed_set_profile_path(PROFILE_DIR, PROFILE_NAME);
-	GtkWidget *mozembed = gtk_moz_embed_new();
-
-	//auto-size flash for screen size
-	int scn_width = 800;
-	int scn_height = 480;
-	GdkScreen *screen = gtk_widget_get_screen ((GtkWidget*)home_plugin);
-	if (screen != NULL) {
-	   scn_width = gdk_screen_get_width(screen);
-	   scn_height = gdk_screen_get_height(screen);
-	}
-	gtk_widget_set_size_request ((GtkWidget*)home_plugin, scn_width, scn_height-MARQUEE_HEIGHT);
+  pthread_t threads;
+  gtk_moz_embed_set_profile_path(PROFILE_DIR, PROFILE_NAME);
+  
+  //auto-size flash for screen size
+  int scn_width = 800;
+  int scn_height = 480;
+  GdkScreen *screen = gtk_widget_get_screen ((GtkWidget*)home_plugin);
+  if (screen != NULL) {
+    scn_width = gdk_screen_get_width(screen);
+    scn_height = gdk_screen_get_height(screen);
+  }
+  //g_print("Screen width = %d\n", scn_width);
+  //g_print("Screen height = %d\n", scn_height);
+  gtk_widget_set_size_request ((GtkWidget*)home_plugin, scn_width, scn_height-MARQUEE_HEIGHT);
+
+  //load html file which auto-loads correct .swf file for screen and shows error if no flash plugin
+  gtk_moz_embed_load_url(GTK_MOZ_EMBED(mozembed), g_strdup_printf("%s/%s", PROFILE_DIR, FLASH_HTML));
+  
+  gtk_widget_show_all ((GtkWidget*)mozembed);
+  gtk_container_add (GTK_CONTAINER (home_plugin), mozembed);
+  gtk_signal_connect(GTK_OBJECT(mozembed), "js_status",
+		     GTK_SIGNAL_FUNC(js_status_cb), NULL);
+  
+	
+  g_thread_create(home_main_loop, NULL, FALSE, NULL);
+  //pthread_create(&threads, NULL, home_main_loop, NULL);
 	
-	//load html file which auto-loads correct .swf file for screen and shows error if no flash plugin
-	gtk_moz_embed_load_url(GTK_MOZ_EMBED(mozembed), g_strdup_printf("%s/%s", PROFILE_DIR, FLASH_HTML));
-			
-	gtk_widget_show_all ((GtkWidget*)mozembed);
-	gtk_container_add (GTK_CONTAINER (home_plugin), mozembed);
 }
 
 static void
@@ -76,6 +220,7 @@ mobile_basic_home_plugin_class_init (MobileBasicHomePluginClass *klass)
 {
 }
 
+
 /* WTF? */
 }}
 
diff --git a/src/mobile-basic-home-plugin.h b/src/mobile-basic-home-plugin.h
index c80ac45..d3df5ad 100644
--- a/src/mobile-basic-home-plugin.h
+++ b/src/mobile-basic-home-plugin.h
@@ -9,6 +9,7 @@
  * Copyright 2007 Intel Corporation
  *
  * Contributors:
+ * Michael Frey <michael.frey@pepper.com>
  * Rusty Lynch <rusty.lynch@intel.com>
  *
  * This library is free software; you can redistribute it and/or
@@ -35,6 +36,12 @@ G_BEGIN_DECLS
 
 #include <libhildondesktop/hildon-desktop-home-item.h>
 
+typedef struct {
+  gchar name[100];
+  gchar value[100];
+} ue_event;
+
+
 typedef struct _MobileBasicHomePlugin MobileBasicHomePlugin;
 typedef struct _MobileBasicHomePluginClass MobileBasicHomePluginClass;
 typedef struct _MobileBasicHomePluginPrivate MobileBasicHomePluginPrivate;
