title: Sony Small App SDK
body: <p>So i've just started to use the new Sony Xperia Tablet S Small App SDK. I'm no realy noob, developed many personal apps before but this has got me stumped.</p>
  
  <p>I've loaded up the Sample project in Eclipse (all correctly configured), sorted some of the errors out, compiled to my device and when I launch the Small App from the launcher at the bottom of the device, it force closes - it's the same with every sample/app that I tried making with the SDK.</p>
  
  <p>I'm attached below my MainApplication.java and AndroidManifest.xml in the hope that someone may be able to see where the issue lies. Don't understand as it's created as per the book. Any help really is appreciated please.</p>
  
  <p>MainApplication.java:</p>
  
  <pre><code>package com.sony.thirdtest;
  
  import android.content.pm.ActivityInfo;
  import android.content.res.Configuration;
  import android.view.View;
  import android.widget.Toast;
  import com.small.sonyapptest.R;
  import com.sony.smallapp.SmallAppWindow;
  import com.sony.smallapp.SmallApplication;
  
  public class MainApplication extends SmallApplication {
      private Configuration mConfig;
  
      @Override
      public void onCreate() {
          super.onCreate();
          mConfig = new Configuration(getResources().getConfiguration());
  
          setContentView(R.layout.activity_main);
          setTitle(R.string.app_name);
  
          SmallAppWindow.Attributes attr = getWindow().getAttributes();
          attr.minWidth = 200;
          attr.minHeight = 200;
          attr.width = 400;
          attr.height = 300;
          attr.flags |= SmallAppWindow.Attributes.FLAG_RESIZABLE;
          getWindow().setAttributes(attr);
  
          findViewById(R.id.button).setOnClickListener(new View.OnClickListener() {
              @Override
              public void onClick(View v) {
                  Toast.makeText(MainApplication.this, R.string.hello, Toast.LENGTH_SHORT).show();
              }
          });
      }
  
      @Override
      public void onDestroy() {
          super.onDestroy();
      }
  
      @Override
      public void onStart() {
          super.onStart();
      }
  
      @Override
      public void onStop() {
          super.onStop();
      }
  
      @Override
      protected boolean onSmallAppConfigurationChanged(Configuration newConfig) {
          int diff = newConfig.diff(mConfig);
          mConfig = new Configuration(getResources().getConfiguration());
          // Avoid application from restarting when orientation changed
          if ((diff &amp; ActivityInfo.CONFIG_ORIENTATION) != 0) {
              return true;
          }
          return super.onSmallAppConfigurationChanged(newConfig);
      }
  }
  </code></pre>
  
  <p>AndroidManifest.xml</p>
  
  <pre><code>&lt;manifest xmlns:android="http://schemas.android.com/apk/res/android" 
      package="com.small.sonyapptest" 
      android:versionCode="1" 
      android:versionName="1.0"&gt;
    &lt;uses-sdk android:minSdkVersion="15" /&gt; 
  
  
      &lt;uses-permission android:name="com.sony.smallapp.permission.SMALLAPP" /&gt;
  
      &lt;application android:icon="@drawable/ic_launcher" android:label="@string/app_name"&gt;
  
  
          &lt;uses-library android:name="com.sony.smallapp.framework" /&gt;
  
              &lt;service 
                  android:name="com.small.sonyapptest.MainApplication" 
                  android:exported="true" &gt;
  
              &lt;intent-filter&gt;
  
                  &lt;action android:name="com.sony.smallapp.intent.action.MAIN" /&gt;
  
                  &lt;category
  
                  android:name="com.sony.smallapp.intent.category.LAUNCHER" /&gt;
  
                  &lt;/intent-filter&gt;
  
              &lt;/service&gt;
  
      &lt;/application&gt;
  &lt;/manifest&gt;
  </code></pre>